/* Copyright 2026 Marimo. All rights reserved. */ import { Kbd } from "@/components/ui/kbd"; import { toast } from "@/components/ui/use-toast"; export const showAddPackageToast = ( packageName: string, error?: string | null, ) => { if (error) { toast({ title: "Failed to add package", description: error, variant: "danger", }); } else { toast({ title: "Package added", description: (
The package {packageName} and its dependencies has been added to your environment.
Some Python packages may require a kernel restart to see changes.
), }); } }; export const showUpgradePackageToast = ( packageName: string, error?: string | null, ) => { if (error) { toast({ title: "Failed to upgrade package", description: error, variant: "danger", }); } else { toast({ title: "Package upgraded", description: (
The package {packageName} has been upgraded.
Some Python packages may require a kernel restart to see changes.
), }); } }; export const showRemovePackageToast = ( packageName: string, error?: string | null, ) => { if (error) { toast({ title: "Failed to remove package", description: error, variant: "danger", }); } else { toast({ title: "Package removed", description: (
The package {packageName} has been removed from your environment.
Some Python packages may require a kernel restart to see changes.
), }); } };