Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix modlog tap effect #1425

Merged
merged 1 commit into from
Apr 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/features/moderation/logs/ModlogItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ import {
import useIsAdmin from "../useIsAdmin";
import { timerOutline } from "ionicons/icons";
import { styled } from "@linaria/react";
import { cx } from "@linaria/core";
import { isTouchDevice } from "../../../helpers/device";

const Container = styled.div`
display: flex;
Expand Down Expand Up @@ -184,7 +186,8 @@ export function ModlogItem({ item }: ModLogItemProps) {

return (
<IonItem
className={maxWidthCss}
mode="ios" // Use iOS style activatable tap highlight
className={cx(isTouchDevice() && "ion-activatable", maxWidthCss)}
href={undefined}
routerLink={link ? buildGeneralBrowseLink(link) : undefined}
detail={false}
Expand Down
17 changes: 10 additions & 7 deletions src/features/moderation/logs/ModlogItemMoreActions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import { ModlogItemType } from "../../../routes/pages/shared/ModlogPage";
import { getHandle } from "../../../helpers/lemmy";
import useAppNavigation from "../../../helpers/useAppNavigation";
import { ModeratorRole, getModIcon } from "../useCanModerate";
import { PlainButton } from "../../shared/PlainButton";

const EllipsisIcon = styled(IonIcon)`
font-size: 1.2rem;
Expand Down Expand Up @@ -81,12 +82,14 @@ export default function ModlogItemMoreActions({
}

return (
<EllipsisIcon
icon={ellipsisHorizontal}
onClick={(e) => {
e.stopPropagation();
presentMoreActions();
}}
/>
<PlainButton>
<EllipsisIcon
icon={ellipsisHorizontal}
onClick={(e) => {
e.stopPropagation();
presentMoreActions();
}}
/>
</PlainButton>
);
}
Loading