Appearance
ContentTerminal
A terminal session: commands as kbd, output as samp, and a copy that takes only the commands.
ts
import { ContentTerminal } from '@zairakai/vue-components/Content'Usage
vue
<ContentTerminal />Example
npm install @zairakai/vue-components added 1 package npm test
vue
<template>
<ContentTerminal
title="Shell"
:lines="['$ npm install @zairakai/vue-components', 'added 1 package', '$ npm test']"
/>
</template>Props
| Name | Type | Default | Description |
|---|---|---|---|
id | string | ||
class | string | ||
lines | array | [] | The session: a string per line ("$ npm install" is a command, the rest is output) or { type: "command" | "output" | "comment", text }. |
prompt | string | '$' | |
title | string | ||
copyable | boolean | true | |
copyLabel | string | 'Copy' | |
copiedLabel | string | 'Copied' |
See Theming for the class hooks and the data-* state of the components.