Render Modal as real markup; drain scripts via CaptureScript (#2742)

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
This commit is contained in:
Paweł Kuna
2026-08-03 00:55:32 +02:00
committed by GitHub
co-authored by StarDev
parent 66dc336726
commit 575d68572f
200 changed files with 10670 additions and 10096 deletions
+12 -10
View File
@@ -1,18 +1,20 @@
---
// Equivalent of ui/payment.html
interface Props {
payment?: string
dark?: boolean
size?: string
class?: string
payment?: string;
dark?: boolean;
size?: string;
class?: string;
}
const { payment = 'visa', dark, size, class: className } = Astro.props
const { payment = 'visa', dark, size, class: className } = Astro.props;
// Class token order exactly as in ui/payment.html. The include['size'] bug
// (junk `payment-N`) is NOT reproduced — only an explicit `size` becomes
// `payment-{size}`.
const classes = ['payment', size && `payment-${size}`, `payment-provider-${payment}${dark ? '-dark' : ''}`, className]
// Only an explicit `size` becomes `payment-{size}`.
const classes = [
'payment',
size && `payment-${size}`,
`payment-provider-${payment}${dark ? '-dark' : ''}`,
className,
]
---
<span class:list={classes}></span>