0.1.31 • Published 11 months ago

hzim-ui v0.1.31

Weekly downloads
-
License
-
Repository
-
Last release
11 months ago

hzim_ui

This template should help get you started developing with Vue 3 in Vite.

安装

npm安装

npm install hzim-ui

yarn安装

yarn add hzim-ui

使用

目前仅支持vite+vue3+js项目

//main.js 引入组件库
import HZIMUI from 'hzim-ui'
import "hzim-ui/style.css"//引入样式文件
const app = createApp(App)
app.use(HZIMUI)

使用组件

<template>
  <HzChatApp ref="charRef"></HzChatApp>
</template>
<script setup>
  let chatRef = ref()
  let options = relative({
    url: "https://example.irenfang.cn",
    MqttUrl: "http://example.irenfang.cn:28083",
    token: 'iusghe9u.43hn9uihvs98ehr.590834g5',
    userId: 'hz031',
    name: '。',
    avatar: '',
    topic: `chat/user/${sessionStorage.getItem('userId')}/inbox`,
    qos: 1
  })
  let MailList = ref([
    {
      name: 'zhangsan',
      id: 'hz099',
      avatar: ''
    },
  ])
  chatRef.value.initChatSys(options, MailList.value)
</script>

API

参数说明类型可选值默认值是否必填
options连接参数object
MailList联系人列表Array

options

参数说明类型可选值默认值是否必填
urlsocket.io及后端服务地址string
MqttUrlmqtt地址string
tokentokenstring
userId用户IDstring
name用户名string
avatar头像string
topicmqtt会话主题string
qos同mqtt qosnumber

MailList

参数说明类型可选值默认值是否必填
userId用户IDstring
name用户名string
avatar头像string

Slot

NameDescription
-
--

Events

事件名称说明回调参数
---

Methods

名称说明类型
initChatSys初始化聊天组件^Function(options,MailList) => void
0.1.31

11 months ago

0.1.30

11 months ago

0.1.29

11 months ago

0.1.28

11 months ago

0.1.27

11 months ago

0.1.26

11 months ago

0.1.25

11 months ago

0.1.24

11 months ago

0.1.23

11 months ago

0.1.22

11 months ago

0.1.21

11 months ago

0.1.20

11 months ago

0.1.19

11 months ago

0.1.18

11 months ago

0.1.17

11 months ago

0.1.16

11 months ago

0.1.15

11 months ago

0.1.14

11 months ago

0.1.13

11 months ago

0.1.11

11 months ago

0.1.10

11 months ago

0.1.9

11 months ago

0.1.8

11 months ago

0.1.7

11 months ago

0.1.6

11 months ago

0.1.5

11 months ago

0.1.4

11 months ago

0.1.3

11 months ago

0.1.2

11 months ago

0.1.1

11 months ago

0.1.0

11 months ago