fix(editor): Update free AI credits success claim callout (no-changelog) (#12480)

This commit is contained in:
Ricardo Espinoza 2025-01-07 10:01:29 -05:00 committed by GitHub
parent c03fe0af38
commit ac6b244c71
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 23 additions and 7 deletions

View file

@ -60,7 +60,17 @@ const assertUserCanClaimCredits = () => {
};
const assertUserClaimedCredits = () => {
expect(screen.getByText('Claimed 100 free OpenAI API credits')).toBeInTheDocument();
expect(
screen.getByText(
'Claimed 100 free OpenAI API credits! Please note these free credits are only for the following models:',
),
).toBeInTheDocument();
expect(
screen.getByText(
'gpt-4o-mini, text-embedding-3-small, dall-e-3, tts-1, whisper-1, and text-moderation-latest',
),
).toBeInTheDocument();
};
describe('FreeAiCreditsCallout', () => {

View file

@ -112,11 +112,16 @@ const onClaimCreditsClicked = async () => {
</template>
</n8n-callout>
<n8n-callout v-else-if="showSuccessCallout" theme="success" icon="check-circle">
{{
i18n.baseText('freeAi.credits.callout.success.title', {
interpolate: { credits: settingsStore.aiCreditsQuota },
})
}}
<n8n-text>
{{
i18n.baseText('freeAi.credits.callout.success.title.part1', {
interpolate: { credits: settingsStore.aiCreditsQuota },
})
}}</n8n-text
>&nbsp;
<n8n-text :bold="true">
{{ i18n.baseText('freeAi.credits.callout.success.title.part2') }}</n8n-text
>
</n8n-callout>
</div>
</template>

View file

@ -2844,7 +2844,8 @@
"testDefinition.deleteTest": "Delete Test",
"freeAi.credits.callout.claim.title": "Get {credits} free OpenAI API credits",
"freeAi.credits.callout.claim.button.label": "Claim credits",
"freeAi.credits.callout.success.title": "Claimed {credits} free OpenAI API credits",
"freeAi.credits.callout.success.title.part1": "Claimed {credits} free OpenAI API credits! Please note these free credits are only for the following models:",
"freeAi.credits.callout.success.title.part2": "gpt-4o-mini, text-embedding-3-small, dall-e-3, tts-1, whisper-1, and text-moderation-latest",
"freeAi.credits.credentials.edit": "This is a managed credential and cannot be edited.",
"freeAi.credits.showError.claim.title": "Free AI credits",
"freeAi.credits.showError.claim.message": "Enable to claim credits"