0.1.1 • Published 1 year ago

@aplus-frontend/watermark v0.1.1

Weekly downloads
-
License
Apache-2.0
Repository
-
Last release
1 year ago

Watermark 水印

给页面的某个区域加上水印

基本使用

import { watermark } from '@aplus-frontend/watermark'
watermark({
  content: 'aplus 水印',
  isShow: true,
})

Props

参数说明类型默认值
container承载水印的父容器HTMLElementbody
isShow水印是否加载booleantrue
width水印的宽度string300px
height水印的高度string200px
textAlign文本对其方式"start" or "end" or "center" or "left" or "right"center
textBaseline文本对其方式"alphabetic" or "top" or "hanging" or "middle" or "ideographic" or "bottom"middle
font文字样式stringrgba20px Microsoft Yahei
fillStyle文字的颜色stringrgba(191, 191, 191, 0.15)
content填充文本string水印
content水印文本旋转的角度number30
zIndex水印的高度number10000

方法

  • init 水印挂载
  • setOption 修改配置项
  • destroy 卸载水印
0.1.0

1 year ago

0.1.1

1 year ago

0.0.10

1 year ago

0.0.11

1 year ago

0.0.12

1 year ago

0.0.13

1 year ago

0.0.9

1 year ago

0.0.8

1 year ago

0.0.7

1 year ago