Merge branch 'revert-654d652a' into 'next'

Revert "Merge branch 'allow-text-selection' into 'next'"

See merge request soapbox-pub/soapbox-fe!1263
revert-5af0e40a
Alex Gleason 2022-04-26 14:30:05 +00:00
commit 5af0e40ad2
2 zmienionych plików z 4 dodań i 14 usunięć

Wyświetl plik

@ -102,7 +102,6 @@ interface IStatus extends RouteComponentProps {
}
interface IStatusState {
isDragging: boolean,
showMedia: boolean,
statusId?: string,
emojiSelectorFocused: boolean,
@ -129,7 +128,6 @@ class Status extends ImmutablePureComponent<IStatus, IStatusState> {
];
state: IStatusState = {
isDragging: false,
showMedia: defaultMediaVisibility(this.props.status, this.props.displayMedia),
statusId: undefined,
emojiSelectorFocused: false,
@ -193,9 +191,7 @@ class Status extends ImmutablePureComponent<IStatus, IStatusState> {
this.setState({ showMedia: !this.state.showMedia });
}
handleClick = (event: any): void => {
event.stopPropagation();
handleClick = (): void => {
if (this.props.onClick) {
this.props.onClick();
return;
@ -609,13 +605,7 @@ class Status extends ImmutablePureComponent<IStatus, IStatusState> {
data-featured={featured ? 'true' : null}
aria-label={textForScreenReader(intl, status, rebloggedByText)}
ref={this.handleRef}
onMouseUp={() => {
if (!this.state.isDragging) {
this.props.history.push(statusUrl);
}
}}
onMouseDown={() => this.setState({ isDragging: false })}
onMouseMove={() => this.setState({ isDragging: true })}
onClick={() => this.props.history.push(statusUrl)}
role='link'
>
{prepend}

Wyświetl plik

@ -67,7 +67,7 @@ interface IStatusContent {
status: Status,
expanded?: boolean,
onExpandedToggle?: () => void,
onClick?: (event: React.MouseEvent) => void,
onClick?: () => void,
collapsable?: boolean,
}
@ -182,7 +182,7 @@ const StatusContent: React.FC<IStatusContent> = ({ status, expanded = false, onE
}
if (deltaX + deltaY < 5 && e.button === 0 && onClick) {
onClick(e);
onClick();
}
startXY.current = undefined;