Translate remaining public pages and remove invoice checkout language option (#7815)
What changed, and why it matters
This commit removes a per-invoice checkout language option and translates more public-facing text so it can be localized. It is a feature-cleanup and internationalization change, not a security fix. There is no evidence of a vulnerability being patched.
No security action required. Treat as a normal feature/localization update; review API consumers that may still send `defaultLanguage` since it is now ignored.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The change drops the DefaultLanguage property from invoice checkout options across the API, controller logic, entity model, tests, and Swagger docs. It also marks many remaining public-page strings with text-translate="true" or StringLocalizer so they are translatable. No input validation, authorization, cryptographic, or injection-related fixes are present in the diff.
Changed components
BTCPayServer.Client/Models/InvoiceData.csBTCPayServer/Controllers/GreenField/GreenfieldInvoiceController.csBTCPayServer/Controllers/UIInvoiceController.UI.csBTCPayServer/Controllers/UIInvoiceController.csBTCPayServer/Services/Invoices/InvoiceEntity.csBTCPayServer/wwwroot/swagger/v1/swagger.template.invoices.jsonCrowdfund public viewPointOfSale public viewsSubscriptions checkout and portal viewsInvoice receipt viewPayment request viewInspect captured patch +122 / −98
### BTCPayServer.Client/Models/InvoiceData.cs
@@ -82,7 +82,6 @@ public class CheckoutOptions
public string RedirectURL { get; set; }
public bool? RedirectAutomatically { get; set; }
- public string DefaultLanguage { get; set; }
public bool? LazyPaymentMethods { get; set; }
}
}
### BTCPayServer.Tests/GreenfieldAPITests.cs
@@ -2590,7 +2590,6 @@ await user.AssertHasWebhookEvent<WebhookInvoiceSettledEvent>(WebhookEventType.In
Amount = 1,
Checkout = new CreateInvoiceRequest.CheckoutOptions
{
- DefaultLanguage = "it-it ",
RedirectURL = "http://toto.com/lol"
}
});
@@ -2600,7 +2599,6 @@ await user.AssertHasWebhookEvent<WebhookInvoiceSettledEvent>(WebhookEventType.In
Assert.EndsWith($"/i/{newInvoice.Id}", newInvoice.CheckoutLink);
var controller = tester.PayTester.GetController<UIInvoiceController>(user.UserId, user.StoreId);
var model = (CheckoutModel)((ViewResult)await controller.Checkout(newInvoice.Id)).Model;
- Assert.Equal("it-IT", model.DefaultLang);
Assert.Equal("http://toto.com/lol", model.MerchantRefLink);
var langs = tester.PayTester.GetService<LanguageService>();
### BTCPayServer/Controllers/GreenField/GreenfieldInvoiceController.cs
@@ -216,21 +216,6 @@ request.Checkout.PaymentMethods[i] is not { } pm ||
"PaymentTolerance can only be between 0 and 100 percent", this);
}
- if (request.Checkout.DefaultLanguage != null)
- {
- var lang = LanguageService.FindLanguage(request.Checkout.DefaultLanguage);
- if (lang == null)
- {
- request.AddModelError(invoiceRequest => invoiceRequest.Checkout.DefaultLanguage,
- "The requested defaultLang does not exists, Browse the ~/misc/lang page of your BTCPay Server instance to see the list of supported languages.", this);
- }
- else
- {
- // Ensure this is good case
- request.Checkout.DefaultLanguage = lang.Code;
- }
- }
-
if (!ModelState.IsValid)
return this.CreateValidationError(ModelState);
@@ -715,7 +700,6 @@ public static InvoiceData ToModel(InvoiceEntity entity, LinkGenerator linkGenera
entity.GetPaymentPrompts().Select(method => method.PaymentMethodId.ToString()).ToArray(),
DefaultPaymentMethod = entity.DefaultPaymentMethod?.ToString(),
SpeedPolicy = entity.SpeedPolicy,
- DefaultLanguage = entity.DefaultLanguage,
RedirectAutomatically = entity.RedirectAutomatically,
RedirectURL = entity.RedirectURLTemplate
},
### BTCPayServer/Controllers/UIInvoiceController.UI.cs
@@ -908,7 +908,7 @@ string GetPaymentMethodImage(PaymentMethodId paymentMethodId2)
RootPath = Request.PathBase.Value.WithTrailingSlash(),
OrderId = orderId,
InvoiceId = invoiceId,
- DefaultLang = lang ?? invoice.DefaultLanguage ?? storeBlob.DefaultLang ?? "en",
+ DefaultLang = lang ?? "en",
ShowPayInWalletButton = storeBlob.ShowPayInWalletButton,
ShowStoreHeader = storeBlob.ShowStoreHeader,
NfcEnabled = storeBlob.NfcEnabled,
### BTCPayServer/Controllers/UIInvoiceController.cs
@@ -182,7 +182,6 @@ public async Task<InvoiceEntity> CreateInvoiceCoreRaw(CreateInvoiceRequest invoi
entity.Type = InvoiceType.TopUp;
}
entity.SpeedPolicy = invoice.Checkout.SpeedPolicy ?? store.SpeedPolicy;
- entity.DefaultLanguage = invoice.Checkout.DefaultLanguage;
if (invoice.Checkout.DefaultPaymentMethod is not null && PaymentMethodId.TryParse(invoice.Checkout.DefaultPaymentMethod, out var paymentMethodId))
{
entity.DefaultPaymentMethod = paymentMethodId;
### BTCPayServer/Plugins/Crowdfund/Views/Public/ViewCrowdfund.cshtml
@@ -87,14 +87,14 @@
}
@if (!Model.Started && Model.StartDate.HasValue)
{
- <h6 class="text-muted fst-italic mt-3" v-if="!started && srvModel.startDate" v-b-tooltip :title="startDate" v-text="`Starts in ${startDiff}`" data-test="time-state">
- @StringLocalizer["Starts {0}", TimeZoneInfo.ConvertTimeFromUtc(Model.StartDate.Value, TimeZoneInfo.Local)]
+ <h6 class="text-muted fst-italic mt-3" v-if="!started && srvModel.startDate" v-b-tooltip :title="startDate" data-test="time-state">
+ <span text-translate="true">Starts in</span> <span v-text="startDiff"></span>
</h6>
}
else if (Model.Started && !Model.Ended && Model.EndDate.HasValue)
{
- <h6 class="text-muted fst-italic mt-3" v-if="started && !ended && srvModel.endDate" v-b-tooltip :title="endDate" v-text="`Ends in ${endDiff}`" data-test="time-state">
- @StringLocalizer["Ends {0}", TimeZoneInfo.ConvertTimeFromUtc(Model.EndDate.Value, TimeZoneInfo.Local)]
+ <h6 class="text-muted fst-italic mt-3" v-if="started && !ended && srvModel.endDate" v-b-tooltip :title="endDate" data-test="time-state">
+ <span text-translate="true">Ends in</span> <span v-text="endDiff"></span>
</h6>
}
else if (Model.Started && !Model.Ended && !Model.EndDate.HasValue)
@@ -136,7 +136,7 @@
<div class="row py-2 text-center crowdfund-stats">
<div class="col-sm border-end p-3 text-center" id="crowdfund-body-raised-amount">
<h3 v-text="`${raisedAmount} ${targetCurrency}`">@Math.Round(Model.Info.CurrentAmount + Model.Info.CurrentPendingAmount, Model.CurrencyData.Divisibility) @Model.TargetCurrency</h3>
- <h5 class="text-muted fst-italic mb-0">Raised</h5>
+ <h5 class="text-muted fst-italic mb-0" text-translate="true">Raised</h5>
<b-tooltip target="crowdfund-body-raised-amount" v-if="paymentStats && paymentStats.length > 0" class="only-for-js">
<ul class="p-0 text-uppercase">
<li v-for="stat of paymentStats" class="list-unstyled">
@@ -148,7 +148,7 @@
<div class="col-sm border-end p-3 text-center" id="crowdfund-body-goal-raised">
<h3 v-text="`${percentageRaisedAmount}%`">@Math.Round(Model.Info.PendingProgressPercentage.GetValueOrDefault(0) + Model.Info.ProgressPercentage.GetValueOrDefault(0))%</h3>
- <h5 class="text-muted fst-italic mb-0">Of Goal</h5>
+ <h5 class="text-muted fst-italic mb-0" text-translate="true">Of Goal</h5>
<b-tooltip target="crowdfund-body-goal-raised" v-if="srvModel.resetEvery !== 'Never'" class="only-for-js">
Goal resets every {{srvModel.resetEveryAmount}} {{srvModel.resetEvery}} {{srvModel.resetEveryAmount>1?'s': ''}}
</b-tooltip>
@@ -241,7 +241,7 @@
</contribute>
</b-modal>
<footer class="store-footer">
- <p class="text-muted" v-text="`Updated ${lastUpdated}`">Updated @Model.Info.LastUpdated</p>
+ <p class="text-muted"><span text-translate="true">Updated</span> <span v-text="lastUpdated">@Model.Info.LastUpdated</span></p>
<a class="store-powered-by" href="https://btcpayserver.org" target="_blank" rel="noreferrer noopener">
<span text-translate="true">Powered by</span> <partial name="_StoreFooterLogo" />
</a>
@@ -328,7 +328,7 @@
</div>
<div class="card-footer d-flex justify-content-between" v-if="perk.sold || perk.inventory != null">
<span v-if="perk.inventory != null && perk.inventory > 0" class="text-center text-muted">{{new Intl.NumberFormat().format(perk.inventory)}} left</span>
- <span v-if="perk.inventory != null && perk.inventory <= 0" class="text-center text-muted">Sold out</span>
+ <span v-if="perk.inventory != null && perk.inventory <= 0" class="text-center text-muted" text-translate="true">Sold out</span>
<span v-if="perk.sold">{{new Intl.NumberFormat().format(perk.sold)}} Contributor{{perk.sold === 1 ? "": "s"}}</span>
<span v-if="perk.value">{{formatAmount(perk.value, srvModel.currencyData.divisibility)}} {{targetCurrency}} total</span>
</div>
### BTCPayServer/Plugins/PointOfSale/Views/Public/Cart.cshtml
@@ -99,7 +99,7 @@
<aside id="cart" ref="cart" tabindex="-1" aria-labelledby="cartLabel">
<div class="public-page-wrap" v-cloak>
<header class="sticky-top bg-tile offcanvas-header py-3 py-lg-4 d-flex align-items-baseline justify-content-center gap-3 px-5 pe-lg-0">
- <h1 class="mb-0" id="cartLabel">Cart</h1>
+ <h1 class="mb-0" id="cartLabel" text-translate="true">Cart</h1>
<button id="CartClear" type="reset" v-on:click="clear" class="btn btn-text text-primary p-1" v-if="cartCount > 0" text-translate="true">
Empty
</button>
### BTCPayServer/Plugins/PointOfSale/Views/Public/Print.cshtml
@@ -30,8 +30,8 @@
@if (supported is null)
{
<div class="alert alert-warning text-center sticky-top mb-0 rounded-0" role="alert">
- LNURL is not enabled on your store, which this print feature relies on.
- <a asp-controller="UIStores" asp-action="LightningSettings" asp-route-cryptoCode="BTC" asp-route-storeId="@store.Id" class="alert-link p-0">
+ <span text-translate="true">LNURL is not enabled on your store, which this print feature relies on.</span>
+ <a asp-controller="UIStores" asp-action="LightningSettings" asp-route-cryptoCode="BTC" asp-route-storeId="@store.Id" class="alert-link p-0" text-translate="true">
Enable LNURL
</a>
</div>
@@ -40,11 +40,11 @@ else
{
<div class="alert alert-info alert-dismissible d-flex align-items-center justify-content-center sticky-top mb-0 rounded-0 d-print-none fade show" role="alert">
<button type="button" class="btn btn-info me-4 border border-light" onclick="window.print()">
- <vc:icon symbol="pos-print" /> Print
+ <vc:icon symbol="pos-print" /> @StringLocalizer["Print"]
</button>
- This view is intended for printing only —
+ @StringLocalizer["This view is intended for printing only"] —
- <a asp-route-viewType="static" class="alert-link">Regular version</a>
+ <a asp-route-viewType="static" class="alert-link" text-translate="true">Regular version</a>
</div>
}
<div id="PosPrint" class="public-page-wrap">
@@ -86,7 +86,7 @@ else
@switch (item.PriceType)
{
case AppItemPriceType.Topup:
- <span>Any amount</span>
+ <span text-translate="true">Any amount</span>
break;
case AppItemPriceType.Minimum:
<span>@formatted minimum</span>
### BTCPayServer/Plugins/PointOfSale/Views/Public/RecentTransactions.cshtml
@@ -5,7 +5,7 @@
<div class="modal-dialog modal-dialog-centered">
<div class="modal-content">
<div class="modal-header">
- <h5 class="modal-title">Recent Transactions</h5>
+ <h5 class="modal-title" text-translate="true">Recent Transactions</h5>
<button type="button" class="btn btn-link px-3 py-0" aria-label="Refresh" v-on:click="loadRecentTransactions" :disabled="recentTransactionsLoading" id="RecentTransactionsRefresh">
<vc:icon symbol="actions-refresh"/>
<span v-if="recentTransactionsLoading" class="visually-hidden" text-translate="true">Loading...</span>
@@ -27,8 +27,8 @@
<vc:icon symbol="caret-right" />
</a>
</div>
- <p v-else-if="recentTransactionsLoading" class="text-muted my-0">Loading...</p>
- <p v-else class="text-muted my-0">No transactions, yet.</p>
+ <p v-else-if="recentTransactionsLoading" class="text-muted my-0" text-translate="true">Loading...</p>
+ <p v-else class="text-muted my-0" text-translate="true">No transactions, yet.</p>
</div>
</div>
</div>
### BTCPayServer/Plugins/PointOfSale/Views/Public/VueLight.cshtml
@@ -34,7 +34,7 @@
<div id="Mode-Discount" class="tab-pane fade px-2" :class="{ show: mode === 'discount', active: mode === 'discount' }" role="tabpanel"
aria-labelledby="ModeTablist-Discount" v-if="showDiscount">
<div class="h4 fw-semibold text-muted text-center" id="Discount">
- <span class="h3 text-body me-1">{{discountPercent || 0}}%</span> discount
+ <span class="h3 text-body me-1">{{discountPercent || 0}}%</span> <span text-translate="true">discount</span>
</div>
</div>
<div id="Mode-Tip" class="tab-pane fade px-2" :class="{ show: mode === 'tip', active: mode === 'tip' }" role="tabpanel"
@@ -48,7 +48,7 @@
:class="{ active: !tipPercent }"
v-on:click.prevent="tipPercent = null">
<template v-if="tip && tip > 0">{{formatCurrency(tip, true)}}</template>
- <template v-else>Custom</template>
+ <template v-else>@StringLocalizer["Custom"]</template>
</button>
<button
v-for="percentage in customTipPercentages"
@@ -107,9 +107,9 @@
</button>
<div class="offcanvas offcanvas-end" data-bs-backdrop="static" tabindex="-1" id="ItemsListOffcanvas" aria-labelledby="ItemsListToggle" v-if="showItems">
<div class="offcanvas-header justify-content-between flex-wrap p-3">
- <h5 class="offcanvas-title" id="offcanvasExampleLabel">Products</h5>
+ <h5 class="offcanvas-title" id="offcanvasExampleLabel" text-translate="true">Products</h5>
<button type="button" class="btn btn-sm rounded-pill" :class="{ 'btn-primary': cart.length > 0, 'btn-outline-secondary': cart.length === 0}"
- data-bs-dismiss="offcanvas" v-text="cart.length > 0 ? 'Apply' : 'Close'"></button>
+ data-bs-dismiss="offcanvas"><template v-if="cart.length > 0">@StringLocalizer["Apply"]</template><template v-else>@StringLocalizer["Close"]</template></button>
@if (Model.ShowSearch)
{
<div class="w-100 mt-3">
### BTCPayServer/Plugins/Subscriptions/Views/UIPlanCheckout/PlanCheckout.cshtml
@@ -1,4 +1,4 @@
-@inject BTCPayServer.Services.BTCPayServerEnvironment Env
+@inject BTCPayServer.Services.BTCPayServerEnvironment Env
@inject DisplayFormatter DisplayFormatter
@inject LinkGenerator LinkGenerator
@using BTCPayServer.Plugins.Subscriptions
@@ -196,7 +196,7 @@
@if (Model.Data.PlanFeatures.Count(i => !string.IsNullOrWhiteSpace(i.Feature.Description)) != 0)
{
- <h5 class="mb-3">What's included:</h5>
+ <h5 class="mb-3" text-translate="true">What's included:</h5>
<ul class="feature-list">
@foreach (var item in Model.Data.PlanFeatures.Where(i => !string.IsNullOrWhiteSpace(i.Feature.Description)))
{
@@ -214,25 +214,25 @@
<div class="col-lg-5 col-md-6">
<div class="checkout-form">
<div class="checkout-header">
- <h4 class="checkout-title">Complete Your Order</h4>
- <p class="checkout-subtitle">Enter your email to proceed to secure payment</p>
+ <h4 class="checkout-title" text-translate="true">Complete Your Order</h4>
+ <p class="checkout-subtitle" text-translate="true">Enter your email to proceed to secure payment</p>
</div>
<form id="checkoutForm" method="post">
<div class="mb-4">
- <label for="customerEmail" class="form-label fw-semibold">Email Address</label>
+ <label for="customerEmail" class="form-label fw-semibold" text-translate="true">Email Address</label>
<input
asp-for="Email"
type="email"
class="plan-checkout__email form-control form-control-lg"
id="emailInput"
- placeholder="Enter your email address"
+ placeholder="@StringLocalizer["Enter your email address"]"
required
disabled="@Model.IsPrefilled">
<span asp-validation-for="Email" class="text-danger"></span>
<div class="form-text">
<i class="fas fa fa-info-circle me-1"></i>
- We'll send your receipt and account details here
+ <span text-translate="true">We'll send your receipt and account details here</span>
</div>
</div>
@if (Model.IsTrial)
### BTCPayServer/Plugins/Subscriptions/Views/UIPlanCheckout/PlanCheckoutDefaultRedirect.cshtml
@@ -1,4 +1,4 @@
-@model PlanCheckoutDefaultRedirectViewModel
+@model PlanCheckoutDefaultRedirectViewModel
@{
ViewData.SetTitle(Model.Title);
ViewData["StoreBranding"] = Model.StoreBranding;
@@ -68,13 +68,13 @@
<i class="fa fa-check"></i>
</div>
- <h1 class="success-title">Payment Successful!</h1>
+ <h1 class="success-title" text-translate="true">Payment Successful!</h1>
- <p class="success-message">
+ <p class="success-message" text-translate="true">
Thank you for your purchase! Your payment has been processed successfully and your subscription is now active.
</p>
- <p class="text-muted">
+ <p class="text-muted" text-translate="true">
A confirmation email has been sent to your registered email address with your subscription details.
</p>
</div>
### BTCPayServer/Plugins/Subscriptions/Views/UISubscriberPortal/NextAction.cshtml
@@ -1,13 +1,13 @@
-@model (string ButtonClass, SubscriberData Subscriber)
+@model (string ButtonClass, SubscriberData Subscriber)
<form method="post">
@if (Model.Subscriber.NextPlan.Renewable)
{
- <button type="submit" name="command" value="pay" class="@Model.ButtonClass">Pay Now</button>
+ <button type="submit" name="command" value="pay" class="@Model.ButtonClass" text-translate="true">Pay Now</button>
}
else
{
- <button type="submit" name="command" value="migrate" class="@Model.ButtonClass">Upgrade</button>
+ <button type="submit" name="command" value="migrate" class="@Model.ButtonClass" text-translate="true">Upgrade</button>
}
</form>
### BTCPayServer/Plugins/Subscriptions/Views/UISubscriberPortal/SubscriberPortal.cshtml
@@ -238,17 +238,17 @@
<partial name="_StatusMessage" />
<!-- Page Header -->
<div class="d-flex justify-content-between align-items-center mb-4">
- <h2 class="mb-0">Subscription Management</h2>
+ <h2 class="mb-0" text-translate="true">Subscription Management</h2>
@if (@Model.Subscriber.Customer.ExternalRef is not null)
{
- <span class="text-muted">Customer Reference: @Model.Subscriber.Customer.ExternalRef</span>
+ <span class="text-muted">@StringLocalizer["Customer Reference: {0}", Model.Subscriber.Customer.ExternalRef]</span>
}
</div>
<!-- Current Subscription -->
<div class="card">
<div class="card-header">
- <i class="fa fa-address-book me-2"></i>Current Subscription
+ <i class="fa fa-address-book me-2"></i><span text-translate="true">Current Subscription</span>
</div>
<div class="card-body">
<div class="row">
@@ -279,15 +279,15 @@
{
@if (Model.Subscriber.Phase is SubscriberData.PhaseTypes.Normal)
{
- <span class="text-muted">Next billing: @date</span>
+ <span class="text-muted">@StringLocalizer["Next billing: {0}", date]</span>
}
else if (Model.Subscriber.Phase is SubscriberData.PhaseTypes.Trial)
{
- <span class="text-muted">Trial expires: @date</span>
+ <span class="text-muted">@StringLocalizer["Trial expires: {0}", date]</span>
}
else if (Model.Subscriber.Phase is SubscriberData.PhaseTypes.Grace)
{
- <span class="text-muted">The subscription has already expired and will soon be inactivated</span>
+ <span class="text-muted" text-translate="true">The subscription has already expired and will soon be inactivated</span>
}
}
</div>
@@ -309,11 +309,11 @@
<div class="notice-content">
<i class="fa fa-warning alert-icon"></i>
<div class="alert-text">
- <div class="notice-title"><span>Access suspended</span></div>
- <p class="notice-subtitle">Your access to this subscription has been suspended.</p>
+ <div class="notice-title"><span text-translate="true">Access suspended</span></div>
+ <p class="notice-subtitle" text-translate="true">Your access to this subscription has been suspended.</p>
@if (!String.IsNullOrEmpty(Model.Subscriber.SuspensionReason))
{
- <p class="notice-subtitle">Reason: @Model.Subscriber.SuspensionReason</p>
+ <p class="notice-subtitle">@StringLocalizer["Reason: {0}", Model.Subscriber.SuspensionReason]</p>
}
</div>
</div>
@@ -325,8 +325,8 @@
<div class="notice-content">
<i class="fa fa-warning alert-icon"></i>
<div class="alert-text">
- <div class="notice-title"><span>Access expired</span></div>
- <p class="notice-subtitle">Your access to this subscription has been expired.</p>
+ <div class="notice-title"><span text-translate="true">Access expired</span></div>
+ <p class="notice-subtitle" text-translate="true">Your access to this subscription has been expired.</p>
</div>
</div>
<partial name="NextAction" model="@("btn btn-danger", Model.Subscriber)" />
@@ -338,8 +338,8 @@
<div class="notice-content">
<i class="fa fa-warning alert-icon"></i>
<div class="alert-text">
- <div class="notice-title"><span>You are in trial</span></div>
- <p class="notice-subtitle">You access will be revoked in <span>@FormatDays(daysRemaining)</span></p>
+ <div class="notice-title"><span text-translate="true">You are in trial</span></div>
+ <p class="notice-subtitle">@StringLocalizer["You access will be revoked in {0}", FormatDays(daysRemaining)]</p>
</div>
</div>
<partial name="NextAction" model="@("btn btn-info", Model.Subscriber)" />
@@ -352,8 +352,8 @@
<div class="notice-content">
<i class="fa fa-warning alert-icon"></i>
<div class="alert-text">
- <div class="notice-title">Upgrade needed in <span>@FormatDays(daysRemaining)</span></div>
- <div class="notice-subtitle">You access will be revoked in <span>@FormatDays(daysRemaining)</span>, you need to subscribe to a new plan.</div>
+ <div class="notice-title">@StringLocalizer["Upgrade needed in {0}", FormatDays(daysRemaining)]</div>
+ <div class="notice-subtitle">@StringLocalizer["You access will be revoked in {0}, you need to subscribe to a new plan.", FormatDays(daysRemaining)]</div>
</div>
</div>
<partial name="NextAction" model="@("btn btn-warning", Model.Subscriber)" />
@@ -368,7 +368,7 @@
<div class="notice-content">
<i class="fa fa-warning alert-icon"></i>
<div class="alert-text">
- <div class="notice-title">Payment due</div>
+ <div class="notice-title" text-translate="true">Payment due</div>
<div class="notice-subtitle">You access will be revoked in <span>@FormatDays(graceRemaining)</span></div>
</div>
</div>
@@ -381,9 +381,8 @@
<div class="notice-content">
<i class="fa fa-clock-o alert-icon"></i>
<div class="alert-text">
- <div class="notice-title">Payment due in <span>@FormatDays(daysRemaining)</span></div>
- <p class="notice-subtitle">Next billing
- date: @date • @DisplayFormatter.Currency(Model.Subscriber.Plan.Price, Model.Subscriber.Plan.Currency, DisplayFormatter.CurrencyFormat.Symbol)</p>
+ <div class="notice-title">@StringLocalizer["Payment due in {0}", FormatDays(daysRemaining)]</div>
+ <p class="notice-subtitle">@StringLocalizer["Next billing date: {0} • {1}", date, DisplayFormatter.Currency(Model.Subscriber.Plan.Price, Model.Subscriber.Plan.Currency, DisplayFormatter.CurrencyFormat.Symbol)]</p>
</div>
</div>
<partial name="NextAction" model="@("btn btn-warning", Model.Subscriber)" />
@@ -414,7 +413,7 @@
<form method="post">
<div class="input-group">
<button type="submit" name="command" value="add-credit" class="btn btn-primary">Proceed to payment</button>
- <input inputmode="decimal" class="form-control" placeholder="Enter credit amount" asp-for="Credit.InputAmount" min="0"
+ <input inputmode="decimal" class="form-control" placeholder="@StringLocalizer["Enter credit amount"]" asp-for="Credit.InputAmount" min="0"
required />
</div>
<span asp-validation-for="Credit.InputAmount" class="text-danger"></span>
@@ -446,7 +445,7 @@
</div>
}
<div class="d-flex justify-content-between fw-semibold credit-next-charge">
- <div>Next charge on @date</div>
+ <div>@StringLocalizer["Next charge on {0}", date]</div>
<div>@DisplayFormatter.Currency(Model.Credit.NextCharge, Model.Credit.Currency, DisplayFormatter.CurrencyFormat.Symbol)</div>
</div>
<form method="post" class="d-flex mt-3">
@@ -504,7 +503,7 @@
<div class="notice-content">
<i class="fa fa-clock-o alert-icon"></i>
<div class="alert-text">
- <div class="notice-title">Plan change scheduled</div>
+ <div class="notice-title" text-translate="true">Plan change scheduled</div>
<p class="notice-subtitle">
Switching to <strong>@Model.Subscriber.NewPlan.Name</strong>
on @(Model.Subscriber.PeriodEnd?.ToString("D") ?? "period end")
@@ -550,7 +549,7 @@
@(hasPending ? "" : "data-bs-toggle=modal")
@(hasPending ? "" : "data-bs-target=#changePlanModal")
data-action="upgrade"
- title="@(hasPending ? "Cancel your scheduled change first" : "")">
+ title="@(hasPending ? StringLocalizer["Cancel your scheduled change first"] : "")">
Upgrade
</a>
}
@@ -561,7 +560,7 @@
@(hasPending ? "" : "data-bs-toggle=modal")
@(hasPending ? "" : "data-bs-target=#changePlanModal")
data-action="downgrade"
- title="@(hasPending ? "Cancel your scheduled change first" : "")">
+ title="@(hasPending ? StringLocalizer["Cancel your scheduled change first"] : "")">
Downgrade
</a>
}
### BTCPayServer/Plugins/Translations/Translations.Default.cs
@@ -74,6 +74,7 @@ static Translations()
"A \"Contact Us\" button with this link will be shown on the checkout page. Can contain the placeholders <code>{OrderId}</code> and <code>{InvoiceId}</code>. Can be any valid URI, such as a website, email, and Nostr.": "",
"A <code>POST</code> callback will be sent to the specified <code>notificationUrl</code> (for on-chain transactions when there are sufficient confirmations):": "",
"A camera was not detected on your device.": "",
+ "A confirmation email has been sent to your registered email address with your subscription details.": "",
"A delay means your service either failed to process earlier deliveries or is taking too long to respond.": "",
"A given currency pair match the most specific rule. If two rules are matching and are as specific, the first\n rule\n will be chosen.": "",
"A malicious actor with access to this QR Code can affect the performances of your server.": "",
@@ -89,6 +90,8 @@ static Translations()
"A self-hosted, open-source bitcoin payment processor.": "",
"Abort": "",
"Accept invitation": "",
+ "Access expired": "",
+ "Access suspended": "",
"Access to vault granted by owner.": "",
"Access Tokens": "",
"Access tokens are for legacy integrations": "",
@@ -135,6 +138,7 @@ static Translations()
"Add User": "",
"Add Webhook": "",
"Additional Actions": "",
+ "Additional Data": "",
"Additional Information": "",
"Additional Options": "",
"Additional rates to track": "",
@@ -148,6 +152,7 @@ static Translations()
"Adjust the design of your BTCPay Server instance to your needs.": "",
"Adjusts the generated invoice amount — use as a prefix to have multiple adjustment fields": "",
"Adjusts the generated invoice amount by multiplying with this value — use as a prefix to have multiple adjustment fields": "",
+ "Admin details": "",
"Admin must approve new users": "",
"Administrator": "",
"Advanced Options": "",
@@ -181,6 +186,7 @@ static Translations()
"Amount": "",
"Amount and currency are not editable once payment request has invoices": "",
"Amount must be greater than 0": "",
+ "Amount paid": "",
"Amount Paid": "",
"Amount requested": "",
"An error occurred while resetting user password": "",
@@ -213,6 +219,7 @@ static Translations()
"App Type": "",
"App updated": "",
"Application": "",
+ "Apply": "",
"Apply the brand color to the store's backend as well": "",
"Approve": "",
"Approve & Send": "",
@@ -315,8 +322,10 @@ static Translations()
"Cancel": "",
"Cancel Invoice": "",
"Cancel pending {0}": "",
+ "Cancel your scheduled change first": "",
"Cannot delete plan. It is currently in use by subscribers.": "",
"Cannot generate API keys while not using HTTPS or Tor": "",
+ "Cart": "",
"Categories": "",
"Caution: Allowing non-admins to have access to API endpoints may expose your BTCPay Server instance to potential security risks from unknown users.": "",
"Caution: Enabling public user registration means anyone can register to your server and may expose your BTCPay Server instance to potential security risks from unknown users.": "",
@@ -387,6 +396,7 @@ static Translations()
"Comment": "",
"Compatible wallets": "",
"Complete signer collection before creating the multisig wallet.": "",
+ "Complete Your Order": "",
"Completed": "",
"CONFIDENTIAL: This QR Code is confidential, close this window as soon as you don't need it anymore.": "",
"Config file was not in the correct format": "",
@@ -517,8 +527,10 @@ static Translations()
"Current effective fee rate": "",
"Current password": "",
"Current Rates source is": "",
+ "Current Subscription": "",
"Currently active!": "",
"Currently enabled on this server.": "",
+ "Custom": "",
"Custom (Advanced)": "",
"Custom amount": "",
"Custom Amount": "",
@@ -535,6 +547,7 @@ static Translations()
"Custom Theme File": "",
"Customer Email": "",
"Customer Information": "",
+ "Customer Reference: {0}": "",
"Customization": "",
"Customize Pay Button Text": "",
"Customize the checkout experience your customers see when paying.": "",
@@ -607,6 +620,7 @@ static Translations()
"Disabled version": "",
"Disabling will delete your rate script.": "",
"Disclaimer of Responsibility:": "",
+ "discount": "",
"Discount": "",
"Discounts": "",
"Discourage search engines from indexing this site": "",
@@ -666,6 +680,7 @@ static Translations()
"Either your {0} wallet is not configured, or it is not a hot wallet. This processor cannot function until a hot wallet is configured in your store.": "",
"Email": "",
"Email address": "",
+ "Email Address": "",
"Email address is confirmed": "",
"Email Configuration": "",
"Email confirmation required": "",
@@ -712,10 +727,10 @@ static Translations()
"Enabling will modify your current rate sources. This is a feature for advanced users.": "",
"End date": "",
"End Date": "",
- "Ends {0}": "",
"Ends in": "",
"Enhance the checkout process for in-store purchases.<br />This assumes the payment page will be displayed on the merchant's device.": "",
"Enhance the checkout process for online purchases.<br />This assumes the payment page will be displayed on the customer's device.": "",
+ "Enter credit amount": "",
"Enter destination to claim funds": "",
"Enter extended public key": "",
"Enter signer key manually": "",
@@ -724,6 +739,8 @@ static Translations()
"Enter the pin.": "",
"Enter the wallet seed": "",
"Enter wallet seed": "",
+ "Enter your email address": "",
+ "Enter your email to proceed to secure payment": "",
"Enter your extended public key": "",
"Error": "",
"Error updating profile": "",
@@ -963,6 +980,7 @@ static Translations()
"Invoice {0}": "",
"Invoice {0} just created!": "",
"Invoice {0}..": "",
+ "Invoice Amount": "",
"Invoice currency": "",
"Invoice expires if the full amount has not been paid after …": "",
"Invoice Id": "",
@@ -1047,6 +1065,7 @@ static Translations()
"LNURL Auth was removed successfully.": "",
"LNURL Authentication": "",
"LNURL Classic Mode": "",
+ "LNURL is not enabled on your store, which this print feature relies on.": "",
"LNURL is required for lightning addresses but has not yet been enabled.": "",
"LNURL or LN is disabled": "",
"LNURL-Withdraw": "",
@@ -1148,6 +1167,9 @@ static Translations()
"New Version": "",
"New version {0} released!": "",
"Next": "",
+ "Next billing date: {0} • {1}": "",
+ "Next billing: {0}": "",
+ "Next charge on {0}": "",
"No": "",
"No access tokens yet.": "",
"No action needed": "",
@@ -1187,6 +1209,7 @@ static Translations()
"No start date has been set": "",
"No stores": "",
"No transaction selected": "",
+ "No transactions, yet.": "",
"No unpaid pending invoice to cancel": "",
"No users": "",
"Node headers height: {0}": "",
@@ -1215,6 +1238,7 @@ static Translations()
"Notifications": "",
"Notifications & Alerts": "",
"Occurred": "",
+ "Of Goal": "",
"Offering ({0})": "",
"Offering configuration updated": "",
"Offline signing, without connecting your wallet to the internet": "",
@@ -1289,6 +1313,8 @@ static Translations()
"Pay Button request failed": "",
"Pay Button Text": "",
"Pay Invoice": "",
+ "Pay Now": "",
+ "Pay Proof": "",
"Paying via this payment method is not supported": "",
"PayJoin BIP21": "",
"PayJoin enhances the privacy for you and your customers. Enabling it gives your customers the option to use PayJoin during checkout.": "",
@@ -1298,6 +1324,8 @@ static Translations()
"Payment {0}": "",
"Payment cancelled": "",
"Payment Details": "",
+ "Payment due": "",
+ "Payment due in {0}": "",
"Payment for <strong>{0}</strong>": "",
"Payment History": "",
"Payment invalid if transactions fails to confirm … after invoice expiration": "",
@@ -1318,6 +1346,7 @@ static Translations()
"payment requests": "",
"Payment Requests": "",
"Payment requests are persistent shareable pages that enable the receiver to pay at their convenience. Funds are paid to a payment request at the current exchange rate.": "",
+ "Payment Successful!": "",
"Payment to <strong>{0}</strong>": "",
"Payment to <strong>{0}</strong> for <strong>{1}</strong>": "",
"Payments": "",
@@ -1354,6 +1383,7 @@ static Translations()
"Placeholder": "",
"Placeholders": "",
"Plan": "",
+ "Plan change scheduled": "",
"Plan deleted": "",
"Plan edited": "",
"Plan ID": "",
@@ -1433,6 +1463,7 @@ static Translations()
"Product Information": "",
"Product list": "",
"Product list with cart": "",
+ "Products": "",
"Profile Picture": "",
"Proof: {0}": "",
"Provide the 12 or 24 word recovery seed": "",
@@ -1461,6 +1492,7 @@ static Translations()
"Query pairs via REST by querying {0} without the need to specify currencyPairs.": "",
"Query timezone": "",
"Quick Fill": "",
+ "Raised": "",
"Rate": "",
"Rate rule scripting": "",
"Rate Rules": "",
@@ -1475,7 +1507,9 @@ static Translations()
"Rates": "",
"Read more": "",
"Ready to create wallet": "",
+ "Reason: {0}": "",
"Receipt": "",
+ "Receipt from {0}": "",
"Receipt Information": "",
"Receive": "",
"Receive {0}": "",
@@ -1512,6 +1546,7 @@ static Translations()
"Register your passkey": "",
"Register your security device": "",
"Registration": "",
+ "Regular version": "",
"Remember me": "",
"Remote plugins lookup failed. Try again later. Error: {0}": "",
"Remove": "",
@@ -1792,7 +1827,7 @@ static Translations()
"Starter plan monthly cost": "",
"Starting {0}...": "",
"Starting index": "",
- "Starts {0}": "",
+ "Starts in": "",
"Startup": "",
"State": "",
"Status": "",
@@ -1844,6 +1879,7 @@ static Translations()
"Subscriber {0} is now unsuspended": "",
"Subscribers": "",
"Subscription dates updated for {0}": "",
+ "Subscription Management": "",
"Subscriptions": "",
"Subtotal": "",
"Subtract fees from amount": "",
@@ -1881,6 +1917,7 @@ static Translations()
"Text to display in the tip input": "",
"Text to display on buttons allowing the user to enter a custom amount": "",
"Text to display on each button for items with a specific price": "",
+ "Thank you for your purchase! Your payment has been processed successfully and your subscription is now active.": "",
"Thank you for your purchase. Here is your receipt": "",
"The {0} offers programmatic access to your instance. You can manage your BTCPay Server (e.g. stores, invoices, users) as well as automate workflows and integrations (see {1}). For that you need the API keys, which can be generated here. Find more information in the {2}.": "",
"The <code>macaroon</code> parameter expects the HEX value, it can be obtained using this\n command:": "",
@@ -1933,6 +1970,7 @@ static Translations()
"The hardware wallet requires previous transactions in the PSBT. Please go to your wallet settings and enable \"Include non-witness UTXO in PSBTs": "",
"The import file is too big (1 MB maximum).": "",
"The invitation expires {0}.": "",
+ "The invoice could not be cancelled": "",
"The invoice currency, at the rate when the refund will be sent.": "",
"The invoice has been archived and will no longer appear in the invoice list by default.": "",
"The invoice has been unarchived and will appear in the invoice list by default again.": "",
@@ -1992,6 +2030,7 @@ static Translations()
"The store template sets defaults for all new stores. It includes rates settings, default invoice settings, checkout display settings but excludes sensitive data like access tokens, payment method settings, webhooks.": "",
"The store will be permanently deleted. This action will also delete all invoices, apps and data associated with the store.": "",
"The store will be permanently deleted. This action will also delete all invoices, apps and data associated with the store. Are you sure?": "",
+ "The subscription has already expired and will soon be inactivated": "",
"The translation <b>{0}</b> will be removed from this server.": "",
"The trial has started.": "",
"The uploaded file needs to be a CSS file": "",
@@ -2109,6 +2148,7 @@ static Translations()
"This transaction will change your balance:": "",
"This translation will be removed from this server.": "",
"This version of NBXplorer is not compatible. Please update to 2.5.22 or above": "",
+ "This view is intended for printing only": "",
"This webhook will be removed from this store.": "",
"This week": "",
"This will approve the user <strong>{0}</strong>.": "",
@@ -2156,10 +2196,12 @@ static Translations()
"Total Contributions": "",
"Total due": "",
"Total Permissions": "",
+ "Total requested": "",
"Total Sales": "",
"total signers": "",
"Total signers (N)": "",
"Total signers must be between 1 and 15.": "",
+ "Total Taxes": "",
"Track signer key collection and finalize setup once all keys are submitted.": "",
"Transaction": "",
"Transaction broadcasted successfully ({0})": "",
@@ -2183,6 +2225,7 @@ static Translations()
"Translations": "",
"Translations are formatted as JSON; for example, <b>{0}</b> translates <b>{1}</b> to <b>{2}</b>.": "",
"Trial": "",
+ "Trial expires: {0}": "",
"Trial Period": "",
"Trial Period (days)": "",
"Trigger": "",
@@ -2232,8 +2275,10 @@ static Translations()
"Update to the latest version of BTCPay Server.": "",
"Update Webhook": "",
"Update your account": "",
+ "Updated": "",
"Updated successfully.": "",
"Upgrade": "",
+ "Upgrade needed in {0}": "",
"Upload": "",
"Upload a file exported from your wallet": "",
"Upload and manage files stored with your configured storage provider.": "",
@@ -2349,12 +2394,14 @@ static Translations()
"We recommend users exercise caution and conduct their own research or consult the community before installing any plugin.": "",
"We rejected the receiver's payjoin proposal: {0}": "",
"We will try to redeliver any failed delivery after 10 seconds, 1 minute and up to 6 times after 10 minutes": "",
+ "We'll send your receipt and account details here": "",
"Webhook successfully deleted": "",
"Webhooks": "",
"Webhooks allow BTCPay Server to send HTTP events related to your store to another server.": "",
"Welcome to {0}": "",
"Well-known Dynamic DNS providers are:": "",
"What is a passkey?": "",
+ "What's included:": "",
"When enabled, prices entered in the keypad are tax inclusive.": "",
"When enabled, this user will not be required to have an active subscription.": "",
"When unchecked, an existing user is given access immediately, without being asked.": "",
@@ -2374,6 +2421,9 @@ static Translations()
"Yes": "",
"Yesterday": "",
"You": "",
+ "You access will be revoked in {0}": "",
+ "You access will be revoked in {0}, you need to subscribe to a new plan.": "",
+ "You are in trial": "",
"You are invited": "",
"You are not a signer": "",
"You are not authorized to run maintenance commands.": "",
@@ -2418,6 +2468,8 @@ static Translations()
"You participated": "",
"You really should not type your seed into a device that is connected to the internet.": "",
"Your access to BTCPay Server is over an unsecured network. If you are using the docker deployment method with NGINX and HTTPS is not available, you probably did not configure your DNS settings correctly. We disabled the register and login link so you don't leak your credentials.": "",
+ "Your access to this subscription has been expired.": "",
+ "Your access to this subscription has been suspended.": "",
"Your account will no longer be linked to the lightning node <strong>{0}</strong> as an option for two-factor authentication.": "",
"Your account will no longer have the passkey <strong>{0}</strong> as an option for passwordless login.": "",
"Your account will no longer have the security device <strong>{0}</strong> as an option for two-factor authentication.": "",
### BTCPayServer/Services/Invoices/InvoiceEntity.cs
@@ -294,8 +294,6 @@ class ProductInformation
public string StoreId { get; set; }
public SpeedPolicy SpeedPolicy { get; set; }
- [JsonProperty]
- public string DefaultLanguage { get; set; }
[JsonIgnore]
public DateTimeOffset InvoiceTime { get; set; }
public DateTimeOffset ExpirationTime { get; set; }
### BTCPayServer/Views/UIInvoice/InvoiceReceipt.cshtml
@@ -85,13 +85,13 @@
</div>
}
<div class="d-flex flex-column">
- <dd class="text-muted mb-0 fw-semibold">Date</dd>
+ <dd class="text-muted mb-0 fw-semibold" text-translate="true">Date</dd>
<dt class="fs-5 mb-0 text-nowrap fw-semibold">@Model.Timestamp.ToBrowserDate()</dt>
</div>
@if (!string.IsNullOrEmpty(Model.OrderId))
{
<div class="d-flex flex-column">
- <dd class="text-muted mb-0 fw-semibold">Order ID</dd>
+ <dd class="text-muted mb-0 fw-semibold" text-translate="true">Order ID</dd>
<dt class="fs-5 mb-0 text-break fw-semibold">@Model.OrderId</dt>
</div>
}
@@ -197,9 +197,9 @@
</main>
<footer class="store-footer">
<p permission="@Policies.CanViewInvoices" class="d-print-none">
- <a asp-action="Invoice" asp-route-invoiceId="@Model.InvoiceId">
- Admin details
- </a>
+ <a asp-action="Invoice" asp-route-invoiceId="@Model.InvoiceId" text-translate="true">
+ Admin details
+ </a>
</p>
<a class="store-powered-by" href="https://btcpayserver.org" target="_blank" rel="noreferrer noopener">
<span text-translate="true">Powered by</span> <partial name="_StoreFooterLogo" />
### BTCPayServer/Views/UIPaymentRequest/ViewPaymentRequest.cshtml
@@ -125,19 +125,19 @@
</div>
<div class="d-flex flex-wrap gap-3 align-items-center justify-content-between">
<div class="d-flex d-print-inline-block flex-column gap-1">
- <dd class="text-secondary mb-0">Amount paid</dd>
+ <dd class="text-secondary mb-0" text-translate="true">Amount paid</dd>
<dt class="h4 fw-semibold text-nowrap" v-text="srvModel.amountCollectedFormatted">@Model.AmountCollectedFormatted</dt>
</div>
<div class="d-flex d-print-inline-block flex-column gap-1">
- <dd class="text-secondary mb-0 text-sm-end">Total requested</dd>
+ <dd class="text-secondary mb-0 text-sm-end" text-translate="true">Total requested</dd>
<dt class="h4 fw-semibold text-nowrap text-sm-end" v-text="srvModel.amountFormatted">@Model.AmountFormatted</dt>
</div>
</div>
</dl>
<div class="buttons mt-3">
<template v-if="srvModel.formId && srvModel.formId !== 'None' && !srvModel.formSubmitted">
- <a asp-action="ViewPaymentRequestForm" asp-route-payReqId="@Model.Id" class="btn btn-primary btn-lg" data-test="form-button">
+ <a asp-action="ViewPaymentRequestForm" asp-route-payReqId="@Model.Id" class="btn btn-primary btn-lg" data-test="form-button" text-translate="true">
Pay Invoice
</a>
</template>
### BTCPayServer/wwwroot/swagger/v1/swagger.template.invoices.json
@@ -1203,11 +1203,6 @@
"type": "boolean",
"nullable": true,
"description": "When the customer has paid the invoice, and a `redirectURL` is set, the checkout is redirected to `redirectURL` automatically if `redirectAutomatically` is true. Defaults to the store's settings. (The default store settings is false)"
- },
- "defaultLanguage": {
- "type": "string",
- "nullable": true,
- "description": "The language code (eg. en-US, en, fr-FR...) of the language presented to your customer in the checkout page. BTCPay Server tries to match the best language available. If null or not set, will fallback on the store's default language. You can see the list of language codes with [this operation](#operation/langCodes)."
}
}
},Why this scored 19/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.