Optional
canDetermines whether the tool can handle the given intent.
Can either return a boolean, or an object where the keys represent the parameters that
can/can not be handled. This will be used to determine whether or not a tool is the best
suited to handle an intent. Note that an object of only false
values (or an empty object)
is treated as true
, so you want to explicitly return false
if you know the intent cannot
fulfill the intent request.
The intent to check.
The parameters for the intent.
The payload for the intent.
Boolean: whether it can handle the intent. Object: Values representing what specific parameters can be handled.
The React component that renders the tool.
Optional
controlsDetermines whether the tool will control the document.title
.
Optional
getGets the state for the given intent.
The intent to get the state for.
The parameters for the intent.
The current router state. See router.RouterState
The payload for the intent.
The state for the intent.
Optional
iconReact component for the icon representing the tool.
The name of the tool, used as part of the URL.
Optional
optionsOptions are passed through from the configuration to the component defined by the component
Optional
routerThe router for the tool. See router.Router
Title of the tool - used for the navigation menu item, along with the icon.
A tool can be thought of as a top-level "view" or "app". They are available through the global menu bar, and has a URL route associated with them.
In essence, a tool is a React component that is rendered when the tool is active, along with a title, name (URL segment) and icon.
Tools can handle intents such as "edit" or "create" by defining a function for the
canHandleIntent
property, as well as thegetIntentState
property, which defines what an intent will be mapped to in terms of the tool's URL state.