2024-03-19 15:23:12 +01:00
|
|
|
import { JSXElement } from "solid-js";
|
|
|
|
|
|
|
|
import { EngagementIcon } from "../../Util/Icons";
|
|
|
|
import { Post } from "../../Util/api";
|
|
|
|
|
|
|
|
export default function EngagementButton({ post }: { post: Post }): JSXElement {
|
|
|
|
return (
|
|
|
|
<>
|
|
|
|
<div class="flex p-1">
|
|
|
|
<button
|
2024-03-20 14:59:14 +01:00
|
|
|
class="btn btn-xs hover:border-primary rounded-base"
|
2024-03-19 15:23:12 +01:00
|
|
|
aria-label="Show sign of engagement"
|
|
|
|
>
|
|
|
|
<EngagementIcon />
|
|
|
|
</button>
|
2024-03-20 14:59:14 +01:00
|
|
|
<span class="text-1xl countdown text-center pt-1.5 px-1.5">
|
2024-03-19 15:23:12 +01:00
|
|
|
<p style={{ "--value": 46 }}>{post.votes}</p>
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
</>
|
|
|
|
);
|
|
|
|
}
|