1.0.1 • Published 3 years ago

vue-element-move v1.0.1

Weekly downloads
6
License
MIT
Repository
github
Last release
3 years ago

vue-element-move

npm (scoped)

directive for moving elements.

Install

npm i vue-element-move

Example

<template>
  <!-- dialog -->
  <div v-move="() => $refs.dialog" ref="dialog">
  </div>
  <!-- dialog -->
</template>

<script>
import move from "vue-element-move";

export default {
  directives: {
    move
  }
  ...
}
</script>

Options

set options to configure move

<template>
  <div v-move="() => $refs.dialog" ref="dialog" move-out>
  </div>
</template>
NameDetail
move-outAllow move out of window
move-x-rightWhen moving, the X coordinate is calculated according to the right side
move-y-bottomWhen moving, the Y coordinate is calculated according to the bottom
move-cursorCursor when moving