From 310c322883911d857e5ffd32900f64386ce80fc7 Mon Sep 17 00:00:00 2001 From: Alejandro Alonso Date: Fri, 10 Jun 2022 10:27:53 +0200 Subject: [PATCH 1/2] :bug: Fix show baground on export arboards --- CHANGES.md | 1 + frontend/src/app/util/import/parser.cljs | 6 ++---- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 338296b4f..54bfb5ddd 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -13,6 +13,7 @@ ### :bug: Bugs fixed - Fix orientation artboard preset not working with differently sized artboards [Taiga #3548](https://tree.taiga.io/project/penpot/issue/3548) +- Fix background on export arboards [Taiga #1991](https://tree.taiga.io/project/penpot/issue/1991) ## 1.13.4-beta diff --git a/frontend/src/app/util/import/parser.cljs b/frontend/src/app/util/import/parser.cljs index f494827ab..292431093 100644 --- a/frontend/src/app/util/import/parser.cljs +++ b/frontend/src/app/util/import/parser.cljs @@ -421,7 +421,6 @@ [props node svg-data] (let [fill (:fill svg-data) - hide-fill-on-export (get-meta node :hide-fill-on-export str->bool) fill-color-ref-id (get-meta node :fill-color-ref-id uuid/uuid) fill-color-ref-file (get-meta node :fill-color-ref-file uuid/uuid) meta-fill-color (get-meta node :fill-color) @@ -455,9 +454,6 @@ (assoc :fill-color fill :fill-opacity (-> svg-data (:fill-opacity "1") d/parse-double)) - (some? hide-fill-on-export) - (assoc :hide-fill-on-export hide-fill-on-export) - (some? fill-color-ref-id) (assoc :fill-color-ref-id fill-color-ref-id :fill-color-ref-file fill-color-ref-file)))) @@ -884,6 +880,8 @@ (assoc :fills (parse-fills node svg-data)) (assoc :strokes (parse-strokes node svg-data)) + (assoc :hide-fill-on-export (get-meta node :hide-fill-on-export str->bool)) + (cond-> (= :svg-raw type) (add-svg-content node)) From 667598a0ebd5ef0520f616b5a519dcf4299a7d4a Mon Sep 17 00:00:00 2001 From: Alejandro Alonso Date: Wed, 15 Jun 2022 07:49:05 +0200 Subject: [PATCH 2/2] :sparkles: Add project ids to create-file mutation for audit log --- backend/src/app/rpc/mutations/files.clj | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/backend/src/app/rpc/mutations/files.clj b/backend/src/app/rpc/mutations/files.clj index 7bc10d656..f52d4fcfa 100644 --- a/backend/src/app/rpc/mutations/files.clj +++ b/backend/src/app/rpc/mutations/files.clj @@ -27,6 +27,7 @@ [promesa.core :as p])) (declare create-file) +(declare retrieve-team-id) ;; --- Helpers & Specs @@ -48,8 +49,11 @@ (sv/defmethod ::create-file [{:keys [pool] :as cfg} {:keys [profile-id project-id] :as params}] (db/with-atomic [conn pool] - (proj/check-edition-permissions! conn profile-id project-id) - (create-file conn params))) + (let [team-id (retrieve-team-id conn project-id)] + (proj/check-edition-permissions! conn profile-id project-id) + (with-meta + (create-file conn params) + {::audit/props {:team-id team-id}})))) (defn create-file-role [conn {:keys [file-id profile-id role]}] @@ -246,7 +250,6 @@ (declare insert-change) (declare retrieve-lagged-changes) -(declare retrieve-team-id) (declare send-notifications) (declare update-file)