btcpayserver/BTCPayServer/Controllers
Wouter Samaey d8c1c51a21
Auto-detect language on payment page (#2552)
* Auto-detect language on payment page

based on the requst Accept-Language header, which is the language you configured in your browser/OS and this 99.99% accurate

* Update BTCPayServer/Services/LanguageService.cs

Co-authored-by: britttttk <39231115+britttttk@users.noreply.github.com>

* Update BTCPayServer/Services/LanguageService.cs

Co-authored-by: Andrew Camilleri <evilkukka@gmail.com>

* Update BTCPayServer/Services/LanguageService.cs

Co-authored-by: Andrew Camilleri <evilkukka@gmail.com>

* Update BTCPayServer/Services/LanguageService.cs

Co-authored-by: Andrew Camilleri <evilkukka@gmail.com>

* Added loop for all locales in Accept-Language sorted by weight + check if know this language

* New public method so a unit test can be created for it

* Unit test for language detection

* Fix language service when not in browser context

* fall back to default lang

* Auto-detect setting + ?lang=auto support

* Added invoice param "?lang=auto" info to docs

* Using null-coalescing assignment operator

* Reduce complexity and http dependency in language service

Co-authored-by: britttttk <39231115+britttttk@users.noreply.github.com>
Co-authored-by: Andrew Camilleri <evilkukka@gmail.com>
2021-07-27 08:17:56 +02:00
..
GreenField Auto-detect language on payment page (#2552) 2021-07-27 08:17:56 +02:00
AccessTokenController.cs Plugins: Allow creation of independent DbContexts 2020-11-18 12:27:26 +01:00
AccountController.cs U2fremove (#2496) 2021-04-28 16:22:09 +09:00
AppsController.Crowdfund.cs Improve and unify page headers (#2412) 2021-04-08 22:32:42 +09:00
AppsController.cs Plugins: Allow creation of independent DbContexts 2020-11-18 12:27:26 +01:00
AppsController.PointOfSale.cs Use ~ prefix for local PoS image references 2021-06-01 14:34:06 +02:00
AppsPublicController.cs Refactor domain mapping (#2407) 2021-03-30 11:47:03 +09:00
ErrorController.cs Http error page 406 for our dear man Jack 2021-01-24 13:41:30 -06:00
HomeController.cs Add misc/permissions to document the hierarchical structure (#2654) 2021-07-08 14:34:10 +09:00
InvoiceController.API.cs Remove only dependency on Dbriize (TextSearch in new invoice column) (#2029) 2020-12-28 19:10:53 +09:00
InvoiceController.cs Auto-detect language on payment page (#2552) 2021-07-27 08:17:56 +02:00
InvoiceController.UI.cs Auto-detect language on payment page (#2552) 2021-07-27 08:17:56 +02:00
Macaroons.cs Removing unused usings, readonly fields where possible 2020-06-28 22:07:48 -05:00
ManageController.2FA.cs Fix 2FA config screens 2020-07-13 10:58:53 +02:00
ManageController.APIKeys.cs Greenfield: Add CanModifyInvoices Permissions (#2595) 2021-07-11 00:30:01 +09:00
ManageController.cs U2fremove (#2496) 2021-04-28 16:22:09 +09:00
ManageController.Notifications.cs Plugins: Allow creation of independent DbContexts 2020-11-18 12:27:26 +01:00
NotificationsController.cs Update NBitcoin, NetworkType => ChainName, signet support (#2224) 2021-01-27 14:39:38 +09:00
PaymentRequestController.cs Save paymentRequestId in Metadata when creating invoice for Payment Request (#2644) 2021-07-14 20:43:13 +09:00
PublicController.cs Create Metadata property for InvoiceEntity, migrate all data without logic there 2020-08-26 21:36:31 +09:00
PublicLightningNodeInfoController.cs Improve Lightning node info view (#2066) 2020-11-17 08:57:14 +01:00
PullPaymentController.cs Mark Payouts as Paid (#2539) 2021-06-10 18:43:45 +09:00
RateController.cs Plugins: Allow creation of independent DbContexts 2020-11-18 12:27:26 +01:00
ServerController.cs Improves create point of sale view (#2646) 2021-07-23 12:57:19 +02:00
ServerController.Plugins.cs Plugin FailSafe (#2351) 2021-04-01 12:27:22 +09:00
ServerController.Storage.cs Updated status message when adding files and related test 2021-07-22 08:49:21 +02:00
ServerController.Users.cs Add IsRoleAdmin to user service 2021-06-02 20:02:26 -07:00
StorageController.cs More Options refactoring (#2179) 2021-01-06 23:51:13 +09:00
StoresController.cs Auto-detect language on payment page (#2552) 2021-07-27 08:17:56 +02:00
StoresController.Email.cs Add tests 2020-10-05 18:09:00 +09:00
StoresController.Integrations.cs Add webhook delivery status indicator (#2679) 2021-07-12 21:58:11 +09:00
StoresController.LightningLike.cs Lightning setup redesign 2021-04-20 12:09:27 +02:00
StoresController.Onchain.cs Add payjoin option to hot wallet setup (#2450) 2021-06-18 10:25:17 +09:00
UserStoresController.cs Plugins: Allow creation of independent DbContexts 2020-11-18 12:27:26 +01:00
VaultController.cs Update HWI library, warn users to run newer version (#2544) 2021-06-06 21:02:15 +09:00
WalletsController.cs Merge pull request #2575 from NicolasDorier/refactor/wallet-cleanup 2021-06-17 21:20:28 +09:00
WalletsController.PSBT.cs Signing context cleanup (#2568) 2021-06-15 17:35:23 +09:00
WalletsController.PullPayments.cs Payouts: Detect External OnChain Payouts (#2462) 2021-07-16 09:57:37 +02:00