gallery/make-pages/NsfwWarning.hs

28 lines
688 B
Haskell
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

module NsfwWarning (script, dialog) where
import BuilderQQ
script :: Bool -> Builder
script False = ""
script True = [b|<script src=/script/nsfw-warning.js></script>|]
dialog :: Bool -> Builder
dialog False = ""
dialog True = [b|@0
<div class=dialog id=nsfw-dialog>
<div class=dialog-inner>
<h1>cw: lewd</h1>
<img class=dialog-icon src=/style/stop_hand.svg>
<div class=dialog-message>
are you an adult? <br> if not please don't look!
</div>
<div class=dialog-buttons>
<button id=nsfw-yes class=yes>yes i am and i wanna see</button>
<button id=nsfw-no class=no>no im not</button>
</div>
</div>
</div>
|]