-
-
Notifications
You must be signed in to change notification settings - Fork 95
Node Status Indicator Revamp #916
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
base: component-revamp
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
2 Skipped Deployments
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR extends the NodeStatusIndicator to support an initial
state, adds two loading variants (border
and overlay
), and updates documentation, component code, and examples accordingly.
- Introduced
NodeStatusLoadingVariant
prop to switch between border and overlay loading indicators - Refactored and renamed loading indicator components; updated default loading variant
- Updated documentation and registry examples to showcase each status and variant
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
File | Description |
---|---|
sites/reactflow.dev/src/content/components/nodes/node-status-indicator.mdx | Added initial state and documented new loadingVariant options |
apps/ui-components/registry/components/node-status-indicator/index.tsx | Added loadingVariant prop, split loading indicators, updated switch logic |
apps/ui-components/registry/components/node-status-indicator/component-example.tsx | Replaced default export with multiple named examples for each status/variant |
apps/ui-components/registry/components/node-status-indicator/app-example.tsx | Updated node definitions and nodeTypes mapping for new example components |
Comments suppressed due to low confidence (3)
sites/reactflow.dev/src/content/components/nodes/node-status-indicator.mdx:9
- [nitpick] Consider adding a brief usage example or note on what the
initial
state looks like in practice, so readers know when and how to apply it.
A node wrapper that has multiple states for indicating the status of a node. Status can be one of the following: `success`, `loading`, `error` and `initial`.
apps/ui-components/registry/components/node-status-indicator/index.tsx:15
- [nitpick] The name
SpinnerLoadingIndicator
describes the inner spinner but doesn’t convey that this is the overlay variant. Consider renaming toOverlayLoadingIndicator
for consistency withBorderLoadingIndicator
.
export const SpinnerLoadingIndicator = ({
apps/ui-components/registry/components/node-status-indicator/index.tsx:29
- The CSS
calc
expressions lack spaces around the operator, which may lead to invalid parsing. Useleft-[calc(50% - 1.25rem)]
andtop-[calc(50% - 1.25rem)]
for correct syntax.
<span className="absolute left-[calc(50%-1.25rem)] top-[calc(50%-1.25rem)] inline-block h-10 w-10 animate-ping rounded-full bg-blue-700/20" />
apps/ui-components/registry/components/node-status-indicator/index.tsx
Outdated
Show resolved
Hide resolved
|
Not yet!
It would need some re-design of the |
No description provided.