-
Notifications
You must be signed in to change notification settings - Fork 49
refactor(web): simplify optimistic rendering #1399
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
Changes from 3 commits
a4980aa
f08107c
2f58e22
8cb3070
4f8d370
1440521
305f4fe
2dc427c
4051c08
1889e22
65120bd
16d3d0c
dba0b68
8c2b2b4
d3feba3
b1fe67c
7f08edd
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -15,6 +15,8 @@ import { | |||||
| TooltipWrapper, | ||||||
| } from "@web/components/ContextMenu/styled"; | ||||||
| import IconButton from "@web/components/IconButton/IconButton"; | ||||||
| import { selectIsEventPending } from "@web/ducks/events/selectors/pending.selectors"; | ||||||
| import { useAppSelector } from "@web/store/store.hooks"; | ||||||
| import { useDraftContext } from "@web/views/Calendar/components/Draft/context/useDraftContext"; | ||||||
| import { useSidebarContext } from "@web/views/Calendar/components/Draft/sidebar/context/useSidebarContext"; | ||||||
|
|
||||||
|
|
@@ -36,6 +38,9 @@ export function ContextMenuItems({ event, close }: ContextMenuItemsProps) { | |||||
| const { setDraft } = setters; | ||||||
|
|
||||||
| const sidebarContext = useSidebarContext(true); | ||||||
| const isPending = useAppSelector((state) => | ||||||
| selectIsEventPending(state, event._id!), | ||||||
|
||||||
| selectIsEventPending(state, event._id!), | |
| event._id ? selectIsEventPending(state, event._id) : false, |
Uh oh!
There was an error while loading. Please reload this page.