Add ping animation to update button
This commit is contained in:
parent
fec3451d93
commit
13f2881f00
3 changed files with 9 additions and 3 deletions
|
|
@ -477,6 +477,7 @@ export default function NodeToolbarComponent({
|
||||||
value={"Update"}
|
value={"Update"}
|
||||||
icon={"Code"}
|
icon={"Code"}
|
||||||
dataTestId="update-button-modal"
|
dataTestId="update-button-modal"
|
||||||
|
ping={isOutdated}
|
||||||
/>
|
/>
|
||||||
</SelectItem>
|
</SelectItem>
|
||||||
)}
|
)}
|
||||||
|
|
|
||||||
|
|
@ -9,14 +9,18 @@ export default function ToolbarSelectItem({
|
||||||
icon,
|
icon,
|
||||||
styleObj,
|
styleObj,
|
||||||
dataTestId,
|
dataTestId,
|
||||||
|
ping,
|
||||||
}: toolbarSelectItemProps) {
|
}: toolbarSelectItemProps) {
|
||||||
return (
|
return (
|
||||||
<div className="flex" data-testid={dataTestId}>
|
<div className="flex" data-testid={dataTestId}>
|
||||||
<ForwardedIconComponent
|
<ForwardedIconComponent
|
||||||
name={icon}
|
name={icon}
|
||||||
className={`relative top-0.5 mr-2 h-4 w-4 ${styleObj?.iconClasses}`}
|
className={`relative top-0.5 mr-2 h-4 w-4 ${styleObj?.iconClasses} ${
|
||||||
/>{" "}
|
ping && "animate-pulse text-green-500"
|
||||||
<span className={styleObj?.valueClasses}>{value}</span>{" "}
|
}`}
|
||||||
|
/>
|
||||||
|
<span className={styleObj?.valueClasses}>{value}</span>
|
||||||
|
|
||||||
{isMac ? (
|
{isMac ? (
|
||||||
<ForwardedIconComponent
|
<ForwardedIconComponent
|
||||||
name="Command"
|
name="Command"
|
||||||
|
|
|
||||||
|
|
@ -707,4 +707,5 @@ export type toolbarSelectItemProps = {
|
||||||
valueClasses?: string;
|
valueClasses?: string;
|
||||||
};
|
};
|
||||||
dataTestId: string;
|
dataTestId: string;
|
||||||
|
ping?: boolean;
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue