Changing Cursor Conditionally #4268
-
Hey all, I am aware you can change the cursor via css like so
But how would I go about applying this conditionally if I do not have access to the pane component? I want to avoid having to do something like
to programmatically add and remove the class |
Beta Was this translation helpful? Give feedback.
Answered by
bcakmakoglu
May 27, 2024
Replies: 1 comment
-
You could still use css + a dynamic class name and do something like this: <ReactFlow className={isLoading ? 'cursor-progress' : ''} ...> .react-flow.cursor-progress .react-flow__pane {
cursor: progress; /* add !important if necessary */
} |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
skspade
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You could still use css + a dynamic class name and do something like this: