mirror of
https://github.com/cheeaun/phanpy.git
synced 2025-01-22 16:46:28 +01:00
Fix document.title bug
This commit is contained in:
parent
8787d44b56
commit
3cec4f66c5
2 changed files with 10 additions and 2 deletions
|
@ -8,9 +8,16 @@ import Link from './link';
|
|||
import Loader from './loader';
|
||||
import Status from './status';
|
||||
|
||||
function Timeline({ title, id, emptyText, errorText, fetchItems = () => {} }) {
|
||||
function Timeline({
|
||||
title,
|
||||
path,
|
||||
id,
|
||||
emptyText,
|
||||
errorText,
|
||||
fetchItems = () => {},
|
||||
}) {
|
||||
if (title) {
|
||||
useTitle(title);
|
||||
useTitle(title, path);
|
||||
}
|
||||
const [items, setItems] = useState([]);
|
||||
const [uiState, setUIState] = useState('default');
|
||||
|
|
|
@ -34,6 +34,7 @@ function AccountStatuses() {
|
|||
<Timeline
|
||||
key={id}
|
||||
title={`${account?.acct ? '@' + account.acct : 'Posts'}`}
|
||||
path="/a/:id"
|
||||
id="account_statuses"
|
||||
emptyText="Nothing to see here yet."
|
||||
errorText="Unable to load statuses"
|
||||
|
|
Loading…
Reference in a new issue