mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 12:56:41 +07:00
fixed some paths according to new backend
This commit is contained in:
parent
2f6207feaa
commit
4912fd255c
27 changed files with 228 additions and 217 deletions
|
@ -3,7 +3,7 @@ import React, { memo, VFC } from 'react';
|
|||
import classNames from 'classnames';
|
||||
|
||||
import { Icon } from '~/components/input/Icon';
|
||||
import { SeparatedMenu } from '~/components/menu';
|
||||
import { SeparatedMenu } from '~/components/menu/SeparatedMenu';
|
||||
import { NodeEditMenu } from '~/components/node/NodeEditMenu';
|
||||
import { Placeholder } from '~/components/placeholders/Placeholder';
|
||||
import { getPrettyDate } from '~/utils/dom';
|
||||
|
@ -35,7 +35,6 @@ interface IProps {
|
|||
|
||||
const NodeTitle: VFC<IProps> = memo(
|
||||
({
|
||||
id,
|
||||
title,
|
||||
username,
|
||||
createdAt,
|
||||
|
@ -69,7 +68,9 @@ const NodeTitle: VFC<IProps> = memo(
|
|||
{isLoading ? (
|
||||
<Placeholder width="100px" />
|
||||
) : (
|
||||
`~${username.toLocaleLowerCase()}, ${getPrettyDate(createdAt)}`
|
||||
`~${username.toLocaleLowerCase()}, ${getPrettyDate(
|
||||
createdAt,
|
||||
)}`
|
||||
)}
|
||||
</aside>
|
||||
)}
|
||||
|
@ -90,7 +91,9 @@ const NodeTitle: VFC<IProps> = memo(
|
|||
|
||||
{canLike && (
|
||||
<div
|
||||
className={classNames(styles.button, styles.like, { [styles.is_liked]: isLiked })}
|
||||
className={classNames(styles.button, styles.like, {
|
||||
[styles.is_liked]: isLiked,
|
||||
})}
|
||||
>
|
||||
{isLiked ? (
|
||||
<Icon icon="heart_full" size={24} onClick={onLike} />
|
||||
|
@ -107,7 +110,7 @@ const NodeTitle: VFC<IProps> = memo(
|
|||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
},
|
||||
);
|
||||
|
||||
export { NodeTitle };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue