mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-14 21:27:20 +00:00
fix(mobile): change mobile docs display config and prevent opening doc when close menu (#12903)
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Improvements** - Updated document explorer to hide quick favorite and document icons, and display more detailed system properties for each document. - Enhanced link behavior in the workbench to prevent unintended clicks from triggering navigation. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
@@ -61,6 +61,11 @@ export const WorkbenchLink = forwardRef<HTMLAnchorElement, WorkbenchLinkProps>(
|
||||
const link = basename + stringTo;
|
||||
const handleClick = useAsyncCallback(
|
||||
async (event: React.MouseEvent<HTMLAnchorElement>) => {
|
||||
// a trick to prevent click from modal overlay propagation
|
||||
if (!event.currentTarget.contains(event.target as Node)) {
|
||||
return;
|
||||
}
|
||||
|
||||
onClick?.(event);
|
||||
if (event.defaultPrevented) {
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user