1.1.2 • Published 5 years ago

vue-testwidget v1.1.2

Weekly downloads
-
License
MIT
Repository
github
Last release
5 years ago

Vue.js Simple widget

Simple use, Easy custom

vue-simple-widget If you find bug / suggest some idea

use issue

or

contect me(desktop@kakao.com)

install

# Use npm
npm install vue-simple-widget --save
# Use yarn
yarn add vue-simple-widget

How to use

Include plugin your .vue file

import SimpleWidget from 'vue-simple-widget';

components: {
  SimpleWidget;
}

Create widget:

<simple-widget
    widgetId='Your ElementId'
    ....
  // input your options
></simple-widget>

or Include your main.js

import Vue from 'vue';
import SimpleWidget from 'vue-simple-widget';

Vue.use(SimpleWidget);

Input your content:

<simple-widget>
  <template v-slot:header>
    <p>vue-simple-widget</p>
  </template>
  <template v-slot:content>
    <p> Input your text! </p>
  </template>
</simple-widget>

Properties

| Name | Required | Default | Description |

NameRequiredTypeDefaultDescription
widgetIdtrueString,Numberinput your element id
widthfalseNumber330pxwidget width, only support px
heightfalseNumber360pxwidget height, only support px
headerAlignfalseStringleftleft,right,center
contentAlignfalseStringleftleft,right,center
verticalPostionfalseStringbottombased on widgetId set vetical postion top,bottom
horizontalPostionfalseStringrightbased on widgetId set horizontal postion left,right
bgcolorfalseString#ffffffwidget background color you can use css color code
borderColorfalseString#ccccccwidget border color you can use css color code
borderStylefalseStringsolidwidget border style you can use css border style
borderWeightfalseString1pxwidget border weight you can use '2' px size

Example

<template>
  <div>
    <button id="showWidget" @click="show = true">
      show
    </button>

    <simple-widget
      v-if="show"
      widgetId="showWidget"
      headerAlign="center"
      contentAlign="right"
      width="400"
      height="200"
      verticalPostion="top"
      horizontalPostion="left"
      @close="show = false"
    >
      <template v-slot:header>
        header
      </template>
      <template v-slot:content>
        content
      </template>
    </simple-widget>
  </div>
</template>

<script>
export defult{
  data(){
    return{
      show: false
    }
  }
}
</script>
1.1.2

5 years ago

1.1.1

5 years ago

1.1.0

5 years ago

1.0.20

5 years ago

1.0.19

5 years ago

1.0.18

5 years ago

1.0.17

5 years ago

1.0.16

5 years ago

1.0.15

5 years ago

1.0.14

5 years ago

1.0.13

5 years ago

1.0.11

5 years ago

1.0.12

5 years ago

1.0.10

5 years ago

1.0.9

5 years ago

1.0.8

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago