blob: 0632173e62b012c1ddeb99db246747fd5ac3fcae [file] [log] [blame]
Krishya7ec1dd02025-04-19 15:29:03 +08001import React from 'react';
2import { useLocation } from 'wouter';
3import { Edit } from '@icon-park/react';
4import './CreatePostButton.css';
5
6const CreatePostButton = () => {
7 const [, navigate] = useLocation();
8
9 const goToCreatePost = () => {
10 navigate('/forum/create-post');
11 };
12
13 return (
14 <div className="create-post">
15 <button onClick={goToCreatePost} className="create-btn">
16 <Edit theme="outline" size="18" /> 发帖
17 </button>
18 </div>
19 );
20};
21
22export default CreatePostButton;