ContainerSelectionDialog
Modal that lists containers and lets the operator pick one or many for a follow-up action.
Modal that lists containers and lets the operator pick one or many for a follow-up action.
import { ContainerSelectionDialog } from "@tetherto/mdk-react-devkit";| Prop | Status | Type | Default | Description |
|---|---|---|---|---|
miner | Optional | Device | undefined | — | — |
containers | Optional | Device[] | undefined | — | — |
isLoading | Optional | boolean | undefined | — | — |
open | Required | boolean | — | — |
onClose | Required | (value?: boolean | undefined) => void | — | — |
Usage
Modal step that lists containers for the operator to choose from as part of a position-change or batch-action flow.
Minimal example
import { ContainerSelectionDialog } from "@tetherto/mdk-react-devkit";
<ContainerSelectionDialog
open={isOpen}
onClose={() => setIsOpen(false)}
containers={availableContainers}
/>
Example
import { useState } from 'react'import { ContainerSelectionDialog } from '@tetherto/mdk-react-devkit'export const ContainerSelectionDialogExample = () => { const [open, setOpen] = useState(false) return ( <div className="mdk-example-row"> <button onClick={() => setOpen(true)}>Open Container Selection</button> <ContainerSelectionDialog open={open} onClose={() => setOpen(false)} containers={[]} isLoading={false} /> </div> )}