Skip to content
/ mirror Public

A Vue2 based component for special mirror effects

Notifications You must be signed in to change notification settings

GJYyyyy/mirror

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Example

将你自己的组件或内容放入 Mirror 组件中即可!
然后你就看到镜面倒影了!

How to use

<template>
  <Mirror
    :gradient="gradient"
    :gradientPoint="gradientPoint"
    :blue="blur"
    :opacity="opacity"
    :gap="gap"
  >
    <div class="dv">你自己的组件或内容</div>
  </Mirror>
</template>

<script>
  import Mirror from "edge-mirror/src/Mirror.vue";
  export default {
    components: {
      Mirror,
    },
    data: {
      gradient: false, // 是否开启镜面倒影渐变
      gradientPoint: 0.5, // 镜面倒影渐变点
      blur: 0, // 镜面倒影模糊度,单位px
      opacity: 0.5, // 镜面倒影透明度
      gap: 5, // 镜面倒影与组件之间的距离,单位px
    },
  };
</script>

<style>
  .dv {
    width: 400px;
    height: 400px;
    background-color: goldenrod;
  }
</style>

About

A Vue2 based component for special mirror effects

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published