diff --git a/src/js/tools/select.js b/src/js/tools/select.js index 63dea70..3ca5d00 100644 --- a/src/js/tools/select.js +++ b/src/js/tools/select.js @@ -101,10 +101,13 @@ class Select_tool_class extends Base_tools_class { var mouse = this.get_mouse_info(e); if (mouse.valid == false || mouse.click_valid == false) return; - if (this.Base_selection.mouse_lock != null) + if (this.Base_selection.mouse_lock != null) { + this.Base_selection.find_settings().keep_ratio = config.layer.type === 'image'; return; + } this.auto_select_object(e); + this.Base_selection.find_settings().keep_ratio = config.layer.type === 'image'; this.saved = false; this.last_post = { diff --git a/src/js/tools/text.js b/src/js/tools/text.js index 8446fa4..ff20c8e 100644 --- a/src/js/tools/text.js +++ b/src/js/tools/text.js @@ -1563,14 +1563,14 @@ class Text_class extends Base_tools_class { */ resize_to_dynamic_bounds(layer, editor) { - if (layer.params.boundary === 'dynamic') { + if (layer && layer.params && layer.params.boundary === 'dynamic') { layer.width = editor.textBoundaryWidth + 1; layer.height = editor.textBoundaryHeight + 1; } } extend_fixed_bounds(layer, editor) { - if (layer.params.boundary !== 'dynamic') { + if (layer && layer.params && layer.params.boundary !== 'dynamic') { const params = this.getParams(); const isHorizontalTextDirection = ['ltr', 'rtl'].includes(params.textDirection); if (isHorizontalTextDirection) { diff --git a/webpack.config.js b/webpack.config.js index 0e46bef..1f3d7fc 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -53,7 +53,7 @@ module.exports = { ], devtool: "cheap-module-source-map", devServer: { - host: '0.0.0.0', + // host: '0.0.0.0', contentBase: "./", compress: true, }