1.0.4 • Published 1 year ago

cell-watermark v1.0.4

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

Class: Watermark

Watermark(options)

new Watermark(options)

Parameters:
NameTypeDescription
optionsObjectThe options of watermark(Properties
Properties:
NameTypeAttributesDefaultDescription
contentString\<optional>watermark's text
appendToString\<optional>'body'parent of watermark's container
widthNumber\<optional>150watermark's width. unit: px
heightNumber\<optional>20watermark's height. unit: px
rowSpacingNumber\<optional>60row spacing of watermarks. unit: px
colSpacingNumber\<optional>30col spacing of watermarks. unit: px
rotateNumber\<optional>15watermark's tangent angle. unit: deg
opacityNumber\<optional>0.1watermark's transparency
fontSizeNumber\<optional>0.85watermark's fontSize. unit: rem
fontFamilyString\<optional>'inherit'watermark's fontFamily.

Author: Lruihao

Methods

upload(content)

Upload watermark's text content

Parameters:
NameTypeDescription
contentStringwatermark's text

render(options)

Rerender watermark

Parameters:
NameTypeDescription
optionsObjectThe options of watermark(Properties

destroy()

Force destroy watermark