diff options
author | Starfall <us@starfall.systems> | 2023-04-14 19:22:47 -0500 |
---|---|---|
committer | Starfall <us@starfall.systems> | 2023-04-14 19:22:47 -0500 |
commit | 4fe1689de43f4404eb9530fcfbcbfb26d6c1c13a (patch) | |
tree | 6811b845bb7f4966b10dcefa3dea404246f161c7 /app/javascript/flavours/glitch/components/edited_timestamp | |
parent | 65c1e53a32cabcdbb7bca57002bb0f6acdebe07e (diff) | |
parent | bed63f6dae0879ac840066b031229e0d139089cd (diff) |
Diffstat (limited to 'app/javascript/flavours/glitch/components/edited_timestamp')
-rw-r--r-- | app/javascript/flavours/glitch/components/edited_timestamp/index.jsx (renamed from app/javascript/flavours/glitch/components/edited_timestamp/index.js) | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/app/javascript/flavours/glitch/components/edited_timestamp/index.js b/app/javascript/flavours/glitch/components/edited_timestamp/index.jsx index 9648133af..6d73fa68c 100644 --- a/app/javascript/flavours/glitch/components/edited_timestamp/index.js +++ b/app/javascript/flavours/glitch/components/edited_timestamp/index.jsx @@ -16,8 +16,6 @@ const mapDispatchToProps = (dispatch, { statusId }) => ({ }); -export default @connect(null, mapDispatchToProps) -@injectIntl class EditedTimestamp extends React.PureComponent { static propTypes = { @@ -36,7 +34,7 @@ class EditedTimestamp extends React.PureComponent { return ( <FormattedMessage id='status.edited_x_times' defaultMessage='Edited {count, plural, one {{count} time} other {{count} times}}' values={{ count: items.size - 1 }} /> ); - } + }; renderItem = (item, index, { onClick, onKeyPress }) => { const formattedDate = <RelativeTimestamp timestamp={item.get('created_at')} short={false} />; @@ -53,7 +51,7 @@ class EditedTimestamp extends React.PureComponent { <button data-index={index} onClick={onClick} onKeyPress={onKeyPress}>{label}</button> </li> ); - } + }; render () { const { timestamp, intl, statusId } = this.props; @@ -68,3 +66,5 @@ class EditedTimestamp extends React.PureComponent { } } + +export default connect(null, mapDispatchToProps)(injectIntl(EditedTimestamp)); |