mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2025-12-17 22:14:26 +01:00
Make sure EmbeddedCSS is CSS
This commit is contained in:
@@ -88,6 +88,8 @@ namespace BTCPayServer.Models.PaymentRequestViewModels
|
|||||||
EmbeddedCSS = blob.EmbeddedCSS;
|
EmbeddedCSS = blob.EmbeddedCSS;
|
||||||
CustomCSSLink = blob.CustomCSSLink;
|
CustomCSSLink = blob.CustomCSSLink;
|
||||||
AllowCustomPaymentAmounts = blob.AllowCustomPaymentAmounts;
|
AllowCustomPaymentAmounts = blob.AllowCustomPaymentAmounts;
|
||||||
|
if (!string.IsNullOrEmpty(EmbeddedCSS))
|
||||||
|
EmbeddedCSS = $"<style>{EmbeddedCSS}</style>";
|
||||||
switch (data.Status)
|
switch (data.Status)
|
||||||
{
|
{
|
||||||
case PaymentRequestData.PaymentRequestStatus.Pending:
|
case PaymentRequestData.PaymentRequestStatus.Pending:
|
||||||
|
|||||||
@@ -31,12 +31,8 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
<bundle name="wwwroot/bundles/payment-request-bundle.min.css"></bundle>
|
<bundle name="wwwroot/bundles/payment-request-bundle.min.css"></bundle>
|
||||||
@if (!string.IsNullOrEmpty(Model.EmbeddedCSS))
|
|
||||||
{
|
@Safe.Raw(Model.EmbeddedCSS);
|
||||||
<style>
|
|
||||||
@Safe.Raw(Model.EmbeddedCSS);
|
|
||||||
</style>
|
|
||||||
}
|
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user