@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
|
@@ -1 +1 @@
|
|
|
1
|
-
import{FlipOutlined}from"@mui/icons-material";import{useCallback,useMemo}from"react";import{TOGGLE_FLIP}from"actions";import ToolsBarItemButton from"components/tools-bar/tools-bar-item-button";import{useStore}from"hooks";import{FLIP_DIRECTIONS,TOOLS_IDS}from"utils/constants";var FlipY=function(a){var b=a.selectTool,c=a.isSelected,d=a.t,e=useStore(),f=e.dispatch,g=e.adjustments.isFlippedY,h=
|
|
1
|
+
import{FlipOutlined}from"@mui/icons-material";import{useCallback,useMemo}from"react";import{TOGGLE_FLIP}from"actions";import ToolsBarItemButton from"components/tools-bar/tools-bar-item-button";import{useStore}from"hooks";import{FLIP_DIRECTIONS,TOOLS_IDS}from"utils/constants";var FlipY=function(a){var b=a.selectTool,c=a.isSelected,d=a.t,e=useStore(),f=e.dispatch,g=e.adjustments.isFlippedY,h=useMemo(function(){return g?d("unFlipY"):d("flipY")},[g,d]),i=useMemo(function(){return{sx:g?{transform:"rotate(90deg)"}:{transform:"rotate(270deg)"}}},[g]),j=useCallback(function(){f({type:TOGGLE_FLIP,payload:{direction:FLIP_DIRECTIONS.Y}})},[]),k=useCallback(function(a){a&&b(a),j()},[]);return React.createElement(ToolsBarItemButton,{id:TOOLS_IDS.FLIP_Y,label:h,Icon:FlipOutlined,onClick:k,isSelected:void 0!==c&&c,slotProps:{icon:i}})};export default FlipY;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/flip/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,UAAU,CAAC;AAE5C,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,UAAU,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface HSVProps {
|
|
2
|
+
selectTool: () => void;
|
|
3
|
+
isSelected?: boolean;
|
|
4
|
+
t: (key: string) => string;
|
|
5
|
+
}
|
|
6
|
+
declare const HSV: ({ selectTool, isSelected, t }: HSVProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default HSV;
|
|
8
|
+
//# sourceMappingURL=hsv.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hsv.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/hsv/hsv.tsx"],"names":[],"mappings":"AAOA,UAAU,QAAQ;IAChB,UAAU,EAAE,MAAM,IAAI,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,GAAG,GAAI,+BAAuC,QAAQ,4CAU3D,CAAC;AAEF,eAAe,GAAG,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hsvoptions.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/hsv/hsvoptions.tsx"],"names":[],"mappings":"AAoBA,UAAU,eAAe;IACvB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,UAAU,GAAI,OAAO,eAAe,4CA0CzC,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/hsv/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,GAAG,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,cAAc,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface ImageButtonProps {
|
|
2
|
+
selectTool: () => void;
|
|
3
|
+
isSelected?: boolean;
|
|
4
|
+
t: (key: string) => string;
|
|
5
|
+
}
|
|
6
|
+
declare const ImageButton: ({ selectTool, isSelected, t, }: ImageButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default ImageButton;
|
|
8
|
+
//# sourceMappingURL=image-button.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"image-button.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/image/image-button.tsx"],"names":[],"mappings":"AAOA,UAAU,gBAAgB;IACxB,UAAU,EAAE,MAAM,IAAI,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,WAAW,GAAI,gCAIlB,gBAAgB,4CAUlB,CAAC;AAEF,eAAe,WAAW,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/** External Dependencies */
|
|
2
|
+
import { Annotation, ImageAnnotation } from 'types/annotations';
|
|
3
|
+
interface ImageControlsProps {
|
|
4
|
+
image: ImageAnnotation | Partial<ImageAnnotation> | (ImageAnnotation & {
|
|
5
|
+
shouldSave?: boolean;
|
|
6
|
+
neverSave?: boolean;
|
|
7
|
+
});
|
|
8
|
+
saveImage: (updates: Partial<Annotation>) => void;
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
}
|
|
11
|
+
declare const ImageControls: ({ image, saveImage, children }: ImageControlsProps) => import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export default ImageControls;
|
|
13
|
+
//# sourceMappingURL=image-controls.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"image-controls.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/image/image-controls.tsx"],"names":[],"mappings":"AAAA,4BAA4B;AAI5B,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAEhE,UAAU,kBAAkB;IAE1B,KAAK,EACD,eAAe,GACf,OAAO,CAAC,eAAe,CAAC,GACxB,CAAC,eAAe,GAAG;QAAE,UAAU,CAAC,EAAE,OAAO,CAAC;QAAC,SAAS,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC,CAAC;IACtE,SAAS,EAAE,CAAC,OAAO,EAAE,OAAO,CAAC,UAAU,CAAC,KAAK,IAAI,CAAC;IAClD,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC5B;AAED,QAAA,MAAM,aAAa,GAAI,gCAAgC,kBAAkB,4CAUxE,CAAC;AAEF,eAAe,aAAa,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import AnnotationOptions from"components/common/annotation-options";var ImageControls=function(a){var b=a.image,c=a.saveImage,d=a.children
|
|
1
|
+
import AnnotationOptions from"components/common/annotation-options";var ImageControls=function(a){var b=a.image,c=a.saveImage,d=a.children;return React.createElement(AnnotationOptions,{annotation:b,updateAnnotation:c,hideFillOption:!0},d)};export default ImageControls;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"image-options.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/image/image-options.tsx"],"names":[],"mappings":"AAgBA,QAAA,MAAM,YAAY,+CAuLjB,CAAC;AAEF,eAAe,YAAY,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import{useMemo,useRef,useState}from"react";import{CollectionsOutlined,FileUploadOutlined}from"@mui/icons-material";import{useAnnotation,usePopover,useStore}from"hooks";import{FEEDBACK_STATUSES,TOOLS_IDS}from"utils/constants";import{SET_FEEDBACK}from"actions";import HiddenUploadInput from"components/common/hidden-upload-input";import ButtonWithMenu from"components/common/button-with-menu";import ImageControls from"./image-controls";import ImagesGallery from"./images-gallery";var ADDED_IMG_SPACING_PERCENT=.15,ImageOptions=function(){var a=useState(),b=_slicedToArray(a,2),c=b[0],d=b[1],e=usePopover(),f=useRef(null),g=useRef(null),h=useStore(),i=h.shownImageDimensions,j=h.dispatch,k=h.adjustments.crop,l=void 0===k?{}:k,m=h.t,n=h.config,o=void 0===n?{}:n,p=o[TOOLS_IDS.IMAGE],q=!p.disableUpload,r=Array.isArray(p.gallery)&&0<p.gallery.length,s=useAnnotation({name:TOOLS_IDS.IMAGE,opacity:1},!1),t=_slicedToArray(s,3),u=t[0],v=t[1],w=t[2],x=useRef(0),y=function(a){var b=l.width||i.width,c=l.height||i.height,d=l.x||0,e=l.y||0,f=Math.min(1,b/(a.width+a.width*ADDED_IMG_SPACING_PERCENT),c/(a.height+a.height*ADDED_IMG_SPACING_PERCENT));w({image:a,x:d+b/2-a.width*f/2,y:e+c/2-a.height*f/2,width:a.width*f,height:a.height*f})},z=function(a){x.current+=1,x.current===a&&(x.current=0,d(!1))},A=function(a){j({type:SET_FEEDBACK,payload:{feedback:{message:a,status:FEEDBACK_STATUSES.WARNING}}})},B=function(){f.current&&f.current.click()},C=function(){e.handleOpen({currentTarget:g.current})},D=useMemo(function(){return[q&&{key:"add-by-upload-image",label:c?m("importing"):m("uploadImage"),icon:FileUploadOutlined,onClick:c?void 0:B},r&&{key:"add-from-gallery",label:m("fromGallery"),icon:CollectionsOutlined,onClick:C}]},[p,c,m]);return React.createElement(ImageControls,{image:u,saveImage:v
|
|
1
|
+
import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import{useMemo,useRef,useState}from"react";import{CollectionsOutlined,FileUploadOutlined}from"@mui/icons-material";import{useAnnotation,usePopover,useStore}from"hooks";import{FEEDBACK_STATUSES,TOOLS_IDS}from"utils/constants";import{SET_FEEDBACK}from"actions";import HiddenUploadInput from"components/common/hidden-upload-input";import ButtonWithMenu from"components/common/button-with-menu";import ImageControls from"./image-controls";import ImagesGallery from"./images-gallery";var ADDED_IMG_SPACING_PERCENT=.15,ImageOptions=function(){var a=useState(),b=_slicedToArray(a,2),c=b[0],d=b[1],e=usePopover(),f=useRef(null),g=useRef(null),h=useStore(),i=h.shownImageDimensions,j=h.dispatch,k=h.adjustments.crop,l=void 0===k?{}:k,m=h.t,n=h.config,o=void 0===n?{}:n,p=o[TOOLS_IDS.IMAGE],q=!p.disableUpload,r=Array.isArray(p.gallery)&&0<p.gallery.length,s=useAnnotation({name:TOOLS_IDS.IMAGE,opacity:1},!1),t=_slicedToArray(s,3),u=t[0],v=t[1],w=t[2],x=useRef(0),y=function(a){var b=l.width||i.width,c=l.height||i.height,d=l.x||0,e=l.y||0,f=Math.min(1,b/(a.width+a.width*ADDED_IMG_SPACING_PERCENT),c/(a.height+a.height*ADDED_IMG_SPACING_PERCENT));w({image:a,x:d+b/2-a.width*f/2,y:e+c/2-a.height*f/2,width:a.width*f,height:a.height*f})},z=function(a){x.current+=1,x.current===a&&(x.current=0,d(!1))},A=function(a){j({type:SET_FEEDBACK,payload:{feedback:{message:a,status:FEEDBACK_STATUSES.WARNING}}})},B=function(){f.current&&f.current.click()},C=function(){e.handleOpen({currentTarget:g.current})},D=useMemo(function(){return[q&&{key:"add-by-upload-image",label:c?m("importing"):m("uploadImage"),icon:FileUploadOutlined,onClick:c?void 0:B},r&&{key:"add-from-gallery",label:m("fromGallery"),icon:CollectionsOutlined,onClick:C}]},[p,c,m]);return React.createElement(ImageControls,{image:u,saveImage:v},React.createElement(ButtonWithMenu,{label:m("addImage"),menuItems:D,buttonRef:g}),q&&React.createElement(HiddenUploadInput,{ref:f,onChange:c?void 0:function(a){if(a.target.files){d(!0);var b=[],c=Array.from(a.target.files),e=c.length;if(c.forEach(function(a){if(a.type.startsWith("image/")){var c=new Image;c.onload=function(){y(c),URL.revokeObjectURL(a),z(e)},c.onerror=function(){A(m("uploadImageError")),z(e)},c.src=URL.createObjectURL(a)}else b.push(a.name),z(e)}),0<b.length){var f=1<b.length?m("areNotImages"):m("isNotImage");A("".concat(b.join(", ")," ").concat(f," ").concat(m("toBeUploaded"),"."))}}a.target.value=""},disabled:c,multiple:!0}),r&&React.createElement(ImagesGallery,{gallery:p.gallery,onSelect:function(a){d(!0);var b=new Image;b.onload=function(){y(b),z(1)},b.onerror=function(){A(m("uploadImageError")),z(1)},b.crossOrigin="Anonymous",b.src=a},onClose:function(){e.handleClose()},anchorEl:e.anchorEl}))};export default ImageOptions;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/** External Dependencies */
|
|
2
|
+
interface GalleryItem {
|
|
3
|
+
originalUrl: string;
|
|
4
|
+
previewUrl: string;
|
|
5
|
+
}
|
|
6
|
+
interface ImagesGalleryProps {
|
|
7
|
+
gallery?: GalleryItem[];
|
|
8
|
+
anchorEl?: HTMLElement | null;
|
|
9
|
+
onClose: () => void;
|
|
10
|
+
onSelect: (originalUrl: string) => void;
|
|
11
|
+
}
|
|
12
|
+
declare const ImagesGallery: ({ gallery, anchorEl, onClose, onSelect, }: ImagesGalleryProps) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export default ImagesGallery;
|
|
14
|
+
//# sourceMappingURL=images-gallery.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"images-gallery.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/image/images-gallery.tsx"],"names":[],"mappings":"AAAA,4BAA4B;AAO5B,UAAU,WAAW;IACnB,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,UAAU,kBAAkB;IAC1B,OAAO,CAAC,EAAE,WAAW,EAAE,CAAC;IACxB,QAAQ,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;IAC9B,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,CAAC,WAAW,EAAE,MAAM,KAAK,IAAI,CAAC;CACzC;AAED,QAAA,MAAM,aAAa,GAAI,2CAKpB,kBAAkB,4CAwCpB,CAAC;AAEF,eAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/image/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAExD,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,iBAAiB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/line/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,eAAe,CAAC;AAEtD,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface LineButtonProps {
|
|
2
|
+
selectTool: () => void;
|
|
3
|
+
isSelected?: boolean;
|
|
4
|
+
t: (key: string) => string;
|
|
5
|
+
}
|
|
6
|
+
declare const LineButton: ({ selectTool, isSelected, t }: LineButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default LineButton;
|
|
8
|
+
//# sourceMappingURL=line-button.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"line-button.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/line/line-button.tsx"],"names":[],"mappings":"AAOA,UAAU,eAAe;IACvB,UAAU,EAAE,MAAM,IAAI,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,UAAU,GAAI,+BAAuC,eAAe,4CAUzE,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"line-options.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/line/line-options.tsx"],"names":[],"mappings":"AAAA,4BAA4B;AAQ5B,QAAA,MAAM,WAAW,+CAahB,CAAC;AAEF,eAAe,WAAW,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import{useAnnotation}from"hooks";import{TOOLS_IDS}from"utils/constants";import AnnotationOptions from"components/common/annotation-options";var LineOptions=function(
|
|
1
|
+
import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import{useAnnotation}from"hooks";import{TOOLS_IDS}from"utils/constants";import AnnotationOptions from"components/common/annotation-options";var LineOptions=function(){var a=useAnnotation({name:TOOLS_IDS.LINE}),b=_slicedToArray(a,2),c=b[0],d=b[1];return React.createElement(AnnotationOptions,{annotation:c,updateAnnotation:d,hidePositionField:!0,hideFillOption:!0})};export default LineOptions;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/pen/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,cAAc,CAAC;AAEpD,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,eAAe,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface PenButtonProps {
|
|
2
|
+
selectTool: () => void;
|
|
3
|
+
isSelected?: boolean;
|
|
4
|
+
t: (key: string) => string;
|
|
5
|
+
}
|
|
6
|
+
declare const PenButton: ({ selectTool, isSelected, t }: PenButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default PenButton;
|
|
8
|
+
//# sourceMappingURL=pen-button.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pen-button.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/pen/pen-button.tsx"],"names":[],"mappings":"AAOA,UAAU,cAAc;IACtB,UAAU,EAAE,MAAM,IAAI,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,SAAS,GAAI,+BAAuC,cAAc,4CAUvE,CAAC;AAEF,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pen-options.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/pen/pen-options.tsx"],"names":[],"mappings":"AAuBA,QAAA,MAAM,UAAU,+CA6Hf,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import _defineProperty from"@babel/runtime/helpers/defineProperty";import _slicedToArray from"@babel/runtime/helpers/slicedToArray";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{useCallback,useEffect,useRef}from"react";import{useAnnotation,useStore}from"hooks";import{TOOLS_IDS}from"utils/constants";import AnnotationOptions from"components/common/annotation-options";import getPointerOffsetPositionBoundedToObject from"utils/get-pointer-offset-position-bounded-to-object";import randomId from"utils/random-id";import{SELECT_ANNOTATION,SET_ANNOTATION}from"actions";import getElemDocumentCoords from"utils/get-elem-document-coords";var eventsOptions={passive:!0},PenOptions=function(
|
|
1
|
+
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import _defineProperty from"@babel/runtime/helpers/defineProperty";import _slicedToArray from"@babel/runtime/helpers/slicedToArray";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{useCallback,useEffect,useRef}from"react";import{useAnnotation,useStore}from"hooks";import{TOOLS_IDS}from"utils/constants";import AnnotationOptions from"components/common/annotation-options";import getPointerOffsetPositionBoundedToObject from"utils/get-pointer-offset-position-bounded-to-object";import randomId from"utils/random-id";import{SELECT_ANNOTATION,SET_ANNOTATION}from"actions";import getElemDocumentCoords from"utils/get-elem-document-coords";var eventsOptions={passive:!0},PenOptions=function(){var a=useStore(),b=a.dispatch,c=a.designLayer,d=a.previewGroup,e=a.config,f=a.t,g=useAnnotation(_objectSpread(_objectSpread(_objectSpread({},e.annotationsCommon),e[TOOLS_IDS.PEN]),{},{name:TOOLS_IDS.PEN}),!1),h=_slicedToArray(g,3),i=h[0],j=h[1],k=h[2],l=useRef(null),m=useRef({points:[],moved:!1,id:""}),n=useCallback(function(){var a=getElemDocumentCoords(l.current.content),b=getPointerOffsetPositionBoundedToObject(d,a);return[b.offsetX-(c.attrs.xPadding||0),b.offsetY-(c.attrs.yPadding||0)]},[c]),o=useCallback(function(){var a;if(!(null!==(a=m.current)&&void 0!==a&&a.moved)){var c;m.current={moved:!0,id:randomId(TOOLS_IDS.PEN),points:[].concat(_toConsumableArray((null===(c=m.current)||void 0===c?void 0:c.points)||[]),_toConsumableArray(n()))},k({id:m.current.id,name:TOOLS_IDS.PEN,points:m.current.points})}else m.current&&(m.current.points=m.current.points.concat(n()),b({type:SET_ANNOTATION,payload:{id:m.current.id,points:m.current.points,dismissHistory:!0}}))},[n]),p=useCallback(function(){var a,c;null!==(a=m.current)&&void 0!==a&&a.id&&null!==(c=e[TOOLS_IDS.PEN])&&void 0!==c&&c.selectAnnotationAfterDrawing&&b({type:SELECT_ANNOTATION,payload:{annotationId:m.current.id}}),m.current=null,l.current.off("mousemove touchmove",o),l.current.off("mouseleave touchcancel",p),document.removeEventListener("mouseup",p,eventsOptions),document.removeEventListener("touchend",p,eventsOptions),document.removeEventListener("mouseleave",p,eventsOptions),document.removeEventListener("touchcancel",p,eventsOptions)},[o]),q=useCallback(function(a){a.target.attrs.draggable||(a.evt.preventDefault(),m.current={points:n()},l.current.on("mousemove touchmove",o),l.current.on("mouseleave touchcancel",p),document.addEventListener("mouseup",p,eventsOptions),document.addEventListener("touchend",p,eventsOptions),document.addEventListener("mouseleave",p,eventsOptions),document.addEventListener("touchcancel",p,eventsOptions))},[n,o,p]);return useEffect(function(){return l.current=null===c||void 0===c?void 0:c.getStage(),l.current&&l.current.on("mousedown touchstart",q),function(){l.current&&l.current.off("mousedown touchstart",q)}},[c]),React.createElement(AnnotationOptions,{annotation:i,updateAnnotation:j,t:f,hidePositionField:!0,hideFillOption:!0})};export default PenOptions;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/polygon/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAE5D,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,mBAAmB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface PolygonButtonProps {
|
|
2
|
+
selectTool: () => void;
|
|
3
|
+
isSelected?: boolean;
|
|
4
|
+
t: (key: string) => string;
|
|
5
|
+
}
|
|
6
|
+
declare const PolygonButton: ({ selectTool, isSelected, t, }: PolygonButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default PolygonButton;
|
|
8
|
+
//# sourceMappingURL=polygon-button.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"polygon-button.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/polygon/polygon-button.tsx"],"names":[],"mappings":"AAOA,UAAU,kBAAkB;IAC1B,UAAU,EAAE,MAAM,IAAI,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,aAAa,GAAI,gCAIpB,kBAAkB,4CAUpB,CAAC;AAEF,eAAe,aAAa,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"polygon-options.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/polygon/polygon-options.tsx"],"names":[],"mappings":"AAAA,4BAA4B;AAY5B,QAAA,MAAM,cAAc,+CAcnB,CAAC;AAEF,eAAe,cAAc,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import{useAnnotation}from"hooks";import{TOOLS_IDS}from"utils/constants";import AnnotationOptions from"components/common/annotation-options";import{polygonOptionsPopupComponents,POLYGON_POPPABLE_OPTIONS}from"./polygon.constants";var PolygonOptions=function(
|
|
1
|
+
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import{useAnnotation}from"hooks";import{TOOLS_IDS}from"utils/constants";import AnnotationOptions from"components/common/annotation-options";import{polygonOptionsPopupComponents,POLYGON_POPPABLE_OPTIONS}from"./polygon.constants";var PolygonOptions=function(){var a=useAnnotation({name:TOOLS_IDS.POLYGON}),b=_slicedToArray(a,2),c=b[0],d=b[1];return React.createElement(AnnotationOptions,{morePoppableOptionsPrepended:_toConsumableArray(POLYGON_POPPABLE_OPTIONS),moreOptionsPopupComponentsObj:polygonOptionsPopupComponents,annotation:c,updateAnnotation:d,hidePositionField:!0})};export default PolygonOptions;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { PolygonAnnotation } from 'types/annotations';
|
|
2
|
+
export interface PolygonSidesFieldProps {
|
|
3
|
+
annotation: PolygonAnnotation;
|
|
4
|
+
updateAnnotation: (updates: Partial<PolygonAnnotation>) => void;
|
|
5
|
+
t: (key: string) => string;
|
|
6
|
+
}
|
|
7
|
+
declare const PolygonSidesField: ({ annotation: polygon, updateAnnotation: updatePolygon, t, }: PolygonSidesFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export default PolygonSidesField;
|
|
9
|
+
//# sourceMappingURL=polygon-sides-field.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"polygon-sides-field.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/polygon/polygon-sides-field.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAMtD,MAAM,WAAW,sBAAsB;IACrC,UAAU,EAAE,iBAAiB,CAAC;IAC9B,gBAAgB,EAAE,CAAC,OAAO,EAAE,OAAO,CAAC,iBAAiB,CAAC,KAAK,IAAI,CAAC;IAChE,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,iBAAiB,GAAI,8DAIxB,sBAAsB,4CAkBxB,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export declare const SIDES_NUMBER: "sides-number";
|
|
2
|
+
export declare const POLYGON_POPPABLE_OPTIONS: readonly [{
|
|
3
|
+
readonly titleKey: "sides";
|
|
4
|
+
readonly name: "sides-number";
|
|
5
|
+
readonly Icon: import("@mui/material/OverridableComponent").OverridableComponent<import("@mui/material").SvgIconTypeMap<{}, "svg">> & {
|
|
6
|
+
muiName: string;
|
|
7
|
+
};
|
|
8
|
+
}];
|
|
9
|
+
export declare const polygonOptionsPopupComponents: {
|
|
10
|
+
readonly "sides-number": ({ annotation: polygon, updateAnnotation: updatePolygon, t, }: import("./polygon-sides-field").PolygonSidesFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
};
|
|
12
|
+
//# sourceMappingURL=polygon.constants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"polygon.constants.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/polygon/polygon.constants.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,YAAY,EAAG,cAAuB,CAAC;AAEpD,eAAO,MAAM,wBAAwB;;;;;;EAM3B,CAAC;AAEX,eAAO,MAAM,6BAA6B;;CAEhC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/rect/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,eAAe,CAAC;AAEtD,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface RectButtonProps {
|
|
2
|
+
selectTool: () => void;
|
|
3
|
+
isSelected?: boolean;
|
|
4
|
+
t: (key: string) => string;
|
|
5
|
+
}
|
|
6
|
+
declare const RectButton: ({ selectTool, isSelected, t }: RectButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default RectButton;
|
|
8
|
+
//# sourceMappingURL=rect-button.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rect-button.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/rect/rect-button.tsx"],"names":[],"mappings":"AAOA,UAAU,eAAe;IACvB,UAAU,EAAE,MAAM,IAAI,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,UAAU,GAAI,+BAAuC,eAAe,4CAUzE,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{CropLandscapeOutlined as RectIcon}from"@mui/icons-material";import ToolsBarItemButton from"components/tools-bar/tools-bar-item-button";import{TOOLS_IDS}from"utils/constants";var RectButton=function(a){var b=a.selectTool,c=a.isSelected,d=a.t;return React.createElement(ToolsBarItemButton,{
|
|
1
|
+
import{CropLandscapeOutlined as RectIcon}from"@mui/icons-material";import ToolsBarItemButton from"components/tools-bar/tools-bar-item-button";import{TOOLS_IDS}from"utils/constants";var RectButton=function(a){var b=a.selectTool,c=a.isSelected,d=a.t;return React.createElement(ToolsBarItemButton,{id:TOOLS_IDS.RECT,label:d("rectangleTool"),Icon:RectIcon,onClick:b,isSelected:void 0!==c&&c})};export default RectButton;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { RectAnnotation } from 'types/annotations';
|
|
2
|
+
export interface RectCornerFieldProps {
|
|
3
|
+
annotation: RectAnnotation;
|
|
4
|
+
updateAnnotation: (updates: Partial<RectAnnotation>) => void;
|
|
5
|
+
t: (key: string) => string;
|
|
6
|
+
}
|
|
7
|
+
declare const RectCornerField: ({ annotation: rect, updateAnnotation: updateRect, t, }: RectCornerFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export default RectCornerField;
|
|
9
|
+
//# sourceMappingURL=rect-corner-field.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rect-corner-field.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/rect/rect-corner-field.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAMnD,MAAM,WAAW,oBAAoB;IACnC,UAAU,EAAE,cAAc,CAAC;IAC3B,gBAAgB,EAAE,CAAC,OAAO,EAAE,OAAO,CAAC,cAAc,CAAC,KAAK,IAAI,CAAC;IAC7D,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,eAAe,GAAI,wDAItB,oBAAoB,4CAmBtB,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rect-options.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/rect/rect-options.tsx"],"names":[],"mappings":"AAAA,4BAA4B;AAY5B,QAAA,MAAM,WAAW,+CAahB,CAAC;AAEF,eAAe,WAAW,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import{useAnnotation}from"hooks";import{TOOLS_IDS}from"utils/constants";import AnnotationOptions from"components/common/annotation-options";import{rectOptionsPopupComponents,RECT_POPPABLE_OPTIONS}from"./rect.constants";var RectOptions=function(
|
|
1
|
+
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import{useAnnotation}from"hooks";import{TOOLS_IDS}from"utils/constants";import AnnotationOptions from"components/common/annotation-options";import{rectOptionsPopupComponents,RECT_POPPABLE_OPTIONS}from"./rect.constants";var RectOptions=function(){var a=useAnnotation({name:TOOLS_IDS.RECT}),b=_slicedToArray(a,2),c=b[0],d=b[1];return React.createElement(AnnotationOptions,{moreOptionsPopupComponentsObj:rectOptionsPopupComponents,morePoppableOptionsPrepended:_toConsumableArray(RECT_POPPABLE_OPTIONS),annotation:c,updateAnnotation:d})};export default RectOptions;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export declare const CORNER_RADIUS: "corner-radius";
|
|
2
|
+
export declare const RECT_POPPABLE_OPTIONS: readonly [{
|
|
3
|
+
readonly titleKey: "cornerRadius";
|
|
4
|
+
readonly name: "corner-radius";
|
|
5
|
+
readonly Icon: import("@mui/material/OverridableComponent").OverridableComponent<import("@mui/material").SvgIconTypeMap<{}, "svg">> & {
|
|
6
|
+
muiName: string;
|
|
7
|
+
};
|
|
8
|
+
}];
|
|
9
|
+
export declare const rectOptionsPopupComponents: {
|
|
10
|
+
readonly "corner-radius": ({ annotation: rect, updateAnnotation: updateRect, t, }: import("./rect-corner-field").RectCornerFieldProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
};
|
|
12
|
+
//# sourceMappingURL=rect.constants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rect.constants.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/rect/rect.constants.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,aAAa,EAAG,eAAwB,CAAC;AAEtD,eAAO,MAAM,qBAAqB;;;;;;EAMxB,CAAC;AAEX,eAAO,MAAM,0BAA0B;;CAE7B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/resize/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,UAAU,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
interface CurrentSize {
|
|
2
|
+
width?: number;
|
|
3
|
+
height?: number;
|
|
4
|
+
ratioUnlocked?: boolean;
|
|
5
|
+
}
|
|
6
|
+
interface ResizeProps {
|
|
7
|
+
onChange?: (newResize: Record<string, any>) => void;
|
|
8
|
+
currentSize?: CurrentSize;
|
|
9
|
+
hideResetButton?: boolean;
|
|
10
|
+
}
|
|
11
|
+
declare const Resize: ({ onChange, currentSize, hideResetButton, }: ResizeProps) => import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export default Resize;
|
|
13
|
+
//# sourceMappingURL=resize.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resize.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/resize/resize.tsx"],"names":[],"mappings":"AAaA,UAAU,WAAW;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,UAAU,WAAW;IACnB,QAAQ,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,KAAK,IAAI,CAAC;IACpD,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B;AAED,QAAA,MAAM,MAAM,GAAI,6CAIb,WAAW,4CAqLb,CAAC;AAEF,eAAe,MAAM,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/rotate/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE1D,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,kBAAkB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface RotateButtonProps {
|
|
2
|
+
selectTool: () => void;
|
|
3
|
+
isSelected?: boolean;
|
|
4
|
+
t: (key: string) => string;
|
|
5
|
+
}
|
|
6
|
+
declare const RotateButton: ({ selectTool, isSelected, t, }: RotateButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default RotateButton;
|
|
8
|
+
//# sourceMappingURL=rotate-button.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rotate-button.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/rotate/rotate-button.tsx"],"names":[],"mappings":"AAOA,UAAU,iBAAiB;IACzB,UAAU,EAAE,MAAM,IAAI,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,YAAY,GAAI,gCAInB,iBAAiB,4CAUnB,CAAC;AAEF,eAAe,YAAY,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rotate-options.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/rotate/rotate-options.tsx"],"names":[],"mappings":"AAiBA,QAAA,MAAM,aAAa,+CAsGlB,CAAC;AAEF,eAAe,aAAa,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{RotateLeftOutlined,RotateRightOutlined,Rotate90DegreesCwOutlined}from"@mui/icons-material";import Slider from"@mui/material/Slider";import{useDebouncedCallback,usePhoneScreen,useStore}from"hooks";import{CHANGE_ROTATION,SET_RESIZE}from"actions";import restrictNumber from"utils/restrict-number";import getSizeAfterRotation from"utils/get-size-after-rotation";import{TOOLS_IDS}from"utils/constants";import ToolsBarItemButton from"components/tools-bar/tools-bar-item-button";import{SFlexBox,SIconButton}from"@solostylist/ui-kit/core";var RotateOptions=function(){var a=useStore(),b=a.dispatch,c=a.adjustments.rotation,d=void 0===c?0:c,e=a.resize,f=void 0===e?{}:e,g=a.config,h=g[TOOLS_IDS.ROTATE],i=usePhoneScreen(),j=useDebouncedCallback(function(a,c){var d=restrictNumber(c,-180,180);if(b({type:CHANGE_ROTATION,payload:{rotation:d}}),f.width&&f.height){var e=getSizeAfterRotation(f.width,f.height,d);b({type:SET_RESIZE,payload:{width:e.width,height:e.height}})}},20);return"buttons"===h.componentType?React.createElement(React.Fragment,null,React.createElement(ToolsBarItemButton,{id:TOOLS_IDS.IMAGE,label:"-".concat(h.angle,"\xB0"),Icon:RotateLeftOutlined,onClick:function(a){var b=d-h.angle;j(a,b)}}),React.createElement(ToolsBarItemButton,{id:TOOLS_IDS.IMAGE,label:"+".concat(null===h||void 0===h?void 0:h.angle,"\xB0"),Icon:RotateRightOutlined,onClick:function(a){var b=d+h.angle;j(a,b)}})):React.createElement(SFlexBox,{alignItems:"center",gap:2},React.createElement(SIconButton,{onClick:function(a){return j(a,d-90)}},React.createElement(Rotate90DegreesCwOutlined,null)),React.createElement(Slider,{
|
|
1
|
+
import{RotateLeftOutlined,RotateRightOutlined,Rotate90DegreesCwOutlined}from"@mui/icons-material";import Slider from"@mui/material/Slider";import{useDebouncedCallback,usePhoneScreen,useStore}from"hooks";import{CHANGE_ROTATION,SET_RESIZE}from"actions";import restrictNumber from"utils/restrict-number";import getSizeAfterRotation from"utils/get-size-after-rotation";import{TOOLS_IDS}from"utils/constants";import ToolsBarItemButton from"components/tools-bar/tools-bar-item-button";import{SFlexBox,SIconButton}from"@solostylist/ui-kit/core";var RotateOptions=function(){var a=useStore(),b=a.dispatch,c=a.adjustments.rotation,d=void 0===c?0:c,e=a.resize,f=void 0===e?{}:e,g=a.config,h=g[TOOLS_IDS.ROTATE],i=usePhoneScreen(),j=useDebouncedCallback(function(a,c){var d=restrictNumber(c,-180,180);if(b({type:CHANGE_ROTATION,payload:{rotation:d}}),f.width&&f.height){var e=getSizeAfterRotation(f.width,f.height,d);b({type:SET_RESIZE,payload:{width:e.width,height:e.height}})}},20);return"buttons"===h.componentType?React.createElement(React.Fragment,null,React.createElement(ToolsBarItemButton,{id:TOOLS_IDS.IMAGE,label:"-".concat(h.angle,"\xB0"),Icon:RotateLeftOutlined,onClick:function(a){var b=d-h.angle;j(a,b)}}),React.createElement(ToolsBarItemButton,{id:TOOLS_IDS.IMAGE,label:"+".concat(null===h||void 0===h?void 0:h.angle,"\xB0"),Icon:RotateRightOutlined,onClick:function(a){var b=d+h.angle;j(a,b)}})):React.createElement(SFlexBox,{alignItems:"center",gap:2},React.createElement(SIconButton,{onClick:function(a){return j(a,d-90)}},React.createElement(Rotate90DegreesCwOutlined,null)),React.createElement(Slider,{valueLabelDisplay:"auto",marks:!0,min:-180,max:180,step:i?h.angle/3:1,value:d,onChange:j,sx:{width:200,"& .MuiSlider-thumb":{width:12,height:12},"& .MuiSlider-mark":{width:4,height:4,borderRadius:"50%"}}}),React.createElement(SIconButton,{onClick:function(a){return j(a,d+90)}},React.createElement(Rotate90DegreesCwOutlined,{sx:{transform:"scaleX(-1)"}})))};export default RotateOptions;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/text/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,eAAe,CAAC;AAEtD,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface TextButtonProps {
|
|
2
|
+
selectTool: () => void;
|
|
3
|
+
isSelected?: boolean;
|
|
4
|
+
t: (key: string) => string;
|
|
5
|
+
}
|
|
6
|
+
declare const TextButton: ({ selectTool, isSelected, t }: TextButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export default TextButton;
|
|
8
|
+
//# sourceMappingURL=text-button.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text-button.d.ts","sourceRoot":"","sources":["../../../../src/components/tools/text/text-button.tsx"],"names":[],"mappings":"AAOA,UAAU,eAAe;IACvB,UAAU,EAAE,MAAM,IAAI,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,QAAA,MAAM,UAAU,GAAI,+BAAuC,eAAe,4CAUzE,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
declare function deactivateTextChange(): void;
|
|
2
|
+
declare const activateTextChange: (textNodeId: string, canvasStage: any, currentTransformer: any, finishingCallback: (textValue: string) => void, dismissingTextEditing: () => void) => void;
|
|
3
|
+
export { activateTextChange, deactivateTextChange };
|
|
4
|
+
//# sourceMappingURL=handle-text-change-area.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handle-text-change-area.d.ts","sourceRoot":"","sources":["../../../../../src/components/tools/text/text-options/handle-text-change-area.ts"],"names":[],"mappings":"AAMA,iBAAS,oBAAoB,IAAI,IAAI,CAwBpC;AAWD,QAAA,MAAM,kBAAkB,GACtB,YAAY,MAAM,EAClB,aAAa,GAAG,EAChB,oBAAoB,GAAG,EACvB,mBAAmB,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,EAC9C,uBAAuB,MAAM,IAAI,KAChC,IAyHF,CAAC;AAEF,OAAO,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/tools/text/text-options/index.tsx"],"names":[],"mappings":"AAAA,4BAA4B;AAQ5B,QAAA,MAAM,WAAW,+CAMhB,CAAC;AAEF,eAAe,WAAW,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/** External Dependencies */
|
|
2
|
+
import { TextAnnotation } from 'types/annotations';
|
|
3
|
+
interface TextAlignmentFieldsProps {
|
|
4
|
+
annotation: TextAnnotation;
|
|
5
|
+
updateAnnotation: (updates: Partial<TextAnnotation>) => void;
|
|
6
|
+
}
|
|
7
|
+
declare const TextAlignmentFields: ({ annotation: text, updateAnnotation: updateText, }: TextAlignmentFieldsProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export default TextAlignmentFields;
|
|
9
|
+
//# sourceMappingURL=text-alignment-fields.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text-alignment-fields.d.ts","sourceRoot":"","sources":["../../../../../src/components/tools/text/text-options/text-alignment-fields.tsx"],"names":[],"mappings":"AAAA,4BAA4B;AAS5B,OAAO,EAAiB,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAIlE,UAAU,wBAAwB;IAChC,UAAU,EAAE,cAAc,CAAC;IAC3B,gBAAgB,EAAE,CAAC,OAAO,EAAE,OAAO,CAAC,cAAc,CAAC,KAAK,IAAI,CAAC;CAC9D;AAED,QAAA,MAAM,mBAAmB,GAAI,qDAG1B,wBAAwB,4CA6B1B,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{FormatAlignCenterOutlined,FormatAlignLeftOutlined}from"@mui/icons-material";import{SFlexBox}from"@solostylist/ui-kit/core";import SIconButtonWrapper from"components/common/icon-wrapper";var rightAlignmentCssTransform={transform:"scaleX(-1)"},TextAlignmentFields=function(a){var b=a.annotation,c=a.updateAnnotation,d=b.align,e=function(a){c({align:a})};return React.createElement(SFlexBox,{gap:1},React.createElement(SIconButtonWrapper,{onClick:function(){return e(
|
|
1
|
+
import{FormatAlignCenterOutlined,FormatAlignLeftOutlined}from"@mui/icons-material";import{SFlexBox}from"@solostylist/ui-kit/core";import SIconButtonWrapper from"components/common/icon-wrapper";import{TextAlignment}from"types/annotations";var rightAlignmentCssTransform={transform:"scaleX(-1)"},TextAlignmentFields=function(a){var b=a.annotation,c=a.updateAnnotation,d=b.align,e=function(a){c({align:a})};return React.createElement(SFlexBox,{gap:1},React.createElement(SIconButtonWrapper,{onClick:function(){return e(TextAlignment.LEFT)},active:d===TextAlignment.LEFT},React.createElement(FormatAlignLeftOutlined,null)),React.createElement(SIconButtonWrapper,{onClick:function(){return e(TextAlignment.CENTER)},active:d===TextAlignment.CENTER},React.createElement(FormatAlignCenterOutlined,null)),React.createElement(SIconButtonWrapper,{onClick:function(){return e(TextAlignment.RIGHT)},active:d===TextAlignment.RIGHT},React.createElement(FormatAlignLeftOutlined,{style:rightAlignmentCssTransform})))};export default TextAlignmentFields;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { TextAnnotation } from 'types/annotations';
|
|
2
|
+
interface TextControlsProps {
|
|
3
|
+
text: TextAnnotation & {
|
|
4
|
+
shouldSave?: boolean;
|
|
5
|
+
neverSave?: boolean;
|
|
6
|
+
};
|
|
7
|
+
saveText: (updater: Partial<TextAnnotation> | ((latest: any) => any)) => void;
|
|
8
|
+
children?: React.ReactNode;
|
|
9
|
+
}
|
|
10
|
+
declare const TextControls: ({ text, saveText, children }: TextControlsProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export default TextControls;
|
|
12
|
+
//# sourceMappingURL=text-controls.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text-controls.d.ts","sourceRoot":"","sources":["../../../../../src/components/tools/text/text-options/text-controls.tsx"],"names":[],"mappings":"AAaA,OAAO,EAAc,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAe/D,UAAU,iBAAiB;IAGzB,IAAI,EAAE,cAAc,GAAG;QAAE,UAAU,CAAC,EAAE,OAAO,CAAC;QAAC,SAAS,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC;IACrE,QAAQ,EAAE,CAAC,OAAO,EAAE,OAAO,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,GAAG,KAAK,GAAG,CAAC,KAAK,IAAI,CAAC;IAC9E,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC5B;AAED,QAAA,MAAM,YAAY,GAAI,8BAA8B,iBAAiB,4CA8IpE,CAAC;AAEF,eAAe,YAAY,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import _typeof from"@babel/runtime/helpers/typeof";import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import _defineProperty from"@babel/runtime/helpers/defineProperty";import{useCallback,useEffect}from"react";import{FormatBoldOutlined,FormatItalicOutlined}from"@mui/icons-material";import{TOOLS_IDS,TRANSFORMERS_LAYER_ID}from"utils/constants";import AnnotationOptions from"components/common/annotation-options";import SIconButtonWrapper from"components/common/icon-wrapper";import{ENABLE_TEXT_CONTENT_EDIT}from"actions";import restrictNumber from"utils/restrict-number";import{useStore}from"hooks";import{SFlexBox,SSelect,STextField}from"@solostylist/ui-kit/core";import{textOptionsPopupComponents,TEXT_POPPABLE_OPTIONS}from"./text-options.constants";import{activateTextChange,deactivateTextChange}from"./handle-text-change-area";var TextControls=function(a){var b=a.text,c=a.saveText,d=a.children,e=useStore(),f=e.dispatch,g=e.textIdOfEditableContent,h=e.designLayer,i=e.t,j=e.config,k=j
|
|
1
|
+
import _typeof from"@babel/runtime/helpers/typeof";import _slicedToArray from"@babel/runtime/helpers/slicedToArray";import _defineProperty from"@babel/runtime/helpers/defineProperty";import{useCallback,useEffect}from"react";import{FormatBoldOutlined,FormatItalicOutlined}from"@mui/icons-material";import{TOOLS_IDS,TRANSFORMERS_LAYER_ID}from"utils/constants";import AnnotationOptions from"components/common/annotation-options";import SIconButtonWrapper from"components/common/icon-wrapper";import{ENABLE_TEXT_CONTENT_EDIT}from"actions";import restrictNumber from"utils/restrict-number";import{useStore}from"hooks";import{SFlexBox,SSelect,STextField}from"@solostylist/ui-kit/core";import{textOptionsPopupComponents,TEXT_POPPABLE_OPTIONS}from"./text-options.constants";import{activateTextChange,deactivateTextChange}from"./handle-text-change-area";var TextControls=function(a){var b=a.text,c=a.saveText,d=a.children,e=useStore(),f=e.dispatch,g=e.textIdOfEditableContent,h=e.designLayer,i=e.t,j=e.config,k=j[TOOLS_IDS.TEXT]||{},l=k.fonts,m=void 0===l?[]:l,n=k.onFontChange,o=useCallback(function(a){var b=a.target,d=b.name,e=b.value,f=b.type;c(function(a){return _defineProperty({id:a.id},d,"number"===f?restrictNumber(+e,1,500):e)})},[c]),p=useCallback(function(a){if(o({target:{name:"fontFamily",value:a}}),b.fontFamily!==a&&"function"==typeof n){var c=h.draw.bind(h);n(a,c)}},[o,b.fontFamily,n,h]),q=useCallback(function(a){var c,d=(null===(c=b.fontStyle)||void 0===c?void 0:c.replace("normal","").split(" "))||[];0<Object.keys(d).length&&d.includes(a)?d=d.filter(function(b){return b!==a}):d.push(a),o({target:{name:"fontStyle",value:d.join(" ").trim()||"normal"}})},[b.fontStyle,o]),r=useCallback(function(){f({type:ENABLE_TEXT_CONTENT_EDIT,payload:{textIdOfEditableContent:null}})},[]),s=useCallback(function(a){o({target:{name:"text",value:a}}),r()},[]);return useEffect(function(){var a;if(g&&b.id===g){var c=h.getStage(),d=c.findOne("#".concat(TRANSFORMERS_LAYER_ID));if(d){var e=d.children||[],f=_slicedToArray(e,1);a=f[0],activateTextChange(g,c,a,s,r)}}return function(){a&&g&&deactivateTextChange()}},[g]),React.createElement(AnnotationOptions,{annotation:b,updateAnnotation:c,morePoppableOptionsPrepended:TEXT_POPPABLE_OPTIONS,moreOptionsPopupComponentsObj:textOptionsPopupComponents},React.createElement(SFlexBox,{sx:{gap:1,alignItems:"center"}},Array.isArray(m)&&1<m.length&&React.createElement(SSelect,{onChange:function(a){return p(a.target.value)},value:b.fontFamily,placeholder:i("fontFamily"),options:m,optionLabel:"object"===_typeof(m[0])?"label":void 0,optionValue:"object"===_typeof(m[0])?"value":void 0,sx:{width:150,textAlign:"left"}}),React.createElement(STextField,{value:b.fontSize||"",name:"fontSize",onChange:o,inputMode:"numeric",type:"number",sx:{width:150},placeholder:i("size")}),React.createElement(SIconButtonWrapper,{active:(b.fontStyle||"").includes("bold"),onClick:function(){return q("bold")}},React.createElement(FormatBoldOutlined,null)),React.createElement(SIconButtonWrapper,{active:(b.fontStyle||"").includes("italic"),onClick:function(){return q("italic")}},React.createElement(FormatItalicOutlined,null)),d))};export default TextControls;
|