Revert "Merge branch 'allow-text-selection' into 'next'"
This reverts merge request !1262
This commit is contained in:
parent
654d652a6f
commit
6db00e0293
|
@ -102,7 +102,6 @@ interface IStatus extends RouteComponentProps {
|
||||||
}
|
}
|
||||||
|
|
||||||
interface IStatusState {
|
interface IStatusState {
|
||||||
isDragging: boolean,
|
|
||||||
showMedia: boolean,
|
showMedia: boolean,
|
||||||
statusId?: string,
|
statusId?: string,
|
||||||
emojiSelectorFocused: boolean,
|
emojiSelectorFocused: boolean,
|
||||||
|
@ -129,7 +128,6 @@ class Status extends ImmutablePureComponent<IStatus, IStatusState> {
|
||||||
];
|
];
|
||||||
|
|
||||||
state: IStatusState = {
|
state: IStatusState = {
|
||||||
isDragging: false,
|
|
||||||
showMedia: defaultMediaVisibility(this.props.status, this.props.displayMedia),
|
showMedia: defaultMediaVisibility(this.props.status, this.props.displayMedia),
|
||||||
statusId: undefined,
|
statusId: undefined,
|
||||||
emojiSelectorFocused: false,
|
emojiSelectorFocused: false,
|
||||||
|
@ -193,9 +191,7 @@ class Status extends ImmutablePureComponent<IStatus, IStatusState> {
|
||||||
this.setState({ showMedia: !this.state.showMedia });
|
this.setState({ showMedia: !this.state.showMedia });
|
||||||
}
|
}
|
||||||
|
|
||||||
handleClick = (event: any): void => {
|
handleClick = (): void => {
|
||||||
event.stopPropagation();
|
|
||||||
|
|
||||||
if (this.props.onClick) {
|
if (this.props.onClick) {
|
||||||
this.props.onClick();
|
this.props.onClick();
|
||||||
return;
|
return;
|
||||||
|
@ -609,13 +605,7 @@ class Status extends ImmutablePureComponent<IStatus, IStatusState> {
|
||||||
data-featured={featured ? 'true' : null}
|
data-featured={featured ? 'true' : null}
|
||||||
aria-label={textForScreenReader(intl, status, rebloggedByText)}
|
aria-label={textForScreenReader(intl, status, rebloggedByText)}
|
||||||
ref={this.handleRef}
|
ref={this.handleRef}
|
||||||
onMouseUp={() => {
|
onClick={() => this.props.history.push(statusUrl)}
|
||||||
if (!this.state.isDragging) {
|
|
||||||
this.props.history.push(statusUrl);
|
|
||||||
}
|
|
||||||
}}
|
|
||||||
onMouseDown={() => this.setState({ isDragging: false })}
|
|
||||||
onMouseMove={() => this.setState({ isDragging: true })}
|
|
||||||
role='link'
|
role='link'
|
||||||
>
|
>
|
||||||
{prepend}
|
{prepend}
|
||||||
|
|
|
@ -67,7 +67,7 @@ interface IStatusContent {
|
||||||
status: Status,
|
status: Status,
|
||||||
expanded?: boolean,
|
expanded?: boolean,
|
||||||
onExpandedToggle?: () => void,
|
onExpandedToggle?: () => void,
|
||||||
onClick?: (event: React.MouseEvent) => void,
|
onClick?: () => void,
|
||||||
collapsable?: boolean,
|
collapsable?: boolean,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -182,7 +182,7 @@ const StatusContent: React.FC<IStatusContent> = ({ status, expanded = false, onE
|
||||||
}
|
}
|
||||||
|
|
||||||
if (deltaX + deltaY < 5 && e.button === 0 && onClick) {
|
if (deltaX + deltaY < 5 && e.button === 0 && onClick) {
|
||||||
onClick(e);
|
onClick();
|
||||||
}
|
}
|
||||||
|
|
||||||
startXY.current = undefined;
|
startXY.current = undefined;
|
||||||
|
|
Loading…
Reference in New Issue