@campxdev/pdfme 1.1.0 → 1.2.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/dist/types/_vendors/common/constants.d.ts +20 -0
- package/dist/types/_vendors/common/dynamicTemplate.d.ts +27 -0
- package/dist/types/_vendors/common/expression.d.ts +6 -0
- package/dist/types/_vendors/common/fontData.d.ts +29 -0
- package/dist/types/_vendors/common/helper.d.ts +37 -0
- package/dist/types/_vendors/common/index.d.ts +9 -0
- package/dist/types/_vendors/common/pluginRegistry.d.ts +5 -0
- package/dist/types/_vendors/common/schema.d.ts +822 -0
- package/dist/types/_vendors/common/types.d.ts +189 -0
- package/dist/types/_vendors/common/version.d.ts +1 -0
- package/dist/types/_vendors/converter/img2pdf.d.ts +12 -0
- package/dist/types/_vendors/converter/index.browser.d.ts +8 -0
- package/dist/types/_vendors/converter/index.node.d.ts +8 -0
- package/dist/types/_vendors/converter/pdf2img.d.ts +17 -0
- package/dist/types/_vendors/converter/pdf2size.d.ts +10 -0
- package/dist/types/_vendors/generator/constants.d.ts +1 -0
- package/dist/types/_vendors/generator/generate.d.ts +3 -0
- package/dist/types/_vendors/generator/helper.d.ts +29 -0
- package/dist/types/_vendors/generator/index.d.ts +2 -0
- package/dist/types/_vendors/generator/types.d.ts +20 -0
- package/dist/types/_vendors/manipulator/index.d.ts +46 -0
- package/dist/types/_vendors/pdf-lib/api/Embeddable.d.ts +7 -0
- package/dist/types/_vendors/pdf-lib/api/PDFDocument.d.ts +778 -0
- package/dist/types/_vendors/pdf-lib/api/PDFDocumentOptions.d.ts +38 -0
- package/dist/types/_vendors/pdf-lib/api/PDFEmbeddedFile.d.ts +38 -0
- package/dist/types/_vendors/pdf-lib/api/PDFEmbeddedPage.d.ts +73 -0
- package/dist/types/_vendors/pdf-lib/api/PDFFont.d.ts +94 -0
- package/dist/types/_vendors/pdf-lib/api/PDFImage.d.ts +95 -0
- package/dist/types/_vendors/pdf-lib/api/PDFJavaScript.d.ts +38 -0
- package/dist/types/_vendors/pdf-lib/api/PDFPage.d.ts +910 -0
- package/dist/types/_vendors/pdf-lib/api/PDFPageOptions.d.ts +172 -0
- package/dist/types/_vendors/pdf-lib/api/StandardFonts.d.ts +16 -0
- package/dist/types/_vendors/pdf-lib/api/colors.d.ts +34 -0
- package/dist/types/_vendors/pdf-lib/api/errors.d.ts +42 -0
- package/dist/types/_vendors/pdf-lib/api/form/PDFButton.d.ts +137 -0
- package/dist/types/_vendors/pdf-lib/api/form/PDFCheckBox.d.ts +142 -0
- package/dist/types/_vendors/pdf-lib/api/form/PDFDropdown.d.ts +402 -0
- package/dist/types/_vendors/pdf-lib/api/form/PDFField.d.ts +203 -0
- package/dist/types/_vendors/pdf-lib/api/form/PDFForm.d.ts +411 -0
- package/dist/types/_vendors/pdf-lib/api/form/PDFOptionList.d.ts +335 -0
- package/dist/types/_vendors/pdf-lib/api/form/PDFRadioGroup.d.ts +252 -0
- package/dist/types/_vendors/pdf-lib/api/form/PDFSignature.d.ts +29 -0
- package/dist/types/_vendors/pdf-lib/api/form/PDFTextField.d.ts +537 -0
- package/dist/types/_vendors/pdf-lib/api/form/appearances.d.ts +41 -0
- package/dist/types/_vendors/pdf-lib/api/form/index.d.ts +10 -0
- package/dist/types/_vendors/pdf-lib/api/image/alignment.d.ts +5 -0
- package/dist/types/_vendors/pdf-lib/api/image/index.d.ts +1 -0
- package/dist/types/_vendors/pdf-lib/api/index.d.ts +20 -0
- package/dist/types/_vendors/pdf-lib/api/objects.d.ts +4 -0
- package/dist/types/_vendors/pdf-lib/api/operations.d.ts +226 -0
- package/dist/types/_vendors/pdf-lib/api/operators.d.ts +90 -0
- package/dist/types/_vendors/pdf-lib/api/rotations.d.ts +38 -0
- package/dist/types/_vendors/pdf-lib/api/sizes.d.ts +52 -0
- package/dist/types/_vendors/pdf-lib/api/svg.d.ts +70 -0
- package/dist/types/_vendors/pdf-lib/api/svgPath.d.ts +2 -0
- package/dist/types/_vendors/pdf-lib/api/text/alignment.d.ts +5 -0
- package/dist/types/_vendors/pdf-lib/api/text/index.d.ts +2 -0
- package/dist/types/_vendors/pdf-lib/api/text/layout.d.ts +54 -0
- package/dist/types/_vendors/pdf-lib/core/PDFContext.d.ts +84 -0
- package/dist/types/_vendors/pdf-lib/core/PDFObjectCopier.d.ts +37 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroButton.d.ts +21 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroCheckBox.d.ts +13 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroChoice.d.ts +20 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroComboBox.d.ts +9 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroField.d.ts +36 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroForm.d.ts +20 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroListBox.d.ts +9 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroNonTerminal.d.ts +13 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroPushButton.d.ts +9 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroRadioButton.d.ts +13 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroSignature.d.ts +7 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroTerminal.d.ts +16 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/PDFAcroText.d.ts +22 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/flags.d.ts +141 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/index.d.ts +15 -0
- package/dist/types/_vendors/pdf-lib/core/acroform/utils.d.ts +6 -0
- package/dist/types/_vendors/pdf-lib/core/annotation/AppearanceCharacteristics.d.ts +33 -0
- package/dist/types/_vendors/pdf-lib/core/annotation/BorderStyle.d.ts +11 -0
- package/dist/types/_vendors/pdf-lib/core/annotation/PDFAnnotation.d.ts +51 -0
- package/dist/types/_vendors/pdf-lib/core/annotation/PDFWidgetAnnotation.d.ts +26 -0
- package/dist/types/_vendors/pdf-lib/core/annotation/flags.d.ts +79 -0
- package/dist/types/_vendors/pdf-lib/core/annotation/index.d.ts +4 -0
- package/dist/types/_vendors/pdf-lib/core/crypto.d.ts +95 -0
- package/dist/types/_vendors/pdf-lib/core/document/PDFCrossRefSection.d.ts +27 -0
- package/dist/types/_vendors/pdf-lib/core/document/PDFHeader.d.ts +10 -0
- package/dist/types/_vendors/pdf-lib/core/document/PDFTrailer.d.ts +9 -0
- package/dist/types/_vendors/pdf-lib/core/document/PDFTrailerDict.d.ts +10 -0
- package/dist/types/_vendors/pdf-lib/core/embedders/CMap.d.ts +3 -0
- package/dist/types/_vendors/pdf-lib/core/embedders/CustomFontEmbedder.d.ts +44 -0
- package/dist/types/_vendors/pdf-lib/core/embedders/CustomFontSubsetEmbedder.d.ts +20 -0
- package/dist/types/_vendors/pdf-lib/core/embedders/FileEmbedder.d.ts +33 -0
- package/dist/types/_vendors/pdf-lib/core/embedders/FontFlags.d.ts +13 -0
- package/dist/types/_vendors/pdf-lib/core/embedders/JavaScriptEmbedder.d.ts +10 -0
- package/dist/types/_vendors/pdf-lib/core/embedders/JpegEmbedder.d.ts +23 -0
- package/dist/types/_vendors/pdf-lib/core/embedders/PDFPageEmbedder.d.ts +37 -0
- package/dist/types/_vendors/pdf-lib/core/embedders/PngEmbedder.d.ts +19 -0
- package/dist/types/_vendors/pdf-lib/core/embedders/StandardFontEmbedder.d.ts +36 -0
- package/dist/types/_vendors/pdf-lib/core/errors.d.ts +91 -0
- package/dist/types/_vendors/pdf-lib/core/index.d.ts +47 -0
- package/dist/types/_vendors/pdf-lib/core/interactive/ViewerPreferences.d.ts +347 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFArray.d.ts +63 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFBool.d.ts +13 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFDict.d.ts +62 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFHexString.d.ts +16 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFInvalidObject.d.ts +11 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFName.d.ts +41 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFNull.d.ts +10 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFNumber.d.ts +15 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFObject.d.ts +8 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFRawStream.d.ts +16 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFRef.d.ts +13 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFStream.d.ts +16 -0
- package/dist/types/_vendors/pdf-lib/core/objects/PDFString.d.ts +16 -0
- package/dist/types/_vendors/pdf-lib/core/operators/PDFOperator.d.ts +19 -0
- package/dist/types/_vendors/pdf-lib/core/operators/PDFOperatorNames.d.ts +76 -0
- package/dist/types/_vendors/pdf-lib/core/parser/BaseParser.d.ts +14 -0
- package/dist/types/_vendors/pdf-lib/core/parser/ByteStream.d.ts +26 -0
- package/dist/types/_vendors/pdf-lib/core/parser/PDFObjectParser.d.ts +31 -0
- package/dist/types/_vendors/pdf-lib/core/parser/PDFObjectStreamParser.d.ts +13 -0
- package/dist/types/_vendors/pdf-lib/core/parser/PDFParser.d.ts +46 -0
- package/dist/types/_vendors/pdf-lib/core/parser/PDFXRefStreamParser.d.ts +21 -0
- package/dist/types/_vendors/pdf-lib/core/streams/Ascii85Stream.d.ts +9 -0
- package/dist/types/_vendors/pdf-lib/core/streams/AsciiHexStream.d.ts +9 -0
- package/dist/types/_vendors/pdf-lib/core/streams/DecodeStream.d.ts +26 -0
- package/dist/types/_vendors/pdf-lib/core/streams/DecryptStream.d.ts +12 -0
- package/dist/types/_vendors/pdf-lib/core/streams/FlateStream.d.ts +13 -0
- package/dist/types/_vendors/pdf-lib/core/streams/LZWStream.d.ts +12 -0
- package/dist/types/_vendors/pdf-lib/core/streams/RunLengthStream.d.ts +8 -0
- package/dist/types/_vendors/pdf-lib/core/streams/Stream.d.ts +34 -0
- package/dist/types/_vendors/pdf-lib/core/streams/decode.d.ts +3 -0
- package/dist/types/_vendors/pdf-lib/core/structures/PDFCatalog.d.ts +27 -0
- package/dist/types/_vendors/pdf-lib/core/structures/PDFContentStream.d.ts +15 -0
- package/dist/types/_vendors/pdf-lib/core/structures/PDFCrossRefStream.d.ts +53 -0
- package/dist/types/_vendors/pdf-lib/core/structures/PDFFlateStream.d.ts +13 -0
- package/dist/types/_vendors/pdf-lib/core/structures/PDFObjectStream.d.ts +20 -0
- package/dist/types/_vendors/pdf-lib/core/structures/PDFPageLeaf.d.ts +54 -0
- package/dist/types/_vendors/pdf-lib/core/structures/PDFPageTree.d.ts +41 -0
- package/dist/types/_vendors/pdf-lib/core/syntax/CharCodes.d.ts +61 -0
- package/dist/types/_vendors/pdf-lib/core/syntax/Delimiters.d.ts +1 -0
- package/dist/types/_vendors/pdf-lib/core/syntax/Irregular.d.ts +1 -0
- package/dist/types/_vendors/pdf-lib/core/syntax/Keywords.d.ts +22 -0
- package/dist/types/_vendors/pdf-lib/core/syntax/Numeric.d.ts +3 -0
- package/dist/types/_vendors/pdf-lib/core/syntax/Whitespace.d.ts +1 -0
- package/dist/types/_vendors/pdf-lib/core/writers/PDFStreamWriter.d.ts +19 -0
- package/dist/types/_vendors/pdf-lib/core/writers/PDFWriter.d.ts +29 -0
- package/dist/types/_vendors/pdf-lib/index.d.ts +4 -0
- package/dist/types/_vendors/pdf-lib/types/fontkit.d.ts +597 -0
- package/dist/types/_vendors/pdf-lib/types/index.d.ts +25 -0
- package/dist/types/_vendors/pdf-lib/types/matrix.d.ts +21 -0
- package/dist/types/_vendors/pdf-lib/utils/Cache.d.ts +10 -0
- package/dist/types/_vendors/pdf-lib/utils/arrays.d.ts +16 -0
- package/dist/types/_vendors/pdf-lib/utils/async.d.ts +5 -0
- package/dist/types/_vendors/pdf-lib/utils/base64.d.ts +10 -0
- package/dist/types/_vendors/pdf-lib/utils/elements/Arc.d.ts +22 -0
- package/dist/types/_vendors/pdf-lib/utils/elements/Circle.d.ts +14 -0
- package/dist/types/_vendors/pdf-lib/utils/elements/Ellipse.d.ts +20 -0
- package/dist/types/_vendors/pdf-lib/utils/elements/GraphElement.d.ts +6 -0
- package/dist/types/_vendors/pdf-lib/utils/elements/Line.d.ts +23 -0
- package/dist/types/_vendors/pdf-lib/utils/elements/Plot.d.ts +11 -0
- package/dist/types/_vendors/pdf-lib/utils/elements/Point.d.ts +18 -0
- package/dist/types/_vendors/pdf-lib/utils/elements/Rectangle.d.ts +21 -0
- package/dist/types/_vendors/pdf-lib/utils/elements/Segment.d.ts +19 -0
- package/dist/types/_vendors/pdf-lib/utils/elements/index.d.ts +9 -0
- package/dist/types/_vendors/pdf-lib/utils/errors.d.ts +1 -0
- package/dist/types/_vendors/pdf-lib/utils/index.d.ts +11 -0
- package/dist/types/_vendors/pdf-lib/utils/intersections.d.ts +9 -0
- package/dist/types/_vendors/pdf-lib/utils/maths.d.ts +45 -0
- package/dist/types/_vendors/pdf-lib/utils/numbers.d.ts +23 -0
- package/dist/types/_vendors/pdf-lib/utils/objects.d.ts +15 -0
- package/dist/types/_vendors/pdf-lib/utils/pdfDocEncoding.d.ts +7 -0
- package/dist/types/_vendors/pdf-lib/utils/png.d.ts +17 -0
- package/dist/types/_vendors/pdf-lib/utils/rng.d.ts +13 -0
- package/dist/types/_vendors/pdf-lib/utils/strings.d.ts +25 -0
- package/dist/types/_vendors/pdf-lib/utils/unicode.d.ts +186 -0
- package/dist/types/_vendors/pdf-lib/utils/validators.d.ts +26 -0
- package/dist/types/_vendors/print-designer-editor/Canvas.d.ts +12 -0
- package/dist/types/_vendors/print-designer-editor/PdfmeProvider.d.ts +4 -0
- package/dist/types/_vendors/print-designer-editor/PropPanel.d.ts +10 -0
- package/dist/types/_vendors/print-designer-editor/SchemaList.d.ts +10 -0
- package/dist/types/_vendors/print-designer-editor/index.d.ts +14 -0
- package/dist/types/_vendors/print-designer-editor/plugins.d.ts +1 -0
- package/dist/types/_vendors/print-designer-editor/types.d.ts +64 -0
- package/dist/types/_vendors/print-designer-editor/useDesigner.d.ts +84 -0
- package/dist/types/_vendors/print-designer-editor/useDesignerContext.d.ts +1 -0
- package/dist/types/_vendors/print-designer-editor/utils.d.ts +9 -0
- package/dist/types/_vendors/schemas/barcodes/constants.d.ts +4 -0
- package/dist/types/_vendors/schemas/barcodes/helper.d.ts +21 -0
- package/dist/types/_vendors/schemas/barcodes/index.d.ts +4 -0
- package/dist/types/_vendors/schemas/barcodes/pdfRender.d.ts +3 -0
- package/dist/types/_vendors/schemas/barcodes/propPanel.d.ts +3 -0
- package/dist/types/_vendors/schemas/barcodes/types.d.ts +10 -0
- package/dist/types/_vendors/schemas/barcodes/uiRender.d.ts +3 -0
- package/dist/types/_vendors/schemas/checkbox/index.d.ts +6 -0
- package/dist/types/_vendors/schemas/constants.d.ts +2 -0
- package/dist/types/_vendors/schemas/date/date.d.ts +2 -0
- package/dist/types/_vendors/schemas/date/dateTime.d.ts +2 -0
- package/dist/types/_vendors/schemas/date/helper.d.ts +8 -0
- package/dist/types/_vendors/schemas/date/time.d.ts +2 -0
- package/dist/types/_vendors/schemas/date/types.d.ts +17 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/core/cell.d.ts +17 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/core/index.d.ts +2 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/core/settings-validator.d.ts +10 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/core/table.d.ts +130 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/engines/layout.engine.d.ts +66 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/engines/overflow.engine.d.ts +36 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/index.d.ts +16 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/core/cell.interface.d.ts +13 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/core/index.d.ts +1 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/engines/index.d.ts +1 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/engines/layout-engine.interface.d.ts +36 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/index.d.ts +5 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/rules/index.d.ts +3 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/rules/rule-engine.interface.d.ts +21 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/rules/rule-registry.interface.d.ts +19 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/stores/cell-registry.interface.d.ts +12 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/stores/index.d.ts +3 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/stores/merge-registry.interface.d.ts +42 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/stores/structure-store.interface.d.ts +31 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/table/index.d.ts +1 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/interfaces/table/table.inteface.d.ts +63 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/renderers/types/renderable-types.d.ts +79 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/renderers/types/serialization.types.d.ts +46 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/ast.types.d.ts +117 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/compiler.d.ts +54 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/evaluator.d.ts +36 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/extract-deps.d.ts +8 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/functions/registry.d.ts +47 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/index.d.ts +20 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/lexer.d.ts +36 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/parser.d.ts +45 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/range-resolver.d.ts +25 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/scope-vocabulary.d.ts +25 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/text-measurer.d.ts +88 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/expression/var-catalog.d.ts +34 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/index.d.ts +13 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/rule-engine.d.ts +36 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/rule-matcher.d.ts +28 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/rule-registry.d.ts +32 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/types/evaluation.types.d.ts +178 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/types/index.d.ts +5 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/rules/types/rule.types.d.ts +78 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/stores/cell-registry.store.d.ts +20 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/stores/merge-registry.stores.d.ts +51 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/stores/structure.store.d.ts +39 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/styles/defaults.d.ts +7 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/styles/index.d.ts +2 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/styles/resolve.d.ts +12 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/types/common.d.ts +138 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/types/index.d.ts +1 -0
- package/dist/types/_vendors/schemas/dynamicTable/engine/types/rule-target.types.d.ts +89 -0
- package/dist/types/_vendors/schemas/dynamicTable/helpers/cellSchemaMapper.d.ts +21 -0
- package/dist/types/_vendors/schemas/dynamicTable/helpers/cellStyleControls.d.ts +6 -0
- package/dist/types/_vendors/schemas/dynamicTable/helpers/domUtils.d.ts +24 -0
- package/dist/types/_vendors/schemas/dynamicTable/helpers/propPanelWidgets.d.ts +13 -0
- package/dist/types/_vendors/schemas/dynamicTable/helpers/regionStyleControls.d.ts +5 -0
- package/dist/types/_vendors/schemas/dynamicTable/helpers/toast.d.ts +5 -0
- package/dist/types/_vendors/schemas/dynamicTable/helpers/widgets/settingsWidgets.d.ts +16 -0
- package/dist/types/_vendors/schemas/dynamicTable/helpers/widgets/structureWidget.d.ts +13 -0
- package/dist/types/_vendors/schemas/dynamicTable/helpers/widgets/styleWidgets.d.ts +20 -0
- package/dist/types/_vendors/schemas/dynamicTable/index.d.ts +4 -0
- package/dist/types/_vendors/schemas/dynamicTable/instanceManager.d.ts +18 -0
- package/dist/types/_vendors/schemas/dynamicTable/pdfRender.d.ts +8 -0
- package/dist/types/_vendors/schemas/dynamicTable/propPanel.d.ts +15 -0
- package/dist/types/_vendors/schemas/dynamicTable/types.d.ts +39 -0
- package/dist/types/_vendors/schemas/dynamicTable/uiComponents/addRemoveButtons.d.ts +6 -0
- package/dist/types/_vendors/schemas/dynamicTable/uiComponents/cellResizeInteractions.d.ts +17 -0
- package/dist/types/_vendors/schemas/dynamicTable/uiComponents/cellSelection.d.ts +16 -0
- package/dist/types/_vendors/schemas/dynamicTable/uiComponents/createButton.d.ts +14 -0
- package/dist/types/_vendors/schemas/dynamicTable/uiComponents/index.d.ts +4 -0
- package/dist/types/_vendors/schemas/dynamicTable/uiRender.d.ts +26 -0
- package/dist/types/_vendors/schemas/graphics/image.d.ts +5 -0
- package/dist/types/_vendors/schemas/graphics/imagehelper.d.ts +4 -0
- package/dist/types/_vendors/schemas/graphics/signature.d.ts +5 -0
- package/dist/types/_vendors/schemas/graphics/svg.d.ts +4 -0
- package/dist/types/_vendors/schemas/index.d.ts +22 -0
- package/dist/types/_vendors/schemas/insertVariableWidget.d.ts +9 -0
- package/dist/types/_vendors/schemas/multiVariableText/helper.d.ts +3 -0
- package/dist/types/_vendors/schemas/multiVariableText/index.d.ts +4 -0
- package/dist/types/_vendors/schemas/multiVariableText/pdfRender.d.ts +3 -0
- package/dist/types/_vendors/schemas/multiVariableText/propPanel.d.ts +3 -0
- package/dist/types/_vendors/schemas/multiVariableText/types.d.ts +5 -0
- package/dist/types/_vendors/schemas/multiVariableText/uiRender.d.ts +3 -0
- package/dist/types/_vendors/schemas/radioGroup/index.d.ts +7 -0
- package/dist/types/_vendors/schemas/select/index.d.ts +7 -0
- package/dist/types/_vendors/schemas/shapes/line.d.ts +6 -0
- package/dist/types/_vendors/schemas/shapes/rectAndEllipse.d.ts +175 -0
- package/dist/types/_vendors/schemas/tables/cell.d.ts +4 -0
- package/dist/types/_vendors/schemas/tables/classes.d.ts +69 -0
- package/dist/types/_vendors/schemas/tables/dynamicTemplate.d.ts +7 -0
- package/dist/types/_vendors/schemas/tables/helper.d.ts +265 -0
- package/dist/types/_vendors/schemas/tables/index.d.ts +4 -0
- package/dist/types/_vendors/schemas/tables/pdfRender.d.ts +3 -0
- package/dist/types/_vendors/schemas/tables/propPanel.d.ts +3 -0
- package/dist/types/_vendors/schemas/tables/tableHelper.d.ts +10 -0
- package/dist/types/_vendors/schemas/tables/types.d.ts +88 -0
- package/dist/types/_vendors/schemas/tables/uiRender.d.ts +3 -0
- package/dist/types/_vendors/schemas/text/constants.d.ts +23 -0
- package/dist/types/_vendors/schemas/text/extraFormatter.d.ts +25 -0
- package/dist/types/_vendors/schemas/text/helper.d.ts +39 -0
- package/dist/types/_vendors/schemas/text/icons/index.d.ts +9 -0
- package/dist/types/_vendors/schemas/text/index.d.ts +4 -0
- package/dist/types/_vendors/schemas/text/pdfRender.d.ts +3 -0
- package/dist/types/_vendors/schemas/text/propPanel.d.ts +3 -0
- package/dist/types/_vendors/schemas/text/types.d.ts +28 -0
- package/dist/types/_vendors/schemas/text/uiRender.d.ts +11 -0
- package/dist/types/_vendors/schemas/utils.d.ts +40 -0
- package/dist/types/_vendors/schemas/variableBarcode/helper.d.ts +10 -0
- package/dist/types/_vendors/schemas/variableBarcode/index.d.ts +6 -0
- package/dist/types/_vendors/schemas/variableBarcode/pdfRender.d.ts +3 -0
- package/dist/types/_vendors/schemas/variableBarcode/propPanel.d.ts +4 -0
- package/dist/types/_vendors/schemas/variableBarcode/types.d.ts +7 -0
- package/dist/types/_vendors/schemas/variableBarcode/uiRender.d.ts +3 -0
- package/dist/types/_vendors/ui/Designer.d.ts +23 -0
- package/dist/types/_vendors/ui/Form.d.ts +26 -0
- package/dist/types/_vendors/ui/Viewer.d.ts +17 -0
- package/dist/types/_vendors/ui/class.d.ts +89 -0
- package/dist/types/_vendors/ui/components/AppContextProvider.d.ts +11 -0
- package/dist/types/_vendors/ui/components/CtlBar.d.ts +18 -0
- package/dist/types/_vendors/ui/components/Designer/Canvas/Guides.d.ts +9 -0
- package/dist/types/_vendors/ui/components/Designer/Canvas/Mask.d.ts +4 -0
- package/dist/types/_vendors/ui/components/Designer/Canvas/Moveable.d.ts +37 -0
- package/dist/types/_vendors/ui/components/Designer/Canvas/Padding.d.ts +6 -0
- package/dist/types/_vendors/ui/components/Designer/Canvas/Selecto.d.ts +10 -0
- package/dist/types/_vendors/ui/components/Designer/Canvas/index.d.ts +22 -0
- package/dist/types/_vendors/ui/components/Designer/LeftSidebar.d.ts +8 -0
- package/dist/types/_vendors/ui/components/Designer/PluginIcon.d.ts +10 -0
- package/dist/types/_vendors/ui/components/Designer/RightSidebar/DetailView/AlignWidget.d.ts +4 -0
- package/dist/types/_vendors/ui/components/Designer/RightSidebar/DetailView/ButtonGroupWidget.d.ts +4 -0
- package/dist/types/_vendors/ui/components/Designer/RightSidebar/DetailView/WidgetRenderer.d.ts +7 -0
- package/dist/types/_vendors/ui/components/Designer/RightSidebar/DetailView/index.d.ts +9 -0
- package/dist/types/_vendors/ui/components/Designer/RightSidebar/ListView/Item.d.ts +45 -0
- package/dist/types/_vendors/ui/components/Designer/RightSidebar/ListView/SelectableSortableContainer.d.ts +4 -0
- package/dist/types/_vendors/ui/components/Designer/RightSidebar/ListView/SelectableSortableItem.d.ts +14 -0
- package/dist/types/_vendors/ui/components/Designer/RightSidebar/ListView/index.d.ts +4 -0
- package/dist/types/_vendors/ui/components/Designer/RightSidebar/index.d.ts +4 -0
- package/dist/types/_vendors/ui/components/Designer/RightSidebar/layout.d.ts +15 -0
- package/dist/types/_vendors/ui/components/Designer/index.d.ts +11 -0
- package/dist/types/_vendors/ui/components/ErrorScreen.d.ts +7 -0
- package/dist/types/_vendors/ui/components/Paper.d.ts +20 -0
- package/dist/types/_vendors/ui/components/Preview.d.ts +15 -0
- package/dist/types/_vendors/ui/components/Renderer.d.ts +13 -0
- package/dist/types/_vendors/ui/components/Root.d.ts +9 -0
- package/dist/types/_vendors/ui/components/Spinner.d.ts +3 -0
- package/dist/types/_vendors/ui/components/StaticSchema.d.ts +10 -0
- package/dist/types/_vendors/ui/components/UnitPager.d.ts +10 -0
- package/dist/types/_vendors/ui/constants.d.ts +11 -0
- package/dist/types/_vendors/ui/contexts.d.ts +10 -0
- package/dist/types/_vendors/ui/helper.d.ts +73 -0
- package/dist/types/_vendors/ui/hooks.d.ts +46 -0
- package/dist/types/_vendors/ui/i18n.d.ts +3 -0
- package/dist/types/_vendors/ui/index.d.ts +4 -0
- package/dist/types/_vendors/ui/theme.d.ts +2 -0
- package/dist/types/_vendors/ui/types.d.ts +19 -0
- package/dist/types/common.d.ts +1 -2
- package/dist/types/converter.d.ts +1 -2
- package/dist/types/generator.d.ts +1 -2
- package/dist/types/index.d.ts +7 -9
- package/dist/types/manipulator.d.ts +1 -2
- package/dist/types/print-designer-editor.d.ts +1 -2
- package/dist/types/schemas.d.ts +1 -2
- package/dist/types/ui.d.ts +1 -2
- package/package.json +12 -11
- package/dist/types/common.d.ts.map +0 -1
- package/dist/types/converter.d.ts.map +0 -1
- package/dist/types/generator.d.ts.map +0 -1
- package/dist/types/index.d.ts.map +0 -1
- package/dist/types/manipulator.d.ts.map +0 -1
- package/dist/types/print-designer-editor.d.ts.map +0 -1
- package/dist/types/schemas.d.ts.map +0 -1
- package/dist/types/ui.d.ts.map +0 -1
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import Circle from './Circle';
|
|
2
|
+
import GraphElement from './GraphElement';
|
|
3
|
+
import Point from './Point';
|
|
4
|
+
export default class Arc extends GraphElement {
|
|
5
|
+
O: Point;
|
|
6
|
+
A: Point;
|
|
7
|
+
B: Point;
|
|
8
|
+
/** Last sweep. Used to deduce the angle orientation */
|
|
9
|
+
lastSweep: number;
|
|
10
|
+
constructor(O?: Point, A?: Point, B?: Point, lastSweep?: number);
|
|
11
|
+
center(): Point;
|
|
12
|
+
origin(): Point;
|
|
13
|
+
destination(): Point;
|
|
14
|
+
sweep(): number;
|
|
15
|
+
ray(): number;
|
|
16
|
+
isEqual(element: GraphElement): boolean;
|
|
17
|
+
getCircle(): Circle;
|
|
18
|
+
originVect(): import("../..").Coordinates;
|
|
19
|
+
middle(): Point;
|
|
20
|
+
includes(P: Point): boolean;
|
|
21
|
+
orthoProjection(P: Point): Point;
|
|
22
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import GraphElement from './GraphElement';
|
|
2
|
+
import Point from './Point';
|
|
3
|
+
export default class Circle extends GraphElement {
|
|
4
|
+
O: Point;
|
|
5
|
+
r: number;
|
|
6
|
+
constructor(O?: Point, r?: number);
|
|
7
|
+
ray(): number;
|
|
8
|
+
center(): Point;
|
|
9
|
+
/** This is used to standardize type Circle | Arc */
|
|
10
|
+
getCircle(): this;
|
|
11
|
+
isEqual(element: GraphElement): boolean;
|
|
12
|
+
includes(P: Point): boolean;
|
|
13
|
+
orthoProjection(P: Point): Point;
|
|
14
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Size } from '../../types';
|
|
2
|
+
import GraphElement from './GraphElement';
|
|
3
|
+
import Point from './Point';
|
|
4
|
+
import Segment from './Segment';
|
|
5
|
+
export default class Ellipse extends GraphElement {
|
|
6
|
+
A: Point;
|
|
7
|
+
B: Point;
|
|
8
|
+
C: Point;
|
|
9
|
+
constructor(A?: Point, B?: Point, C?: Point);
|
|
10
|
+
center(): Point;
|
|
11
|
+
axis(): Segment;
|
|
12
|
+
a(): number;
|
|
13
|
+
b(): number;
|
|
14
|
+
rotation(): number;
|
|
15
|
+
getSize(): Size;
|
|
16
|
+
isEqual(element: GraphElement): boolean;
|
|
17
|
+
includes(P: Point): boolean;
|
|
18
|
+
orthoProjection(P: Point): Point;
|
|
19
|
+
polarRay(teta: number): number;
|
|
20
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Coordinates } from '../../types';
|
|
2
|
+
import GraphElement from './GraphElement';
|
|
3
|
+
import Point from './Point';
|
|
4
|
+
export default class Line extends GraphElement {
|
|
5
|
+
origin(): Point;
|
|
6
|
+
dirVect(): Coordinates;
|
|
7
|
+
A: Point;
|
|
8
|
+
B: Point;
|
|
9
|
+
constructor(A?: Point, B?: Point);
|
|
10
|
+
/** Line equation */
|
|
11
|
+
y(x: number): number;
|
|
12
|
+
/** The slope */
|
|
13
|
+
a(): number;
|
|
14
|
+
/** Origin y coordinate */
|
|
15
|
+
b(): number;
|
|
16
|
+
isEqual(element: GraphElement): boolean;
|
|
17
|
+
/** Reversed line equation */
|
|
18
|
+
x(y: number): number;
|
|
19
|
+
includes(P: Point): boolean;
|
|
20
|
+
/** This is used to standarsize type Segment | HalfLine | Line */
|
|
21
|
+
getLine(): Line;
|
|
22
|
+
orthoProjection(P: Point): Point;
|
|
23
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Coordinates } from '../../types';
|
|
2
|
+
import GraphElement from './GraphElement';
|
|
3
|
+
import Point from './Point';
|
|
4
|
+
export default class Plot extends GraphElement {
|
|
5
|
+
points: Coordinates[];
|
|
6
|
+
constructor(points?: Coordinates[]);
|
|
7
|
+
getPoints(): Coordinates[];
|
|
8
|
+
translate(translationVector: Coordinates): void;
|
|
9
|
+
isEqual(element: GraphElement): boolean;
|
|
10
|
+
orthoProjection(P: Point): Point;
|
|
11
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { Coordinates } from '../../types';
|
|
2
|
+
import GraphElement from './GraphElement';
|
|
3
|
+
export default class Point extends GraphElement {
|
|
4
|
+
static type: string;
|
|
5
|
+
x: number;
|
|
6
|
+
y: number;
|
|
7
|
+
constructor(coords?: {
|
|
8
|
+
x: number;
|
|
9
|
+
y: number;
|
|
10
|
+
});
|
|
11
|
+
toCoords(): {
|
|
12
|
+
x: number;
|
|
13
|
+
y: number;
|
|
14
|
+
};
|
|
15
|
+
isEqual(element: GraphElement): boolean;
|
|
16
|
+
orthoProjection(): Point;
|
|
17
|
+
plus(vect: Coordinates): Point;
|
|
18
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import GraphElement from './GraphElement';
|
|
2
|
+
import Point from './Point';
|
|
3
|
+
export default class Rectangle extends GraphElement {
|
|
4
|
+
static type: string;
|
|
5
|
+
start: Point;
|
|
6
|
+
end: Point;
|
|
7
|
+
constructor(start?: Point, end?: Point);
|
|
8
|
+
getSize(): {
|
|
9
|
+
width: number;
|
|
10
|
+
height: number;
|
|
11
|
+
};
|
|
12
|
+
getCoords(): {
|
|
13
|
+
x: number;
|
|
14
|
+
y: number;
|
|
15
|
+
};
|
|
16
|
+
getStart(): Point;
|
|
17
|
+
getEnd(): Point;
|
|
18
|
+
center(): Point;
|
|
19
|
+
isEqual(element: GraphElement): boolean;
|
|
20
|
+
orthoProjection(P: Point): Point;
|
|
21
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import GraphElement from './GraphElement';
|
|
2
|
+
import Line from './Line';
|
|
3
|
+
import Point from './Point';
|
|
4
|
+
export default class Segment extends GraphElement {
|
|
5
|
+
static type: string;
|
|
6
|
+
A: Point;
|
|
7
|
+
B: Point;
|
|
8
|
+
constructor(A?: Point, B?: Point);
|
|
9
|
+
origin(): Point;
|
|
10
|
+
destination(): Point;
|
|
11
|
+
dirVect(): import("../..").Coordinates;
|
|
12
|
+
length(): number;
|
|
13
|
+
isEqual(element: GraphElement): boolean;
|
|
14
|
+
/** Returns an equivalent line object */
|
|
15
|
+
getLine(): Line;
|
|
16
|
+
includes(P: Point): boolean;
|
|
17
|
+
middle(): Point;
|
|
18
|
+
orthoProjection(P: Point): Point;
|
|
19
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export { default as Arc } from './Arc';
|
|
2
|
+
export { default as Circle } from './Circle';
|
|
3
|
+
export { default as GraphElement } from './GraphElement';
|
|
4
|
+
export { default as Ellipse } from './Ellipse';
|
|
5
|
+
export { default as Line } from './Line';
|
|
6
|
+
export { default as SegmePlotnt } from './Plot';
|
|
7
|
+
export { default as Point } from './Point';
|
|
8
|
+
export { default as Rectangle } from './Rectangle';
|
|
9
|
+
export { default as Segment } from './Segment';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const error: (msg: string) => never;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * from './arrays';
|
|
2
|
+
export * from './async';
|
|
3
|
+
export * from './strings';
|
|
4
|
+
export * from './unicode';
|
|
5
|
+
export * from './numbers';
|
|
6
|
+
export * from './errors';
|
|
7
|
+
export * from './base64';
|
|
8
|
+
export * from './objects';
|
|
9
|
+
export * from './validators';
|
|
10
|
+
export * from './pdfDocEncoding';
|
|
11
|
+
export { default as Cache } from './Cache';
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import Circle from './elements/Circle';
|
|
2
|
+
import Line from './elements/Line';
|
|
3
|
+
import { Coordinates, GraphicElement } from '../types';
|
|
4
|
+
export declare function intersections(A: GraphicElement, B: GraphicElement): Coordinates[];
|
|
5
|
+
export declare function intersection(A: GraphicElement, B: GraphicElement): Coordinates | undefined;
|
|
6
|
+
export declare function intersectionLine(A: Line, B: Line): Coordinates[];
|
|
7
|
+
export declare function intersectionCircleLine(A: Circle, B: Line): Coordinates[];
|
|
8
|
+
export declare function intersectionCircle(A: Circle, B: Circle): Coordinates[];
|
|
9
|
+
export declare function getIntersections(elements: GraphicElement[]): Coordinates[];
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import Point from './elements/Point';
|
|
2
|
+
import { Coordinates } from '../types';
|
|
3
|
+
/** This value represents the precision we accept for float values */
|
|
4
|
+
export declare const FLOAT_APPROXIMATION = 0.000001;
|
|
5
|
+
/** Calculates the distance between 2 points */
|
|
6
|
+
export declare const distance: (A: Point, B: Point) => number;
|
|
7
|
+
export declare const distanceCoords: (A: Coordinates, B: Coordinates) => number;
|
|
8
|
+
/** Calculates the distance denoted by a vector */
|
|
9
|
+
export declare const norm: (vect: Coordinates) => number;
|
|
10
|
+
/** Calculates the orthogonal vector of provided vector */
|
|
11
|
+
export declare const orthogonal: ({ x, y }: Coordinates) => Coordinates;
|
|
12
|
+
/** Check if 2 vectors are proportional */
|
|
13
|
+
export declare const isColinear: ({ x: ux, y: uy }: Coordinates, { x: vx, y: vy }: Coordinates) => boolean;
|
|
14
|
+
/** Check if 2 floating values can be considered equals */
|
|
15
|
+
export declare const isEqual: (a: number, b: number) => boolean;
|
|
16
|
+
/** Return true if a is proportional to b: (a = kb), considering float imprecision */
|
|
17
|
+
export declare const isProportional: (a: number, b: number) => boolean;
|
|
18
|
+
/** Calculate the scalar product between 2 vectors */
|
|
19
|
+
export declare const scalar: ({ x: ux, y: uy }: Coordinates, { x: vx, y: vy }: Coordinates) => number;
|
|
20
|
+
/** Calculate the sum of 2 vectors */
|
|
21
|
+
export declare const plus: ({ x: ux, y: uy }: Coordinates, { x: vx, y: vy }: Coordinates) => Coordinates;
|
|
22
|
+
/** Calculate the vector multiplied by a scalar */
|
|
23
|
+
export declare const times: ({ x, y }: Coordinates, k?: number) => Coordinates;
|
|
24
|
+
/** Calculate the difference of 2 vectors */
|
|
25
|
+
export declare const minus: (u: Coordinates, v: Coordinates) => Coordinates;
|
|
26
|
+
/** Returns the vector between 2 points. */
|
|
27
|
+
export declare const vector: (A: Point, B: Point) => Coordinates;
|
|
28
|
+
/**
|
|
29
|
+
* Returns the angle between the vector and the horizontal axis (Ox).
|
|
30
|
+
* The return value is between -PI and PI.
|
|
31
|
+
* @returns {number} angle in radian between -Pi and Pi
|
|
32
|
+
*/
|
|
33
|
+
export declare const orientation: ({ x, y }: Coordinates) => number;
|
|
34
|
+
/** Returns the unit vector associated to the provided vector,
|
|
35
|
+
* or the Null vector (0, 0) if the vector is null
|
|
36
|
+
*/
|
|
37
|
+
export declare const unitVector: (u: Coordinates) => Coordinates;
|
|
38
|
+
/** Returns the angle from u to v in radian */
|
|
39
|
+
export declare const angle: (u: Coordinates, v: Coordinates, previousAngle?: number) => number;
|
|
40
|
+
/** Returns the angle between the lines (BA) and (BC) in radian
|
|
41
|
+
* @returns {number} the angle in radian, between -Pi and Pi
|
|
42
|
+
*/
|
|
43
|
+
export declare const angleABC: (A: Point, B: Point, C: Point, previousAngle?: number) => number;
|
|
44
|
+
/** Rotate the vector by an angle in radian */
|
|
45
|
+
export declare const rotate: (vect: Coordinates, teta: number) => Coordinates;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Converts a number to its string representation in decimal. This function
|
|
3
|
+
* differs from simply converting a number to a string with `.toString()`
|
|
4
|
+
* because this function's output string will **not** contain exponential
|
|
5
|
+
* notation.
|
|
6
|
+
*
|
|
7
|
+
* Credit: https://stackoverflow.com/a/46545519
|
|
8
|
+
*/
|
|
9
|
+
export declare const numberToString: (num: number) => string;
|
|
10
|
+
export declare const sizeInBytes: (n: number) => number;
|
|
11
|
+
/**
|
|
12
|
+
* Converts a number into its constituent bytes and returns them as
|
|
13
|
+
* a number[].
|
|
14
|
+
*
|
|
15
|
+
* Returns most significant byte as first element in array. It may be necessary
|
|
16
|
+
* to call .reverse() to get the bits in the desired order.
|
|
17
|
+
*
|
|
18
|
+
* Example:
|
|
19
|
+
* bytesFor(0x02A41E) => [ 0b10, 0b10100100, 0b11110 ]
|
|
20
|
+
*
|
|
21
|
+
* Credit for algorithm: https://stackoverflow.com/a/1936865
|
|
22
|
+
*/
|
|
23
|
+
export declare const bytesFor: (n: number) => Uint8Array<ArrayBuffer>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { FontNames } from '@pdf-lib/standard-fonts';
|
|
2
|
+
export declare const values: (obj: any) => any[];
|
|
3
|
+
export declare const StandardFontValues: any[];
|
|
4
|
+
export declare const isStandardFont: (input: any) => input is FontNames;
|
|
5
|
+
export declare const rectanglesAreEqual: (a: {
|
|
6
|
+
x: number;
|
|
7
|
+
y: number;
|
|
8
|
+
width: number;
|
|
9
|
+
height: number;
|
|
10
|
+
}, b: {
|
|
11
|
+
x: number;
|
|
12
|
+
y: number;
|
|
13
|
+
width: number;
|
|
14
|
+
height: number;
|
|
15
|
+
}) => boolean;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export declare enum PngType {
|
|
2
|
+
Greyscale = "Greyscale",
|
|
3
|
+
Truecolour = "Truecolour",
|
|
4
|
+
IndexedColour = "IndexedColour",
|
|
5
|
+
GreyscaleWithAlpha = "GreyscaleWithAlpha",
|
|
6
|
+
TruecolourWithAlpha = "TruecolourWithAlpha"
|
|
7
|
+
}
|
|
8
|
+
export declare class PNG {
|
|
9
|
+
static load: (pngData: Uint8Array) => PNG;
|
|
10
|
+
readonly rgbChannel: Uint8Array;
|
|
11
|
+
readonly alphaChannel?: Uint8Array;
|
|
12
|
+
readonly type: PngType;
|
|
13
|
+
readonly width: number;
|
|
14
|
+
readonly height: number;
|
|
15
|
+
readonly bitsPerComponent: number;
|
|
16
|
+
private constructor();
|
|
17
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generates a pseudo random number. Although it is not cryptographically secure
|
|
3
|
+
* and uniformly distributed, it is not a concern for the intended use-case,
|
|
4
|
+
* which is to generate distinct numbers.
|
|
5
|
+
*
|
|
6
|
+
* Credit: https://stackoverflow.com/a/19303725/10254049
|
|
7
|
+
*/
|
|
8
|
+
export declare class SimpleRNG {
|
|
9
|
+
static withSeed: (seed: number) => SimpleRNG;
|
|
10
|
+
private seed;
|
|
11
|
+
private constructor();
|
|
12
|
+
nextInt(): number;
|
|
13
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export declare const toCharCode: (character: string) => number;
|
|
2
|
+
export declare const toCodePoint: (character: string) => number | undefined;
|
|
3
|
+
export declare const toHexStringOfMinLength: (num: number, minLength: number) => string;
|
|
4
|
+
export declare const toHexString: (num: number) => string;
|
|
5
|
+
export declare const charFromCode: (code: number) => string;
|
|
6
|
+
export declare const charFromHexCode: (hex: string) => string;
|
|
7
|
+
export declare const padStart: (value: string, length: number, padChar: string) => string;
|
|
8
|
+
export declare const stringAsByteArray: (str: string) => Uint8Array;
|
|
9
|
+
export declare const copyStringIntoBuffer: (str: string, buffer: Uint8Array, offset: number) => number;
|
|
10
|
+
export declare const addRandomSuffix: (prefix: string, suffixLength?: number) => string;
|
|
11
|
+
export declare const escapeRegExp: (str: string) => string;
|
|
12
|
+
export declare const cleanText: (text: string) => string;
|
|
13
|
+
export declare const escapedNewlineChars: string[];
|
|
14
|
+
export declare const newlineChars: string[];
|
|
15
|
+
export declare const isNewlineChar: (text: string) => boolean;
|
|
16
|
+
export declare const lineSplit: (text: string) => string[];
|
|
17
|
+
export declare const mergeLines: (text: string) => string;
|
|
18
|
+
export declare const charAtIndex: (text: string, index: number) => [string, number];
|
|
19
|
+
export declare const charSplit: (text: string) => string[];
|
|
20
|
+
export declare const breakTextIntoLines: (text: string, wordBreaks: string[], maxWidth: number, computeWidthOfText: (t: string) => number) => string[];
|
|
21
|
+
export declare const parseDate: (dateStr: string) => Date | undefined;
|
|
22
|
+
export declare const findLastMatch: (value: string, regex: RegExp) => {
|
|
23
|
+
match: RegExpMatchArray | undefined;
|
|
24
|
+
pos: number;
|
|
25
|
+
};
|
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Encodes a string to UTF-8.
|
|
3
|
+
*
|
|
4
|
+
* @param input The string to be encoded.
|
|
5
|
+
* @param byteOrderMark Whether or not a byte order marker (BOM) should be added
|
|
6
|
+
* to the start of the encoding. (default `true`)
|
|
7
|
+
* @returns A Uint8Array containing the UTF-8 encoding of the input string.
|
|
8
|
+
*
|
|
9
|
+
* -----------------------------------------------------------------------------
|
|
10
|
+
*
|
|
11
|
+
* JavaScript strings are composed of Unicode code points. Code points are
|
|
12
|
+
* integers in the range 0 to 1,114,111 (0x10FFFF). When serializing a string,
|
|
13
|
+
* it must be encoded as a sequence of words. A word is typically 8, 16, or 32
|
|
14
|
+
* bytes in size. As such, Unicode defines three encoding forms: UTF-8, UTF-16,
|
|
15
|
+
* and UTF-32. These encoding forms are described in the Unicode standard [1].
|
|
16
|
+
* This function implements the UTF-8 encoding form.
|
|
17
|
+
*
|
|
18
|
+
* -----------------------------------------------------------------------------
|
|
19
|
+
*
|
|
20
|
+
* In UTF-8, each code point is mapped to a sequence of 1, 2, 3, or 4 bytes.
|
|
21
|
+
* Note that the logic which defines this mapping is slightly convoluted, and
|
|
22
|
+
* not as straightforward as the mapping logic for UTF-16 or UTF-32. The UTF-8
|
|
23
|
+
* mapping logic is as follows [2]:
|
|
24
|
+
*
|
|
25
|
+
* • If a code point is in the range U+0000..U+007F, then view it as a 7-bit
|
|
26
|
+
* integer: 0bxxxxxxx. Map the code point to 1 byte with the first high order
|
|
27
|
+
* bit set to 0:
|
|
28
|
+
*
|
|
29
|
+
* b1=0b0xxxxxxx
|
|
30
|
+
*
|
|
31
|
+
* • If a code point is in the range U+0080..U+07FF, then view it as an 11-bit
|
|
32
|
+
* integer: 0byyyyyxxxxxx. Map the code point to 2 bytes with the first 5 bits
|
|
33
|
+
* of the code point stored in the first byte, and the last 6 bits stored in
|
|
34
|
+
* the second byte:
|
|
35
|
+
*
|
|
36
|
+
* b1=0b110yyyyy b2=0b10xxxxxx
|
|
37
|
+
*
|
|
38
|
+
* • If a code point is in the range U+0800..U+FFFF, then view it as a 16-bit
|
|
39
|
+
* integer, 0bzzzzyyyyyyxxxxxx. Map the code point to 3 bytes with the first
|
|
40
|
+
* 4 bits stored in the first byte, the next 6 bits stored in the second byte,
|
|
41
|
+
* and the last 6 bits in the third byte:
|
|
42
|
+
*
|
|
43
|
+
* b1=0b1110zzzz b2=0b10yyyyyy b3=0b10xxxxxx
|
|
44
|
+
*
|
|
45
|
+
* • If a code point is in the range U+10000...U+10FFFF, then view it as a
|
|
46
|
+
* 21-bit integer, 0bvvvzzzzzzyyyyyyxxxxxx. Map the code point to 4 bytes with
|
|
47
|
+
* the first 3 bits stored in the first byte, the next 6 bits stored in the
|
|
48
|
+
* second byte, the next 6 bits stored in the third byte, and the last 6 bits
|
|
49
|
+
* stored in the fourth byte:
|
|
50
|
+
*
|
|
51
|
+
* b1=0b11110xxx b2=0b10zzzzzz b3=0b10yyyyyy b4=0b10xxxxxx
|
|
52
|
+
*
|
|
53
|
+
* -----------------------------------------------------------------------------
|
|
54
|
+
*
|
|
55
|
+
* It is important to note, when iterating through the code points of a string
|
|
56
|
+
* in JavaScript, that if a character is encoded as a surrogate pair it will
|
|
57
|
+
* increase the string's length by 2 instead of 1 [4]. For example:
|
|
58
|
+
*
|
|
59
|
+
* ```
|
|
60
|
+
* > 'a'.length
|
|
61
|
+
* 1
|
|
62
|
+
* > '💩'.length
|
|
63
|
+
* 2
|
|
64
|
+
* > '語'.length
|
|
65
|
+
* 1
|
|
66
|
+
* > 'a💩語'.length
|
|
67
|
+
* 4
|
|
68
|
+
* ```
|
|
69
|
+
*
|
|
70
|
+
* The results of the above example are explained by the fact that the
|
|
71
|
+
* characters 'a' and '語' are not represented by surrogate pairs, but '💩' is.
|
|
72
|
+
*
|
|
73
|
+
* Because of this idiosyncrasy in JavaScript's string implementation and APIs,
|
|
74
|
+
* we must "jump" an extra index after encoding a character as a surrogate
|
|
75
|
+
* pair. In practice, this means we must increment the index of our for loop by
|
|
76
|
+
* 2 if we encode a surrogate pair, and 1 in all other cases.
|
|
77
|
+
*
|
|
78
|
+
* -----------------------------------------------------------------------------
|
|
79
|
+
*
|
|
80
|
+
* References:
|
|
81
|
+
* - [1] https://www.unicode.org/versions/Unicode12.0.0/UnicodeStandard-12.0.pdf
|
|
82
|
+
* 3.9 Unicode Encoding Forms - UTF-8
|
|
83
|
+
* - [2] http://www.herongyang.com/Unicode/UTF-8-UTF-8-Encoding.html
|
|
84
|
+
* - [3] http://www.herongyang.com/Unicode/UTF-8-UTF-8-Encoding-Algorithm.html
|
|
85
|
+
* - [4] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/length#Description
|
|
86
|
+
*
|
|
87
|
+
*/
|
|
88
|
+
export declare const utf8Encode: (input: string, byteOrderMark?: boolean) => Uint8Array;
|
|
89
|
+
/**
|
|
90
|
+
* Encodes a string to UTF-16.
|
|
91
|
+
*
|
|
92
|
+
* @param input The string to be encoded.
|
|
93
|
+
* @param byteOrderMark Whether or not a byte order marker (BOM) should be added
|
|
94
|
+
* to the start of the encoding. (default `true`)
|
|
95
|
+
* @returns A Uint16Array containing the UTF-16 encoding of the input string.
|
|
96
|
+
*
|
|
97
|
+
* -----------------------------------------------------------------------------
|
|
98
|
+
*
|
|
99
|
+
* JavaScript strings are composed of Unicode code points. Code points are
|
|
100
|
+
* integers in the range 0 to 1,114,111 (0x10FFFF). When serializing a string,
|
|
101
|
+
* it must be encoded as a sequence of words. A word is typically 8, 16, or 32
|
|
102
|
+
* bytes in size. As such, Unicode defines three encoding forms: UTF-8, UTF-16,
|
|
103
|
+
* and UTF-32. These encoding forms are described in the Unicode standard [1].
|
|
104
|
+
* This function implements the UTF-16 encoding form.
|
|
105
|
+
*
|
|
106
|
+
* -----------------------------------------------------------------------------
|
|
107
|
+
*
|
|
108
|
+
* In UTF-16, each code point is mapped to one or two 16-bit integers. The
|
|
109
|
+
* UTF-16 mapping logic is as follows [2]:
|
|
110
|
+
*
|
|
111
|
+
* • If a code point is in the range U+0000..U+FFFF, then map the code point to
|
|
112
|
+
* a 16-bit integer with the most significant byte first.
|
|
113
|
+
*
|
|
114
|
+
* • If a code point is in the range U+10000..U+10000, then map the code point
|
|
115
|
+
* to two 16-bit integers. The first integer should contain the high surrogate
|
|
116
|
+
* and the second integer should contain the low surrogate. Both surrogates
|
|
117
|
+
* should be written with the most significant byte first.
|
|
118
|
+
*
|
|
119
|
+
* -----------------------------------------------------------------------------
|
|
120
|
+
*
|
|
121
|
+
* It is important to note, when iterating through the code points of a string
|
|
122
|
+
* in JavaScript, that if a character is encoded as a surrogate pair it will
|
|
123
|
+
* increase the string's length by 2 instead of 1 [4]. For example:
|
|
124
|
+
*
|
|
125
|
+
* ```
|
|
126
|
+
* > 'a'.length
|
|
127
|
+
* 1
|
|
128
|
+
* > '💩'.length
|
|
129
|
+
* 2
|
|
130
|
+
* > '語'.length
|
|
131
|
+
* 1
|
|
132
|
+
* > 'a💩語'.length
|
|
133
|
+
* 4
|
|
134
|
+
* ```
|
|
135
|
+
*
|
|
136
|
+
* The results of the above example are explained by the fact that the
|
|
137
|
+
* characters 'a' and '語' are not represented by surrogate pairs, but '💩' is.
|
|
138
|
+
*
|
|
139
|
+
* Because of this idiosyncrasy in JavaScript's string implementation and APIs,
|
|
140
|
+
* we must "jump" an extra index after encoding a character as a surrogate
|
|
141
|
+
* pair. In practice, this means we must increment the index of our for loop by
|
|
142
|
+
* 2 if we encode a surrogate pair, and 1 in all other cases.
|
|
143
|
+
*
|
|
144
|
+
* -----------------------------------------------------------------------------
|
|
145
|
+
*
|
|
146
|
+
* References:
|
|
147
|
+
* - [1] https://www.unicode.org/versions/Unicode12.0.0/UnicodeStandard-12.0.pdf
|
|
148
|
+
* 3.9 Unicode Encoding Forms - UTF-8
|
|
149
|
+
* - [2] http://www.herongyang.com/Unicode/UTF-16-UTF-16-Encoding.html
|
|
150
|
+
* - [3] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/length#Description
|
|
151
|
+
*
|
|
152
|
+
*/
|
|
153
|
+
export declare const utf16Encode: (input: string, byteOrderMark?: boolean) => Uint16Array;
|
|
154
|
+
/**
|
|
155
|
+
* Returns `true` if the `codePoint` is within the
|
|
156
|
+
* Basic Multilingual Plane (BMP). Code points inside the BMP are not encoded
|
|
157
|
+
* with surrogate pairs.
|
|
158
|
+
* @param codePoint The code point to be evaluated.
|
|
159
|
+
*
|
|
160
|
+
* Reference: https://en.wikipedia.org/wiki/UTF-16#Description
|
|
161
|
+
*/
|
|
162
|
+
export declare const isWithinBMP: (codePoint: number) => boolean;
|
|
163
|
+
/**
|
|
164
|
+
* Returns `true` if the given `codePoint` is valid and must be represented
|
|
165
|
+
* with a surrogate pair when encoded.
|
|
166
|
+
* @param codePoint The code point to be evaluated.
|
|
167
|
+
*
|
|
168
|
+
* Reference: https://en.wikipedia.org/wiki/UTF-16#Description
|
|
169
|
+
*/
|
|
170
|
+
export declare const hasSurrogates: (codePoint: number) => boolean;
|
|
171
|
+
export declare const highSurrogate: (codePoint: number) => number;
|
|
172
|
+
export declare const lowSurrogate: (codePoint: number) => number;
|
|
173
|
+
/**
|
|
174
|
+
* Decodes a Uint8Array of data to a string using UTF-16.
|
|
175
|
+
*
|
|
176
|
+
* Note that this function attempts to recover from erronous input by
|
|
177
|
+
* inserting the replacement character (�) to mark invalid code points
|
|
178
|
+
* and surrogate pairs.
|
|
179
|
+
*
|
|
180
|
+
* @param input A Uint8Array containing UTF-16 encoded data
|
|
181
|
+
* @param byteOrderMark Whether or not a byte order marker (BOM) should be read
|
|
182
|
+
* at the start of the encoding. (default `true`)
|
|
183
|
+
* @returns The decoded string.
|
|
184
|
+
*/
|
|
185
|
+
export declare const utf16Decode: (input: Uint8Array, byteOrderMark?: boolean) => string;
|
|
186
|
+
export declare const hasUtf16BOM: (bytes: Uint8Array) => boolean;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
export declare const backtick: (val: any) => string;
|
|
2
|
+
export declare const singleQuote: (val: any) => string;
|
|
3
|
+
type Primitive = string | number | boolean | undefined | null;
|
|
4
|
+
export declare const createValueErrorMsg: (value: any, valueName: string, values: Primitive[]) => string;
|
|
5
|
+
export declare const assertIsOneOf: (value: any, valueName: string, allowedValues: Primitive[] | {
|
|
6
|
+
[key: string]: Primitive;
|
|
7
|
+
}) => void;
|
|
8
|
+
export declare const assertIsOneOfOrUndefined: (value: any, valueName: string, allowedValues: Primitive[] | {
|
|
9
|
+
[key: string]: Primitive;
|
|
10
|
+
}) => void;
|
|
11
|
+
export declare const assertIsSubset: (values: any[], valueName: string, allowedValues: Primitive[] | {
|
|
12
|
+
[key: string]: Primitive;
|
|
13
|
+
}) => void;
|
|
14
|
+
export declare const getType: (val: any) => any;
|
|
15
|
+
export type TypeDescriptor = 'null' | 'undefined' | 'string' | 'number' | 'boolean' | 'symbol' | 'bigint' | DateConstructor | ArrayConstructor | Uint8ArrayConstructor | ArrayBufferConstructor | FunctionConstructor | [Function, string];
|
|
16
|
+
export declare const isType: (value: any, type: TypeDescriptor) => boolean;
|
|
17
|
+
export declare const createTypeErrorMsg: (value: any, valueName: string, types: TypeDescriptor[]) => string;
|
|
18
|
+
export declare const assertIs: (value: any, valueName: string, types: TypeDescriptor[]) => void;
|
|
19
|
+
export declare const assertOrUndefined: (value: any, valueName: string, types: TypeDescriptor[]) => void;
|
|
20
|
+
export declare const assertEachIs: (values: any[], valueName: string, types: TypeDescriptor[]) => void;
|
|
21
|
+
export declare const assertRange: (value: any, valueName: string, min: number, max: number) => void;
|
|
22
|
+
export declare const assertRangeOrUndefined: (value: any, valueName: string, min: number, max: number) => void;
|
|
23
|
+
export declare const assertMultiple: (value: any, valueName: string, multiplier: number) => void;
|
|
24
|
+
export declare const assertInteger: (value: any, valueName: string) => void;
|
|
25
|
+
export declare const assertPositive: (value: number, valueName: string) => void;
|
|
26
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface CanvasProps {
|
|
3
|
+
style?: React.CSSProperties;
|
|
4
|
+
className?: string;
|
|
5
|
+
/** Hide the built-in left sidebar (plugin icons). Default: false */
|
|
6
|
+
hideLeftSidebar?: boolean;
|
|
7
|
+
/** Hide the built-in right sidebar (prop panel). Default: false */
|
|
8
|
+
hideRightSidebar?: boolean;
|
|
9
|
+
/** Hide the built-in control bar (zoom/pager). Default: false */
|
|
10
|
+
hideCtlBar?: boolean;
|
|
11
|
+
}
|
|
12
|
+
export declare const Canvas: ({ style, className, hideLeftSidebar, hideRightSidebar, hideCtlBar, }: CanvasProps) => React.JSX.Element;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { PdfmeProviderProps, DesignerContextValue } from './types.js';
|
|
3
|
+
export declare const DesignerContext: React.Context<DesignerContextValue | null>;
|
|
4
|
+
export declare const PdfmeProvider: ({ template, plugins, options, children, }: PdfmeProviderProps) => React.JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface PropPanelProps {
|
|
3
|
+
style?: React.CSSProperties;
|
|
4
|
+
className?: string;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Standalone PropPanel that renders the property editor for the currently selected schema.
|
|
8
|
+
* Use this when you set `hideRightSidebar` on Canvas and want to place the panel elsewhere.
|
|
9
|
+
*/
|
|
10
|
+
export declare const PropPanel: ({ style, className }: PropPanelProps) => React.JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface SchemaListProps {
|
|
3
|
+
style?: React.CSSProperties;
|
|
4
|
+
className?: string;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Standalone SchemaList (plugin icon bar) for drag-and-drop schema creation.
|
|
8
|
+
* Use this when you set `hideLeftSidebar` on Canvas and want to place the list elsewhere.
|
|
9
|
+
*/
|
|
10
|
+
export declare const SchemaList: ({ style, className }: SchemaListProps) => React.JSX.Element;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export { PdfmeProvider } from './PdfmeProvider.js';
|
|
2
|
+
export { Canvas } from './Canvas.js';
|
|
3
|
+
export type { CanvasProps } from './Canvas.js';
|
|
4
|
+
export { PropPanel } from './PropPanel.js';
|
|
5
|
+
export type { PropPanelProps } from './PropPanel.js';
|
|
6
|
+
export { SchemaList } from './SchemaList.js';
|
|
7
|
+
export type { SchemaListProps } from './SchemaList.js';
|
|
8
|
+
export { useDesigner } from './useDesigner.js';
|
|
9
|
+
export { useDesignerContext } from './useDesignerContext.js';
|
|
10
|
+
export { convertPdfToBase64 } from './utils.js';
|
|
11
|
+
export { generate } from '../generator/index.js';
|
|
12
|
+
export { getInputFromTemplate, getDefaultFont, getBuiltinFontsData, getAllFonts } from '../common/index.js';
|
|
13
|
+
export { plugins } from './plugins.js';
|
|
14
|
+
export type { Template, Schema, SchemaForUI, ChangeSchemas, Size, BasePdf, Font, Lang, UIOptions, Plugin, PluginRegistry, PdfmeProviderProps, DesignerContextValue, TemplateVariable, TemplateVariables, } from './types.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const plugins: Record<string, any>;
|