@vue-pdf-viewer/viewer 3.7.0-beta.7 → 3.7.0-rc.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/README.md +1 -1
- package/dist/{index-D5Vct58x.js → index-CkNfIVah.js} +1 -1
- package/dist/index-DIDvNOvh.js +28053 -0
- package/dist/index.js +2 -2
- package/dist/index.umd.cjs +37 -37
- package/dist/types/components/VPdfViewer.vue.d.ts +6 -7
- package/dist/types/components/ui/button/index.d.ts +1 -1
- package/dist/types/components/ui/popover/PopoverContent.vue.d.ts +3 -3
- package/dist/types/composables/useAnnotationHighlight.d.ts +1 -43
- package/dist/types/composables/useAnnotationStorage.d.ts +0 -9
- package/dist/types/composables/usePlugins.d.ts +1 -2
- package/dist/types/composables/useVirtualPages.d.ts +0 -12
- package/dist/types/const.d.ts +5 -734
- package/dist/types/utils/color.d.ts +0 -5
- package/dist/types/utils/types.d.ts +3 -14
- package/package.json +4 -5
- package/dist/index-CYad3DaA.js +0 -29500
- package/dist/lib/assets/pdf-legacy/pdf.worker.min.mjs +0 -21
- package/dist/lib/assets/pdf.worker.min.mjs +0 -21
- package/dist/types/components/LayerAnnotationEditorTextSelectionItem.vue.d.ts +0 -26
- package/dist/types/components/LayerAnnotationEditorTextSelectionItemMenu.vue.d.ts +0 -31
- package/dist/types/composables/useAnnotationStrikethrough.d.ts +0 -790
- package/dist/types/composables/useAnnotationTextSelection.d.ts +0 -30
- package/dist/types/composables/useAnnotationUnderline.d.ts +0 -790
- /package/dist/types/components/{AppColorPicker.vue.d.ts → HighlightColorPicker.vue.d.ts} +0 -0
|
@@ -2,8 +2,3 @@ export declare const makeHexColor: (r: number, g: number, b: number) => string;
|
|
|
2
2
|
export declare const uint8ClampedArrayToRgb: (color: Uint8ClampedArray | number[]) => number[];
|
|
3
3
|
export declare function rgbToUint8ClampedArray(hexColor: string): number[];
|
|
4
4
|
export declare function hexToUint8ClampedArray(hexColor: string): Uint8ClampedArray;
|
|
5
|
-
export declare function hexToRgb(hexColor: string): {
|
|
6
|
-
r: number;
|
|
7
|
-
g: number;
|
|
8
|
-
b: number;
|
|
9
|
-
} | null;
|
|
@@ -2,7 +2,7 @@ import { ComputedRef, MaybeRef, PropType, Reactive, Ref } from 'vue';
|
|
|
2
2
|
import type { PageViewport, RenderTask } from 'pdfjs-dist';
|
|
3
3
|
import type { DocumentInitParameters, OnProgressParameters, PDFDataRangeTransport, TextContent, TypedArray, PDFPageProxy, PDFDocumentProxy, RenderParameters } from 'pdfjs-dist/types/src/display/api';
|
|
4
4
|
import type { Metadata } from 'pdfjs-dist/types/src/display/metadata';
|
|
5
|
-
import type { Annotation
|
|
5
|
+
import type { Annotation } from '@vue-pdf-viewer/shared';
|
|
6
6
|
import { ZoomLevel, ViewMode, ScrollMode, VPVAnnotationType, LicenseType, LicenseProduct } from './enumerators';
|
|
7
7
|
import { Localization, Plugin, AnnotationType } from '@vue-pdf-viewer/shared';
|
|
8
8
|
export interface VirtualRange {
|
|
@@ -36,7 +36,6 @@ export interface PageShowRatioChangePayload {
|
|
|
36
36
|
ratio: number;
|
|
37
37
|
}
|
|
38
38
|
export type AnnotationIconType = keyof typeof AnnotationType | 'Signature';
|
|
39
|
-
export type AnnotationTextSelectionType = 'highlight' | 'underline' | 'strikethrough';
|
|
40
39
|
export interface AnnotationEventPayload {
|
|
41
40
|
type: VPVAnnotationType;
|
|
42
41
|
data: any;
|
|
@@ -422,7 +421,7 @@ export interface VPdfViewerProps {
|
|
|
422
421
|
/**
|
|
423
422
|
* The plugins to be used in the VPV.
|
|
424
423
|
*/
|
|
425
|
-
plugins?: Plugin
|
|
424
|
+
plugins?: Plugin[];
|
|
426
425
|
/**
|
|
427
426
|
* Document loading options for configuring how the PDF is fetched and loaded.
|
|
428
427
|
* Controls chunk size, streaming, and auto-fetch behavior.
|
|
@@ -460,8 +459,6 @@ export interface PdfProperties {
|
|
|
460
459
|
pdfVersion: string;
|
|
461
460
|
pageCount?: number;
|
|
462
461
|
}
|
|
463
|
-
export type TextSelectionMenuOption = Pick<TextSelectionOption, 'highlight' | 'underline' | 'strikethrough'>;
|
|
464
|
-
export type TextSelectionMenuItemOption = AnnotationToolOption;
|
|
465
462
|
export declare const VPVBaseProps: {
|
|
466
463
|
readonly src: {
|
|
467
464
|
readonly type: PropType<string | VPVSrc>;
|
|
@@ -540,7 +537,7 @@ export declare const VPVBaseProps: {
|
|
|
540
537
|
readonly default: undefined;
|
|
541
538
|
};
|
|
542
539
|
readonly plugins: {
|
|
543
|
-
readonly type: PropType<Plugin
|
|
540
|
+
readonly type: PropType<Plugin[]>;
|
|
544
541
|
readonly default: undefined;
|
|
545
542
|
};
|
|
546
543
|
readonly documentOptions: {
|
|
@@ -705,15 +702,7 @@ export interface AnnotationHighlight extends Annotation {
|
|
|
705
702
|
drawLayerId: number;
|
|
706
703
|
outlineId: number;
|
|
707
704
|
pageIndex?: number;
|
|
708
|
-
boxes?: Array<{
|
|
709
|
-
x: number;
|
|
710
|
-
y: number;
|
|
711
|
-
width: number;
|
|
712
|
-
height: number;
|
|
713
|
-
}>;
|
|
714
705
|
}
|
|
715
|
-
export type AnnotationUnderline = AnnotationHighlight;
|
|
716
|
-
export type AnnotationStrikethrough = AnnotationHighlight;
|
|
717
706
|
export interface AnnotationStamp extends Annotation {
|
|
718
707
|
hasOwnCanvas: boolean;
|
|
719
708
|
originalAnnotation?: any;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vue-pdf-viewer/viewer",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "3.7.0-
|
|
4
|
+
"version": "3.7.0-rc.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.umd.cjs",
|
|
7
7
|
"module": "./dist/index.js",
|
|
@@ -21,11 +21,11 @@
|
|
|
21
21
|
"vue pdf viewer",
|
|
22
22
|
"web component",
|
|
23
23
|
"vue-pdf",
|
|
24
|
-
"vue-pdf-viewer",
|
|
24
|
+
"vue-pdf-viewer ",
|
|
25
25
|
"pdf-viewer",
|
|
26
26
|
"nuxt-pdf"
|
|
27
27
|
],
|
|
28
|
-
"author": "Vue PDF Viewer <
|
|
28
|
+
"author": "Vue PDF Viewer <david@vue-pdf-viewer.dev>",
|
|
29
29
|
"license": "See license section",
|
|
30
30
|
"homepage": "https://www.vue-pdf-viewer.dev",
|
|
31
31
|
"url": "https://github.com/vue-pdf-viewer/vue-pdf-viewer",
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"prepare": "husky"
|
|
61
61
|
},
|
|
62
62
|
"dependencies": {
|
|
63
|
-
"@vue-pdf-viewer/shared": "1.
|
|
63
|
+
"@vue-pdf-viewer/shared": "1.1.3",
|
|
64
64
|
"@vueuse/core": "^13.6.0",
|
|
65
65
|
"node-forge": "^1.3.2",
|
|
66
66
|
"pdfjs-dist": "4.10.38",
|
|
@@ -106,7 +106,6 @@
|
|
|
106
106
|
"unocss-preset-shadcn": "^0.3.1",
|
|
107
107
|
"vite": "^5.2.8",
|
|
108
108
|
"vite-plugin-node-polyfills": "^0.21.0",
|
|
109
|
-
"vite-plugin-static-copy": "^3.1.2",
|
|
110
109
|
"vite-svg-loader": "^5.1.0",
|
|
111
110
|
"vitest": "^3.2.4",
|
|
112
111
|
"vitest-browser-vue": "^1.1.0",
|