You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
385 B
15 lines
385 B
---
|
|
import "../css/spoiler.scss"
|
|
|
|
const warning = Astro.props.warning ?? "Click to show NSFW image"
|
|
// waltuh
|
|
const trolley = "spoiler-check-" + Math.floor(Math.random() * 102105122122126).toString()
|
|
---
|
|
|
|
<div class="spoiler" >
|
|
<input id={trolley} type="checkbox">
|
|
<div class="spoiler-content">
|
|
<slot />
|
|
</div>
|
|
<label for={trolley} class="spoiler-button">{warning}</label>
|
|
</div> |