@solostylist/image-editor 1.0.0 → 1.0.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.
- package/lib/actions/add-filter.d.ts +10 -0
- package/lib/actions/add-filter.d.ts.map +1 -0
- package/lib/actions/change-pointer-icon.d.ts +6 -0
- package/lib/actions/change-pointer-icon.d.ts.map +1 -0
- package/lib/actions/change-rotation.d.ts +6 -0
- package/lib/actions/change-rotation.d.ts.map +1 -0
- package/lib/actions/clear-annotations-selections.d.ts +5 -0
- package/lib/actions/clear-annotations-selections.d.ts.map +1 -0
- package/lib/actions/duplicate-annotations.d.ts +9 -0
- package/lib/actions/duplicate-annotations.d.ts.map +1 -0
- package/lib/actions/enable-text-content-edit.d.ts +8 -0
- package/lib/actions/enable-text-content-edit.d.ts.map +1 -0
- package/lib/actions/hide-loader.d.ts +5 -0
- package/lib/actions/hide-loader.d.ts.map +1 -0
- package/lib/actions/index.d.ts +40 -0
- package/lib/actions/index.d.ts.map +1 -0
- package/lib/actions/redo.d.ts +5 -0
- package/lib/actions/redo.d.ts.map +1 -0
- package/lib/actions/remove-annotations.d.ts +9 -0
- package/lib/actions/remove-annotations.d.ts.map +1 -0
- package/lib/actions/reset.d.ts +8 -0
- package/lib/actions/reset.d.ts.map +1 -0
- package/lib/actions/select-annotation.d.ts +6 -0
- package/lib/actions/select-annotation.d.ts.map +1 -0
- package/lib/actions/select-tab.d.ts +6 -0
- package/lib/actions/select-tab.d.ts.map +1 -0
- package/lib/actions/select-tool.d.ts +9 -0
- package/lib/actions/select-tool.d.ts.map +1 -0
- package/lib/actions/set-annotation.d.ts +10 -0
- package/lib/actions/set-annotation.d.ts.map +1 -0
- package/lib/actions/set-canvas-size.d.ts +6 -0
- package/lib/actions/set-canvas-size.d.ts.map +1 -0
- package/lib/actions/set-crop.d.ts +9 -0
- package/lib/actions/set-crop.d.ts.map +1 -0
- package/lib/actions/set-feedback.d.ts +6 -0
- package/lib/actions/set-feedback.d.ts.map +1 -0
- package/lib/actions/set-finetune.d.ts +11 -0
- package/lib/actions/set-finetune.d.ts.map +1 -0
- package/lib/actions/set-latest-color.d.ts +6 -0
- package/lib/actions/set-latest-color.d.ts.map +1 -0
- package/lib/actions/set-original-image.d.ts +6 -0
- package/lib/actions/set-original-image.d.ts.map +1 -0
- package/lib/actions/set-resize.d.ts +9 -0
- package/lib/actions/set-resize.d.ts.map +1 -0
- package/lib/actions/set-saved.d.ts +5 -0
- package/lib/actions/set-saved.d.ts.map +1 -0
- package/lib/actions/set-saving.d.ts +6 -0
- package/lib/actions/set-saving.d.ts.map +1 -0
- package/lib/actions/set-show-tabs-menu.d.ts +8 -0
- package/lib/actions/set-show-tabs-menu.d.ts.map +1 -0
- package/lib/actions/set-shown-image-dimensions.d.ts +13 -0
- package/lib/actions/set-shown-image-dimensions.d.ts.map +1 -0
- package/lib/actions/show-loader.d.ts +5 -0
- package/lib/actions/show-loader.d.ts.map +1 -0
- package/lib/actions/toggle-flip.d.ts +9 -0
- package/lib/actions/toggle-flip.d.ts.map +1 -0
- package/lib/actions/toggle-flip.js +1 -1
- package/lib/actions/toggle-original-image-display.d.ts +8 -0
- package/lib/actions/toggle-original-image-display.d.ts.map +1 -0
- package/lib/actions/undo.d.ts +5 -0
- package/lib/actions/undo.d.ts.map +1 -0
- package/lib/actions/update-state.d.ts +7 -0
- package/lib/actions/update-state.d.ts.map +1 -0
- package/lib/actions/zoom-canvas.d.ts +10 -0
- package/lib/actions/zoom-canvas.d.ts.map +1 -0
- package/lib/components/app/index.d.ts +3 -0
- package/lib/components/app/index.d.ts.map +1 -0
- package/lib/components/app/index.js +1 -1
- package/lib/components/assembly-point/index.d.ts +9 -0
- package/lib/components/assembly-point/index.d.ts.map +1 -0
- package/lib/components/assembly-point/index.js +1 -1
- package/lib/components/common/annotation-options/annotation-options.constants.d.ts +9 -0
- package/lib/components/common/annotation-options/annotation-options.constants.d.ts.map +1 -0
- package/lib/components/common/annotation-options/index.d.ts +21 -0
- package/lib/components/common/annotation-options/index.d.ts.map +1 -0
- package/lib/components/common/annotation-options/index.js +1 -1
- package/lib/components/common/annotation-options/opacity-field.d.ts +10 -0
- package/lib/components/common/annotation-options/opacity-field.d.ts.map +1 -0
- package/lib/components/common/annotation-options/opacity-field.js +1 -1
- package/lib/components/common/annotation-options/position-fields.d.ts +8 -0
- package/lib/components/common/annotation-options/position-fields.d.ts.map +1 -0
- package/lib/components/common/annotation-options/shadow-fields.d.ts +9 -0
- package/lib/components/common/annotation-options/shadow-fields.d.ts.map +1 -0
- package/lib/components/common/annotation-options/shadow-fields.js +1 -1
- package/lib/components/common/annotation-options/stroke-fields.d.ts +9 -0
- package/lib/components/common/annotation-options/stroke-fields.d.ts.map +1 -0
- package/lib/components/common/button-with-menu/index.d.ts +16 -0
- package/lib/components/common/button-with-menu/index.d.ts.map +1 -0
- package/lib/components/common/color-input/index.d.ts +8 -0
- package/lib/components/common/color-input/index.d.ts.map +1 -0
- package/lib/components/common/color-input/index.js +1 -1
- package/lib/components/common/color-picker-modal/index.d.ts +10 -0
- package/lib/components/common/color-picker-modal/index.d.ts.map +1 -0
- package/lib/components/common/hidden-upload-input/index.d.ts +3 -0
- package/lib/components/common/hidden-upload-input/index.d.ts.map +1 -0
- package/lib/components/common/icon-wrapper/index.d.ts +16 -0
- package/lib/components/common/icon-wrapper/index.d.ts.map +1 -0
- package/lib/components/common/image-preview-tile/index.d.ts +14 -0
- package/lib/components/common/image-preview-tile/index.d.ts.map +1 -0
- package/lib/components/common/slider/index.d.ts +12 -0
- package/lib/components/common/slider/index.d.ts.map +1 -0
- package/lib/components/feedback-popup/index.d.ts +8 -0
- package/lib/components/feedback-popup/index.d.ts.map +1 -0
- package/lib/components/layers/design-layer/annotation-nodes/annotation-nodes.constants.d.ts +11 -0
- package/lib/components/layers/design-layer/annotation-nodes/annotation-nodes.constants.d.ts.map +1 -0
- package/lib/components/layers/design-layer/annotation-nodes/arrow-node.d.ts +15 -0
- package/lib/components/layers/design-layer/annotation-nodes/arrow-node.d.ts.map +1 -0
- package/lib/components/layers/design-layer/annotation-nodes/ellipse-node.d.ts +14 -0
- package/lib/components/layers/design-layer/annotation-nodes/ellipse-node.d.ts.map +1 -0
- package/lib/components/layers/design-layer/annotation-nodes/image-node.d.ts +14 -0
- package/lib/components/layers/design-layer/annotation-nodes/image-node.d.ts.map +1 -0
- package/lib/components/layers/design-layer/annotation-nodes/index.d.ts +3 -0
- package/lib/components/layers/design-layer/annotation-nodes/index.d.ts.map +1 -0
- package/lib/components/layers/design-layer/annotation-nodes/line-node.d.ts +12 -0
- package/lib/components/layers/design-layer/annotation-nodes/line-node.d.ts.map +1 -0
- package/lib/components/layers/design-layer/annotation-nodes/memoized-annotation.d.ts +11 -0
- package/lib/components/layers/design-layer/annotation-nodes/memoized-annotation.d.ts.map +1 -0
- package/lib/components/layers/design-layer/annotation-nodes/polygon-node.d.ts +15 -0
- package/lib/components/layers/design-layer/annotation-nodes/polygon-node.d.ts.map +1 -0
- package/lib/components/layers/design-layer/annotation-nodes/rect-node.d.ts +16 -0
- package/lib/components/layers/design-layer/annotation-nodes/rect-node.d.ts.map +1 -0
- package/lib/components/layers/design-layer/annotation-nodes/text-node.d.ts +21 -0
- package/lib/components/layers/design-layer/annotation-nodes/text-node.d.ts.map +1 -0
- package/lib/components/layers/design-layer/index.d.ts +3 -0
- package/lib/components/layers/design-layer/index.d.ts.map +1 -0
- package/lib/components/layers/design-layer/nodes-common-prop-types.d.ts +45 -0
- package/lib/components/layers/design-layer/nodes-common-prop-types.d.ts.map +1 -0
- package/lib/components/layers/design-layer/preview-group.d.ts +3 -0
- package/lib/components/layers/design-layer/preview-group.d.ts.map +1 -0
- package/lib/components/layers/index.d.ts +3 -0
- package/lib/components/layers/index.d.ts.map +1 -0
- package/lib/components/layers/transformers-layer/crop-transformer.d.ts +3 -0
- package/lib/components/layers/transformers-layer/crop-transformer.d.ts.map +1 -0
- package/lib/components/layers/transformers-layer/crop-transformer.js +1 -1
- package/lib/components/layers/transformers-layer/index.d.ts +3 -0
- package/lib/components/layers/transformers-layer/index.d.ts.map +1 -0
- package/lib/components/layers/transformers-layer/nodes-transformer.d.ts +3 -0
- package/lib/components/layers/transformers-layer/nodes-transformer.d.ts.map +1 -0
- package/lib/components/layers/transformers-layer/nodes-transformer.js +1 -1
- package/lib/components/layers/transformers-layer/transformers-layer.utils.d.ts +42 -0
- package/lib/components/layers/transformers-layer/transformers-layer.utils.d.ts.map +1 -0
- package/lib/components/main-canvas/canvas-node.d.ts +6 -0
- package/lib/components/main-canvas/canvas-node.d.ts.map +1 -0
- package/lib/components/main-canvas/canvas-node.js +1 -1
- package/lib/components/main-canvas/index.d.ts +3 -0
- package/lib/components/main-canvas/index.d.ts.map +1 -0
- package/lib/components/main-canvas/index.js +1 -1
- package/lib/components/main-canvas/touch-zooming-events.d.ts +11 -0
- package/lib/components/main-canvas/touch-zooming-events.d.ts.map +1 -0
- package/lib/components/node-controls/index.d.ts +3 -0
- package/lib/components/node-controls/index.d.ts.map +1 -0
- package/lib/components/node-controls/index.js +1 -1
- package/lib/components/tabs/index.d.ts +6 -0
- package/lib/components/tabs/index.d.ts.map +1 -0
- package/lib/components/tabs/index.js +1 -1
- package/lib/components/tabs/tabs.constants.d.ts +9 -0
- package/lib/components/tabs/tabs.constants.d.ts.map +1 -0
- package/lib/components/tabs/tabs.constants.js +1 -1
- package/lib/components/tabs-drawer/index.d.ts +6 -0
- package/lib/components/tabs-drawer/index.d.ts.map +1 -0
- package/lib/components/tabs-drawer/index.js +1 -1
- package/lib/components/tools/arrow/arrow-button.d.ts +8 -0
- package/lib/components/tools/arrow/arrow-button.d.ts.map +1 -0
- package/lib/components/tools/arrow/arrow-options.d.ts +4 -0
- package/lib/components/tools/arrow/arrow-options.d.ts.map +1 -0
- package/lib/components/tools/arrow/arrow-options.js +1 -1
- package/lib/components/tools/arrow/index.d.ts +3 -0
- package/lib/components/tools/arrow/index.d.ts.map +1 -0
- package/lib/components/tools/blur/blur-options.d.ts +6 -0
- package/lib/components/tools/blur/blur-options.d.ts.map +1 -0
- package/lib/components/tools/blur/blur-options.js +1 -1
- package/lib/components/tools/blur/blur.d.ts +8 -0
- package/lib/components/tools/blur/blur.d.ts.map +1 -0
- package/lib/components/tools/blur/blur.js +1 -1
- package/lib/components/tools/blur/index.d.ts +3 -0
- package/lib/components/tools/blur/index.d.ts.map +1 -0
- package/lib/components/tools/brightness/brightness-options.d.ts +6 -0
- package/lib/components/tools/brightness/brightness-options.d.ts.map +1 -0
- package/lib/components/tools/brightness/brightness.d.ts +8 -0
- package/lib/components/tools/brightness/brightness.d.ts.map +1 -0
- package/lib/components/tools/brightness/brightness.js +1 -1
- package/lib/components/tools/brightness/index.d.ts +3 -0
- package/lib/components/tools/brightness/index.d.ts.map +1 -0
- package/lib/components/tools/contrast/contrast-options.d.ts +6 -0
- package/lib/components/tools/contrast/contrast-options.d.ts.map +1 -0
- package/lib/components/tools/contrast/contrast.d.ts +8 -0
- package/lib/components/tools/contrast/contrast.d.ts.map +1 -0
- package/lib/components/tools/contrast/contrast.js +1 -1
- package/lib/components/tools/contrast/index.d.ts +3 -0
- package/lib/components/tools/contrast/index.d.ts.map +1 -0
- package/lib/components/tools/crop/crop.constants.d.ts +15 -0
- package/lib/components/tools/crop/crop.constants.d.ts.map +1 -0
- package/lib/components/tools/crop/crop.constants.js +1 -1
- package/lib/components/tools/crop/crop.d.ts +7 -0
- package/lib/components/tools/crop/crop.d.ts.map +1 -0
- package/lib/components/tools/crop/crop.js +1 -1
- package/lib/components/tools/crop/index.d.ts +2 -0
- package/lib/components/tools/crop/index.d.ts.map +1 -0
- package/lib/components/tools/ellipse/ellipse-button.d.ts +8 -0
- package/lib/components/tools/ellipse/ellipse-button.d.ts.map +1 -0
- package/lib/components/tools/ellipse/ellipse-options.d.ts +4 -0
- package/lib/components/tools/ellipse/ellipse-options.d.ts.map +1 -0
- package/lib/components/tools/ellipse/ellipse-options.js +1 -1
- package/lib/components/tools/ellipse/index.d.ts +3 -0
- package/lib/components/tools/ellipse/index.d.ts.map +1 -0
- package/lib/components/tools/filters/filter-item.d.ts +10 -0
- package/lib/components/tools/filters/filter-item.d.ts.map +1 -0
- package/lib/components/tools/filters/filters.constants.d.ts +8 -0
- package/lib/components/tools/filters/filters.constants.d.ts.map +1 -0
- package/lib/components/tools/filters/filters.d.ts +3 -0
- package/lib/components/tools/filters/filters.d.ts.map +1 -0
- package/lib/components/tools/filters/index.d.ts +2 -0
- package/lib/components/tools/filters/index.d.ts.map +1 -0
- package/lib/components/tools/flip/flip-x.d.ts +8 -0
- package/lib/components/tools/flip/flip-x.d.ts.map +1 -0
- package/lib/components/tools/flip/flip-x.js +1 -1
- package/lib/components/tools/flip/flip-y.d.ts +8 -0
- package/lib/components/tools/flip/flip-y.d.ts.map +1 -0
- package/lib/components/tools/flip/flip-y.js +1 -1
- package/lib/components/tools/flip/index.d.ts +3 -0
- package/lib/components/tools/flip/index.d.ts.map +1 -0
- package/lib/components/tools/hsv/hsv.d.ts +8 -0
- package/lib/components/tools/hsv/hsv.d.ts.map +1 -0
- package/lib/components/tools/hsv/hsvoptions.d.ts +6 -0
- package/lib/components/tools/hsv/hsvoptions.d.ts.map +1 -0
- package/lib/components/tools/hsv/index.d.ts +3 -0
- package/lib/components/tools/hsv/index.d.ts.map +1 -0
- package/lib/components/tools/image/image-button.d.ts +8 -0
- package/lib/components/tools/image/image-button.d.ts.map +1 -0
- package/lib/components/tools/image/image-controls.d.ts +13 -0
- package/lib/components/tools/image/image-controls.d.ts.map +1 -0
- package/lib/components/tools/image/image-controls.js +1 -1
- package/lib/components/tools/image/image-options.d.ts +3 -0
- package/lib/components/tools/image/image-options.d.ts.map +1 -0
- package/lib/components/tools/image/image-options.js +1 -1
- package/lib/components/tools/image/images-gallery.d.ts +14 -0
- package/lib/components/tools/image/images-gallery.d.ts.map +1 -0
- package/lib/components/tools/image/index.d.ts +3 -0
- package/lib/components/tools/image/index.d.ts.map +1 -0
- package/lib/components/tools/line/index.d.ts +3 -0
- package/lib/components/tools/line/index.d.ts.map +1 -0
- package/lib/components/tools/line/line-button.d.ts +8 -0
- package/lib/components/tools/line/line-button.d.ts.map +1 -0
- package/lib/components/tools/line/line-options.d.ts +4 -0
- package/lib/components/tools/line/line-options.d.ts.map +1 -0
- package/lib/components/tools/line/line-options.js +1 -1
- package/lib/components/tools/pen/index.d.ts +3 -0
- package/lib/components/tools/pen/index.d.ts.map +1 -0
- package/lib/components/tools/pen/pen-button.d.ts +8 -0
- package/lib/components/tools/pen/pen-button.d.ts.map +1 -0
- package/lib/components/tools/pen/pen-options.d.ts +3 -0
- package/lib/components/tools/pen/pen-options.d.ts.map +1 -0
- package/lib/components/tools/pen/pen-options.js +1 -1
- package/lib/components/tools/polygon/index.d.ts +3 -0
- package/lib/components/tools/polygon/index.d.ts.map +1 -0
- package/lib/components/tools/polygon/polygon-button.d.ts +8 -0
- package/lib/components/tools/polygon/polygon-button.d.ts.map +1 -0
- package/lib/components/tools/polygon/polygon-options.d.ts +4 -0
- package/lib/components/tools/polygon/polygon-options.d.ts.map +1 -0
- package/lib/components/tools/polygon/polygon-options.js +1 -1
- package/lib/components/tools/polygon/polygon-sides-field.d.ts +9 -0
- package/lib/components/tools/polygon/polygon-sides-field.d.ts.map +1 -0
- package/lib/components/tools/polygon/polygon.constants.d.ts +12 -0
- package/lib/components/tools/polygon/polygon.constants.d.ts.map +1 -0
- package/lib/components/tools/rect/index.d.ts +3 -0
- package/lib/components/tools/rect/index.d.ts.map +1 -0
- package/lib/components/tools/rect/rect-button.d.ts +8 -0
- package/lib/components/tools/rect/rect-button.d.ts.map +1 -0
- package/lib/components/tools/rect/rect-button.js +1 -1
- package/lib/components/tools/rect/rect-corner-field.d.ts +9 -0
- package/lib/components/tools/rect/rect-corner-field.d.ts.map +1 -0
- package/lib/components/tools/rect/rect-options.d.ts +4 -0
- package/lib/components/tools/rect/rect-options.d.ts.map +1 -0
- package/lib/components/tools/rect/rect-options.js +1 -1
- package/lib/components/tools/rect/rect.constants.d.ts +12 -0
- package/lib/components/tools/rect/rect.constants.d.ts.map +1 -0
- package/lib/components/tools/resize/index.d.ts +2 -0
- package/lib/components/tools/resize/index.d.ts.map +1 -0
- package/lib/components/tools/resize/resize.d.ts +13 -0
- package/lib/components/tools/resize/resize.d.ts.map +1 -0
- package/lib/components/tools/rotate/index.d.ts +3 -0
- package/lib/components/tools/rotate/index.d.ts.map +1 -0
- package/lib/components/tools/rotate/rotate-button.d.ts +8 -0
- package/lib/components/tools/rotate/rotate-button.d.ts.map +1 -0
- package/lib/components/tools/rotate/rotate-options.d.ts +3 -0
- package/lib/components/tools/rotate/rotate-options.d.ts.map +1 -0
- package/lib/components/tools/rotate/rotate-options.js +1 -1
- package/lib/components/tools/text/index.d.ts +3 -0
- package/lib/components/tools/text/index.d.ts.map +1 -0
- package/lib/components/tools/text/text-button.d.ts +8 -0
- package/lib/components/tools/text/text-button.d.ts.map +1 -0
- package/lib/components/tools/text/text-options/handle-text-change-area.d.ts +4 -0
- package/lib/components/tools/text/text-options/handle-text-change-area.d.ts.map +1 -0
- package/lib/components/tools/text/text-options/index.d.ts +4 -0
- package/lib/components/tools/text/text-options/index.d.ts.map +1 -0
- package/lib/components/tools/text/text-options/text-alignment-fields.d.ts +9 -0
- package/lib/components/tools/text/text-options/text-alignment-fields.d.ts.map +1 -0
- package/lib/components/tools/text/text-options/text-alignment-fields.js +1 -1
- package/lib/components/tools/text/text-options/text-controls.d.ts +12 -0
- package/lib/components/tools/text/text-options/text-controls.d.ts.map +1 -0
- package/lib/components/tools/text/text-options/text-controls.js +1 -1
- package/lib/components/tools/text/text-options/text-options.constants.d.ts +14 -0
- package/lib/components/tools/text/text-options/text-options.constants.d.ts.map +1 -0
- package/lib/components/tools/text/text-options/text-spacings-fields.d.ts +10 -0
- package/lib/components/tools/text/text-options/text-spacings-fields.d.ts.map +1 -0
- package/lib/components/tools/tools.constants.d.ts +9 -0
- package/lib/components/tools/tools.constants.d.ts.map +1 -0
- package/lib/components/tools/tools.constants.js +1 -1
- package/lib/components/tools/warmth/index.d.ts +3 -0
- package/lib/components/tools/warmth/index.d.ts.map +1 -0
- package/lib/components/tools/warmth/warmth-options.d.ts +7 -0
- package/lib/components/tools/warmth/warmth-options.d.ts.map +1 -0
- package/lib/components/tools/warmth/warmth.d.ts +8 -0
- package/lib/components/tools/warmth/warmth.d.ts.map +1 -0
- package/lib/components/tools/watermark/index.d.ts +2 -0
- package/lib/components/tools/watermark/index.d.ts.map +1 -0
- package/lib/components/tools/watermark/watermark-padding.d.ts +8 -0
- package/lib/components/tools/watermark/watermark-padding.d.ts.map +1 -0
- package/lib/components/tools/watermark/watermark.d.ts +3 -0
- package/lib/components/tools/watermark/watermark.d.ts.map +1 -0
- package/lib/components/tools/watermark/watermark.js +1 -1
- package/lib/components/tools/watermark/watermarks-gallery.d.ts +7 -0
- package/lib/components/tools/watermark/watermarks-gallery.d.ts.map +1 -0
- package/lib/components/tools/watermark/watermarks-gallery.js +1 -1
- package/lib/components/tools-bar/index.d.ts +3 -0
- package/lib/components/tools-bar/index.d.ts.map +1 -0
- package/lib/components/tools-bar/index.js +1 -1
- package/lib/components/tools-bar/tools-bar-item-button.d.ts +23 -0
- package/lib/components/tools-bar/tools-bar-item-button.d.ts.map +1 -0
- package/lib/components/tools-bar/tools-bar-item-button.js +1 -1
- package/lib/components/topbar/canvas-zooming.d.ts +3 -0
- package/lib/components/topbar/canvas-zooming.d.ts.map +1 -0
- package/lib/components/topbar/confirmation-modal.d.ts +8 -0
- package/lib/components/topbar/confirmation-modal.d.ts.map +1 -0
- package/lib/components/topbar/image-dimensions-and-display-toggle.d.ts +3 -0
- package/lib/components/topbar/image-dimensions-and-display-toggle.d.ts.map +1 -0
- package/lib/components/topbar/index.d.ts +7 -0
- package/lib/components/topbar/index.d.ts.map +1 -0
- package/lib/components/topbar/index.js +1 -1
- package/lib/components/topbar/redo-button.d.ts +3 -0
- package/lib/components/topbar/redo-button.d.ts.map +1 -0
- package/lib/components/topbar/reset-button.d.ts +3 -0
- package/lib/components/topbar/reset-button.d.ts.map +1 -0
- package/lib/components/topbar/save-button.d.ts +3 -0
- package/lib/components/topbar/save-button.d.ts.map +1 -0
- package/lib/components/topbar/save-button.js +1 -1
- package/lib/components/topbar/topbar.constants.d.ts +8 -0
- package/lib/components/topbar/topbar.constants.d.ts.map +1 -0
- package/lib/components/topbar/undo-button.d.ts +3 -0
- package/lib/components/topbar/undo-button.d.ts.map +1 -0
- package/lib/context/app-context.d.ts +14 -0
- package/lib/context/app-context.d.ts.map +1 -0
- package/lib/context/app-provider-overriden-value.d.ts +11 -0
- package/lib/context/app-provider-overriden-value.d.ts.map +1 -0
- package/lib/context/app-provider.d.ts +10 -0
- package/lib/context/app-provider.d.ts.map +1 -0
- package/lib/context/app-provider.js +1 -1
- package/lib/context/app-reducer.d.ts +5 -0
- package/lib/context/app-reducer.d.ts.map +1 -0
- package/lib/context/default-config.d.ts +4 -0
- package/lib/context/default-config.d.ts.map +1 -0
- package/lib/context/default-config.js +1 -1
- package/lib/context/default-translations.d.ts +3 -0
- package/lib/context/default-translations.d.ts.map +1 -0
- package/lib/context/default-translations.js +1 -1
- package/lib/context/get-initial-app-state.d.ts +5 -0
- package/lib/context/get-initial-app-state.d.ts.map +1 -0
- package/lib/context/get-initial-app-state.js +1 -1
- package/lib/context/index.d.ts +5 -0
- package/lib/context/index.d.ts.map +1 -0
- package/lib/custom/filters/aden.d.ts +14 -0
- package/lib/custom/filters/aden.d.ts.map +1 -0
- package/lib/custom/filters/amaro.d.ts +14 -0
- package/lib/custom/filters/amaro.d.ts.map +1 -0
- package/lib/custom/filters/ashby.d.ts +14 -0
- package/lib/custom/filters/ashby.d.ts.map +1 -0
- package/lib/custom/filters/base-filters.d.ts +14 -0
- package/lib/custom/filters/base-filters.d.ts.map +1 -0
- package/lib/custom/filters/black-and-white.d.ts +14 -0
- package/lib/custom/filters/black-and-white.d.ts.map +1 -0
- package/lib/custom/filters/brannan.d.ts +14 -0
- package/lib/custom/filters/brannan.d.ts.map +1 -0
- package/lib/custom/filters/brooklyn.d.ts +14 -0
- package/lib/custom/filters/brooklyn.d.ts.map +1 -0
- package/lib/custom/filters/charmes.d.ts +14 -0
- package/lib/custom/filters/charmes.d.ts.map +1 -0
- package/lib/custom/filters/clarendon.d.ts +14 -0
- package/lib/custom/filters/clarendon.d.ts.map +1 -0
- package/lib/custom/filters/crema.d.ts +14 -0
- package/lib/custom/filters/crema.d.ts.map +1 -0
- package/lib/custom/filters/dogpatch.d.ts +14 -0
- package/lib/custom/filters/dogpatch.d.ts.map +1 -0
- package/lib/custom/filters/earlybird.d.ts +14 -0
- package/lib/custom/filters/earlybird.d.ts.map +1 -0
- package/lib/custom/filters/gingham.d.ts +14 -0
- package/lib/custom/filters/gingham.d.ts.map +1 -0
- package/lib/custom/filters/ginza.d.ts +14 -0
- package/lib/custom/filters/ginza.d.ts.map +1 -0
- package/lib/custom/filters/hefe.d.ts +14 -0
- package/lib/custom/filters/hefe.d.ts.map +1 -0
- package/lib/custom/filters/helena.d.ts +14 -0
- package/lib/custom/filters/helena.d.ts.map +1 -0
- package/lib/custom/filters/hudson.d.ts +14 -0
- package/lib/custom/filters/hudson.d.ts.map +1 -0
- package/lib/custom/filters/index.d.ts +41 -0
- package/lib/custom/filters/index.d.ts.map +1 -0
- package/lib/custom/filters/juno.d.ts +14 -0
- package/lib/custom/filters/juno.d.ts.map +1 -0
- package/lib/custom/filters/kelvin.d.ts +14 -0
- package/lib/custom/filters/kelvin.d.ts.map +1 -0
- package/lib/custom/filters/lark.d.ts +14 -0
- package/lib/custom/filters/lark.d.ts.map +1 -0
- package/lib/custom/filters/lo-fi.d.ts +14 -0
- package/lib/custom/filters/lo-fi.d.ts.map +1 -0
- package/lib/custom/filters/ludwig.d.ts +14 -0
- package/lib/custom/filters/ludwig.d.ts.map +1 -0
- package/lib/custom/filters/maven.d.ts +14 -0
- package/lib/custom/filters/maven.d.ts.map +1 -0
- package/lib/custom/filters/mayfair.d.ts +14 -0
- package/lib/custom/filters/mayfair.d.ts.map +1 -0
- package/lib/custom/filters/moon.d.ts +14 -0
- package/lib/custom/filters/moon.d.ts.map +1 -0
- package/lib/custom/filters/nashville.d.ts +14 -0
- package/lib/custom/filters/nashville.d.ts.map +1 -0
- package/lib/custom/filters/ninteen-seventy-seven.d.ts +14 -0
- package/lib/custom/filters/ninteen-seventy-seven.d.ts.map +1 -0
- package/lib/custom/filters/perpetua.d.ts +14 -0
- package/lib/custom/filters/perpetua.d.ts.map +1 -0
- package/lib/custom/filters/reyes.d.ts +14 -0
- package/lib/custom/filters/reyes.d.ts.map +1 -0
- package/lib/custom/filters/rise.d.ts +14 -0
- package/lib/custom/filters/rise.d.ts.map +1 -0
- package/lib/custom/filters/sierra.d.ts +14 -0
- package/lib/custom/filters/sierra.d.ts.map +1 -0
- package/lib/custom/filters/skyline.d.ts +14 -0
- package/lib/custom/filters/skyline.d.ts.map +1 -0
- package/lib/custom/filters/slumber.d.ts +14 -0
- package/lib/custom/filters/slumber.d.ts.map +1 -0
- package/lib/custom/filters/stinson.d.ts +14 -0
- package/lib/custom/filters/stinson.d.ts.map +1 -0
- package/lib/custom/filters/sutro.d.ts +14 -0
- package/lib/custom/filters/sutro.d.ts.map +1 -0
- package/lib/custom/filters/toaster.d.ts +14 -0
- package/lib/custom/filters/toaster.d.ts.map +1 -0
- package/lib/custom/filters/valencia.d.ts +14 -0
- package/lib/custom/filters/valencia.d.ts.map +1 -0
- package/lib/custom/filters/vesper.d.ts +14 -0
- package/lib/custom/filters/vesper.d.ts.map +1 -0
- package/lib/custom/filters/walden.d.ts +14 -0
- package/lib/custom/filters/walden.d.ts.map +1 -0
- package/lib/custom/filters/willow.d.ts +14 -0
- package/lib/custom/filters/willow.d.ts.map +1 -0
- package/lib/custom/filters/xpro2.d.ts +14 -0
- package/lib/custom/filters/xpro2.d.ts.map +1 -0
- package/lib/custom/finetunes/custom-threshold.d.ts +15 -0
- package/lib/custom/finetunes/custom-threshold.d.ts.map +1 -0
- package/lib/custom/finetunes/index.d.ts +3 -0
- package/lib/custom/finetunes/index.d.ts.map +1 -0
- package/lib/custom/finetunes/warmth.d.ts +17 -0
- package/lib/custom/finetunes/warmth.d.ts.map +1 -0
- package/lib/demo/app.d.ts +6 -0
- package/lib/demo/app.d.ts.map +1 -0
- package/lib/demo/app.js +1 -0
- package/lib/demo/index.d.ts +2 -0
- package/lib/demo/index.d.ts.map +1 -0
- package/lib/demo/index.js +1 -0
- package/lib/hooks/index.d.ts +13 -0
- package/lib/hooks/index.d.ts.map +1 -0
- package/lib/hooks/use-annotation/get-bounding-rect-un-scaled.d.ts +19 -0
- package/lib/hooks/use-annotation/get-bounding-rect-un-scaled.d.ts.map +1 -0
- package/lib/hooks/use-annotation/get-new-annotation-preview.d.ts +25 -0
- package/lib/hooks/use-annotation/get-new-annotation-preview.d.ts.map +1 -0
- package/lib/hooks/use-annotation/index.d.ts +74 -0
- package/lib/hooks/use-annotation/index.d.ts.map +1 -0
- package/lib/hooks/use-annotation/index.js +1 -1
- package/lib/hooks/use-annotation/preview-then-call-annotation-adding.d.ts +3 -0
- package/lib/hooks/use-annotation/preview-then-call-annotation-adding.d.ts.map +1 -0
- package/lib/hooks/use-annotation-events.d.ts +11 -0
- package/lib/hooks/use-annotation-events.d.ts.map +1 -0
- package/lib/hooks/use-annotation-events.js +1 -1
- package/lib/hooks/use-app-reducer.d.ts +13 -0
- package/lib/hooks/use-app-reducer.d.ts.map +1 -0
- package/lib/hooks/use-debounced-callback.d.ts +5 -0
- package/lib/hooks/use-debounced-callback.d.ts.map +1 -0
- package/lib/hooks/use-drag.d.ts +8 -0
- package/lib/hooks/use-drag.d.ts.map +1 -0
- package/lib/hooks/use-filter.d.ts +4 -0
- package/lib/hooks/use-filter.d.ts.map +1 -0
- package/lib/hooks/use-finetune.d.ts +5 -0
- package/lib/hooks/use-finetune.d.ts.map +1 -0
- package/lib/hooks/use-phone-screen.d.ts +3 -0
- package/lib/hooks/use-phone-screen.d.ts.map +1 -0
- package/lib/hooks/use-popover.d.ts +11 -0
- package/lib/hooks/use-popover.d.ts.map +1 -0
- package/lib/hooks/use-resize-observer.d.ts +12 -0
- package/lib/hooks/use-resize-observer.d.ts.map +1 -0
- package/lib/hooks/use-store.d.ts +5 -0
- package/lib/hooks/use-store.d.ts.map +1 -0
- package/lib/hooks/use-store.js +1 -1
- package/lib/hooks/use-transformed-img-data.d.ts +20 -0
- package/lib/hooks/use-transformed-img-data.d.ts.map +1 -0
- package/lib/hooks/use-transformed-img-data.js +1 -1
- package/lib/hooks/use-update-effect.d.ts +5 -0
- package/lib/hooks/use-update-effect.d.ts.map +1 -0
- package/lib/index.d.ts +6 -345
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +1 -1
- package/lib/types/actions.d.ts +204 -0
- package/lib/types/actions.d.ts.map +1 -0
- package/lib/types/annotations.d.ts +181 -0
- package/lib/types/annotations.d.ts.map +1 -0
- package/lib/types/annotations.js +1 -1
- package/lib/types/common.d.ts +31 -0
- package/lib/types/common.d.ts.map +1 -0
- package/lib/types/config.d.ts +144 -0
- package/lib/types/config.d.ts.map +1 -0
- package/lib/types/index.d.ts +6 -0
- package/lib/types/index.d.ts.map +1 -0
- package/lib/types/state.d.ts +105 -0
- package/lib/types/state.d.ts.map +1 -0
- package/lib/utils/assign-finetune-names-to-konva.d.ts +3 -0
- package/lib/utils/assign-finetune-names-to-konva.d.ts.map +1 -0
- package/lib/utils/calculate-zoom-data.d.ts +9 -0
- package/lib/utils/calculate-zoom-data.d.ts.map +1 -0
- package/lib/utils/compare-ratios.d.ts +3 -0
- package/lib/utils/compare-ratios.d.ts.map +1 -0
- package/lib/utils/constants.d.ts +85 -0
- package/lib/utils/constants.d.ts.map +1 -0
- package/lib/utils/constants.js +1 -1
- package/lib/utils/crop-image.d.ts +10 -0
- package/lib/utils/crop-image.d.ts.map +1 -0
- package/lib/utils/debounce.d.ts +3 -0
- package/lib/utils/debounce.d.ts.map +1 -0
- package/lib/utils/deep-merge.d.ts +3 -0
- package/lib/utils/deep-merge.d.ts.map +1 -0
- package/lib/utils/deep-merge.js +1 -1
- package/lib/utils/extract-current-design-state.d.ts +11 -0
- package/lib/utils/extract-current-design-state.d.ts.map +1 -0
- package/lib/utils/extract-name-from-url.d.ts +3 -0
- package/lib/utils/extract-name-from-url.d.ts.map +1 -0
- package/lib/utils/filter-str-to-class.d.ts +4 -0
- package/lib/utils/filter-str-to-class.d.ts.map +1 -0
- package/lib/utils/finetunes-strs-to-classes.d.ts +4 -0
- package/lib/utils/finetunes-strs-to-classes.d.ts.map +1 -0
- package/lib/utils/finetunes-strs-to-classes.js +1 -1
- package/lib/utils/get-center-rotated-point.d.ts +8 -0
- package/lib/utils/get-center-rotated-point.d.ts.map +1 -0
- package/lib/utils/get-default-save-quality.d.ts +3 -0
- package/lib/utils/get-default-save-quality.d.ts.map +1 -0
- package/lib/utils/get-dimensions-minimal-ratio.d.ts +3 -0
- package/lib/utils/get-dimensions-minimal-ratio.d.ts.map +1 -0
- package/lib/utils/get-elem-document-coords.d.ts +9 -0
- package/lib/utils/get-elem-document-coords.d.ts.map +1 -0
- package/lib/utils/get-file-full-name.d.ts +8 -0
- package/lib/utils/get-file-full-name.d.ts.map +1 -0
- package/lib/utils/get-pointer-offset-position-bounded-to-object.d.ts +21 -0
- package/lib/utils/get-pointer-offset-position-bounded-to-object.d.ts.map +1 -0
- package/lib/utils/get-pointer-offset-position-bounded-to-object.js +1 -1
- package/lib/utils/get-proper-dimensions.d.ts +11 -0
- package/lib/utils/get-proper-dimensions.d.ts.map +1 -0
- package/lib/utils/get-proper-image-to-canvas-spacing.d.ts +3 -0
- package/lib/utils/get-proper-image-to-canvas-spacing.d.ts.map +1 -0
- package/lib/utils/get-scroll-offset.d.ts +7 -0
- package/lib/utils/get-scroll-offset.d.ts.map +1 -0
- package/lib/utils/get-size-after-rotation.d.ts +9 -0
- package/lib/utils/get-size-after-rotation.d.ts.map +1 -0
- package/lib/utils/get-zoom-fit-factor.d.ts +4 -0
- package/lib/utils/get-zoom-fit-factor.d.ts.map +1 -0
- package/lib/utils/image-to-base64.d.ts +3 -0
- package/lib/utils/image-to-base64.d.ts.map +1 -0
- package/lib/utils/is-default-zero-values-only.d.ts +3 -0
- package/lib/utils/is-default-zero-values-only.d.ts.map +1 -0
- package/lib/utils/is-same-image.d.ts +3 -0
- package/lib/utils/is-same-image.d.ts.map +1 -0
- package/lib/utils/is-same-image.js +1 -1
- package/lib/utils/load-image.d.ts +3 -0
- package/lib/utils/load-image.d.ts.map +1 -0
- package/lib/utils/map-crop-box.d.ts +16 -0
- package/lib/utils/map-crop-box.d.ts.map +1 -0
- package/lib/utils/map-number.d.ts +3 -0
- package/lib/utils/map-number.d.ts.map +1 -0
- package/lib/utils/map-position-string-to-point.d.ts +8 -0
- package/lib/utils/map-position-string-to-point.d.ts.map +1 -0
- package/lib/utils/map-position-string-to-point.js +1 -1
- package/lib/utils/random-id.d.ts +3 -0
- package/lib/utils/random-id.d.ts.map +1 -0
- package/lib/utils/restrict-number.d.ts +3 -0
- package/lib/utils/restrict-number.d.ts.map +1 -0
- package/lib/utils/serialize-design-state.d.ts +27 -0
- package/lib/utils/serialize-design-state.d.ts.map +1 -0
- package/lib/utils/serialize-design-state.js +1 -0
- package/lib/utils/to-precised-float.d.ts +3 -0
- package/lib/utils/to-precised-float.d.ts.map +1 -0
- package/lib/utils/translator.d.ts +3 -0
- package/lib/utils/translator.d.ts.map +1 -0
- package/lib/utils/translator.js +1 -1
- package/package.json +63 -61
- package/lib/components/tools/crop/crop-preset-item.js +0 -1
- package/lib/components/tools/crop/crop-presets-option.js +0 -1
- package/lib/components/tools-bar/tools-bar-item-options-wrapper.js +0 -1
- package/lib/utils/cloudimage-query-to-design-state.js +0 -1
- package/lib/utils/get-image-sealing-params.js +0 -1
- package/lib/utils/operations-to-cloudimage-url.js +0 -1
- package/lib/utils/rgba-to-hexa.js +0 -1
- package/lib/utils/sha1.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"debounce.d.ts","sourceRoot":"","sources":["../../src/utils/debounce.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,QAAQ,GAAI,CAAC,SAAS,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,EACjD,MAAM,CAAC,EACP,UAAS,MAAY,KACpB,CAAC,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,CAa3B,CAAC;AAEF,eAAe,QAAQ,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deep-merge.d.ts","sourceRoot":"","sources":["../../src/utils/deep-merge.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,SAAS,GAAI,CAAC,SAAS,MAAM,EACjC,QAAQ,CAAC,EACT,SAAQ,GAAQ,EAChB,gBAAe,OAAe,KAC7B,CA+BF,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
package/lib/utils/deep-merge.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import _typeof from"@babel/runtime/helpers/typeof";import _defineProperty from"@babel/runtime/helpers/defineProperty";function ownKeys(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function _objectSpread(a){for(var b,c=1;c<arguments.length;c++)b=null==arguments[c]?{}:arguments[c],c%2?ownKeys(Object(b),!0).forEach(function(c){_defineProperty(a,c,b[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):ownKeys(Object(b)).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))});return a}var _deepMerge=function(a){var b=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},c=!!(2<arguments.length&&void 0!==arguments[2])&&arguments[2],d=_objectSpread({},a),e=Object.keys(b);return e.forEach(function(e){var f=b[e];if(void 0!==f){var g=_typeof(f);if("object"!==g||f instanceof HTMLElement||null===f||Array.isArray(f)||!
|
|
1
|
+
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import _typeof from"@babel/runtime/helpers/typeof";import _defineProperty from"@babel/runtime/helpers/defineProperty";function ownKeys(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function _objectSpread(a){for(var b,c=1;c<arguments.length;c++)b=null==arguments[c]?{}:arguments[c],c%2?ownKeys(Object(b),!0).forEach(function(c){_defineProperty(a,c,b[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):ownKeys(Object(b)).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))});return a}var _deepMerge=function(a){var b=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},c=!!(2<arguments.length&&void 0!==arguments[2])&&arguments[2],d=_objectSpread({},a),e=Object.keys(b);return e.forEach(function(e){var f=b[e];if(void 0!==f){var g=_typeof(f),h=a[e];if("object"!==g||f instanceof HTMLElement||null===f||Array.isArray(f)||!h||"object"!==_typeof(h)){var i=d[e];return void(d[e]=c&&Array.isArray(i)&&Array.isArray(f)?[].concat(_toConsumableArray(i),_toConsumableArray(f)):f)}d[e]=_deepMerge(h,f)}}),d};export default _deepMerge;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { AppState, ImageDesignState } from 'types/state';
|
|
2
|
+
/**
|
|
3
|
+
* Extracts the needed properties/state that are used in canvas's design from the global state.
|
|
4
|
+
*
|
|
5
|
+
* @param state The global state.
|
|
6
|
+
* @param useStateAsConfig Value assigned to any undefined/null property in returned object.
|
|
7
|
+
* @returns The extracted design state.
|
|
8
|
+
*/
|
|
9
|
+
declare const extractCurrentDesignState: (state: AppState, useStateAsConfig?: boolean) => ImageDesignState;
|
|
10
|
+
export default extractCurrentDesignState;
|
|
11
|
+
//# sourceMappingURL=extract-current-design-state.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"extract-current-design-state.d.ts","sourceRoot":"","sources":["../../src/utils/extract-current-design-state.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,QAAQ,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAG9D;;;;;;GAMG;AACH,QAAA,MAAM,yBAAyB,GAC7B,OAAO,QAAQ,EACf,mBAAmB,OAAO,KACzB,gBAgBF,CAAC;AAEF,eAAe,yBAAyB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"extract-name-from-url.d.ts","sourceRoot":"","sources":["../../src/utils/extract-name-from-url.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,kBAAkB,GAAI,KAAK,MAAM,KAAG,MAGzC,CAAC;AAEF,eAAe,kBAAkB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"filter-str-to-class.d.ts","sourceRoot":"","sources":["../../src/utils/filter-str-to-class.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAKxC,QAAA,MAAM,gBAAgB,GACpB,cAAc,MAAM,GAAG,IAAI,GAAG,SAAS,KACtC,MAAM,GAAG,IASX,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"finetunes-strs-to-classes.d.ts","sourceRoot":"","sources":["../../src/utils/finetunes-strs-to-classes.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAIxC,QAAA,MAAM,sBAAsB,GAC1B,kBAAkB,MAAM,EAAE,GAAG,SAAS,KACrC,MAAM,EAYR,CAAC;AAEF,eAAe,sBAAsB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import Konva from"konva";import*as CustomFinetunes from"custom/finetunes";var finetunesStrsToClasses=function(a){return Array.isArray(a)&&0<a.length?a.map(function(a){return Konva.Filters[a]||CustomFinetunes[a]}):[]};export default finetunesStrsToClasses;
|
|
1
|
+
import Konva from"konva";import*as CustomFinetunes from"custom/finetunes";var finetunesStrsToClasses=function(a){return Array.isArray(a)&&0<a.length?a.map(function(a){return Konva.Filters[a]||CustomFinetunes[a]}).filter(function(a){return void 0!==a}):[]};export default finetunesStrsToClasses;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/** External Dependencies */
|
|
2
|
+
import type { Vector2d } from 'konva/lib/types';
|
|
3
|
+
interface RotatedPoint extends Vector2d {
|
|
4
|
+
rotation: number;
|
|
5
|
+
}
|
|
6
|
+
declare const getCenterRotatedPoint: (width: number, height: number, newRotationAngleDegree: number) => RotatedPoint;
|
|
7
|
+
export default getCenterRotatedPoint;
|
|
8
|
+
//# sourceMappingURL=get-center-rotated-point.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-center-rotated-point.d.ts","sourceRoot":"","sources":["../../src/utils/get-center-rotated-point.ts"],"names":[],"mappings":"AAAA,4BAA4B;AAC5B,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAEhD,UAAU,YAAa,SAAQ,QAAQ;IACrC,QAAQ,EAAE,MAAM,CAAC;CAClB;AASD,QAAA,MAAM,qBAAqB,GACzB,OAAO,MAAM,EACb,QAAQ,MAAM,EACd,wBAAwB,MAAM,KAC7B,YAmBF,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-default-save-quality.d.ts","sourceRoot":"","sources":["../../src/utils/get-default-save-quality.ts"],"names":[],"mappings":"AAEA,QAAA,MAAM,qBAAqB,GAAI,wBAAwB,MAAM,KAAG,MAGpC,CAAC;AAE7B,eAAe,qBAAqB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-dimensions-minimal-ratio.d.ts","sourceRoot":"","sources":["../../src/utils/get-dimensions-minimal-ratio.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,yBAAyB,GAC7B,YAAY,MAAM,EAClB,aAAa,MAAM,EACnB,aAAa,MAAM,EACnB,cAAc,MAAM,KACnB,MAKF,CAAC;AAEF,eAAe,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
interface ElementCoords {
|
|
2
|
+
top: number;
|
|
3
|
+
left: number;
|
|
4
|
+
width: number;
|
|
5
|
+
height: number;
|
|
6
|
+
}
|
|
7
|
+
declare const getElemDocumentCoords: (elem: Element | null | undefined) => ElementCoords | null;
|
|
8
|
+
export default getElemDocumentCoords;
|
|
9
|
+
//# sourceMappingURL=get-elem-document-coords.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-elem-document-coords.d.ts","sourceRoot":"","sources":["../../src/utils/get-elem-document-coords.ts"],"names":[],"mappings":"AAGA,UAAU,aAAa;IACrB,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,QAAA,MAAM,qBAAqB,GACzB,MAAM,OAAO,GAAG,IAAI,GAAG,SAAS,KAC/B,aAAa,GAAG,IAsBlB,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface FileFullName {
|
|
2
|
+
fullName: string;
|
|
3
|
+
name: string;
|
|
4
|
+
extension: string;
|
|
5
|
+
}
|
|
6
|
+
declare const getFileFullName: (fileNameProp?: string, appendedExtension?: string) => FileFullName;
|
|
7
|
+
export default getFileFullName;
|
|
8
|
+
//# sourceMappingURL=get-file-full-name.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-file-full-name.d.ts","sourceRoot":"","sources":["../../src/utils/get-file-full-name.ts"],"names":[],"mappings":"AAMA,UAAU,YAAY;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,QAAA,MAAM,eAAe,GACnB,eAAe,MAAM,EACrB,oBAAoB,MAAM,KACzB,YA6BF,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/** Internal Dependencies */
|
|
2
|
+
import type Konva from 'konva';
|
|
3
|
+
interface RelativeToObject {
|
|
4
|
+
width: number;
|
|
5
|
+
height: number;
|
|
6
|
+
}
|
|
7
|
+
interface PointerOffset {
|
|
8
|
+
offsetX: number;
|
|
9
|
+
offsetY: number;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Gets the touch/mouse position relative to the passed object to be considered as offset X/Y.
|
|
13
|
+
*
|
|
14
|
+
* @param previewGroup - The preview group that is a direct child of the design layer
|
|
15
|
+
* @param relativeToObject - The object to be considered as parent element
|
|
16
|
+
* contains left, top, width & height relative to the document.
|
|
17
|
+
* @returns both X & Y offset values.
|
|
18
|
+
*/
|
|
19
|
+
declare const getPointerOffsetPositionBoundedToObject: (previewGroup?: Konva.Group | null, relativeToObject?: RelativeToObject) => PointerOffset;
|
|
20
|
+
export default getPointerOffsetPositionBoundedToObject;
|
|
21
|
+
//# sourceMappingURL=get-pointer-offset-position-bounded-to-object.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-pointer-offset-position-bounded-to-object.d.ts","sourceRoot":"","sources":["../../src/utils/get-pointer-offset-position-bounded-to-object.ts"],"names":[],"mappings":"AAAA,4BAA4B;AAC5B,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,UAAU,gBAAgB;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,UAAU,aAAa;IACrB,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;;;;;;GAOG;AACH,QAAA,MAAM,uCAAuC,GAC3C,eAAc,KAAK,CAAC,KAAK,GAAG,IAAW,EACvC,mBAAkB,gBAA0C,KAC3D,aAwBF,CAAC;AAEF,eAAe,uCAAuC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import restrictNumber from"./restrict-number";var getPointerOffsetPositionBoundedToObject=function(){var a=0<arguments.length&&arguments[0]!==void 0?arguments[0]:
|
|
1
|
+
import restrictNumber from"./restrict-number";var getPointerOffsetPositionBoundedToObject=function(){var a=0<arguments.length&&arguments[0]!==void 0?arguments[0]:null,b=1<arguments.length&&arguments[1]!==void 0?arguments[1]:{width:0,height:0};if(!a)return{offsetX:0,offsetY:0};var c=a.parent,d=c.getStage(),e=d.attrs.zoomFactor,f=c.getRelativePointerPosition()||{x:0,y:0};return{offsetX:restrictNumber(f.x,0,b.width/(d.scaleX()/e))+c.attrs.xPadding,offsetY:restrictNumber(f.y,0,b.height/(d.scaleY()/e))+c.attrs.yPadding}};export default getPointerOffsetPositionBoundedToObject;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/** Internal Dependencies */
|
|
2
|
+
import type { Dimensions } from 'types/common';
|
|
3
|
+
interface CropDimensions {
|
|
4
|
+
x?: number;
|
|
5
|
+
y?: number;
|
|
6
|
+
width?: number;
|
|
7
|
+
height?: number;
|
|
8
|
+
}
|
|
9
|
+
declare const getProperDimensions: (resizeDimensions: Partial<Dimensions>, cropDimensions: CropDimensions, shownImageDimensions: Dimensions, originalDimensions: Dimensions, rotationAngle?: number) => Dimensions;
|
|
10
|
+
export default getProperDimensions;
|
|
11
|
+
//# sourceMappingURL=get-proper-dimensions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-proper-dimensions.d.ts","sourceRoot":"","sources":["../../src/utils/get-proper-dimensions.ts"],"names":[],"mappings":"AAAA,4BAA4B;AAC5B,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAI/C,UAAU,cAAc;IACtB,CAAC,CAAC,EAAE,MAAM,CAAC;IACX,CAAC,CAAC,EAAE,MAAM,CAAC;IACX,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,QAAA,MAAM,mBAAmB,GACvB,kBAAkB,OAAO,CAAC,UAAU,CAAC,EACrC,gBAAgB,cAAc,EAC9B,sBAAsB,UAAU,EAChC,oBAAoB,UAAU,EAC9B,gBAAe,MAAU,KACxB,UAkCF,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-proper-image-to-canvas-spacing.d.ts","sourceRoot":"","sources":["../../src/utils/get-proper-image-to-canvas-spacing.ts"],"names":[],"mappings":"AAGA,QAAA,MAAM,6BAA6B,QAAO,MAGhB,CAAC;AAE3B,eAAe,6BAA6B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-scroll-offset.d.ts","sourceRoot":"","sources":["../../src/utils/get-scroll-offset.ts"],"names":[],"mappings":"AAAA,UAAU,YAAY;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,QAAA,MAAM,eAAe,QAAO,YAa3B,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
interface SizeAfterRotation {
|
|
2
|
+
width: number;
|
|
3
|
+
height: number;
|
|
4
|
+
offsetTop: number;
|
|
5
|
+
offsetLeft: number;
|
|
6
|
+
}
|
|
7
|
+
declare const getSizeAfterRotation: (width: number, height: number, rotationAngleInDegree?: number) => SizeAfterRotation;
|
|
8
|
+
export default getSizeAfterRotation;
|
|
9
|
+
//# sourceMappingURL=get-size-after-rotation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-size-after-rotation.d.ts","sourceRoot":"","sources":["../../src/utils/get-size-after-rotation.ts"],"names":[],"mappings":"AAAA,UAAU,iBAAiB;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,QAAA,MAAM,oBAAoB,GACxB,OAAO,MAAM,EACb,QAAQ,MAAM,EACd,wBAAuB,MAAU,KAChC,iBAiCF,CAAC;AAEF,eAAe,oBAAoB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-zoom-fit-factor.d.ts","sourceRoot":"","sources":["../../src/utils/get-zoom-fit-factor.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAG/C,QAAA,MAAM,gBAAgB,GACpB,eAAe,UAAU,EACzB,gBAAgB,UAAU,KACzB,MAIuB,CAAC;AAE3B,eAAe,gBAAgB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"image-to-base64.d.ts","sourceRoot":"","sources":["../../src/utils/image-to-base64.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,aAAa,GAAI,OAAO,gBAAgB,KAAG,MAWhD,CAAC;AAEF,eAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-default-zero-values-only.d.ts","sourceRoot":"","sources":["../../src/utils/is-default-zero-values-only.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,uBAAuB,GAC3B,cAAc,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,SAAS,GAAG,IAAI,EACpD,UAAU,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,SAAS,GAAG,IAAI,KAC/C,OAQA,CAAC;AAEJ,eAAe,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is-same-image.d.ts","sourceRoot":"","sources":["../../src/utils/is-same-image.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,WAAW,GACf,OAAO,MAAM,GAAG,gBAAgB,EAChC,kBAAkB,gBAAgB,KACjC,OAUA,CAAC;AAEJ,eAAe,WAAW,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var isSameImage=function(a,b){return!!(a&&b&&(a instanceof HTMLImageElement&&a.src===b.src&&a.width===b.width&&a.height===b.height||(
|
|
1
|
+
var isSameImage=function(a,b){return!!(a&&b&&(a instanceof HTMLImageElement&&a.src===b.src&&a.width===b.width&&a.height===b.height||(a instanceof HTMLImageElement&&a.src||a)===b.src))};export default isSameImage;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"load-image.d.ts","sourceRoot":"","sources":["../../src/utils/load-image.ts"],"names":[],"mappings":"AAEA,QAAA,MAAM,SAAS,GACb,UAAU,MAAM,EAChB,gBAAgB,MAAM,EACtB,gBAAe,OAAe,KAC7B,OAAO,CAAC,gBAAgB,CAkBvB,CAAC;AAEL,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Dimensions } from 'types/common';
|
|
2
|
+
interface CropInput {
|
|
3
|
+
x?: number;
|
|
4
|
+
y?: number;
|
|
5
|
+
width?: number;
|
|
6
|
+
height?: number;
|
|
7
|
+
}
|
|
8
|
+
interface MappedCropBox {
|
|
9
|
+
x?: number;
|
|
10
|
+
y?: number;
|
|
11
|
+
width: number;
|
|
12
|
+
height: number;
|
|
13
|
+
}
|
|
14
|
+
declare const mapCropBox: (crop: CropInput, shownImageDimensions: Dimensions, toDimensions: Dimensions) => MappedCropBox;
|
|
15
|
+
export default mapCropBox;
|
|
16
|
+
//# sourceMappingURL=map-crop-box.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"map-crop-box.d.ts","sourceRoot":"","sources":["../../src/utils/map-crop-box.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAG/C,UAAU,SAAS;IACjB,CAAC,CAAC,EAAE,MAAM,CAAC;IACX,CAAC,CAAC,EAAE,MAAM,CAAC;IACX,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,UAAU,aAAa;IACrB,CAAC,CAAC,EAAE,MAAM,CAAC;IACX,CAAC,CAAC,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,QAAA,MAAM,UAAU,GACd,MAAM,SAAS,EACf,sBAAsB,UAAU,EAChC,cAAc,UAAU,KACvB,aA6CD,CAAC;AAEH,eAAe,UAAU,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"map-number.d.ts","sourceRoot":"","sources":["../../src/utils/map-number.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,SAAS,GACb,QAAQ,MAAM,EACd,QAAQ,MAAM,EACd,QAAQ,MAAM,EACd,QAAQ,MAAM,EACd,QAAQ,MAAM,KACb,MACmE,CAAC;AAEvE,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/** External Dependencies */
|
|
2
|
+
import type { Vector2d } from 'konva/lib/types';
|
|
3
|
+
import { Layer } from 'konva/lib/Layer';
|
|
4
|
+
/** Internal Dependencies */
|
|
5
|
+
import type { Annotation } from 'types/annotations';
|
|
6
|
+
declare const mapPositionStringToPoint: (annotation: Annotation, designLayer: Layer, position: string) => Vector2d;
|
|
7
|
+
export default mapPositionStringToPoint;
|
|
8
|
+
//# sourceMappingURL=map-position-string-to-point.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"map-position-string-to-point.d.ts","sourceRoot":"","sources":["../../src/utils/map-position-string-to-point.ts"],"names":[],"mappings":"AAAA,4BAA4B;AAC5B,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAExC,4BAA4B;AAC5B,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAKpD,QAAA,MAAM,wBAAwB,GAC5B,YAAY,UAAU,EACtB,aAAa,KAAK,EAClB,UAAU,MAAM,KACf,QAqGF,CAAC;AAEF,eAAe,wBAAwB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import _defineProperty from"@babel/runtime/helpers/defineProperty";import{POSITIONS}from"./constants";import getSizeAfterRotation from"./get-size-after-rotation";var mapPositionStringToPoint=function(a,b,c){var d=a.
|
|
1
|
+
import _defineProperty from"@babel/runtime/helpers/defineProperty";import{hasDimensions,hasRadius,hasRadii}from"types/annotations";import{POSITIONS}from"./constants";import getSizeAfterRotation from"./get-size-after-rotation";var mapPositionStringToPoint=function(a,b,c){var d=a.scaleX,e=void 0===d?1:d,f=a.scaleY,g=void 0===f?1:f,h=a.rotation,i=void 0===h?0:h,j=a.padding,k=void 0===j?0:j,l=0,m=0;hasDimensions(a)?(l=a.width,m=a.height):hasRadius(a)?(l=2*a.radius,m=2*a.radius):hasRadii(a)&&(l=2*a.radiusX,m=2*a.radiusY);var n=getSizeAfterRotation(l*e,m*g,i),o=b.attrs,p=o.clipWidth,q=o.clipHeight,r=o.clipX,s=void 0===r?0:r,t=o.clipY,u=void 0===t?0:t,v={left:s+n.offsetLeft+k,center:s+p/2-(n.width/2-n.offsetLeft)+k,right:s+p-n.width-k+n.offsetLeft},w={top:u+n.offsetTop+k,middle:u+q/2-(n.height/2-n.offsetTop)+k,bottom:u+q-n.height-k+n.offsetTop},x=_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({},POSITIONS.TOP_LEFT,function(){return{x:v.left,y:w.top}}),POSITIONS.TOP_CENTER,function(){return{x:v.center,y:w.top}}),POSITIONS.TOP_RIGHT,function(){return{x:v.right,y:w.top}}),POSITIONS.MIDDLE_LEFT,function(){return{x:v.left,y:w.middle}}),POSITIONS.MIDDLE_CENTER,function(){return{x:v.center,y:w.middle}}),POSITIONS.MIDDLE_RIGHT,function(){return{x:v.right,y:w.middle}}),POSITIONS.BOTTOM_LEFT,function(){return{x:v.left,y:w.bottom}}),POSITIONS.BOTTOM_CENTER,function(){return{x:v.center,y:w.bottom}}),POSITIONS.BOTTOM_RIGHT,function(){return{x:v.right,y:w.bottom}});return x[c]()};export default mapPositionStringToPoint;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"random-id.d.ts","sourceRoot":"","sources":["../../src/utils/random-id.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,QAAQ,GAAI,eAAc,MAAW,KAAG,MAIzC,CAAC;AAEN,eAAe,QAAQ,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"restrict-number.d.ts","sourceRoot":"","sources":["../../src/utils/restrict-number.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,cAAc,GAClB,QAAQ,MAAM,EACd,UAAU,MAAM,EAChB,MAAM,MAAM,KACX,MAOF,CAAC;AAEF,eAAe,cAAc,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/** External Dependencies */
|
|
2
|
+
import { Filter } from 'konva/lib/Node';
|
|
3
|
+
/** Internal Dependencies */
|
|
4
|
+
import { AnnotationsMap } from 'types/annotations';
|
|
5
|
+
import { AppState, ImageDesignState } from 'types/state';
|
|
6
|
+
/**
|
|
7
|
+
* Extracts the filter name from a Konva Filter instance.
|
|
8
|
+
*/
|
|
9
|
+
export declare const filterToString: (filter: Filter | null | undefined) => string | undefined;
|
|
10
|
+
/**
|
|
11
|
+
* Extracts the finetune name from a Konva Filter instance.
|
|
12
|
+
*/
|
|
13
|
+
export declare const finetuneToString: (finetune: Filter) => string;
|
|
14
|
+
/**
|
|
15
|
+
* Converts an array of Filter instances to an array of filter name strings.
|
|
16
|
+
*/
|
|
17
|
+
export declare const finetunesToStrings: (finetunes: Filter[]) => string[];
|
|
18
|
+
/**
|
|
19
|
+
* Serializes annotations by converting HTMLImageElement to base64 strings.
|
|
20
|
+
*/
|
|
21
|
+
export declare const serializeAnnotations: (annotations: AnnotationsMap) => AnnotationsMap;
|
|
22
|
+
/**
|
|
23
|
+
* Main serialization function: converts runtime AppState to serializable ImageDesignState.
|
|
24
|
+
* Replaces manual mutation in use-transformed-img-data.ts.
|
|
25
|
+
*/
|
|
26
|
+
export declare const serializeDesignState: (state: AppState, includeShownImageDimensions?: boolean) => ImageDesignState;
|
|
27
|
+
//# sourceMappingURL=serialize-design-state.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"serialize-design-state.d.ts","sourceRoot":"","sources":["../../src/utils/serialize-design-state.ts"],"names":[],"mappings":"AAAA,4BAA4B;AAC5B,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC,4BAA4B;AAC5B,OAAO,EAAE,cAAc,EAAqB,MAAM,mBAAmB,CAAC;AACtE,OAAO,EAAE,QAAQ,EAAE,gBAAgB,EAAe,MAAM,aAAa,CAAC;AAGtE;;GAEG;AACH,eAAO,MAAM,cAAc,GACzB,QAAQ,MAAM,GAAG,IAAI,GAAG,SAAS,KAChC,MAAM,GAAG,SAKX,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,gBAAgB,GAAI,UAAU,MAAM,KAAG,MAGnD,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,kBAAkB,GAAI,WAAW,MAAM,EAAE,KAAG,MAAM,EAE9D,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,oBAAoB,GAC/B,aAAa,cAAc,KAC1B,cAsCF,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,oBAAoB,GAC/B,OAAO,QAAQ,EACf,8BAA6B,OAAe,KAC3C,gBA+BF,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import _defineProperty from"@babel/runtime/helpers/defineProperty";function ownKeys(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function _objectSpread(a){for(var b,c=1;c<arguments.length;c++)b=null==arguments[c]?{}:arguments[c],c%2?ownKeys(Object(b),!0).forEach(function(c){_defineProperty(a,c,b[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):ownKeys(Object(b)).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))});return a}import{isImageAnnotation}from"types/annotations";import imageToBase64 from"./image-to-base64";export var filterToString=function(a){if(a){var b=a;return b.filterName||b.name}};export var finetuneToString=function(a){var b=a;return b.finetuneName||b.name||""};export var finetunesToStrings=function(a){return a.map(finetuneToString).filter(Boolean)};export var serializeAnnotations=function(a){var b={};return Object.keys(a).forEach(function(c){var d=a[c];if(isImageAnnotation(d)&&d.image){var e="string"==typeof d.image?d.image:d.image.src;b[c]=d.image instanceof HTMLImageElement?e&&e.startsWith("blob:")?_objectSpread(_objectSpread({},d),{},{image:imageToBase64(d.image)}):_objectSpread(_objectSpread({},d),{},{image:e}):d}else b[c]=d}),b};export var serializeDesignState=function(a){var b=!!(1<arguments.length&&void 0!==arguments[1])&&arguments[1],c={imgSrc:a.imgSrc,finetunes:finetunesToStrings(a.finetunes),finetunesProps:a.finetunesProps,filter:filterToString(a.filter),adjustments:a.adjustments,annotations:serializeAnnotations(a.annotations),resize:a.resize};return b&&(c.shownImageDimensions={width:a.shownImageDimensions.width,height:a.shownImageDimensions.height,scaledBy:a.shownImageDimensions.scaledBy}),c};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"to-precised-float.d.ts","sourceRoot":"","sources":["../../src/utils/to-precised-float.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,eAAe,GAAI,QAAQ,MAAM,EAAE,YAAW,MAAU,KAAG,MACJ,CAAC;AAE9D,eAAe,eAAe,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"translator.d.ts","sourceRoot":"","sources":["../../src/utils/translator.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,kBAAkB,GAC7B,kBAAiB,MAAM,CAAC,MAAM,EAAE,MAAM,CAAM,EAC5C,WAAU,MAAa,KACtB,MAAM,CAAC,MAAM,EAAE,MAAM,CAKrB,CAAC;AAEJ,eAAO,MAAM,SAAS,GAAI,KAAK,MAAM,KAAG,MACC,CAAC"}
|
package/lib/utils/translator.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import _defineProperty from"@babel/runtime/helpers/defineProperty";function ownKeys(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function _objectSpread(a){for(var b,c=1;c<arguments.length;c++)b=null==arguments[c]?{}:arguments[c],c%2?ownKeys(Object(b),!0).forEach(function(c){_defineProperty(a,c,b[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):ownKeys(Object(b)).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))});return a}import defaultTranslations from"context/default-translations";
|
|
1
|
+
import _defineProperty from"@babel/runtime/helpers/defineProperty";function ownKeys(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function _objectSpread(a){for(var b,c=1;c<arguments.length;c++)b=null==arguments[c]?{}:arguments[c],c%2?ownKeys(Object(b),!0).forEach(function(c){_defineProperty(a,c,b[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):ownKeys(Object(b)).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))});return a}import defaultTranslations from"context/default-translations";var customTranslations={},activatedTranslations=_objectSpread({},defaultTranslations);export var updateTranslations=function(){var a=0<arguments.length&&arguments[0]!==void 0?arguments[0]:{},b=1<arguments.length&&arguments[1]!==void 0?arguments[1]:"en";return Object.assign(activatedTranslations,customTranslations[null===b||void 0===b?void 0:b.toLowerCase()]||{},a)};export var translate=function(a){return activatedTranslations[a]||a||""};
|
package/package.json
CHANGED
|
@@ -1,61 +1,63 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@solostylist/image-editor",
|
|
3
|
-
"publishConfig": {
|
|
4
|
-
"access": "public"
|
|
5
|
-
},
|
|
6
|
-
"version": "1.0.
|
|
7
|
-
"license": "MIT",
|
|
8
|
-
"author": "Lê Đặng Trường Đạt",
|
|
9
|
-
"main": "./lib/index.js",
|
|
10
|
-
"types": "./lib/index.d.ts",
|
|
11
|
-
"repository": {
|
|
12
|
-
"type": "git",
|
|
13
|
-
"url": "https://github.com/ledangtruongdatdnvn/solostylist-image-editor"
|
|
14
|
-
},
|
|
15
|
-
"keywords": [
|
|
16
|
-
"Image editing react component",
|
|
17
|
-
"React Image Editor",
|
|
18
|
-
"image editor",
|
|
19
|
-
"solostylist image editor",
|
|
20
|
-
"edit image",
|
|
21
|
-
"modify image",
|
|
22
|
-
"update image",
|
|
23
|
-
"finetune",
|
|
24
|
-
"filters",
|
|
25
|
-
"weatermark",
|
|
26
|
-
"resize",
|
|
27
|
-
"annotate"
|
|
28
|
-
],
|
|
29
|
-
"files": [
|
|
30
|
-
"lib"
|
|
31
|
-
],
|
|
32
|
-
"dependencies": {
|
|
33
|
-
"@babel/runtime": "^7.28.6",
|
|
34
|
-
"@emotion/cache": "^11.14.0",
|
|
35
|
-
"@emotion/react": "^11.14.0",
|
|
36
|
-
"@emotion/styled": "^11.14.1",
|
|
37
|
-
"@fontsource/outfit": "^5.2.8",
|
|
38
|
-
"@mui/icons-material": "^7.3.7",
|
|
39
|
-
"@mui/lab": "^7.0.1-beta.21",
|
|
40
|
-
"@mui/material": "^7.3.7",
|
|
41
|
-
"@mui/system": "^7.3.7",
|
|
42
|
-
"@mui/utils": "^7.3.7",
|
|
43
|
-
"@solostylist/ui-kit": "^1.0.195",
|
|
44
|
-
"dayjs": "^1.11.19",
|
|
45
|
-
"framer-motion": "^12.34.0",
|
|
46
|
-
"konva": "10.2.0",
|
|
47
|
-
"overlayscrollbars": "^2.14.0",
|
|
48
|
-
"overlayscrollbars-react": "^0.5.6",
|
|
49
|
-
"react-colorful": "^5.6.1",
|
|
50
|
-
"uuid": "^13.0.0"
|
|
51
|
-
},
|
|
52
|
-
"peerDependencies": {
|
|
53
|
-
"react": ">=17.0.0",
|
|
54
|
-
"react-dom": ">=17.0.0",
|
|
55
|
-
"react-konva": ">=17.0.0"
|
|
56
|
-
},
|
|
57
|
-
"scripts": {
|
|
58
|
-
"build:
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@solostylist/image-editor",
|
|
3
|
+
"publishConfig": {
|
|
4
|
+
"access": "public"
|
|
5
|
+
},
|
|
6
|
+
"version": "1.0.2",
|
|
7
|
+
"license": "MIT",
|
|
8
|
+
"author": "Lê Đặng Trường Đạt",
|
|
9
|
+
"main": "./lib/index.js",
|
|
10
|
+
"types": "./lib/index.d.ts",
|
|
11
|
+
"repository": {
|
|
12
|
+
"type": "git",
|
|
13
|
+
"url": "https://github.com/ledangtruongdatdnvn/solostylist-image-editor"
|
|
14
|
+
},
|
|
15
|
+
"keywords": [
|
|
16
|
+
"Image editing react component",
|
|
17
|
+
"React Image Editor",
|
|
18
|
+
"image editor",
|
|
19
|
+
"solostylist image editor",
|
|
20
|
+
"edit image",
|
|
21
|
+
"modify image",
|
|
22
|
+
"update image",
|
|
23
|
+
"finetune",
|
|
24
|
+
"filters",
|
|
25
|
+
"weatermark",
|
|
26
|
+
"resize",
|
|
27
|
+
"annotate"
|
|
28
|
+
],
|
|
29
|
+
"files": [
|
|
30
|
+
"lib"
|
|
31
|
+
],
|
|
32
|
+
"dependencies": {
|
|
33
|
+
"@babel/runtime": "^7.28.6",
|
|
34
|
+
"@emotion/cache": "^11.14.0",
|
|
35
|
+
"@emotion/react": "^11.14.0",
|
|
36
|
+
"@emotion/styled": "^11.14.1",
|
|
37
|
+
"@fontsource/outfit": "^5.2.8",
|
|
38
|
+
"@mui/icons-material": "^7.3.7",
|
|
39
|
+
"@mui/lab": "^7.0.1-beta.21",
|
|
40
|
+
"@mui/material": "^7.3.7",
|
|
41
|
+
"@mui/system": "^7.3.7",
|
|
42
|
+
"@mui/utils": "^7.3.7",
|
|
43
|
+
"@solostylist/ui-kit": "^1.0.195",
|
|
44
|
+
"dayjs": "^1.11.19",
|
|
45
|
+
"framer-motion": "^12.34.0",
|
|
46
|
+
"konva": "10.2.0",
|
|
47
|
+
"overlayscrollbars": "^2.14.0",
|
|
48
|
+
"overlayscrollbars-react": "^0.5.6",
|
|
49
|
+
"react-colorful": "^5.6.1",
|
|
50
|
+
"uuid": "^13.0.0"
|
|
51
|
+
},
|
|
52
|
+
"peerDependencies": {
|
|
53
|
+
"react": ">=17.0.0",
|
|
54
|
+
"react-dom": ">=17.0.0",
|
|
55
|
+
"react-konva": ">=17.0.0"
|
|
56
|
+
},
|
|
57
|
+
"scripts": {
|
|
58
|
+
"build:babel": "cross-env BABEL_ENV=production NODE_ENV=production babel src -d lib --config-file ../../babel.config.json --extensions '.ts,.tsx' --ignore '**/*.d.ts' --copy-files -D",
|
|
59
|
+
"build:types": "tsc --project tsconfig.build.json",
|
|
60
|
+
"build:lib": "rimraf lib && npm run build:babel && npm run build:types"
|
|
61
|
+
},
|
|
62
|
+
"gitHead": "eb3c52c580ba7169cbfe3a226748fa9b4ddd0d30"
|
|
63
|
+
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{SFlexBox}from"@solostylist/ui-kit/core";var CropPresetItem=function(a){var b=a.titleKey,c=a.description,d=a.ratio,f=a.onClick,g=a.Icon,h=a.isActive,i=a.isAccordion,j=a.width,k=a.height,l=a.t,m=a.disableManualResize,n=a.noEffect;return React.createElement(SFlexBox,{active:h,onClick:function(a){return f(a,d,{ratioTitleKey:b,width:j,height:k,disableManualResize:void 0!==m&&m,noEffect:void 0!==n&&n})},isAccordion:void 0!==i&&i,sx:{display:"flex",gap:2,justifyContent:"flex-start",alignItems:"center",paddingX:2,paddingY:1,"&:hover":{cursor:"pointer",backgroundColor:"action.hover"}}},g&&("string"==typeof g?React.createElement("span",{dangerouslySetInnerHTML:{__html:g}}):React.createElement(g,null)),l(b)," ",c&&"(".concat(c,")"))};export default CropPresetItem;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import{useMemo}from"react";import{Typography}from"@mui/material";import Menu from"@mui/material/Menu";import{SET_CROP,SET_RESIZE,ZOOM_CANVAS}from"actions";import{useStore}from"hooks";import{DEFAULT_ZOOM_FACTOR,ORIGINAL_CROP,TOOLS_IDS}from"utils/constants";import getZoomFitFactor from"utils/get-zoom-fit-factor";import toPrecisedFloat from"utils/to-precised-float";import CropPresetItem from"./crop-preset-item";import{DEFAULT_CROP_PRESETS}from"./crop.constants";var CropPresetsOption=function(a){var b=a.anchorEl,c=void 0===b?null:b,d=a.onClose,e=useStore(),f=e.dispatch,g=e.t,h=e.adjustments,i=void 0===h?{}:h,j=i.crop,k=void 0===j?{}:j,l=k.ratio,m=k.ratioTitleKey,n=e.shownImageDimensions,o=e.config,p=o[TOOLS_IDS.CROP],q=useMemo(function(){var a=p||{},b=a.presetsItems,c=void 0===b?[]:b,d=a.lockCropAreaAt,e=d?DEFAULT_CROP_PRESETS.filter(function(a){var b;return!(null!==(b=a.hide)&&void 0!==b&&b.call(a,{lockCropAreaAt:d}))}):DEFAULT_CROP_PRESETS;return[].concat(_toConsumableArray(e),_toConsumableArray(c))},[p]),r=function(a,b,c){a.stopPropagation();var e={ratio:b,ratioTitleKey:c.ratioTitleKey,noEffect:c.noEffect};if(f({type:SET_CROP,payload:e}),null!==p&&void 0!==p&&p.autoResize){var g,h;f({type:SET_RESIZE,payload:{width:c.width,height:c.height,manualChangeDisabled:c.disableManualResize}}),f({type:ZOOM_CANVAS,payload:{factor:(null!==(g=c.width)&&void 0!==g?g:0)>n.width||(null!==(h=c.height)&&void 0!==h?h:0)>n.height?getZoomFitFactor(n,c):DEFAULT_ZOOM_FACTOR}})}d()};return React.createElement(React.Fragment,null,React.createElement(Typography,null,g(m||"cropTool")),React.createElement(Menu,{anchorEl:c,onClose:d,open:!!c,anchorOrigin:{vertical:"top",horizontal:"center"},transformOrigin:{vertical:"bottom",horizontal:"center"}},q.map(function(a){var b=a.titleKey,c=a.descriptionKey,d=a.ratio,e=a.width,f=a.height,h=a.icon,i=a.disableManualResize,j=a.noEffect;return React.createElement(CropPresetItem,{key:d,ratio:null!==d&&void 0!==d?d:toPrecisedFloat((null!==e&&void 0!==e?e:0)/(null!==f&&void 0!==f?f:1)),titleKey:b,t:g,description:g(null!==c&&void 0!==c?c:""),Icon:h,isActive:(l||ORIGINAL_CROP)===(null!==d&&void 0!==d?d:toPrecisedFloat((null!==e&&void 0!==e?e:0)/(null!==f&&void 0!==f?f:1))),width:e,height:f,onClick:r,disableManualResize:i,noEffect:j})})))};export default CropPresetsOption;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import _defineProperty from"@babel/runtime/helpers/defineProperty";function ownKeys(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function _objectSpread(a){for(var b,c=1;c<arguments.length;c++)b=null==arguments[c]?{}:arguments[c],c%2?ownKeys(Object(b),!0).forEach(function(c){_defineProperty(a,c,b[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):ownKeys(Object(b)).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))});return a}import{SFlexBox}from"@solostylist/ui-kit/core";var ToolsBarItemOptionsWrapper=function(a){var b=a.children,c=a.isPhoneScreen;return React.createElement(SFlexBox,{sx:_objectSpread({position:"relative",width:"100%",transition:"max-height 100ms ease-in-out",justifyContent:"center",alignItems:"center",gap:3,maxHeight:b?"56px":0,mb:b?1:0,mx:"auto"},void 0!==c&&c&&{maxHeight:"unset",flexDirection:"column",px:1.5,pb:1,gap:1,m:0})},b)};export default ToolsBarItemOptionsWrapper;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import _objectWithoutProperties from"@babel/runtime/helpers/objectWithoutProperties";import _defineProperty from"@babel/runtime/helpers/defineProperty";import _slicedToArray from"@babel/runtime/helpers/slicedToArray";var _excluded=["cropX2","cropY2","crop","watermark"];function ownKeys(a,b){var c=Object.keys(a);if(Object.getOwnPropertySymbols){var d=Object.getOwnPropertySymbols(a);b&&(d=d.filter(function(b){return Object.getOwnPropertyDescriptor(a,b).enumerable})),c.push.apply(c,d)}return c}function _objectSpread(a){for(var b,c=1;c<arguments.length;c++)b=null==arguments[c]?{}:arguments[c],c%2?ownKeys(Object(b),!0).forEach(function(c){_defineProperty(a,c,b[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(a,Object.getOwnPropertyDescriptors(b)):ownKeys(Object(b)).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(b,c))});return a}import Konva from"konva";import{CLOUDIMG_TO_EDITOR_POSITIONS,ELLIPSE_CROP,TOOLS_IDS,WATERMARK_ANNOTATION_ID}from"./constants";import deepMerge from"./deep-merge";import mapNumber from"./map-number";import{finetuneNameToParamInfo}from"./operations-to-cloudimage-url";var propertyToOperation=function(a,b){var c=2<arguments.length&&arguments[2]!==void 0?arguments[2]:{},d=3<arguments.length&&arguments[3]!==void 0?arguments[3]:{},e=CLOUDIMG_TO_EDITOR_POSITIONS[b];switch(a){case"wat_text":return{watermark:{text:b.replaceAll("+"," ")}};case"wat_font":return{watermark:{fontFamily:b}};case"wat_color":return{watermark:{fill:"#".concat(b)}};case"wat_fontsize":return{watermark:{fontSize:parseFloat(b)}};case"wat_opacity":return{watermark:{opacity:parseFloat(b)}};case"wat_pos":{var f=b.split(","),g=_slicedToArray(f,2),h=g[0],i=g[1];return{watermark:{x:parseFloat(h)/100*(c.width||0),y:parseFloat(i)/100*(c.height||0)}}}case"wat_url":return{watermark:{image:decodeURIComponent(b)}};case"wat_scale":{var j=b.split(","),k=_slicedToArray(j,2),l=k[0],m=k[1];return{watermark:{width:parseFloat(l)/100*(c.width||0),height:parseFloat(m)/100*(c.height||0)}}}case"tl_px":{var n=b.split(","),o=_slicedToArray(n,2),p=o[0],q=o[1];return{crop:{x:mapNumber(parseFloat(p),0,d.width||0,0,c.width||0),y:mapNumber(parseFloat(q),0,d.height||0,0,c.height||0)}}}case"br_px":{var r=b.split(","),s=_slicedToArray(r,2),t=s[0],u=s[1];return{cropX2:mapNumber(parseFloat(t),0,d.width||0,0,c.width||0),cropY2:mapNumber(parseFloat(u),0,d.height||0,0,c.height||0)}}case"round":return{crop:{ratio:ELLIPSE_CROP}};case"gravity":return{crop:e?{lockCropAreaAt:e,width:null,height:null}:{noEffect:!0,ratio:b,ratioTitleKey:b,width:null,height:null}};case"aspect_ratio":return{crop:{ratio:+b}};case"w":return{resize:{width:parseFloat(b)}};case"h":return{resize:{height:parseFloat(b)}};case"r":return{adjustments:{rotation:-parseInt(b,10)}};case"flip":case"mirror":return{adjustments:{isFlippedX:b.includes("x")||b.includes("h"),isFlippedY:b.includes("y")||b.includes("v")}};default:{var v;if(Object.keys(finetuneNameToParamInfo).forEach(function(b){finetuneNameToParamInfo[b].cloudimage.name===a.toLowerCase()&&(v=b)}),!v)return null;var w=finetuneNameToParamInfo[v],x=w.cloudimage,y=w.internal;return{finetunes:[Konva.Filters[v]],finetunesProps:_defineProperty({},y.propName,mapNumber(parseFloat(b),x.min,x.max,y.min,y.max))}}}},cloudimageQueryToDesignState=function(a,b,c){if(!a)return null;var d=a.split("&"),e={};d.forEach(function(a){var d=a.split("="),f=_slicedToArray(d,2),g=f[0],h=f[1],i=propertyToOperation(g,h,b,c);i&&(e=deepMerge(e,i,!0))});var f=e,g=f.cropX2,h=f.cropY2,i=f.crop,j=f.watermark,k=_objectWithoutProperties(f,_excluded),l=_objectSpread(_objectSpread(_objectSpread({},k),g&&h&&i||null!==i&&void 0!==i&&i.noEffect||null!==i&&void 0!==i&&i.lockCropAreaAt?{adjustments:_objectSpread(_objectSpread({},k.adjustments),{},{crop:_objectSpread({width:(g||0)-i.x,height:(h||0)-i.y},i)})}:{}),{},{annotations:_objectSpread({},j?_defineProperty({},WATERMARK_ANNOTATION_ID,_objectSpread(_objectSpread({},j),{},{x:((null===i||void 0===i?void 0:i.x)||0)+(j.x||0),y:((null===i||void 0===i?void 0:i.y)||0)+(j.y||0),id:WATERMARK_ANNOTATION_ID,name:j.text?TOOLS_IDS.TEXT:TOOLS_IDS.IMAGE},j.text?{width:j.text.length*j.fontSize,height:j.fontSize}:{})):{})});return l};export default cloudimageQueryToDesignState;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import sha1 from"./sha1";var encodeBase64=function(a){return btoa(a).replace(/=*$/g,"")},getSha1=function(a,b){return sha1(a).slice(0,b)},getSealingParams=function(a,b,c,d){var e=encodeBase64(a),f=getSha1(b+e+(c||""),d);return[f?"ci_seal=".concat(f):"",e?"ci_eqs=".concat(e):""].filter(function(a){return a}).join("&")},getImageSealingParams=function(a,b,c){var d=b||{},e=d.salt,f=d.charCount,g=d.includeParams,h=void 0===g?[]:g,i=!h||0===(null===h||void 0===h?void 0:h.length),j="",k=[],l=[];a.split("&").forEach(function(a){var b=a.split("="),c=_slicedToArray(b,1),d=c[0];-1<(null===h||void 0===h?void 0:h.indexOf(d))||i?k.push(a):l.push(a)}),0<l.length&&(j=l.join("&"));var m=getSealingParams(k.join("&"),c,e,f);return[m,j].filter(function(a){return a}).join("&")};export default getImageSealingParams;
|