npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

smart-screen-design

v3.9.3

Published

``` import MZUI from 'smart-screen-design'; import 'smart-screen-design/windi.css'; app.use(MZUI); ```

Downloads

26

Readme

使用

import MZUI from 'smart-screen-design';
import 'smart-screen-design/windi.css';
app.use(MZUI);

TLayout

T型布局

<TLayout>
    <template #top>
    </template>
    <template #left>
    </template>
    <template #right>
    </template>
  </TLayout>

slot | 说明 --- | :---: top | 顶部栏 left | 下方左半部分 right | 下方左半部分

topBar

顶部栏

<top-bar
    :device-name="deviceInfo.value.name"
    :room-name="deviceInfo.value.homeName"
    :desc="delayDesc"
    @exit="exitPage"
></top-bar>

prop|type|default|说明 --- |:---:|:---:|:---: deviceName| string | 灯光 | 设备名 roomName | string | 主卧 | 房间名 desc | string | 你想讲滴咩野 | 设备状态描述 background-color| string | #000 | 背景色

event|callback|type|说明 --- |:---:|:---:|:---: exit | | |告知点击退出按钮

powerSwitch

设备开关

<power-switch :power="OnOff" :on-icon="onIcon" :off-icon="offIcon" @change="OnOffControl"></power-switch>

prop|type|default|说明 --- |:---:|:---:|:---: power| boolean | true |当前开关值 onIcon | 图片 | 智慧屏开图标 |开图标 offIcon | 图片 | 智慧屏关图标 |关图标

event|callback|type|说明 --- |:---:|:---:|:---: change | !power | boolean |返回!power

adjustCard

调节卡片

<adjust-card class="flex-auto" title="亮度" :percentage="brightNessPercentage" @update="brightNessHandler">
</adjust-card>

prop| type |default|说明 --- |:-------:|:--:|:---: title| string | 亮度 |标题 desc| string | '' | 描述 percentage | number | 60 |百分比 min | number | 0 |最小百分比 max | number | 100 |最大百分比 color | string | 0 |背景色 height | number | 20 |拖动条高度 unit| string | % | 单位 step | number | 1 | 指定步长 graph | number | 3 | 段落分节 disabled | boolean | false | 是否禁用 slideDisabled | boolean | false | 是否禁用滑动

event|callback| type |说明 --- |:---:|:------:|:---: update | percent | number |返回拖动变化percent sliderEnd | percent | number |返回拖动结束时的百分比percent

modeCard

模式卡片

<mode-card class="flex-auto" :modes="runModes" @select="changeMode"></mode-card>
interface Mode {
  id: number;

  name: string;

  icon_on: string;

  icon_off: string;

  selected: boolean;

  [key: string]: any;
}

prop|type|default|说明 --- |:---:|:---:|:---: title| string | 模式 |标题 selectedVisable | boolean | true |已选模式是否标注 modes | Array<Mode> | 0 |最小百分比 row | number | 4 | 行容量

event|callback|type|说明 --- |:---:|:---:|:---: select | id | number |返回选择模式id

DropdownMenu

下拉框组件

<DropdownMenu
          title="模式"
          :value="device.mode"
          :options="config.modeList"
          @change="changeMode"
        ></DropdownMenu>
import { DropdownMenu } from 'smart-screen-design';

prop| type | default |说明 --- |:----------------------------------:|:-------:|:---: title| string | 标题 |标题 v-model | string | "" | 当前选中项对应的 value disabled | boolean | false | 是否禁用 options | Array<{text: string;value: string }> | [] | 选项数组

event|回调参数|说明 --- |:---:|:---: change | {text: string;value: string } |点击选项导致 value 变化时触发

functionCard

功能卡片

        <functionCard title="零冷水" :icon="noCold">
          <template #right>
            <functionSwitch :checked="zeroOnOff" @change="handleNoCold">
            </functionSwitch>
          </template>
        </functionCard>
import { functionCard, functionSwitch } from 'smart-screen-design';

prop| type | default |说明 --- |:----------------------------------:|:-------:|:---: title| string | 标题 |标题 icon | string | '' | 前置图标

slot|说明 --- |:---: right | 右侧插槽

functionSwitch

功能开关

            <functionSwitch :checked="zeroOnOff" @change="handleNoCold">
            </functionSwitch>
import { functionSwitch } from 'smart-screen-design';

prop| type | default |说明 --- |:----------------------------------:|:-------:|:---: checked| boolean | true |开关

event|回调参数|说明 --- |:---:|:---: change | swi: boolean |点击切换

ScreenCell

单元格组件

<ScreenCell
          title="模式"
          :value="device.mode"
          :options="config.modeList"
          @change="changeMode"
        ></ScreenCell>
import { ScreenCell } from 'smart-screen-design';

prop| type | default |说明 --- |:---------------------------------------:|:-------:|:---: title| string | 标题 |标题 desc | string | "" | 描述状态文案 icon | 图片 | - | 图标