Skip to content

zk-terminal ​

A shell session: commands with a prompt, their output, and a button that copies the commands only.

Props ​

PropTypeDefaultDescription
linesarray[]Commands (strings) or arrays with type (command or output) and text
promptstring'$'Prompt shown before a command
titlestring|nullnullTitle
copyablebooltrueShows the copy button
copyLabelstring'Copy'Text of the button
idstring|nullnullIdentifier
classstring|nullnullCSS class(es) merged onto the root element

Undeclared attributes forward to the root element.

Needs the script copy of zk-scripts: the component asks for it by itself. The prompt is decorative (aria-hidden) and is not copied. Class hooks: terminal, terminal-header, terminal-title, terminal-copy, terminal-body, terminal-line (data-type), terminal-prompt.

Examples ​

Install ​

blade
<x-zk-terminal title="Install" :lines="[
    'composer require zairakai/laravel-blade-components',
    ['type' => 'output', 'text' => 'Using version ^3.1'],
]" />

Documentation of 3.2.0 , built from c93e21f on 3.2.0 by pipeline #2919741884 on 2026-10-06.