diff --git a/frontend/src/uxbox/main/refs.cljs b/frontend/src/uxbox/main/refs.cljs index 84d72442f..2437461b3 100644 --- a/frontend/src/uxbox/main/refs.cljs +++ b/frontend/src/uxbox/main/refs.cljs @@ -74,7 +74,6 @@ (def workspace-saved-grids (l/derived :saved-grids workspace-page-options)) - (def workspace-objects (l/derived :objects workspace-data)) diff --git a/frontend/src/uxbox/main/ui/components/dropdown.cljs b/frontend/src/uxbox/main/ui/components/dropdown.cljs index eae0f817d..48f8f6d86 100644 --- a/frontend/src/uxbox/main/ui/components/dropdown.cljs +++ b/frontend/src/uxbox/main/ui/components/dropdown.cljs @@ -43,8 +43,8 @@ (mf/defc dropdown {::mf/wrap-props false} [props] - #_(assert (fn? (gobj/get props "on-close")) "missing `on-close` prop") - #_(assert (boolean? (gobj/get props "show")) "missing `show` prop") + (assert (fn? (gobj/get props "on-close")) "missing `on-close` prop") + (assert (boolean? (gobj/get props "show")) "missing `show` prop") (when (gobj/get props "show") (mf/element dropdown' props))) diff --git a/frontend/src/uxbox/main/ui/components/editable_select.cljs b/frontend/src/uxbox/main/ui/components/editable_select.cljs index 57093c6cb..5d2994d4c 100644 --- a/frontend/src/uxbox/main/ui/components/editable_select.cljs +++ b/frontend/src/uxbox/main/ui/components/editable_select.cljs @@ -55,7 +55,7 @@ :type type}] [:span.dropdown-button {:on-click open-dropdown} i/arrow-down] - [:& dropdown {:show (:is-open? @state) + [:& dropdown {:show (get @state :is-open? false) :on-close close-dropdown} [:ul.custom-select-dropdown (for [[index item] (map-indexed vector options)] diff --git a/frontend/src/uxbox/main/ui/workspace/shapes/frame.cljs b/frontend/src/uxbox/main/ui/workspace/shapes/frame.cljs index 28cadea2c..e39abfe6c 100644 --- a/frontend/src/uxbox/main/ui/workspace/shapes/frame.cljs +++ b/frontend/src/uxbox/main/ui/workspace/shapes/frame.cljs @@ -71,7 +71,7 @@ childs (mapv #(get objects %) (:shapes shape)) ds-modifier (get-in shape [:modifiers :displacement]) - label-pos (gpt/point x (- y 10)) + label-pos (gpt/point x (- y (/ 10 zoom))) on-double-click (mf/use-callback diff --git a/frontend/src/uxbox/main/ui/workspace/sidebar/options/frame.cljs b/frontend/src/uxbox/main/ui/workspace/sidebar/options/frame.cljs index 13d525922..1dabf3e55 100644 --- a/frontend/src/uxbox/main/ui/workspace/sidebar/options/frame.cljs +++ b/frontend/src/uxbox/main/ui/workspace/sidebar/options/frame.cljs @@ -38,10 +38,10 @@ on-orientation-clicked (fn [orientation] - (let [width (:width shape) - height (:height shape) - new-width (if (= orientation :horiz) (max width height) (min width height)) - new-height (if (= orientation :horiz) (min width height) (max width height))] + (let [width (:width shape) + height (:height shape) + new-width (if (= orientation :horiz) (max width height) (min width height)) + new-height (if (= orientation :horiz) (min width height) (max width height))] (st/emit! (udw/update-rect-dimensions (:id shape) :width new-width) (udw/update-rect-dimensions (:id shape) :height new-height)))) diff --git a/frontend/src/uxbox/main/ui/workspace/sidebar/options/frame_grid.cljs b/frontend/src/uxbox/main/ui/workspace/sidebar/options/frame_grid.cljs index 29588bad5..5e2fc522f 100644 --- a/frontend/src/uxbox/main/ui/workspace/sidebar/options/frame_grid.cljs +++ b/frontend/src/uxbox/main/ui/workspace/sidebar/options/frame_grid.cljs @@ -180,8 +180,8 @@ (when (#{:row :column} type) [:& input-row {:label (if (= :row type) - (t locale "workspace.options.grid.params.width") - (t locale "workspace.options.grid.params.height")) + (t locale "workspace.options.grid.params.height") + (t locale "workspace.options.grid.params.width")) :class "pixels" :value (or (:item-length params) "") :on-change handle-change-item-length}])