@intlayer/backend 7.5.12 → 7.5.14
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/assets/utils/AI/askDocQuestion/embeddings/blog/en/per-component_vs_centralized_i18n.json +6158 -0
- package/dist/assets/utils/AI/askDocQuestion/embeddings/frequent_questions/en/error-vite-env-only.json +2054 -0
- package/dist/esm/controllers/ai.controller.mjs.map +1 -1
- package/dist/esm/controllers/bitbucket.controller.mjs.map +1 -1
- package/dist/esm/controllers/dictionary.controller.mjs.map +1 -1
- package/dist/esm/controllers/eventListener.controller.mjs.map +1 -1
- package/dist/esm/controllers/github.controller.mjs.map +1 -1
- package/dist/esm/controllers/gitlab.controller.mjs.map +1 -1
- package/dist/esm/controllers/project.controller.mjs.map +1 -1
- package/dist/esm/controllers/stripe.controller.mjs.map +1 -1
- package/dist/esm/controllers/tag.controller.mjs.map +1 -1
- package/dist/esm/controllers/user.controller.mjs.map +1 -1
- package/dist/esm/emails/InviteUserEmail.mjs.map +1 -1
- package/dist/esm/emails/MagicLinkEmail.mjs.map +1 -1
- package/dist/esm/emails/OAuthTokenCreatedEmail.mjs.map +1 -1
- package/dist/esm/emails/PasswordChangeConfirmation.mjs.map +1 -1
- package/dist/esm/emails/ResetUserPassword.mjs.map +1 -1
- package/dist/esm/emails/SubscriptionPaymentCancellation.mjs.map +1 -1
- package/dist/esm/emails/SubscriptionPaymentError.mjs.map +1 -1
- package/dist/esm/emails/SubscriptionPaymentSuccess.mjs.map +1 -1
- package/dist/esm/emails/ValidateUserEmail.mjs.map +1 -1
- package/dist/esm/emails/Welcome.mjs.map +1 -1
- package/dist/esm/index.mjs.map +1 -1
- package/dist/esm/services/bitbucket.service.mjs.map +1 -1
- package/dist/esm/services/github.service.mjs.map +1 -1
- package/dist/esm/services/gitlab.service.mjs.map +1 -1
- package/dist/esm/services/oAuth2.service.mjs.map +1 -1
- package/dist/esm/services/projectAccessKey.service.mjs.map +1 -1
- package/dist/esm/services/subscription.service.mjs.map +1 -1
- package/dist/esm/services/user.service.mjs.map +1 -1
- package/dist/esm/services/webhook.service.mjs.map +1 -1
- package/dist/esm/utils/AI/askDocQuestion/askDocQuestion.mjs.map +1 -1
- package/dist/esm/utils/AI/askDocQuestion/embeddings/blog/en/per-component_vs_centralized_i18n.json +6158 -0
- package/dist/esm/utils/AI/askDocQuestion/embeddings/frequent_questions/en/error-vite-env-only.json +2054 -0
- package/dist/esm/utils/AI/askDocQuestion/indexMarkdownFiles.mjs.map +1 -1
- package/dist/esm/utils/AI/auditDictionary/index.mjs.map +1 -1
- package/dist/esm/utils/AI/auditDictionaryField/index.mjs.map +1 -1
- package/dist/esm/utils/AI/auditDictionaryMetadata/index.mjs.map +1 -1
- package/dist/esm/utils/AI/auditTag/index.mjs.map +1 -1
- package/dist/esm/utils/AI/autocomplete/index.mjs.map +1 -1
- package/dist/esm/utils/AI/customQuery/index.mjs.map +1 -1
- package/dist/esm/utils/AI/translateJSON/index.mjs.map +1 -1
- package/dist/esm/utils/accessControl.mjs.map +1 -1
- package/dist/esm/utils/auth/getAuth.mjs.map +1 -1
- package/dist/esm/utils/cors.mjs.map +1 -1
- package/dist/esm/utils/ensureArrayQueryFilter.mjs.map +1 -1
- package/dist/esm/utils/ensureMongoDocumentToObject.mjs.map +1 -1
- package/dist/esm/utils/filtersAndPagination/getDictionaryFiltersAndPagination.mjs.map +1 -1
- package/dist/esm/utils/filtersAndPagination/getDiscussionFiltersAndPagination.mjs.map +1 -1
- package/dist/esm/utils/filtersAndPagination/getOrganizationFiltersAndPagination.mjs.map +1 -1
- package/dist/esm/utils/filtersAndPagination/getProjectFiltersAndPagination.mjs.map +1 -1
- package/dist/esm/utils/filtersAndPagination/getTagFiltersAndPagination.mjs.map +1 -1
- package/dist/esm/utils/filtersAndPagination/getUserFiltersAndPagination.mjs.map +1 -1
- package/dist/esm/utils/mongoDB/connectDB.mjs.map +1 -1
- package/dist/esm/utils/oAuth2.mjs.map +1 -1
- package/dist/esm/utils/permissions.mjs.map +1 -1
- package/dist/esm/utils/plan.mjs.map +1 -1
- package/dist/esm/utils/rateLimiter.mjs.map +1 -1
- package/dist/esm/utils/validation/validateArray.mjs.map +1 -1
- package/dist/esm/utils/validation/validateDictionary.mjs.map +1 -1
- package/dist/esm/utils/validation/validateOrganization.mjs.map +1 -1
- package/dist/esm/utils/validation/validateProject.mjs.map +1 -1
- package/dist/esm/utils/validation/validateString.mjs.map +1 -1
- package/dist/esm/utils/validation/validateTag.mjs.map +1 -1
- package/dist/esm/utils/validation/validateUser.mjs.map +1 -1
- package/dist/esm/webhooks/stripe.webhook.mjs.map +1 -1
- package/dist/types/controllers/ai.controller.d.ts.map +1 -1
- package/dist/types/controllers/gitlab.controller.d.ts.map +1 -1
- package/dist/types/emails/InviteUserEmail.d.ts +4 -4
- package/dist/types/emails/InviteUserEmail.d.ts.map +1 -1
- package/dist/types/emails/MagicLinkEmail.d.ts +4 -4
- package/dist/types/emails/OAuthTokenCreatedEmail.d.ts +4 -4
- package/dist/types/emails/PasswordChangeConfirmation.d.ts +4 -4
- package/dist/types/emails/ResetUserPassword.d.ts +4 -4
- package/dist/types/emails/SubscriptionPaymentCancellation.d.ts +4 -4
- package/dist/types/emails/SubscriptionPaymentError.d.ts +4 -4
- package/dist/types/emails/SubscriptionPaymentError.d.ts.map +1 -1
- package/dist/types/emails/SubscriptionPaymentSuccess.d.ts +4 -4
- package/dist/types/emails/ValidateUserEmail.d.ts +4 -4
- package/dist/types/emails/Welcome.d.ts +4 -4
- package/dist/types/models/dictionary.model.d.ts +4 -4
- package/dist/types/models/discussion.model.d.ts +3 -3
- package/dist/types/models/oAuth2.model.d.ts +3 -3
- package/dist/types/schemas/dictionary.schema.d.ts +6 -6
- package/dist/types/schemas/discussion.schema.d.ts +6 -6
- package/dist/types/schemas/oAuth2.schema.d.ts +5 -5
- package/dist/types/schemas/organization.schema.d.ts +6 -6
- package/dist/types/schemas/plans.schema.d.ts +6 -6
- package/dist/types/schemas/plans.schema.d.ts.map +1 -1
- package/dist/types/schemas/project.schema.d.ts +6 -6
- package/dist/types/schemas/project.schema.d.ts.map +1 -1
- package/dist/types/schemas/session.schema.d.ts +6 -6
- package/dist/types/schemas/tag.schema.d.ts +6 -6
- package/dist/types/schemas/user.schema.d.ts +6 -6
- package/dist/types/schemas/user.schema.d.ts.map +1 -1
- package/dist/types/utils/filtersAndPagination/getDictionaryFiltersAndPagination.d.ts +2 -2
- package/dist/types/utils/filtersAndPagination/getDiscussionFiltersAndPagination.d.ts +2 -2
- package/dist/types/utils/filtersAndPagination/getOrganizationFiltersAndPagination.d.ts +2 -2
- package/dist/types/utils/filtersAndPagination/getTagFiltersAndPagination.d.ts +2 -2
- package/package.json +20 -20
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PasswordChangeConfirmation.mjs","names":[
|
|
1
|
+
{"version":3,"file":"PasswordChangeConfirmation.mjs","names":[],"sources":["../../../src/emails/PasswordChangeConfirmation.tsx"],"sourcesContent":["import {\n Body,\n Container,\n Head,\n Heading,\n Hr,\n Html,\n Img,\n Preview,\n Section,\n Tailwind,\n Text,\n} from '@react-email/components';\n\nexport type PasswordChangeConfirmationEmailProps = {\n username: string;\n};\n\nexport const PasswordChangeConfirmationEmailEN = ({\n username,\n}: PasswordChangeConfirmationEmailProps) => {\n const previewText = `Your Intlayer password has been changed`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Your password has been changed\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hello {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n This email is to confirm that your password for your{' '}\n <strong>Intlayer</strong> account has been successfully changed.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n If you did not make this change or believe an unauthorized person\n has accessed your account, please contact us immediately by\n replying to this email.\n </Text>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n If you have any questions or need further assistance, feel free to\n reach out to us. We're here to help!\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const PasswordChangeConfirmationEmailFR = ({\n username,\n}: PasswordChangeConfirmationEmailProps) => {\n const previewText = `Votre mot de passe Intlayer a été modifié`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Votre mot de passe a été modifié\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Bonjour {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Cet email confirme que votre mot de passe pour votre compte{' '}\n <strong>Intlayer</strong> a été changé avec succès.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Si vous n'avez pas effectué ce changement ou si vous pensez qu'une\n personne non autorisée a accédé à votre compte, veuillez nous\n contacter immédiatement en répondant à cet email.\n </Text>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Si vous avez des questions ou avez besoin d'assistance\n supplémentaire, n'hésitez pas à nous contacter. Nous sommes là\n pour vous aider !\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const PasswordChangeConfirmationEmailES = ({\n username,\n}: PasswordChangeConfirmationEmailProps) => {\n const previewText = `Tu contraseña de Intlayer ha sido cambiada`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Tu contraseña ha sido cambiada\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hola {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Este correo es para confirmar que la contraseña de tu cuenta en{' '}\n <strong>Intlayer</strong> ha sido cambiada exitosamente.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Si no realizaste este cambio o crees que una persona no autorizada\n ha accedido a tu cuenta, por favor contáctanos inmediatamente\n respondiendo a este correo electrónico.\n </Text>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Si tienes alguna pregunta o necesitas asistencia adicional, no\n dudes en ponerte en contacto con nosotros. ¡Estamos aquí para\n ayudarte!\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nconst PreviewProps: PasswordChangeConfirmationEmailProps = {\n username: 'alanturing',\n};\n\nPasswordChangeConfirmationEmailEN.PreviewProps = PreviewProps;\nPasswordChangeConfirmationEmailFR.PreviewProps = PreviewProps;\nPasswordChangeConfirmationEmailES.PreviewPro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C,SAAO;EACR,oBAAC,qBALe,+CAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,oBAAC;MAAQ,WAAU;gBAAoE;OAE7E;KACV,qBAAC;MAAK,WAAU;;OAAwC;OAChD;OAAS;;OACV;KACP,qBAAC;MAAK,WAAU;;OAAwC;OACU;OAChE,oBAAC,sBAAO,aAAiB;;;OACpB;KACP,oBAAC;MAAK,WAAU;gBAAwC;OAIjD;KACP,oBAAC,MAAG,WAAU,+DAA+D;KAC7E,oBAAC;MAAK,WAAU;gBAA4C;OAIrD;;KACG;IACP,GACE;KACN;;AAIX,MAAM,eAAqD,EACzD,UAAU,cACX;AAED,kCAAkC,eAAe;AACjD,kCAAkC,eAAe;AACjD,kCAAkC,eAAe"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ResetUserPassword.mjs","names":["PreviewProps: ResetPasswordEmailProps"],"sources":["../../../src/emails/ResetUserPassword.tsx"],"sourcesContent":["import {\n Body,\n Button,\n Container,\n Head,\n Heading,\n Hr,\n Html,\n Img,\n Link,\n Preview,\n Section,\n Tailwind,\n Text,\n} from '@react-email/components';\n\nexport type ResetPasswordEmailProps = {\n username: string;\n resetLink: string;\n};\n\nexport const ResetPasswordEmailEN = ({\n username,\n resetLink,\n}: ResetPasswordEmailProps) => {\n const previewText = `Reset your password for Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Reset your password for <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hello {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n We received a request to reset your password for your{' '}\n <strong>Intlayer</strong> account.\n </Text>\n\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={resetLink}\n >\n Reset Password\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n or copy and paste this URL into your browser:\n </Text>\n <Link\n href={resetLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {resetLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n This password reset request was intended for{' '}\n <span className=\"text-black\">{username}</span>. If you did not\n request a password reset, you can ignore this email. If you are\n concerned about your account's safety, please reply to this email\n to get in touch with us.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const ResetPasswordEmailFR = ({\n username,\n resetLink,\n}: ResetPasswordEmailProps) => {\n const previewText = `Réinitialisez votre mot de passe pour Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Réinitialisez votre mot de passe pour <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Bonjour {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Nous avons reçu une demande de réinitialisation de votre mot de\n passe pour votre compte <strong>Intlayer</strong>.\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={resetLink}\n >\n Réinitialiser le mot de passe\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n ou copiez et collez cette URL dans votre navigateur :\n </Text>\n <Link\n href={resetLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {resetLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Cette demande de réinitialisation de mot de passe était destinée à{' '}\n <span className=\"text-black\">{username}</span>. Si vous n'avez pas\n demandé une réinitialisation de mot de passe, vous pouvez ignorer\n cet email. Si vous êtes préoccupé par la sécurité de votre compte,\n veuillez répondre à cet email pour nous contacter.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const ResetPasswordEmailES = ({\n username,\n resetLink,\n}: ResetPasswordEmailProps) => {\n const previewText = `Restablece tu contraseña para Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Restablece tu contraseña para <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hola {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hemos recibido una solicitud para restablecer tu contraseña de tu\n cuenta en <strong>Intlayer</strong>.\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={resetLink}\n >\n Restablecer Contraseña\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n o copia y pega esta URL en tu navegador:\n </Text>\n <Link\n href={resetLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {resetLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Esta solicitud de restablecimiento de contraseña estaba destinada\n a <span className=\"text-black\">{username}</span>. Si no\n solicitaste un restablecimiento de contraseña, puedes ignorar este\n correo. Si estás preocupado por la seguridad de tu cuenta, por\n favor responde a este correo para ponerte en contacto con\n nosotros.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nconst PreviewProps: ResetPasswordEmailProps = {\n username: 'alanturing',\n resetLink: 'https://intlayer.org/reset/foo',\n};\n\nResetPasswordEmailEN.PreviewProps = PreviewProps;\nResetPasswordEmailFR.PreviewProps = PreviewProps;\nResetPasswordEmailES.PreviewProps = PreviewProps;\n"],"mappings":";;;;AAqBA,MAAa,wBAAwB,EACnC,UACA,gBAC6B;AAG7B,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBALe,qCAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,qBAAC;MAAQ,WAAU;iBAAoE,4BAC7D,oBAAC,sBAAO,aAAiB;OACzC;KACV,qBAAC;MAAK,WAAU;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ACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBALe,2CAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,qBAAC;MAAQ,WAAU;iBAAoE,kCACvD,oBAAC,sBAAO,aAAiB;OAC/C;KACV,qBAAC;MAAK,WAAU;;OAAwC;OAChD;OAAS;;OACV;KACP,qBAAC;MAAK,WAAU;;OAAwC;OAE5C,oBAAC,sBAAO,aAAiB;;;OAC9B;KACP,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,WAAU;OACV,MAAM;iBACP;QAEQ;OACD;KACV,oBAAC;MAAK,WAAU;gBAAwC;OAEjD;KACP,oBAAC;MACC,MAAM;MACN,WAAU;gBAET;OACI;KACP,oBAAC,MAAG,WAAU,+DAA+D;KAC7E,qBAAC;MAAK,WAAU;;OAA4C;OAExD,oBAAC;QAAK,WAAU;kBAAc;SAAgB;;;OAK3C;;KACG;IACP,GACE;KACN;;AAIX,MAAMA,eAAwC;CAC5C,UAAU;CACV,WAAW;CACZ;AAED,qBAAqB,eAAe;AACpC,qBAAqB,eAAe;AACpC,qBAAqB,eAAe"}
|
|
1
|
+
{"version":3,"file":"ResetUserPassword.mjs","names":[],"sources":["../../../src/emails/ResetUserPassword.tsx"],"sourcesContent":["import {\n Body,\n Button,\n Container,\n Head,\n Heading,\n Hr,\n Html,\n Img,\n Link,\n Preview,\n Section,\n Tailwind,\n Text,\n} from '@react-email/components';\n\nexport type ResetPasswordEmailProps = {\n username: string;\n resetLink: string;\n};\n\nexport const ResetPasswordEmailEN = ({\n username,\n resetLink,\n}: ResetPasswordEmailProps) => {\n const previewText = `Reset your password for Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Reset your password for <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hello {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n We received a request to reset your password for your{' '}\n <strong>Intlayer</strong> account.\n </Text>\n\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={resetLink}\n >\n Reset Password\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n or copy and paste this URL into your browser:\n </Text>\n <Link\n href={resetLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {resetLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n This password reset request was intended for{' '}\n <span className=\"text-black\">{username}</span>. If you did not\n request a password reset, you can ignore this email. If you are\n concerned about your account's safety, please reply to this email\n to get in touch with us.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const ResetPasswordEmailFR = ({\n username,\n resetLink,\n}: ResetPasswordEmailProps) => {\n const previewText = `Réinitialisez votre mot de passe pour Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Réinitialisez votre mot de passe pour <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Bonjour {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Nous avons reçu une demande de réinitialisation de votre mot de\n passe pour votre compte <strong>Intlayer</strong>.\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={resetLink}\n >\n Réinitialiser le mot de passe\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n ou copiez et collez cette URL dans votre navigateur :\n </Text>\n <Link\n href={resetLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {resetLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Cette demande de réinitialisation de mot de passe était destinée à{' '}\n <span className=\"text-black\">{username}</span>. Si vous n'avez pas\n demandé une réinitialisation de mot de passe, vous pouvez ignorer\n cet email. Si vous êtes préoccupé par la sécurité de votre compte,\n veuillez répondre à cet email pour nous contacter.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const ResetPasswordEmailES = ({\n username,\n resetLink,\n}: ResetPasswordEmailProps) => {\n const previewText = `Restablece tu contraseña para Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Restablece tu contraseña para <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hola {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hemos recibido una solicitud para restablecer tu contraseña de tu\n cuenta en <strong>Intlayer</strong>.\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={resetLink}\n >\n Restablecer Contraseña\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n o copia y pega esta URL en tu navegador:\n </Text>\n <Link\n href={resetLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {resetLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Esta solicitud de restablecimiento de contraseña estaba destinada\n a <span className=\"text-black\">{username}</span>. Si no\n solicitaste un restablecimiento de contraseña, puedes ignorar este\n correo. Si estás preocupado por la seguridad de tu cuenta, por\n favor responde a este correo para ponerte en contacto con\n nosotros.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nconst PreviewProps: ResetPasswordEmailProps = {\n username: 'alanturing',\n resetLink: 'https://intlayer.org/reset/foo',\n};\n\nResetPasswordEmailEN.PreviewProps = PreviewProps;\nResetPasswordEmailFR.PreviewProps = PreviewProps;\nResetPasswordEmailES.PreviewProps = PreviewProps;\n"],"mappings":";;;;AAqBA,MAAa,wBAAwB,EACnC,UACA,gBAC6B;AAG7B,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBALe,qCAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ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C,MAAG,WAAU,+DAA+D;KAC7E,qBAAC;MAAK,WAAU;;OAA4C;OACS;OACnE,oBAAC;QAAK,WAAU;kBAAc;SAAgB;;;OAIzC;;KACG;IACP,GACE;KACN;;AAIX,MAAa,wBAAwB,EACnC,UACA,gBAC6B;AAG7B,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBALe,2CAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,qBAAC;MAAQ,WAAU;iBAAoE,kCACvD,oBAAC,sBAAO,aAAiB;OAC/C;KACV,qBAAC;MAAK,WAAU;;OAAwC;OAChD;OAAS;;OACV;KACP,qBAAC;MAAK,WAAU;;OAAwC;OAE5C,oBAAC,sBAAO,aAAiB;;;OAC9B;KACP,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,WAAU;OACV,MAAM;iBACP;QAEQ;OACD;KACV,oBAAC;MAAK,WAAU;gBAAwC;OAEjD;KACP,oBAAC;MACC,MAAM;MACN,WAAU;gBAET;OACI;KACP,oBAAC,MAAG,WAAU,+DAA+D;KAC7E,qBAAC;MAAK,WAAU;;OAA4C;OAExD,oBAAC;QAAK,WAAU;kBAAc;SAAgB;;;OAK3C;;KACG;IACP,GACE;KACN;;AAIX,MAAM,eAAwC;CAC5C,UAAU;CACV,WAAW;CACZ;AAED,qBAAqB,eAAe;AACpC,qBAAqB,eAAe;AACpC,qBAAqB,eAAe"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SubscriptionPaymentCancellation.mjs","names":[
|
|
1
|
+
{"version":3,"file":"SubscriptionPaymentCancellation.mjs","names":[],"sources":["../../../src/emails/SubscriptionPaymentCancellation.tsx"],"sourcesContent":["import {\n Body,\n Button,\n Container,\n Head,\n Heading,\n Html,\n Img,\n Preview,\n Section,\n Tailwind,\n Text,\n} from '@react-email/components';\n\nexport type SubscriptionPaymentCancellationProps = {\n username: string; // The name of the user receiving the email\n email: string; // The email address of the user\n planName: string; // The name of the subscription plan\n organizationName: string; // The name of the organization\n cancellationDate: string; // The date when the subscription will end\n reactivateLink: string; // A link for the user to reactivate their subscription\n};\n\nexport const SubscriptionPaymentCancellationEN = ({\n username,\n planName,\n organizationName,\n cancellationDate,\n reactivateLink,\n}: SubscriptionPaymentCancellationProps) => {\n const previewText = `Your ${planName} subscription has been canceled`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Subscription Canceled\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hello {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n We’re sorry to see you go! Your subscription to the{' '}\n <strong>{planName}</strong> plan has been canceled. You will still\n have access until <strong>{cancellationDate}</strong>.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Organization: <strong>{organizationName}</strong>\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={reactivateLink}\n >\n Reactivate Your Subscription\n </Button>\n </Section>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const SubscriptionPaymentCancellationFR = ({\n username,\n planName,\n organizationName,\n cancellationDate,\n reactivateLink,\n}: SubscriptionPaymentCancellationProps) => {\n const previewText = `Votre abonnement ${planName} a été annulé`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Abonnement Annulé\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Bonjour {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Nous sommes désolés de vous voir partir ! Votre abonnement au plan{' '}\n <strong>{planName}</strong> a été annulé. Vous aurez toujours\n accès jusqu'au <strong>{cancellationDate}</strong>.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Organisation : <strong>{organizationName}</strong>\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={reactivateLink}\n >\n Réactiver votre abonnement\n </Button>\n </Section>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const SubscriptionPaymentCancellationES = ({\n username,\n planName,\n organizationName,\n cancellationDate,\n reactivateLink,\n}: SubscriptionPaymentCancellationProps) => {\n const previewText = `Tu suscripción ${planName} ha sido cancelada`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Suscripción Cancelada\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hola {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Lamentamos verte partir. Tu suscripción al plan{' '}\n <strong>{planName}</strong> ha sido cancelada. Tendrás acceso\n hasta <strong>{cancellationDate}</strong>.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Organización : <strong>{organizationName}</strong>\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={reactivateLink}\n >\n Reactivar tu suscripción\n </Button>\n </Section>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nconst PreviewProps: SubscriptionPaymentCancellationProps = {\n username: 'John Doe',\n email: 'john.doe@example.com',\n planName: 'Pro Plan',\n organizationName: 'My Organization',\n cancellationDate: 'November 30, 2024',\n reactivateLink: 'https://intlayer.org/reactivate-subscription',\n};\n\nSubscriptionPaymentCancellationEN.PreviewProps = PreviewProps;\nSubscriptionPaymentCancellationFR.PreviewProps = PreviewProps;\nSubscriptionPaymentCancellationES.PreviewProps = PreviewProps;\n"],"mappings":";;;;AAuBA,MAAa,qCAAqC,EAChD,UACA,UACA,kBACA,kBACA,qBAC0C;CAC1C,MAAM,cAAc,QAAQ,SAAS;AAErC,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBAAS,cAAsB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,oBAAC;MAAQ,WAAU;gBAAoE;OAE7E;KACV,qBAAC;MAAK,WAAU;;OAAwC;OAC/C;OAAS;;OACX;KACP,qBAAC;MAAK,WA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M;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,oBAAC;MAAQ,WAAU;gBAAoE;OAE7E;KACV,qBAAC;MAAK,WAAU;;OAAwC;OAChD;OAAS;;OACV;KACP,qBAAC;MAAK,WAAU;;OAAwC;OACN;OAChD,oBAAC,sBAAQ,WAAkB;;OACrB,oBAAC,sBAAQ,mBAA0B;;;OACpC;KACP,qBAAC;MAAK,WAAU;iBAAwC,mBACvC,oBAAC,sBAAQ,mBAA0B;OAC7C;KACP,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,WAAU;OACV,MAAM;iBACP;QAEQ;OACD;;KACA;IACP,GACE;KACN;;AAIX,MAAM,eAAqD;CACzD,UAAU;CACV,OAAO;CACP,UAAU;CACV,kBAAkB;CAClB,kBAAkB;CAClB,gBAAgB;CACjB;AAED,kCAAkC,eAAe;AACjD,kCAAkC,eAAe;AACjD,kCAAkC,eAAe"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SubscriptionPaymentError.mjs","names":[
|
|
1
|
+
{"version":3,"file":"SubscriptionPaymentError.mjs","names":[],"sources":["../../../src/emails/SubscriptionPaymentError.tsx"],"sourcesContent":["import {\n Body,\n Button,\n Container,\n Head,\n Heading,\n Html,\n Img,\n Preview,\n Section,\n Tailwind,\n Text,\n} from '@react-email/components';\n\nexport type SubscriptionPaymentErrorProps = {\n username: string; // The name of the user receiving the email\n email: string; // The email address of the user\n planName: string; // The name of the subscription plan\n organizationName: string; // The name of the organization\n errorDate: string; // The date the payment error occurred\n retryPaymentLink: string; // A link for the user to retry their payment\n};\n\n// Payment Error Email - English (EN)\nexport const SubscriptionPaymentErrorEN = ({\n username,\n planName,\n organizationName,\n errorDate,\n retryPaymentLink,\n}: SubscriptionPaymentErrorProps) => {\n const previewText = `There was an issue with your ${planName} subscription payment`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Payment Issue Detected\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hello {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n We encountered an issue processing your payment for the{' '}\n <strong>{planName}</strong> plan on <strong>{errorDate}</strong>.\n Please update your payment information to ensure continued access\n to your subscription.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Organization: <strong>{organizationName}</strong>\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={retryPaymentLink}\n >\n Retry Payment\n </Button>\n </Section>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\n// Payment Error Email - French (FR)\nexport const SubscriptionPaymentErrorFR = ({\n username,\n planName,\n organizationName,\n errorDate,\n retryPaymentLink,\n}: SubscriptionPaymentErrorProps) => {\n const previewText = `Un problème est survenu avec votre paiement pour l'abonnement ${planName}`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Problème de Paiement\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Bonjour {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Nous avons rencontré un problème lors du traitement de votre\n paiement pour le plan <strong>{planName}</strong> le{' '}\n <strong>{errorDate}</strong>. Veuillez mettre à jour vos\n informations de paiement pour garantir un accès continu à votre\n abonnement.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Organisation : <strong>{organizationName}</strong>\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={retryPaymentLink}\n >\n Réessayer le Paiement\n </Button>\n </Section>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\n// Payment Error Email - Spanish (ES)\nexport const SubscriptionPaymentErrorES = ({\n username,\n planName,\n organizationName,\n errorDate,\n retryPaymentLink,\n}: SubscriptionPaymentErrorProps) => {\n const previewText = `Hubo un problema con el pago de tu suscripción ${planName}`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Problema de Pago\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hola {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hubo un problema al procesar tu pago para el plan{' '}\n <strong>{planName}</strong> el <strong>{errorDate}</strong>. Por\n favor, actualiza tu información de pago para garantizar el acceso\n continuo a tu suscripción.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Organización : <strong>{organizationName}</strong>\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={retryPaymentLink}\n >\n Reintentar el Pago\n </Button>\n </Section>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\n// Preview Props Example\nconst PreviewProps: SubscriptionPaymentErrorProps = {\n username: 'John Doe',\n email: 'john.doe@example.com',\n planName: 'Pro Plan',\n organizationName: 'My Organization',\n errorDate: 'November 18, 2024',\n retryPaymentLink: 'https://intlayer.org/retry-payment',\n};\n\nSubscriptionPaymentErrorEN.PreviewProps = PreviewProps;\nSubscriptionPaymentErrorFR.PreviewProps = PreviewProps;\nSubscriptionPaymentErrorES.PreviewProps = PreviewProps;\n"],"mappings":";;;;AAwBA,MAAa,8BAA8B,EACzC,UACA,UACA,kBACA,WACA,uBACmC;CACnC,MAAM,cAAc,gCAAgC,SAAS;AAE7D,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBAAS,cAAsB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,oBAAC;MAAQ,WAAU;gBAAoE;OAE7E;KACV,qBAAC;MAAK,WAAU;;OAAwC;OAC/C;OAAS;;OACX;KACP,qBAAC;MAAK,WAAU;;OAAwC;OACE;OACxD,oBAAC,sBAAQ,WAAkB;;OAAS,oBAAC,sBAAQ,YAAmB;;;OAG3D;KACP,qBAAC;MAAK,WAAU;iBAAwC,kBACxC,oBAAC,sBAAQ,mBAA0B;OAC5C;KACP,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,WAAU;OACV,MAAM;iBACP;QAEQ;OACD;;KACA;IACP,GACE;KACN;;AAKX,MAAa,8BAA8B,EACzC,UACA,UACA,kBACA,WACA,uBACmC;CACnC,MAAM,cAAc,iEAAi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;OACC,WAAU;OACV,MAAM;iBACP;QAEQ;OACD;;KACA;IACP,GACE;KACN;;AAKX,MAAM,eAA8C;CAClD,UAAU;CACV,OAAO;CACP,UAAU;CACV,kBAAkB;CAClB,WAAW;CACX,kBAAkB;CACnB;AAED,2BAA2B,eAAe;AAC1C,2BAA2B,eAAe;AAC1C,2BAA2B,eAAe"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SubscriptionPaymentSuccess.mjs","names":[
|
|
1
|
+
{"version":3,"file":"SubscriptionPaymentSuccess.mjs","names":[],"sources":["../../../src/emails/SubscriptionPaymentSuccess.tsx"],"sourcesContent":["import {\n Body,\n Button,\n Container,\n Head,\n Heading,\n Html,\n Img,\n Preview,\n Section,\n Tailwind,\n Text,\n} from '@react-email/components';\n\nexport type SubscriptionPaymentSuccessProps = {\n username: string; // The name of the user receiving the email\n email: string; // The email address of the user\n planName: string; // The name of the subscription plan\n organizationName: string; // The name of the organization\n subscriptionStartDate: string; // The start date of the subscription\n manageSubscriptionLink: string; // A link for the user to manage their subscription\n};\n\nexport const SubscriptionPaymentSuccessEN = ({\n username,\n planName,\n organizationName,\n subscriptionStartDate,\n manageSubscriptionLink,\n}: SubscriptionPaymentSuccessProps) => {\n const previewText = `Your payment for ${planName} subscription is confirmed`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Payment Confirmed\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hello {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Thank you for your payment! Your subscription to the{' '}\n <strong>{planName}</strong> plan is now active.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Start Date: <strong>{subscriptionStartDate}</strong>\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Organization: <strong>{organizationName}</strong>\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={manageSubscriptionLink}\n >\n Manage Your Subscription\n </Button>\n </Section>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const SubscriptionPaymentSuccessFR = ({\n username,\n planName,\n organizationName,\n subscriptionStartDate,\n manageSubscriptionLink,\n}: SubscriptionPaymentSuccessProps) => {\n const previewText = `Votre paiement pour l'abonnement ${planName} est confirmé`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Paiement Confirmé\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Bonjour {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Merci pour votre paiement ! Votre abonnement au plan{' '}\n <strong>{planName}</strong> est maintenant actif.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Date de début : <strong>{subscriptionStartDate}</strong>\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Organisation : <strong>{organizationName}</strong>\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={manageSubscriptionLink}\n >\n Gérer votre abonnement\n </Button>\n </Section>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const SubscriptionPaymentSuccessES = ({\n username,\n planName,\n organizationName,\n subscriptionStartDate,\n manageSubscriptionLink,\n}: SubscriptionPaymentSuccessProps) => {\n const previewText = `Tu pago por la suscripción ${planName} ha sido confirmado`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Pago Confirmado\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hola {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n ¡Gracias por tu pago! Tu suscripción al plan{' '}\n <strong>{planName}</strong> ya está activa.\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Fecha de inicio: <strong>{subscriptionStartDate}</strong>\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Organización: <strong>{organizationName}</strong>\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={manageSubscriptionLink}\n >\n Gestionar tu suscripción\n </Button>\n </Section>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nconst PreviewProps: SubscriptionPaymentSuccessProps = {\n username: 'John Doe',\n email: 'john.doe@example.com',\n planName: 'Pro Plan',\n organizationName: 'My Organization',\n subscriptionStartDate: 'November 20, 2024',\n manageSubscriptionLink: 'https://intlayer.org/manage-subscription',\n};\n\nSubscriptionPaymentSuccessEN.PreviewProps = PreviewProps;\nSubscriptionPaymentSuccessFR.PreviewProps = PreviewProps;\nSubscriptionPaymentSuccessES.PreviewProps = PreviewProps;\n"],"mappings":";;;;AAuBA,MAAa,gCAAgC,EAC3C,UACA,UACA,kBACA,uBACA,6BACqC;CACrC,MAAM,cAAc,oBAAoB,SAAS;AAEjD,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBAAS,cAAsB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,oBAAC;MAAQ,WAAU;gBAAoE;OAE7E;KACV,qBAAC;MAAK,WAAU;;OAAwC;OAC/C;OAAS;;OACX;KACP,qBAAC;MAAK,WAAU;;OAAwC;OACD;OACrD,oBAAC,sBAAQ,WAAkB;;;OACtB;KACP,qBAAC;MAAK,WAAU;iBAAwC,gBAC1C,oBAAC,sBAAQ,wBAA+B;OAC/C;KACP,qBAAC;MAAK,WAAU;iBAAwC,kBACxC,oBAAC,sBAAQ,mBAA0B;OAC5C;KACP,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,WAAU;OACV,MAAM;iBACP;QAEQ;OACD;;KACA;IACP,GACE;KACN;;AAIX,MAAa,gCAAgC,EAC3C,UACA,UACA,kBACA,uBACA,6BACqC;CACrC,MAAM,cAAc,oCAAoC,SAAS;AAEjE,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBAAS,cAAsB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,o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ACzB;AAED,6BAA6B,eAAe;AAC5C,6BAA6B,eAAe;AAC5C,6BAA6B,eAAe"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ValidateUserEmail.mjs","names":["previewProps: ValidateUserEmailProps"],"sources":["../../../src/emails/ValidateUserEmail.tsx"],"sourcesContent":["import {\n Body,\n Button,\n Container,\n Head,\n Heading,\n Hr,\n Html,\n Img,\n Link,\n Preview,\n Section,\n Tailwind,\n Text,\n} from '@react-email/components';\n\nexport type ValidateUserEmailProps = {\n username: string;\n validationLink: string;\n};\n\nexport const ValidateUserEmailEN = ({\n username,\n validationLink,\n}: ValidateUserEmailProps) => {\n const previewText = `Validate your email for Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Validate your email for <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hello {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Please validate your email address to complete your registration\n on <strong>Intlayer</strong>.\n </Text>\n\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={validationLink}\n >\n Validate Email\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n or copy and paste this URL into your browser:\n </Text>\n <Link\n href={validationLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {validationLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n This email was intended for{' '}\n <span className=\"text-black\">{username}</span>. If you were not\n expecting this email, you can ignore it. If you are concerned\n about your account's safety, please reply to this email to get in\n touch with us.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const ValidateUserEmailFR = ({\n username,\n validationLink,\n}: ValidateUserEmailProps) => {\n const previewText = `Validez votre e-mail pour Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Validez votre e-mail pour <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Bonjour {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Veuillez valider votre adresse e-mail pour compléter votre\n inscription sur <strong>Intlayer</strong>.\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={validationLink}\n >\n Valider l'e-mail\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n ou copiez et collez cette URL dans votre navigateur :\n </Text>\n <Link\n href={validationLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {validationLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Cet e-mail était destiné à{' '}\n <span className=\"text-black\">{username}</span>. Si vous\n n'attendiez pas cet e-mail, vous pouvez l'ignorer. Si vous êtes\n préoccupé par la sécurité de votre compte, veuillez répondre à cet\n e-mail pour nous contacter.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const ValidateUserEmailES = ({\n username,\n validationLink,\n}: ValidateUserEmailProps) => {\n const previewText = `Valida tu correo electrónico para Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Valida tu correo electrónico para <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hola {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Por favor valida tu dirección de correo electrónico para completar\n tu registro en <strong>Intlayer</strong>.\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={validationLink}\n >\n Validar Email\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n o copia y pega esta URL en tu navegador:\n </Text>\n <Link\n href={validationLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {validationLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Este correo fue enviado a{' '}\n <span className=\"text-black\">{username}</span>. Si no esperabas\n este correo, puedes ignorarlo. Si estás preocupado por la\n seguridad de tu cuenta, por favor responde a este correo para\n contactarte con nosotros.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nconst previewProps: ValidateUserEmailProps = {\n username: 'alanturing',\n validationLink: 'https://intlayer.org/validate/foo',\n};\n\nValidateUserEmailEN.PreviewProps = previewProps;\nValidateUserEmailFR.PreviewProps = previewProps;\nValidateUserEmailES.PreviewProps = previewProps;\n"],"mappings":";;;;AAqBA,MAAa,uBAAuB,EAClC,UACA,qBAC4B;AAG5B,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBALe,qCAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,qBAAC;MAAQ,WAAU;iBAAoE,4BAC7D,oBAAC,sBAAO,aAAiB;OACzC;KACV,qBAAC;MAAK,WAAU;;OAAwC;OAC/C;OAAS;;OACX;KACP,qBAAC;MAAK,WAAU;;OAAwC;OAEnD,oBAAC,sBAAO,aAAiB;;;OACvB;KAEP,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,WAAU;OACV,MAAM;iBACP;QAEQ;OACD;KACV,oBAAC;MAAK,WAAU;gBAAwC;OAEjD;KACP,oBAAC;MACC,MAAM;MACN,WAAU;gBAET;OACI;KACP,oBAAC,MAAG,WAAU,+DAA+D;KAC7E,qBAAC;MAAK,WAAU;;OAA4C;OAC9B;OAC5B,oBAAC;QAAK,WAAU;kBAAc;SAAgB;;;OAIzC;;KACG;IACP,GACE;KACN;;AAIX,MAAa,uBAAuB,EAClC,UACA,qBAC4B;AAG5B,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBALe,uCAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OAC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;OAC1B,oBAAC;QAAK,WAAU;kBAAc;SAAgB;;;OAIzC;;KACG;IACP,GACE;KACN;;AAIX,MAAMA,eAAuC;CAC3C,UAAU;CACV,gBAAgB;CACjB;AAED,oBAAoB,eAAe;AACnC,oBAAoB,eAAe;AACnC,oBAAoB,eAAe"}
|
|
1
|
+
{"version":3,"file":"ValidateUserEmail.mjs","names":[],"sources":["../../../src/emails/ValidateUserEmail.tsx"],"sourcesContent":["import {\n Body,\n Button,\n Container,\n Head,\n Heading,\n Hr,\n Html,\n Img,\n Link,\n Preview,\n Section,\n Tailwind,\n Text,\n} from '@react-email/components';\n\nexport type ValidateUserEmailProps = {\n username: string;\n validationLink: string;\n};\n\nexport const ValidateUserEmailEN = ({\n username,\n validationLink,\n}: ValidateUserEmailProps) => {\n const previewText = `Validate your email for Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Validate your email for <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hello {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Please validate your email address to complete your registration\n on <strong>Intlayer</strong>.\n </Text>\n\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={validationLink}\n >\n Validate Email\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n or copy and paste this URL into your browser:\n </Text>\n <Link\n href={validationLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {validationLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n This email was intended for{' '}\n <span className=\"text-black\">{username}</span>. If you were not\n expecting this email, you can ignore it. If you are concerned\n about your account's safety, please reply to this email to get in\n touch with us.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const ValidateUserEmailFR = ({\n username,\n validationLink,\n}: ValidateUserEmailProps) => {\n const previewText = `Validez votre e-mail pour Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Validez votre e-mail pour <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Bonjour {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Veuillez valider votre adresse e-mail pour compléter votre\n inscription sur <strong>Intlayer</strong>.\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={validationLink}\n >\n Valider l'e-mail\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n ou copiez et collez cette URL dans votre navigateur :\n </Text>\n <Link\n href={validationLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {validationLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Cet e-mail était destiné à{' '}\n <span className=\"text-black\">{username}</span>. Si vous\n n'attendiez pas cet e-mail, vous pouvez l'ignorer. Si vous êtes\n préoccupé par la sécurité de votre compte, veuillez répondre à cet\n e-mail pour nous contacter.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const ValidateUserEmailES = ({\n username,\n validationLink,\n}: ValidateUserEmailProps) => {\n const previewText = `Valida tu correo electrónico para Intlayer`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Valida tu correo electrónico para <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hola {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Por favor valida tu dirección de correo electrónico para completar\n tu registro en <strong>Intlayer</strong>.\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={validationLink}\n >\n Validar Email\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n o copia y pega esta URL en tu navegador:\n </Text>\n <Link\n href={validationLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {validationLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Este correo fue enviado a{' '}\n <span className=\"text-black\">{username}</span>. Si no esperabas\n este correo, puedes ignorarlo. Si estás preocupado por la\n seguridad de tu cuenta, por favor responde a este correo para\n contactarte con nosotros.\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nconst previewProps: ValidateUserEmailProps = {\n username: 'alanturing',\n validationLink: 'https://intlayer.org/validate/foo',\n};\n\nValidateUserEmailEN.PreviewProps = previewProps;\nValidateUserEmailFR.PreviewProps = previewProps;\nValidateUserEmailES.PreviewProps = previewProps;\n"],"mappings":";;;;AAqBA,MAAa,uBAAuB,EAClC,UACA,qBAC4B;AAG5B,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBALe,qCAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,qBAAC;MAAQ,WAAU;iBAAoE,4BAC7D,oBAAC,sBAAO,aAAiB;OACzC;KACV,qBAAC;MAAK,WAAU;;OAAwC;OAC/C;OAAS;;OACX;KACP,qBAAC;MAAK,WAAU;;OAAwC;OAEnD,oBAAC,sBAAO,aAAiB;;;OACvB;KAEP,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,WAAU;OACV,MAAM;iBACP;QAEQ;OACD;KACV,oBAAC;MAAK,WAAU;gBAAwC;OAEjD;KACP,oBAAC;MACC,MAAM;MACN,WAAU;gBAET;OACI;KACP,oBAAC,MAAG,WAAU,+DAA+D;KAC7E,qBAAC;MAAK,WAAU;;OAA4C;OAC9B;OAC5B,oBAAC;QAAK,WAAU;kBAAc;SAAgB;;;OAIzC;;KACG;IACP,GACE;KACN;;AAIX,MAAa,uBAAuB,EAClC,UACA,qBAC4B;AAG5B,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBALe,uCAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;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OACI;KACP,oBAAC,MAAG,WAAU,+DAA+D;KAC7E,qBAAC;MAAK,WAAU;;OAA4C;OAChC;OAC1B,oBAAC;QAAK,WAAU;kBAAc;SAAgB;;;OAIzC;;KACG;IACP,GACE;KACN;;AAIX,MAAM,eAAuC;CAC3C,UAAU;CACV,gBAAgB;CACjB;AAED,oBAAoB,eAAe;AACnC,oBAAoB,eAAe;AACnC,oBAAoB,eAAe"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Welcome.mjs","names":[
|
|
1
|
+
{"version":3,"file":"Welcome.mjs","names":[],"sources":["../../../src/emails/Welcome.tsx"],"sourcesContent":["import {\n Body,\n Button,\n Container,\n Head,\n Heading,\n Hr,\n Html,\n Img,\n Link,\n Preview,\n Section,\n Tailwind,\n Text,\n} from '@react-email/components';\n\nexport type WelcomeEmailProps = {\n username: string;\n loginLink: string;\n};\n\nexport const WelcomeEmailEN = ({ username, loginLink }: WelcomeEmailProps) => {\n const previewText = `Welcome to Intlayer!`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Welcome to <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hello {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n We're excited to have you on board! Get started by logging in to\n your <strong>Intlayer</strong> account.\n </Text>\n\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={loginLink}\n >\n Log In to Your Account\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n or copy and paste this URL into your browser:\n </Text>\n <Link\n href={loginLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {loginLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n If you have any questions or need help getting started, feel free\n to reply to this email. We're here to help!\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const WelcomeEmailFR = ({ username, loginLink }: WelcomeEmailProps) => {\n const previewText = `Bienvenue chez Intlayer !`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Bienvenue chez <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Bonjour {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Nous sommes ravis de vous avoir parmi nous ! Commencez par vous\n connecter à votre compte <strong>Intlayer</strong>.\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={loginLink}\n >\n Connectez-vous à votre compte\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n ou copiez et collez cette URL dans votre navigateur :\n </Text>\n <Link\n href={loginLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {loginLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Si vous avez des questions ou besoin d'aide pour commencer,\n n'hésitez pas à répondre à cet e-mail. Nous sommes là pour vous\n aider !\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nexport const WelcomeEmailES = ({ username, loginLink }: WelcomeEmailProps) => {\n const previewText = `¡Bienvenido a Intlayer!`;\n\n return (\n <Html>\n <Head />\n <Preview>{previewText}</Preview>\n <Tailwind>\n <Body className=\"m-auto px-2 font-sans\">\n <Container className=\"mx-auto my-[40px] max-w-[465px] rounded-xl border border-[#eaeaea] border-solid bg-white p-[20px]\">\n <Section className=\"mt-[32px]\">\n <Img\n src=\"https://intlayer.org/apple-touch-icon.png\"\n width=\"40\"\n height=\"37\"\n alt=\"Intlayer\"\n className=\"mx-auto my-0\"\n />\n </Section>\n <Heading className=\"mx-0 my-[30px] p-0 text-center font-normal text-[24px] text-black\">\n Bienvenido a <strong>Intlayer</strong>\n </Heading>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n Hola {username},\n </Text>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n ¡Estamos emocionados de tenerte a bordo! Comienza iniciando sesión\n en tu cuenta de <strong>Intlayer</strong>.\n </Text>\n <Section className=\"my-[32px] text-center\">\n <Button\n className=\"rounded-md bg-[#000000] px-5 py-3 text-center font-semibold text-[12px] text-white no-underline\"\n href={loginLink}\n >\n Inicia sesión en tu cuenta\n </Button>\n </Section>\n <Text className=\"text-[14px] text-black leading-[24px]\">\n o copia y pega esta URL en tu navegador:\n </Text>\n <Link\n href={loginLink}\n className=\"text-[#8a8a8a] text-[10px] no-underline\"\n >\n {loginLink}\n </Link>\n <Hr className=\"mx-0 my-[26px] w-full border border-[#eaeaea] border-solid\" />\n <Text className=\"text-[#666666] text-[12px] leading-[24px]\">\n Si tienes preguntas o necesitas ayuda para comenzar, no dudes en\n responder a este correo electrónico. ¡Estamos aquí para ayudarte!\n </Text>\n </Container>\n </Body>\n </Tailwind>\n </Html>\n );\n};\n\nconst PreviewProps: WelcomeEmailProps = {\n username: 'alanturing',\n loginLink: 'https://intlayer.org/login',\n};\n\nWelcomeEmailEN.PreviewProps = PreviewProps;\nWelcomeEmailFR.PreviewProps = PreviewProps;\nWelcomeEmailES.PreviewProps = PreviewProps;\n"],"mappings":";;;;AAqBA,MAAa,kBAAkB,EAAE,UAAU,gBAAmC;AAG5E,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBALe,yBAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WAAU;QACV;OACM;KACV,qBAAC;MAAQ,WAAU;iBAAoE,eAC1E,oBAAC,sBAAO,aAAiB;OAC5B;KACV,qBAAC;MAAK,WAAU;;OAAwC;OAC/C;OAAS;;OACX;KACP,qBAAC;MAAK,WAAU;;OAAwC;OAEjD,oBAAC,sBAAO,aAAiB;;;OACzB;KAEP,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,WAAU;OACV,MAAM;iBACP;QAEQ;OACD;KACV,oBAAC;MAAK,WAAU;gBAAwC;OAEjD;KACP,oBAAC;MACC,MAAM;MACN,WAAU;gBAET;OACI;KACP,oBAAC,MAAG,WAAU,+DAA+D;KAC7E,oBAAC;MAAK,WAAU;gBAA4C;OAGrD;;KACG;IACP,GACE;KACN;;AAIX,MAAa,kBAAkB,EAAE,UAAU,gBAAmC;AAG5E,QACE,qBAAC;EACC,oBAAC,SAAO;EACR,oBAAC,qBALe,8BAKgB;EAChC,oBAAC,sBACC,oBAAC;GAAK,WAAU;aACd,qBAAC;IAAU,WAAU;;KACnB,oBAAC;MAAQ,WAAU;gBACjB,oBAAC;OACC,KAAI;OACJ,OAAM;OACN,QAAO;OACP,KAAI;OACJ,WA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CACZ;AAED,eAAe,eAAe;AAC9B,eAAe,eAAe;AAC9B,eAAe,eAAe"}
|
package/dist/esm/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","names":["app: FastifyInstance"],"sources":["../../src/index.ts"],"sourcesContent":["/// Controllers\nimport { getOAuth2AccessToken } from '@controllers/oAuth2.controller';\nimport fastifyCompress from '@fastify/compress';\nimport fastifyCookie from '@fastify/cookie';\nimport fastifyCors from '@fastify/cors';\nimport fastifyFormbody from '@fastify/formbody';\nimport fastifyHelmet from '@fastify/helmet';\nimport fastifyRateLimit from '@fastify/rate-limit';\n// Middlewares\nimport {\n attachOAuthInstance,\n oAuth2Middleware,\n} from '@middlewares/oAuth2.middleware';\nimport { authMiddleware } from '@middlewares/sessionAuth.middleware';\n// Routes\nimport { aiRoute, aiRouter } from '@routes/ai.routes';\nimport { bitbucketRoute, bitbucketRouter } from '@routes/bitbucket.routes';\nimport { dictionaryRoute, dictionaryRouter } from '@routes/dictionary.routes';\nimport {\n eventListenerRoute,\n eventListenerRouter,\n} from '@routes/eventListener.routes';\nimport { githubRoute, githubRouter } from '@routes/github.routes';\nimport { gitlabRoute, gitlabRouter } from '@routes/gitlab.routes';\nimport { newsletterRoute, newsletterRouter } from '@routes/newsletter.routes';\nimport {\n organizationRoute,\n organizationRouter,\n} from '@routes/organization.routes';\nimport { projectRoute, projectRouter } from '@routes/project.routes';\nimport { searchRoute, searchRouter } from '@routes/search.routes';\nimport { stripeRoute, stripeRouter } from '@routes/stripe.routes';\nimport { tagRoute, tagRouter } from '@routes/tags.routes';\nimport { userRoute, userRouter } from '@routes/user.routes';\n// Utils\nimport { getAuth } from '@utils/auth/getAuth';\nimport { corsOptions } from '@utils/cors';\nimport { connectDB } from '@utils/mongoDB/connectDB';\nimport { ipLimiter } from '@utils/rateLimiter';\n// Webhooks\nimport { stripeWebhook } from '@webhooks/stripe.webhook';\n// Libraries\nimport dotenv from 'dotenv';\nimport Fastify, { type FastifyInstance } from 'fastify';\nimport { intlayer, t } from 'fastify-intlayer';\n/// Logger\nimport { logger } from './logger/index';\n\nconst startServer = async () => {\n const app: FastifyInstance = Fastify({\n disableRequestLogging: true,\n trustProxy: true,\n routerOptions: {\n ignoreTrailingSlash: true,\n },\n });\n\n // Environment variables\n const env = process.env.NODE_ENV || 'development';\n\n logger.info(`run as ${env}`);\n\n dotenv.config({\n path: [`.env.${env}.local`, `.env.${env}`, '.env.local', '.env'],\n });\n\n // Security Headers\n await app.register(fastifyHelmet, {\n contentSecurityPolicy: false,\n global: true,\n });\n\n // CORS\n await app.register(fastifyCors, corsOptions);\n\n // Compression\n await app.register(fastifyCompress);\n\n // Cookie Parser\n await app.register(fastifyCookie);\n\n // Parse application/x-www-form-urlencoded\n await app.register(fastifyFormbody);\n\n // Load internationalization request handler\n await app.register(intlayer);\n\n // Rate limiter\n await app.register(fastifyRateLimit, ipLimiter);\n\n // Connect to MongoDB\n const dbClient = await connectDB();\n\n // Stripe webhook (needs raw body)\n // Register a content type parser for raw body\n await app.register(async (stripeScope) => {\n stripeScope.addContentTypeParser(\n 'application/json',\n { parseAs: 'buffer' },\n (_req, body, done) => {\n done(null, body);\n }\n );\n\n stripeScope.post('/webhook/stripe', async (request, reply) => {\n // For Stripe webhooks, we need the raw body as a Buffer\n // Fastify will parse it as buffer when content-type parser is set\n const rawBody = request.body as Buffer;\n // Create a mock request object for the webhook handler\n const mockReq = {\n ...request.raw,\n body: rawBody,\n headers: request.headers,\n } as any;\n await stripeWebhook(mockReq, reply as any);\n });\n });\n\n // Liveness check\n app.get('/', async (_request, reply) => {\n return reply.send(\n t({\n en: 'Ok - locale: en',\n fr: 'Ok - locale: fr',\n es: 'Ok - locale: es',\n })\n );\n });\n\n // Session Auth\n const auth = getAuth(dbClient as any);\n\n // Better Auth handler - Using Fetch API approach for Fastify compatibility\n app.route({\n method: ['GET', 'POST'],\n url: '/api/auth/*',\n async handler(request, reply) {\n try {\n // This respects the X-Forwarded-Proto header from Coolify\n const protocol = request.protocol;\n const host = request.headers.host;\n\n // Construct request URL using the detected protocol\n const url = new URL(request.url, `${protocol}://${host}`);\n\n const headers = new Headers();\n Object.entries(request.headers).forEach(([key, value]) => {\n if (value) headers.append(key, String(value));\n });\n\n // Create Fetch API-compatible request\n const req = new Request(url.toString(), {\n method: request.method,\n headers,\n ...(request.body ? { body: JSON.stringify(request.body) } : {}),\n });\n\n // Process authentication request\n const response = await auth.handler(req);\n\n // Forward response to client\n reply.status(response.status);\n response.headers.forEach((value, key) => {\n reply.header(key, value);\n });\n\n const responseBody = response.body ? await response.text() : null;\n return reply.send(responseBody);\n } catch (error) {\n logger.error('Authentication Error:', error);\n return reply.status(500).send({\n error: 'Internal authentication error',\n code: 'AUTH_FAILURE',\n });\n }\n },\n });\n\n // Register auth middleware as a hook\n app.addHook('onRequest', authMiddleware(auth));\n\n // // oAuth2 Auth\n app.addHook('onRequest', attachOAuthInstance);\n app.post('/oauth2/token', getOAuth2AccessToken); // Route to get the token\n app.addHook('preHandler', oAuth2Middleware);\n\n // // debug\n const isDev = env === 'development';\n if (isDev) {\n app.addHook('onRequest', async (request) => {\n const queryDetails = {\n params: request.params,\n query: request.query,\n body: request.body,\n locals: request.locals,\n };\n\n logger.info(\n `API Request - ${request.method} - ${request.url} - ${JSON.stringify(queryDetails, null, 2)}`\n );\n });\n }\n\n // Routes\n await app.register(userRouter, { prefix: userRoute });\n await app.register(organizationRouter, { prefix: organizationRoute });\n await app.register(projectRouter, { prefix: projectRoute });\n await app.register(tagRouter, { prefix: tagRoute });\n await app.register(dictionaryRouter, { prefix: dictionaryRoute });\n await app.register(stripeRouter, { prefix: stripeRoute });\n await app.register(aiRouter, { prefix: aiRoute });\n await app.register(eventListenerRouter, { prefix: eventListenerRoute });\n await app.register(searchRouter, { prefix: searchRoute });\n await app.register(newsletterRouter, { prefix: newsletterRoute });\n await app.register(githubRouter, { prefix: githubRoute });\n await app.register(gitlabRouter, { prefix: gitlabRoute });\n await app.register(bitbucketRouter, { prefix: bitbucketRoute });\n\n // Server\n await app.listen({\n port: Number(process.env.PORT) || 3100,\n host: '0.0.0.0',\n });\n logger.info(`Listening on port ${process.env.PORT || 3100}`);\n};\n\nstartServer();\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgDA,MAAM,cAAc,YAAY;CAC9B,MAAMA,MAAuB,QAAQ;EACnC,uBAAuB;EACvB,YAAY;EACZ,eAAe,EACb,qBAAqB,MACtB;EACF,CAAC;CAGF,MAAM;AAEN,QAAO,KAAK,UAAU,MAAM;AAE5B,QAAO,OAAO,EACZ,MAAM;EAAC,QAAQ,IAAI;EAAS,QAAQ;EAAO;EAAc;EAAO,EACjE,CAAC;AAGF,OAAM,IAAI,SAAS,eAAe;EAChC,uBAAuB;EACvB,QAAQ;EACT,CAAC;AAGF,OAAM,IAAI,SAAS,aAAa,YAAY;AAG5C,OAAM,IAAI,SAAS,gBAAgB;AAGnC,OAAM,IAAI,SAAS,cAAc;AAGjC,OAAM,IAAI,SAAS,gBAAgB;AAGnC,OAAM,IAAI,SAAS,SAAS;AAG5B,OAAM,IAAI,SAAS,kBAAkB,UAAU;CAG/C,MAAM,WAAW,MAAM,WAAW;AAIlC,OAAM,IAAI,SAAS,OAAO,gBAAgB;AACxC,cAAY,qBACV,oBACA,EAAE,SAAS,UAAU,GACpB,MAAM,MAAM,SAAS;AACpB,QAAK,MAAM,KAAK;IAEnB;AAED,cAAY,KAAK,mBAAmB,OAAO,SAAS,UAAU;GAG5D,MAAM,UAAU,QAAQ;AAOxB,SAAM,cALU;IACd,GAAG,QAAQ;IACX,MAAM;IACN,SAAS,QAAQ;IAClB,EAC4B,MAAa;IAC1C;GACF;AAGF,KAAI,IAAI,KAAK,OAAO,UAAU,UAAU;AACtC,SAAO,MAAM,KACX,EAAE;GACA,IAAI;GACJ,IAAI;GACJ,IAAI;GACL,CAAC,CACH;GACD;CAGF,MAAM,OAAO,QAAQ,SAAgB;AAGrC,KAAI,MAAM;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ACL,iBAAiB,QAAQ,OAAO,KAAK,QAAQ,IAAI,KAAK,KAAK,UAAU,cAAc,MAAM,EAAE,GAC5F;GACD;AAIJ,OAAM,IAAI,SAAS,YAAY,EAAE,QAAQ,WAAW,CAAC;AACrD,OAAM,IAAI,SAAS,oBAAoB,EAAE,QAAQ,mBAAmB,CAAC;AACrE,OAAM,IAAI,SAAS,eAAe,EAAE,QAAQ,cAAc,CAAC;AAC3D,OAAM,IAAI,SAAS,WAAW,EAAE,QAAQ,UAAU,CAAC;AACnD,OAAM,IAAI,SAAS,kBAAkB,EAAE,QAAQ,iBAAiB,CAAC;AACjE,OAAM,IAAI,SAAS,cAAc,EAAE,QAAQ,aAAa,CAAC;AACzD,OAAM,IAAI,SAAS,UAAU,EAAE,QAAQ,SAAS,CAAC;AACjD,OAAM,IAAI,SAAS,qBAAqB,EAAE,QAAQ,oBAAoB,CAAC;AACvE,OAAM,IAAI,SAAS,cAAc,EAAE,QAAQ,aAAa,CAAC;AACzD,OAAM,IAAI,SAAS,kBAAkB,EAAE,QAAQ,iBAAiB,CAAC;AACjE,OAAM,IAAI,SAAS,cAAc,EAAE,QAAQ,aAAa,CAAC;AACzD,OAAM,IAAI,SAAS,cAAc,EAAE,QAAQ,aAAa,CAAC;AACzD,OAAM,IAAI,SAAS,iBAAiB,EAAE,QAAQ,gBAAgB,CAAC;AAG/D,OAAM,IAAI,OAAO;EACf,MAAM,OAAO,QAAQ,IAAI,KAAK,IAAI;EAClC,MAAM;EACP,CAAC;AACF,QAAO,KAAK,qBAAqB,QAAQ,IAAI,QAAQ,OAAO;;AAG9D,aAAa"}
|
|
1
|
+
{"version":3,"file":"index.mjs","names":[],"sources":["../../src/index.ts"],"sourcesContent":["/// Controllers\nimport { getOAuth2AccessToken } from '@controllers/oAuth2.controller';\nimport fastifyCompress from '@fastify/compress';\nimport fastifyCookie from '@fastify/cookie';\nimport fastifyCors from '@fastify/cors';\nimport fastifyFormbody from '@fastify/formbody';\nimport fastifyHelmet from '@fastify/helmet';\nimport fastifyRateLimit from '@fastify/rate-limit';\n// Middlewares\nimport {\n attachOAuthInstance,\n oAuth2Middleware,\n} from '@middlewares/oAuth2.middleware';\nimport { authMiddleware } from '@middlewares/sessionAuth.middleware';\n// Routes\nimport { aiRoute, aiRouter } from '@routes/ai.routes';\nimport { bitbucketRoute, bitbucketRouter } from '@routes/bitbucket.routes';\nimport { dictionaryRoute, dictionaryRouter } from '@routes/dictionary.routes';\nimport {\n eventListenerRoute,\n eventListenerRouter,\n} from '@routes/eventListener.routes';\nimport { githubRoute, githubRouter } from '@routes/github.routes';\nimport { gitlabRoute, gitlabRouter } from '@routes/gitlab.routes';\nimport { newsletterRoute, newsletterRouter } from '@routes/newsletter.routes';\nimport {\n organizationRoute,\n organizationRouter,\n} from '@routes/organization.routes';\nimport { projectRoute, projectRouter } from '@routes/project.routes';\nimport { searchRoute, searchRouter } from '@routes/search.routes';\nimport { stripeRoute, stripeRouter } from '@routes/stripe.routes';\nimport { tagRoute, tagRouter } from '@routes/tags.routes';\nimport { userRoute, userRouter } from '@routes/user.routes';\n// Utils\nimport { getAuth } from '@utils/auth/getAuth';\nimport { corsOptions } from '@utils/cors';\nimport { connectDB } from '@utils/mongoDB/connectDB';\nimport { ipLimiter } from '@utils/rateLimiter';\n// Webhooks\nimport { stripeWebhook } from '@webhooks/stripe.webhook';\n// Libraries\nimport dotenv from 'dotenv';\nimport Fastify, { type FastifyInstance } from 'fastify';\nimport { intlayer, t } from 'fastify-intlayer';\n/// Logger\nimport { logger } from './logger/index';\n\nconst startServer = async () => {\n const app: FastifyInstance = Fastify({\n disableRequestLogging: true,\n trustProxy: true,\n routerOptions: {\n ignoreTrailingSlash: true,\n },\n });\n\n // Environment variables\n const env = process.env.NODE_ENV || 'development';\n\n logger.info(`run as ${env}`);\n\n dotenv.config({\n path: [`.env.${env}.local`, `.env.${env}`, '.env.local', '.env'],\n });\n\n // Security Headers\n await app.register(fastifyHelmet, {\n contentSecurityPolicy: false,\n global: true,\n });\n\n // CORS\n await app.register(fastifyCors, corsOptions);\n\n // Compression\n await app.register(fastifyCompress);\n\n // Cookie Parser\n await app.register(fastifyCookie);\n\n // Parse application/x-www-form-urlencoded\n await app.register(fastifyFormbody);\n\n // Load internationalization request handler\n await app.register(intlayer);\n\n // Rate limiter\n await app.register(fastifyRateLimit, ipLimiter);\n\n // Connect to MongoDB\n const dbClient = await connectDB();\n\n // Stripe webhook (needs raw body)\n // Register a content type parser for raw body\n await app.register(async (stripeScope) => {\n stripeScope.addContentTypeParser(\n 'application/json',\n { parseAs: 'buffer' },\n (_req, body, done) => {\n done(null, body);\n }\n );\n\n stripeScope.post('/webhook/stripe', async (request, reply) => {\n // For Stripe webhooks, we need the raw body as a Buffer\n // Fastify will parse it as buffer when content-type parser is set\n const rawBody = request.body as Buffer;\n // Create a mock request object for the webhook handler\n const mockReq = {\n ...request.raw,\n body: rawBody,\n headers: request.headers,\n } as any;\n await stripeWebhook(mockReq, reply as any);\n });\n });\n\n // Liveness check\n app.get('/', async (_request, reply) => {\n return reply.send(\n t({\n en: 'Ok - locale: en',\n fr: 'Ok - locale: fr',\n es: 'Ok - locale: es',\n })\n );\n });\n\n // Session Auth\n const auth = getAuth(dbClient as any);\n\n // Better Auth handler - Using Fetch API approach for Fastify compatibility\n app.route({\n method: ['GET', 'POST'],\n url: '/api/auth/*',\n async handler(request, reply) {\n try {\n // This respects the X-Forwarded-Proto header from Coolify\n const protocol = request.protocol;\n const host = request.headers.host;\n\n // Construct request URL using the detected protocol\n const url = new URL(request.url, `${protocol}://${host}`);\n\n const headers = new Headers();\n Object.entries(request.headers).forEach(([key, value]) => {\n if (value) headers.append(key, String(value));\n });\n\n // Create Fetch API-compatible request\n const req = new Request(url.toString(), {\n method: request.method,\n headers,\n ...(request.body ? { body: JSON.stringify(request.body) } : {}),\n });\n\n // Process authentication request\n const response = await auth.handler(req);\n\n // Forward response to client\n reply.status(response.status);\n response.headers.forEach((value, key) => {\n reply.header(key, value);\n });\n\n const responseBody = response.body ? await response.text() : null;\n return reply.send(responseBody);\n } catch (error) {\n logger.error('Authentication Error:', error);\n return reply.status(500).send({\n error: 'Internal authentication error',\n code: 'AUTH_FAILURE',\n });\n }\n },\n });\n\n // Register auth middleware as a hook\n app.addHook('onRequest', authMiddleware(auth));\n\n // // oAuth2 Auth\n app.addHook('onRequest', attachOAuthInstance);\n app.post('/oauth2/token', getOAuth2AccessToken); // Route to get the token\n app.addHook('preHandler', oAuth2Middleware);\n\n // // debug\n const isDev = env === 'development';\n if (isDev) {\n app.addHook('onRequest', async (request) => {\n const queryDetails = {\n params: request.params,\n query: request.query,\n body: request.body,\n locals: request.locals,\n };\n\n logger.info(\n `API Request - ${request.method} - ${request.url} - ${JSON.stringify(queryDetails, null, 2)}`\n );\n });\n }\n\n // Routes\n await app.register(userRouter, { prefix: userRoute });\n await app.register(organizationRouter, { prefix: organizationRoute });\n await app.register(projectRouter, { prefix: projectRoute });\n await app.register(tagRouter, { prefix: tagRoute });\n await app.register(dictionaryRouter, { prefix: dictionaryRoute });\n await app.register(stripeRouter, { prefix: stripeRoute });\n await app.register(aiRouter, { prefix: aiRoute });\n await app.register(eventListenerRouter, { prefix: eventListenerRoute });\n await app.register(searchRouter, { prefix: searchRoute });\n await app.register(newsletterRouter, { prefix: newsletterRoute });\n await app.register(githubRouter, { prefix: githubRoute });\n await app.register(gitlabRouter, { prefix: gitlabRoute });\n await app.register(bitbucketRouter, { prefix: bitbucketRoute });\n\n // Server\n await app.listen({\n port: Number(process.env.PORT) || 3100,\n host: '0.0.0.0',\n });\n logger.info(`Listening on port ${process.env.PORT || 3100}`);\n};\n\nstartServer();\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgDA,MAAM,cAAc,YAAY;CAC9B,MAAM,MAAuB,QAAQ;EACnC,uBAAuB;EACvB,YAAY;EACZ,eAAe,EACb,qBAAqB,MACtB;EACF,CAAC;CAGF,MAAM;AAEN,QAAO,KAAK,UAAU,MAAM;AAE5B,Q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QAAQ,iBAAiB,CAAC;AACjE,OAAM,IAAI,SAAS,cAAc,EAAE,QAAQ,aAAa,CAAC;AACzD,OAAM,IAAI,SAAS,UAAU,EAAE,QAAQ,SAAS,CAAC;AACjD,OAAM,IAAI,SAAS,qBAAqB,EAAE,QAAQ,oBAAoB,CAAC;AACvE,OAAM,IAAI,SAAS,cAAc,EAAE,QAAQ,aAAa,CAAC;AACzD,OAAM,IAAI,SAAS,kBAAkB,EAAE,QAAQ,iBAAiB,CAAC;AACjE,OAAM,IAAI,SAAS,cAAc,EAAE,QAAQ,aAAa,CAAC;AACzD,OAAM,IAAI,SAAS,cAAc,EAAE,QAAQ,aAAa,CAAC;AACzD,OAAM,IAAI,SAAS,iBAAiB,EAAE,QAAQ,gBAAgB,CAAC;AAG/D,OAAM,IAAI,OAAO;EACf,MAAM,OAAO,QAAQ,IAAI,KAAK,IAAI;EAClC,MAAM;EACP,CAAC;AACF,QAAO,KAAK,qBAAqB,QAAQ,IAAI,QAAQ,OAAO;;AAG9D,aAAa"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bitbucket.service.mjs","names":["error: any"],"sources":["../../../src/services/bitbucket.service.ts"],"sourcesContent":["import { configurationFilesCandidates } from '@intlayer/config';\nimport { logger } from '@logger';\nimport { getDBClient } from '@utils/mongoDB/connectDB';\nimport { ObjectId } from 'mongodb';\n\nconst BITBUCKET_API_URL = 'https://api.bitbucket.org/2.0';\nconst BITBUCKET_AUTH_URL = 'https://bitbucket.org/site/oauth2';\n\nexport type BitbucketRepository = {\n uuid: string;\n name: string;\n full_name: string;\n slug: string;\n mainbranch?: {\n name: string;\n type: string;\n };\n links: {\n html: {\n href: string;\n };\n };\n workspace: {\n slug: string;\n name: string;\n uuid: string;\n };\n owner: {\n display_name: string;\n username?: string;\n uuid: string;\n };\n updated_on: string;\n is_private: boolean;\n};\n\nexport type BitbucketTreeItem = {\n path: string;\n type: 'commit_file' | 'commit_directory';\n size?: number;\n};\n\n/**\n * Get Bitbucket (Atlassian) authorization URL for OAuth flow\n */\nexport const getAuthorizationUrl = (redirectUri: string): string => {\n const clientId = process.env.ATLASSIAN_CLIENT_ID;\n\n if (!clientId) {\n throw new Error('Bitbucket/Atlassian Client ID is not configured');\n }\n\n const params = new URLSearchParams({\n client_id: clientId,\n response_type: 'code',\n state: 'bitbucket_oauth',\n });\n\n return `${BITBUCKET_AUTH_URL}/authorize?${params.toString()}`;\n};\n\n/**\n * Exchange Bitbucket authorization code for access token\n */\nexport const exchangeCodeForToken = async (code: string): Promise<string> => {\n const clientId = process.env.ATLASSIAN_CLIENT_ID;\n const clientSecret = process.env.ATLASSIAN_CLIENT_SECRET;\n\n if (!clientId || !clientSecret) {\n throw new Error('Bitbucket OAuth credentials are not configured');\n }\n\n try {\n const credentials = Buffer.from(`${clientId}:${clientSecret}`).toString(\n 'base64'\n );\n\n const response = await fetch(`${BITBUCKET_AUTH_URL}/access_token`, {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/x-www-form-urlencoded',\n Authorization: `Basic ${credentials}`,\n },\n body: new URLSearchParams({\n grant_type: 'authorization_code',\n code,\n }),\n });\n\n if (!response.ok) {\n throw new Error(\n `Bitbucket token exchange failed: ${response.statusText}`\n );\n }\n\n const data = await response.json();\n\n if (data.error) {\n throw new Error(`Bitbucket token error: ${data.error_description}`);\n }\n\n return data.access_token;\n } catch (error) {\n logger.error('Error exchanging Bitbucket code for token:', error);\n throw error;\n }\n};\n\n/**\n * Get user's Bitbucket repositories\n */\nexport const getUserRepositories = async (\n accessToken: string\n): Promise<BitbucketRepository[]> => {\n try {\n // First, get the current user to find their workspaces\n const userResponse = await fetch(`${BITBUCKET_API_URL}/user`, {\n headers: {\n Authorization: `Bearer ${accessToken}`,\n Accept: 'application/json',\n },\n });\n\n if (!userResponse.ok) {\n throw new Error(\n `Failed to fetch Bitbucket user: ${userResponse.statusText}`\n );\n }\n\n // Get repositories the user has access to\n const reposResponse = await fetch(\n `${BITBUCKET_API_URL}/repositories?role=member&sort=-updated_on&pagelen=100`,\n {\n headers: {\n Authorization: `Bearer ${accessToken}`,\n Accept: 'application/json',\n },\n }\n );\n\n if (!reposResponse.ok) {\n throw new Error(\n `Failed to fetch Bitbucket repositories: ${reposResponse.statusText}`\n );\n }\n\n const data = await reposResponse.json();\n return data.values || [];\n } catch (error) {\n logger.error('Error fetching Bitbucket repositories:', error);\n throw error;\n }\n};\n\n/**\n * Check if valid intlayer configuration files exist in a Bitbucket repository (Recursively).\n * Returns an array of file paths found.\n */\nexport const checkIntlayerConfig = async (\n accessToken: string,\n workspace: string,\n repoSlug: string,\n branch: string = 'main'\n): Promise<string[]> => {\n try {\n // Use Bitbucket's src API to list files recursively\n const response = await fetch(\n `${BITBUCKET_API_URL}/repositories/${workspace}/${repoSlug}/src/${encodeURIComponent(branch)}/?max_depth=10&pagelen=10000`,\n {\n headers: {\n Authorization: `Bearer ${accessToken}`,\n Accept: 'application/json',\n },\n }\n );\n\n if (!response.ok) {\n if (response.status === 404) return [];\n throw new Error(\n `Failed to fetch repository tree: ${response.statusText}`\n );\n }\n\n const data = await response.json();\n const items: BitbucketTreeItem[] = data.values || [];\n\n // Filter files that match the configuration candidates\n const foundFiles = items\n .filter((item) => {\n if (item.type !== 'commit_file') return false;\n return (configurationFilesCandidates as readonly string[]).some(\n (candidate) => item.path.endsWith(candidate)\n );\n })\n .map((item) => item.path);\n\n return foundFiles;\n } catch (error: any) {\n if (error.status === 404) return [];\n logger.error('Error checking intlayer configuration on Bitbucket:', error);\n return [];\n }\n};\n\n/**\n * Get repository file contents from Bitbucket and decode it\n */\nexport const getRepositoryFileContents = async (\n accessToken: string,\n workspace: string,\n repoSlug: string,\n path: string,\n branch: string = 'main'\n): Promise<string | null> => {\n try {\n const response = await fetch(\n `${BITBUCKET_API_URL}/repositories/${workspace}/${repoSlug}/src/${encodeURIComponent(branch)}/${encodeURIComponent(path)}`,\n {\n headers: {\n Authorization: `Bearer ${accessToken}`,\n Accept: 'application/json',\n },\n }\n );\n\n if (!response.ok) {\n if (response.status === 404) return null;\n throw new Error(`Failed to fetch file contents: ${response.statusText}`);\n }\n\n const content = await response.text();\n return content;\n } catch (error: any) {\n if (error.status === 404) return null;\n logger.error('Error fetching Bitbucket file contents:', error);\n throw error;\n }\n};\n\n/**\n * Get Bitbucket access token from user's linked account (Atlassian)\n */\nexport const getBitbucketTokenFromUser = async (\n userId: string\n): Promise<string | null> => {\n try {\n const client = getDBClient();\n const db = client.db();\n\n // Try with 'atlassian' provider ID (as it's linked through Better Auth's atlassian provider)\n let account = await db.collection('account').findOne({\n userId: userId,\n providerId: 'atlassian',\n });\n\n if (!account && ObjectId.isValid(userId)) {\n account = await db.collection('account').findOne({\n userId: new ObjectId(userId),\n providerId: 'atlassian',\n });\n }\n\n if (!account) {\n account = await db.collection('accounts').findOne({\n userId: userId,\n providerId: 'atlassian',\n });\n }\n\n if (!account && ObjectId.isValid(userId)) {\n account = await db.collection('accounts').findOne({\n userId: new ObjectId(userId),\n providerId: 'atlassian',\n });\n }\n\n if (!account) {\n return null;\n }\n\n const accessToken = account.accessToken || account.access_token;\n\n return accessToken || null;\n } catch (error) {\n logger.error('Error retrieving Bitbucket token from DB:', error);\n return null;\n }\n};\n\n/**\n * Check if a Bitbucket pipeline file exists\n */\nexport const checkPipelineFileExists = async (\n accessToken: string,\n workspace: string,\n repoSlug: string,\n filename: string = 'bitbucket-pipelines.yml',\n branch: string = 'main'\n): Promise<boolean> => {\n try {\n const response = await fetch(\n `${BITBUCKET_API_URL}/repositories/${workspace}/${repoSlug}/src/${encodeURIComponent(branch)}/${encodeURIComponent(filename)}`,\n {\n headers: {\n Authorization: `Bearer ${accessToken}`,\n Accept: 'application/json',\n },\n }\n );\n\n if (response.status === 404) return false;\n if (!response.ok) {\n throw new Error(`Failed to check file existence: ${response.statusText}`);\n }\n\n return true;\n } catch (error: any) {\n if (error.status === 404) return false;\n logger.error('Error checking pipeline file existence:', error);\n throw error;\n }\n};\n\n/**\n * Create or update a Bitbucket pipeline file\n * Note: Bitbucket API doesn't support direct file creation via API v2.0\n * This function returns false for allowAutoPush, requiring manual installation\n */\nexport const createPipelineFile = async (\n accessToken: string,\n workspace: string,\n repoSlug: string,\n filename: string = 'bitbucket-pipelines.yml',\n content: string,\n branch: string = 'main',\n message: string = 'Add Intlayer CI pipeline'\n): Promise<void> => {\n // Bitbucket API v2.0 doesn't support direct file creation/update\n // Users need to manually add the file or use the web interface\n // We'll throw an error indicating manual installation is required\n throw new Error(\n 'Bitbucket API does not support automatic file creation. Please manually add the pipeline file to your repository.'\n );\n};\n"],"mappings":";;;;;;AAKA,MAAM,oBAAoB;AAC1B,MAAM,qBAAqB;;;;AAuC3B,MAAa,uBAAuB,gBAAgC;CAClE,MAAM,WAAW,QAAQ,IAAI;AAE7B,KAAI,CAAC,SACH,OAAM,IAAI,MAAM,kDAAkD;AASpE,QAAO,GAAG,mBAAmB,aANd,IAAI,gBAAgB;EACjC,WAAW;EACX,eAAe;EACf,OAAO;EACR,CAAC,CAE+C,UAAU;;;;;AAM7D,MAAa,uBAAuB,OAAO,SAAkC;CAC3E,MAAM,WAAW,QAAQ,IAAI;CAC7B,MAAM,eAAe,QAAQ,IAAI;AAEjC,KAAI,CAAC,YAAY,CAAC,aAChB,OAAM,IAAI,MAAM,iDAAiD;AAGnE,KAAI;EACF,MAAM,cAAc,OAAO,KAAK,GAAG,SAAS,GAAG,eAAe,CAAC,SAC7D,SACD;EAED,MAAM,WAAW,MAAM,MAAM,GAAG,mBAAmB,gBAAgB;GACjE,QAAQ;GACR,SAAS;IACP,gBAAgB;IAChB,eAAe,SAAS;IACzB;GACD,MAAM,IAAI,gBAAgB;IACxB,YAAY;IACZ;IACD,CAAC;GACH,CAAC;AAEF,MAAI,CAAC,SAAS,GACZ,OAAM,IAAI,MACR,oCAAoC,SAAS,aAC9C;EAGH,MAAM,OAAO,MAAM,SAAS,MAAM;AAElC,MAAI,KAAK,MACP,OAAM,IAAI,MAAM,0BAA0B,KAAK,oBAAoB;AAGrE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ACA,UACA,WAAmB,2BACnB,SAAiB,WACI;AACrB,KAAI;EACF,MAAM,WAAW,MAAM,MACrB,GAAG,kBAAkB,gBAAgB,UAAU,GAAG,SAAS,OAAO,mBAAmB,OAAO,CAAC,GAAG,mBAAmB,SAAS,IAC5H,EACE,SAAS;GACP,eAAe,UAAU;GACzB,QAAQ;GACT,EACF,CACF;AAED,MAAI,SAAS,WAAW,IAAK,QAAO;AACpC,MAAI,CAAC,SAAS,GACZ,OAAM,IAAI,MAAM,mCAAmC,SAAS,aAAa;AAG3E,SAAO;UACAA,OAAY;AACnB,MAAI,MAAM,WAAW,IAAK,QAAO;AACjC,SAAO,MAAM,2CAA2C,MAAM;AAC9D,QAAM;;;;;;;;AASV,MAAa,qBAAqB,OAChC,aACA,WACA,UACA,WAAmB,2BACnB,SACA,SAAiB,QACjB,UAAkB,+BACA;AAIlB,OAAM,IAAI,MACR,oHACD"}
|
|
1
|
+
{"version":3,"file":"bitbucket.service.mjs","names":[],"sources":["../../../src/services/bitbucket.service.ts"],"sourcesContent":["import { configurationFilesCandidates } from '@intlayer/config';\nimport { logger } from '@logger';\nimport { getDBClient } from '@utils/mongoDB/connectDB';\nimport { ObjectId } from 'mongodb';\n\nconst BITBUCKET_API_URL = 'https://api.bitbucket.org/2.0';\nconst BITBUCKET_AUTH_URL = 'https://bitbucket.org/site/oauth2';\n\nexport type BitbucketRepository = {\n uuid: string;\n name: string;\n full_name: string;\n slug: string;\n mainbranch?: {\n name: string;\n type: string;\n };\n links: {\n html: {\n href: string;\n };\n };\n workspace: {\n slug: string;\n name: string;\n uuid: string;\n };\n owner: {\n display_name: string;\n username?: string;\n uuid: string;\n };\n updated_on: string;\n is_private: boolean;\n};\n\nexport type BitbucketTreeItem = {\n path: string;\n type: 'commit_file' | 'commit_directory';\n size?: number;\n};\n\n/**\n * Get Bitbucket (Atlassian) authorization URL for OAuth flow\n */\nexport const getAuthorizationUrl = (redirectUri: string): string => {\n const clientId = process.env.ATLASSIAN_CLIENT_ID;\n\n if (!clientId) {\n throw new Error('Bitbucket/Atlassian Client ID is not configured');\n }\n\n const params = new URLSearchParams({\n client_id: clientId,\n response_type: 'code',\n state: 'bitbucket_oauth',\n });\n\n return `${BITBUCKET_AUTH_URL}/authorize?${params.toString()}`;\n};\n\n/**\n * Exchange Bitbucket authorization code for access token\n */\nexport const exchangeCodeForToken = async (code: string): Promise<string> => {\n const clientId = process.env.ATLASSIAN_CLIENT_ID;\n const clientSecret = process.env.ATLASSIAN_CLIENT_SECRET;\n\n if (!clientId || !clientSecret) {\n throw new Error('Bitbucket OAuth credentials are not configured');\n }\n\n try {\n const credentials = Buffer.from(`${clientId}:${clientSecret}`).toString(\n 'base64'\n );\n\n const response = await fetch(`${BITBUCKET_AUTH_URL}/access_token`, {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/x-www-form-urlencoded',\n Authorization: `Basic ${credentials}`,\n },\n body: new URLSearchParams({\n grant_type: 'authorization_code',\n code,\n }),\n });\n\n if (!response.ok) {\n throw new Error(\n `Bitbucket token exchange failed: ${response.statusText}`\n );\n }\n\n const data = await response.json();\n\n if (data.error) {\n throw new Error(`Bitbucket token error: ${data.error_description}`);\n }\n\n return data.access_token;\n } catch (error) {\n logger.error('Error exchanging Bitbucket code for token:', error);\n throw error;\n }\n};\n\n/**\n * Get user's Bitbucket repositories\n */\nexport const getUserRepositories = async (\n accessToken: string\n): Promise<BitbucketRepository[]> => {\n try {\n // First, get the current user to find their workspaces\n const userResponse = await fetch(`${BITBUCKET_API_URL}/user`, {\n headers: {\n Authorization: `Bearer ${accessToken}`,\n Accept: 'application/json',\n },\n });\n\n if (!userResponse.ok) {\n throw new Error(\n `Failed to fetch Bitbucket user: ${userResponse.statusText}`\n );\n }\n\n // Get repositories the user has access to\n const reposResponse = await fetch(\n `${BITBUCKET_API_URL}/repositories?role=member&sort=-updated_on&pagelen=100`,\n {\n headers: {\n Authorization: `Bearer ${accessToken}`,\n Accept: 'application/json',\n },\n }\n );\n\n if (!reposResponse.ok) {\n throw new Error(\n `Failed to fetch Bitbucket repositories: ${reposResponse.statusText}`\n );\n }\n\n const data = await reposResponse.json();\n return data.values || [];\n } catch (error) {\n logger.error('Error fetching Bitbucket repositories:', error);\n throw error;\n }\n};\n\n/**\n * Check if valid intlayer configuration files exist in a Bitbucket repository (Recursively).\n * Returns an array of file paths found.\n */\nexport const checkIntlayerConfig = async (\n accessToken: string,\n workspace: string,\n repoSlug: string,\n branch: string = 'main'\n): Promise<string[]> => {\n try {\n // Use Bitbucket's src API to list files recursively\n const response = await fetch(\n `${BITBUCKET_API_URL}/repositories/${workspace}/${repoSlug}/src/${encodeURIComponent(branch)}/?max_depth=10&pagelen=10000`,\n {\n headers: {\n Authorization: `Bearer ${accessToken}`,\n Accept: 'application/json',\n },\n }\n );\n\n if (!response.ok) {\n if (response.status === 404) return [];\n throw new Error(\n `Failed to fetch repository tree: ${response.statusText}`\n );\n }\n\n const data = await response.json();\n const items: BitbucketTreeItem[] = data.values || [];\n\n // Filter files that match the configuration candidates\n const foundFiles = items\n .filter((item) => {\n if (item.type !== 'commit_file') return false;\n return (configurationFilesCandidates as readonly string[]).some(\n (candidate) => item.path.endsWith(candidate)\n );\n })\n .map((item) => item.path);\n\n return foundFiles;\n } catch (error: any) {\n if (error.status === 404) return [];\n logger.error('Error checking intlayer configuration on Bitbucket:', error);\n return [];\n }\n};\n\n/**\n * Get repository file contents from Bitbucket and decode it\n */\nexport const getRepositoryFileContents = async (\n accessToken: string,\n workspace: string,\n repoSlug: string,\n path: string,\n branch: string = 'main'\n): Promise<string | null> => {\n try {\n const response = await fetch(\n `${BITBUCKET_API_URL}/repositories/${workspace}/${repoSlug}/src/${encodeURIComponent(branch)}/${encodeURIComponent(path)}`,\n {\n headers: {\n Authorization: `Bearer ${accessToken}`,\n Accept: 'application/json',\n },\n }\n );\n\n if (!response.ok) {\n if (response.status === 404) return null;\n throw new Error(`Failed to fetch file contents: ${response.statusText}`);\n }\n\n const content = await response.text();\n return content;\n } catch (error: any) {\n if (error.status === 404) return null;\n logger.error('Error fetching Bitbucket file contents:', error);\n throw error;\n }\n};\n\n/**\n * Get Bitbucket access token from user's linked account (Atlassian)\n */\nexport const getBitbucketTokenFromUser = async (\n userId: string\n): Promise<string | null> => {\n try {\n const client = getDBClient();\n const db = client.db();\n\n // Try with 'atlassian' provider ID (as it's linked through Better Auth's atlassian provider)\n let account = await db.collection('account').findOne({\n userId: userId,\n providerId: 'atlassian',\n });\n\n if (!account && ObjectId.isValid(userId)) {\n account = await db.collection('account').findOne({\n userId: new ObjectId(userId),\n providerId: 'atlassian',\n });\n }\n\n if (!account) {\n account = await db.collection('accounts').findOne({\n userId: userId,\n providerId: 'atlassian',\n });\n }\n\n if (!account && ObjectId.isValid(userId)) {\n account = await db.collection('accounts').findOne({\n userId: new ObjectId(userId),\n providerId: 'atlassian',\n });\n }\n\n if (!account) {\n return null;\n }\n\n const accessToken = account.accessToken || account.access_token;\n\n return accessToken || null;\n } catch (error) {\n logger.error('Error retrieving Bitbucket token from DB:', error);\n return null;\n }\n};\n\n/**\n * Check if a Bitbucket pipeline file exists\n */\nexport const checkPipelineFileExists = async (\n accessToken: string,\n workspace: string,\n repoSlug: string,\n filename: string = 'bitbucket-pipelines.yml',\n branch: string = 'main'\n): Promise<boolean> => {\n try {\n const response = await fetch(\n `${BITBUCKET_API_URL}/repositories/${workspace}/${repoSlug}/src/${encodeURIComponent(branch)}/${encodeURIComponent(filename)}`,\n {\n headers: {\n Authorization: `Bearer ${accessToken}`,\n Accept: 'application/json',\n },\n }\n );\n\n if (response.status === 404) return false;\n if (!response.ok) {\n throw new Error(`Failed to check file existence: ${response.statusText}`);\n }\n\n return true;\n } catch (error: any) {\n if (error.status === 404) return false;\n logger.error('Error checking pipeline file existence:', error);\n throw error;\n }\n};\n\n/**\n * Create or update a Bitbucket pipeline file\n * Note: Bitbucket API doesn't support direct file creation via API v2.0\n * This function returns false for allowAutoPush, requiring manual installation\n */\nexport const createPipelineFile = async (\n accessToken: string,\n workspace: string,\n repoSlug: string,\n filename: string = 'bitbucket-pipelines.yml',\n content: string,\n branch: string = 'main',\n message: string = 'Add Intlayer CI pipeline'\n): Promise<void> => {\n // Bitbucket API v2.0 doesn't support direct file creation/update\n // Users need to manually add the file or use the web interface\n // We'll throw an error indicating manual installation is required\n throw new Error(\n 'Bitbucket API does not support automatic file creation. Please manually add the pipeline file to your repository.'\n );\n};\n"],"mappings":";;;;;;AAKA,MAAM,oBAAoB;AAC1B,MAAM,qBAAqB;;;;AAuC3B,MAAa,uBAAuB,gBAAgC;CAClE,MAAM,WAAW,QAAQ,IAAI;AAE7B,KAAI,CAAC,SACH,OAAM,IAAI,MAAM,kDAAkD;AASpE,QAAO,GAAG,mBAAmB,aANd,IAAI,gBAAgB;EACjC,WAAW;EACX,eAAe;EACf,OAAO;EACR,CAAC,CAE+C,UAAU;;;;;AAM7D,MAAa,uBAAuB,OAAO,SAAkC;CAC3E,MAAM,WAAW,QAAQ,IAAI;CAC7B,MAAM,eAAe,QAAQ,IAAI;AAEjC,KAAI,CAAC,YAAY,CAAC,aAChB,OAAM,IAAI,MAAM,iDAAiD;AAGnE,KAAI;EACF,MAAM,cAAc,OAAO,KAAK,GAAG,SAAS,GAAG,eAAe,CAAC,SAC7D,SACD;EAED,MAAM,WAAW,MAAM,MAAM,GAAG,mBAAmB,gBAAgB;GACjE,QAAQ;GACR,SAAS;IACP,gBAAgB;IAChB,eAAe,SAAS;IACzB;GACD,MAAM,IAAI,gBAAgB;IACxB,YAAY;IACZ;IACD,CAAC;GACH,CAAC;AAEF,MAAI,CAAC,SAAS,GACZ,OAAM,IAAI,MACR,oCAAoC,SAAS,aAC9C;EAGH,MAAM,OAAO,MAAM,SAAS,MAAM;AAElC,MAAI,KAAK,MACP,OAAM,IAAI,MAAM,0BAA0B,KAAK,oBAAoB;AAGrE,SAAO,KAAK;UACL,OAAO;AACd,SAAO,MAAM,8CAA8C,MAAM;AACjE,QAAM;;;;;;AAOV,MAAa,sBAAsB,OACjC,g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