mirror of
https://github.com/Steffo99/festa.git
synced 2024-12-23 07:04:22 +00:00
14 lines
402 B
TypeScript
14 lines
402 B
TypeScript
|
import { useState } from "react";
|
||
|
import { PostcardImage, PostcardVisibility } from "./PostcardContext";
|
||
|
|
||
|
export function useStatePostcard() {
|
||
|
const [visibility, setVisibility] = useState<PostcardVisibility>(PostcardVisibility.BACKGROUND)
|
||
|
const [image, setImage] = useState<PostcardImage>("none")
|
||
|
|
||
|
return {
|
||
|
visibility,
|
||
|
setVisibility,
|
||
|
image,
|
||
|
setImage,
|
||
|
}
|
||
|
}
|