mirror of
https://github.com/stoatchat/for-legacy-web.git
synced 2026-03-09 18:15:28 +00:00
Update EmbedSpoiler.tsx
This commit is contained in:
@@ -1,10 +1,15 @@
|
||||
import classNames from "classnames";
|
||||
import { useState } from "preact/hooks";
|
||||
import { API } from "revolt.js";
|
||||
import styles from "./Embed.module.scss";
|
||||
|
||||
|
||||
export default function EmbedSpoiler(){
|
||||
|
||||
const [visible, setVisible] = useState(true);
|
||||
|
||||
return (
|
||||
<div className={classNames(styles.spoiler_container)}>
|
||||
<div className={classNames(styles.spoiler_container, visible ? null : styles.hidden)} onClick={() => setVisible(!visible)}>
|
||||
<h1 className={classNames(styles.spoiler_title)}>SPOILER</h1>
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user