diff --git a/CHANGES.md b/CHANGES.md index 308543214..ce587c767 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -17,6 +17,7 @@ - Update Typography palette order (by @akshay-gupta7) [Github #3156](https://github.com/penpot/penpot/pull/3156) - Palettes (color, typographies) empty state (by @akshay-gupta7) [Github #3160](https://github.com/penpot/penpot/pull/3160) - Duplicate objects via drag + alt (by @akshay-gupta7) [Github #3147](https://github.com/penpot/penpot/pull/3147) +-Set line-height to auto as 1.2 (by @akshay-gupta7) [Github #3185](https://github.com/penpot/penpot/pull/3185) ## 1.18.3 (Unreleased) diff --git a/frontend/src/app/main/ui/workspace/sidebar/options/menus/typography.cljs b/frontend/src/app/main/ui/workspace/sidebar/options/menus/typography.cljs index 4d51e1480..c4b0f48ff 100644 --- a/frontend/src/app/main/ui/workspace/sidebar/options/menus/typography.cljs +++ b/frontend/src/app/main/ui/workspace/sidebar/options/menus/typography.cljs @@ -374,6 +374,8 @@ line-height (or line-height "1.2") letter-spacing (or letter-spacing "0") + line-height-nillable (if (= (str line-height) "1.2") false true) + handle-change (fn [value attr] (on-change {attr (str value)}))] @@ -387,8 +389,10 @@ {:min -200 :max 200 :step 0.1 + :default "1.2" :value (attr->string line-height) :placeholder (tr "settings.multiple") + :nillable line-height-nillable :on-change #(handle-change % :line-height) :on-blur on-blur}]]