@component-hook/pdf-canvas 1.3.0-alpha.0 → 1.3.0-alpha.2

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.
@@ -92,24 +92,16 @@ export declare function loadFile(file: File, password?: string, id?: string): Pr
92
92
  PDFId: string;
93
93
  name: string;
94
94
  updateDate: number;
95
- PDFBase64: string;
96
- }> | Promise<{
97
- pages: number;
98
- PDFId: string;
99
- name: string;
100
- updateDate: number;
101
- data: ArrayBuffer;
102
- } | undefined>;
95
+ data: File;
96
+ }>;
103
97
 
104
98
  export declare interface PDF {
105
99
  PDFId: string;
106
100
  name: string;
107
101
  updateDate: number;
108
- data: ArrayBuffer | string;
102
+ data: File;
109
103
  pages: number;
110
- canvas?: ArrayBuffer[];
111
- trashDate?: number;
112
- isUpdate?: boolean;
104
+ canvas?: Blob[];
113
105
  }
114
106
 
115
107
  declare const PdfCanvas: ForwardRefExoticComponent<ComponentProps & ComponentEmits & RefAttributes<PdfCanvasHandle>>;
@@ -128,7 +120,7 @@ export declare interface PdfCanvasHandle {
128
120
  }
129
121
 
130
122
  export declare interface RenderImageArgs {
131
- url: string;
123
+ data: File;
132
124
  scale?: number;
133
125
  }
134
126
 
@@ -138,7 +130,7 @@ export declare type SelectedEvent = Partial<TEvent> & {
138
130
 
139
131
  export declare interface SpecifyPageArgs {
140
132
  page: number;
141
- data: ArrayBuffer;
133
+ data: Blob;
142
134
  scale: number;
143
135
  password?: string;
144
136
  }
@@ -161,16 +153,10 @@ export declare function useFabric(params?: FabricHookParams & {
161
153
  PDFId: string;
162
154
  name: string;
163
155
  updateDate: number;
164
- PDFBase64: string;
165
- }> | Promise<{
166
- pages: number;
167
- PDFId: string;
168
- name: string;
169
- updateDate: number;
170
- data: ArrayBuffer;
171
- } | undefined>;
156
+ data: File;
157
+ }>;
172
158
  specifyPage: (specifyPageParams: SpecifyPageArgs) => Promise<number>;
173
- renderImage: ({ url, scale }: RenderImageArgs) => Promise<void>;
159
+ renderImage: ({ data, scale }: RenderImageArgs) => Promise<void>;
174
160
  addFabric: (src: string, options?: TOptions<ImageProps>, offset?: DropOffset) => Promise<void>;
175
161
  addTextFabric: (text: string, options?: TOptions<TextProps>, offset?: DropOffset) => void;
176
162
  clearActive: () => void;