@varlet/ui 2.13.6 → 2.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@varlet/ui",
3
- "version": "2.13.6",
3
+ "version": "2.14.0",
4
4
  "description": "A material like components library",
5
5
  "main": "lib/varlet.cjs.js",
6
6
  "module": "es/index.mjs",
@@ -46,9 +46,9 @@
46
46
  "@popperjs/core": "^2.11.6",
47
47
  "dayjs": "^1.10.4",
48
48
  "decimal.js": "^10.2.1",
49
- "@varlet/icons": "2.13.6",
50
- "@varlet/use": "2.13.6",
51
- "@varlet/shared": "2.13.6"
49
+ "@varlet/icons": "2.14.0",
50
+ "@varlet/shared": "2.14.0",
51
+ "@varlet/use": "2.14.0"
52
52
  },
53
53
  "devDependencies": {
54
54
  "@vue/runtime-core": "3.3.4",
@@ -63,8 +63,8 @@
63
63
  "typescript": "^5.1.5",
64
64
  "vue": "3.3.4",
65
65
  "vue-router": "4.2.0",
66
- "@varlet/touch-emulator": "2.13.6",
67
- "@varlet/cli": "2.13.6"
66
+ "@varlet/touch-emulator": "2.14.0",
67
+ "@varlet/cli": "2.14.0"
68
68
  },
69
69
  "browserslist": [
70
70
  "Chrome >= 54",
package/types/index.d.ts CHANGED
@@ -86,6 +86,7 @@ export * from './tooltip'
86
86
  export * from './uploader'
87
87
  export * from './varComponent'
88
88
  export * from './varDirective'
89
+ export * from './watermark'
89
90
 
90
91
  declare module 'vue' {
91
92
  export interface GlobalComponents {
@@ -167,6 +168,7 @@ declare module 'vue' {
167
168
  VarTimePicker: typeof import('@varlet/ui')['_TimePickerComponent']
168
169
  VarTooltip: typeof import('@varlet/ui')['_TooltipComponent']
169
170
  VarUploader: typeof import('@varlet/ui')['_UploaderComponent']
171
+ VarWatermark: typeof import('@varlet/ui')['_WatermarkComponent']
170
172
  }
171
173
 
172
174
  export interface ComponentCustomProperties {
@@ -0,0 +1,40 @@
1
+ import { VNode } from 'vue'
2
+ import { VarComponent, BasicAttributes } from './varComponent'
3
+
4
+ export declare const watermarkProps: Record<string, any>
5
+
6
+ export interface WatermarkFont {
7
+ fontSize?: number
8
+ fontVariant?: string
9
+ fontWeight?: string
10
+ fontStyle?: string
11
+ fontFamily?: string
12
+ }
13
+
14
+ export interface WatermarkProps extends BasicAttributes {
15
+ width?: number
16
+ height?: number
17
+ content?: string
18
+ image?: string
19
+ rotate?: number
20
+ offsetX?: number
21
+ offsetY?: number
22
+ gapX?: number
23
+ gapY?: number
24
+ zIndex?: number | string
25
+ opacity?: number | string
26
+ fullscreen?: boolean
27
+ font?: WatermarkFont
28
+ }
29
+
30
+ export class Watermark extends VarComponent {
31
+ $props: WatermarkProps
32
+
33
+ $slots: {
34
+ content(): VNode[]
35
+ }
36
+
37
+ resize(): void
38
+ }
39
+
40
+ export class _WatermarkComponent extends Watermark {}