From 5b906322313d9bc0e68f6d0c020af9ee07da4f75 Mon Sep 17 00:00:00 2001 From: nobohan Date: Wed, 4 Sep 2024 10:14:08 +0200 Subject: [PATCH 01/18] Signature: add a signature zone manually --- .../Resources/public/types.ts | 4 +- .../public/vuejs/DocumentSignature/App.vue | 163 +++++++++++++----- .../public/vuejs/DocumentSignature/index.ts | 4 +- 3 files changed, 128 insertions(+), 43 deletions(-) diff --git a/src/Bundle/ChillDocStoreBundle/Resources/public/types.ts b/src/Bundle/ChillDocStoreBundle/Resources/public/types.ts index 840421991..921da3a9a 100644 --- a/src/Bundle/ChillDocStoreBundle/Resources/public/types.ts +++ b/src/Bundle/ChillDocStoreBundle/Resources/public/types.ts @@ -83,7 +83,7 @@ export interface PDFPage { height: number, } export interface SignatureZone { - index: number, + index: number | null, x: number, y: number, width: number, @@ -98,3 +98,5 @@ export interface Signature { } export type SignedState = 'pending' | 'signed' | 'rejected' | 'canceled' | 'error'; + +export type CanvasEvent = 'select' | 'add'; diff --git a/src/Bundle/ChillDocStoreBundle/Resources/public/vuejs/DocumentSignature/App.vue b/src/Bundle/ChillDocStoreBundle/Resources/public/vuejs/DocumentSignature/App.vue index 47edd87c3..04cdf9eea 100644 --- a/src/Bundle/ChillDocStoreBundle/Resources/public/vuejs/DocumentSignature/App.vue +++ b/src/Bundle/ChillDocStoreBundle/Resources/public/vuejs/DocumentSignature/App.vue @@ -80,8 +80,32 @@
+ +
+
+
+ +
+
+ +
+
+
+
-
+
-
+
-
-
- -
-
- -
-
+
+
+
+
+ +
+
+ +
-
+
-
- +
@@ -510,7 +503,7 @@ downloadAndOpen();