0.0.31 • Published 9 months ago

@specificlab/ui v0.0.31

Weekly downloads
-
License
MIT
Repository
github
Last release
9 months ago

@specificlab/ui

A Vue 3 UI component library based on TailwindCSS.

Installation

# npm
npm install @specificlab/ui

# pnpm
pnpm add @specificlab/ui

# yarn
yarn add @specificlab/ui

Usage

Global Registration

import { createApp } from 'vue'
import SpecificUI from '@specificlab/ui'
import '@specificlab/ui/dist/style.css'

const app = createApp(App)
app.use(SpecificUI)
app.mount('#app')

On-Demand Import

// 1. Import component
import { AgentBoard } from '@specificlab/ui'
import '@specificlab/ui/dist/style.css'

// 2. Register in your component
export default {
  components: {
    [AgentBoard.name]: AgentBoard
  }
}

Or in setup script:

<script setup lang="ts">
import { AgentBoard } from '@specificlab/ui'
import '@specificlab/ui/dist/style.css'
</script>

<template>
  <agent-board
    title="Agent Name"
    status="INACTIVE"
  />
</template>

Components

AgentBoard

A card component for displaying AI agent status and controls.

Props

NameTypeDefaultDescription
titlestring'Agent Alpha'Agent name
status'INACTIVE' | 'RUNNING' | 'STOPPED' | 'ERROR''INACTIVE'Agent status
descriptionstring'An AI agent...'Agent description
progressnumber0Progress percentage
currentStepnumber1Current step
totalStepsnumber4Total steps

Events

NameParametersDescription
start-Emitted when start button clicked
view-Emitted when view button clicked

Slots

NameDescription
avatarCustom avatar content

AgentStepTimeline Slots

NamePropsDescription
timelinesteps整个时间线的自定义渲染
indicatorstep, isLast步骤指示器的自定义渲染
dotstep步骤圆点的自定义渲染
completed-icon-完成状态图标
processing-icon-处理中状态图标
pending-icon-待处理状态图标
linestep, isLast连接线的自定义渲染
headerstep步骤头部的自定义渲染
titlestep步骤标题的自定义渲染
statusstep步骤状态的自定义渲染
detailsstep, content步骤详情的自定义渲染
content-titlecontent内容标题的自定义渲染
contentstep, content步骤内容的自定义渲染

AgentDetailLayout

The layout component requires a parent container with a defined height. Example:

<div style="height: 100vh;">
  <agent-detail-layout>
    <!-- content -->
  </agent-detail-layout>
</div>

Or using CSS:

.parent-container {
  height: 100%;
  display: flex;
  flex-direction: column;
}

AgentCompletedCard

Slots

NamePropsDescription
avatar-自定义头像内容
namename自定义名称内容
tagtype自定义标签内容
summarysummary自定义摘要内容

Customization

You can customize the theme when installing:

app.use(SpecificUI, {
  theme: {
    AgentBoard: {
      // Custom theme options
      inactiveGradientStart: '#93a8ff',
      inactiveGradientEnd: '#7490ff'
    }
  }
})

License

MIT

0.0.31

9 months ago

0.0.30

9 months ago

0.0.29

9 months ago

0.0.28

9 months ago

0.0.26

9 months ago

0.0.25

9 months ago

0.0.24

9 months ago

0.0.23

9 months ago

0.0.22

9 months ago

0.0.21

9 months ago

0.0.19

9 months ago

0.0.18

9 months ago

0.0.17

9 months ago

0.0.16

9 months ago

0.0.15

9 months ago

0.0.14

9 months ago

0.0.13

9 months ago

0.0.12

9 months ago

0.0.11

9 months ago

0.0.10

10 months ago

0.0.9

10 months ago

0.0.8

10 months ago

0.0.7

10 months ago

0.0.6

10 months ago

0.0.5

10 months ago

0.0.4

10 months ago

0.0.3

10 months ago

0.0.2

10 months ago

0.0.1

10 months ago