Skip to content

DocsAITool call

PT

AI

Tool call

Tool running with steps that go from pending to done.

data-u="ai-tool"Demo

Example

search_customerssegment: "agri" Done
  • Validate parameters0.3s
  • Query the database0.5s
  • Filter results0.4s
  • Build the answer0.2s

Tool call

Pending, running and done states, with the step list moving forward one at a time.

Installation

Tool call ships in the full package, along with the skill:

curl -fsSL unslop.leallabs.dev/i | sh

The example HTML, to paste:

curl -fsSL unslop.leallabs.dev/i | sh -s add ai-tool

Uses The block is just HTML. The CSS and JS come from the full package's unslop.css and unslop.js.

Classes and variants

ClassWhat it does
.u-ai-toolThe block, with __head and __name.
.u-ai-badge[data-state]running or done.
ul.u-ai-steps > li.u-ai-step[data-state]running or done. Without data-state it's pending.

Accessibility and keyboard

State and roles

WhereAttributeWhat it says
.u-ai-card__panelrole="group" and aria-labelSays it's a demo and of what.
stepsdata-stateThe state is an attribute, also read by the CSS.

Keyboard

KeyDoes
Tabenters the card and pauses the animation while focus is there

Motion

Plays on its own when it enters the viewport, for up to 3 cycles, and stops in its final state. Hovering or focusing inside pauses it. With reduced motion, it shows the final state right away.

Events and API

No public events. For a real chat, copy the markup and wire up your own state, without relying on data-u for logic.

Type to search. Arrows pick, Enter opens.