diff --git a/CHANGES.md b/CHANGES.md index 6278c887ae..d1ca253de6 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -34,6 +34,8 @@ - New text-decoration token [Taiga #10941](https://tree.taiga.io/project/penpot/us/10941) - New letter spacing token [Taiga #10940](https://tree.taiga.io/project/penpot/us/10940) - New font weight token [Taiga #10939](https://tree.taiga.io/project/penpot/us/10939) +- Upgrade Node to v22.18.0 [Github #7283](https://github.com/penpot/penpot/pull/7283) +- Upgrade the base docker image for penpot frontend to v1.29.1 [Github #7283](https://github.com/penpot/penpot/pull/7283) ### :bug: Bugs fixed @@ -58,6 +60,7 @@ - Layout item tokens should be unapplied when moving out of a layout [Taiga #11012](https://tree.taiga.io/project/penpot/issue/11012) - Fix incorrect date displayed for support plan [Taiga #11986](https://tree.taiga.io/project/penpot/issue/11986) - Fix can't import 'borderWidth' type token [#132](https://github.com/tokens-studio/penpot/issues/132) +- Fix moving elements up or down while pressing alt [Taiga Issue #11992](https://tree.taiga.io/project/penpot/issue/11992) ## 2.9.0 diff --git a/common/src/app/common/types/plugins.cljc b/common/src/app/common/types/plugins.cljc index b582da3583..e2188d3585 100644 --- a/common/src/app/common/types/plugins.cljc +++ b/common/src/app/common/types/plugins.cljc @@ -27,7 +27,7 @@ schema:string schema:string]]) -(def ^:private schema:registry-entry +(def schema:registry-entry [:map [:plugin-id :string] [:name :string] diff --git a/docker/images/Dockerfile.backend b/docker/images/Dockerfile.backend index 9200e67101..da51673cb3 100644 --- a/docker/images/Dockerfile.backend +++ b/docker/images/Dockerfile.backend @@ -5,7 +5,7 @@ ENV LANG='C.UTF-8' \ LC_ALL='C.UTF-8' \ JAVA_HOME="/opt/jdk" \ DEBIAN_FRONTEND=noninteractive \ - NODE_VERSION=v22.16.0 \ + NODE_VERSION=v22.18.0 \ TZ=Etc/UTC RUN set -ex; \ diff --git a/docker/images/Dockerfile.exporter b/docker/images/Dockerfile.exporter index b745353cfb..74d3a41657 100644 --- a/docker/images/Dockerfile.exporter +++ b/docker/images/Dockerfile.exporter @@ -3,7 +3,7 @@ LABEL maintainer="Penpot " ENV LANG=en_US.UTF-8 \ LC_ALL=en_US.UTF-8 \ - NODE_VERSION=v22.16.0 \ + NODE_VERSION=v22.18.0 \ DEBIAN_FRONTEND=noninteractive \ PATH=/opt/node/bin:$PATH diff --git a/docker/images/Dockerfile.frontend b/docker/images/Dockerfile.frontend index e5276fba4e..93dc27cb33 100644 --- a/docker/images/Dockerfile.frontend +++ b/docker/images/Dockerfile.frontend @@ -1,4 +1,4 @@ -FROM nginxinc/nginx-unprivileged:1.28.0 +FROM nginxinc/nginx-unprivileged:1.29.1 LABEL maintainer="Penpot " USER root diff --git a/frontend/src/app/main/data/workspace/shortcuts.cljs b/frontend/src/app/main/data/workspace/shortcuts.cljs index de041ba2ee..c1741df475 100644 --- a/frontend/src/app/main/data/workspace/shortcuts.cljs +++ b/frontend/src/app/main/data/workspace/shortcuts.cljs @@ -233,12 +233,12 @@ :fn #(emit-when-no-readonly (dwt/move-selected :left true))} :move-unit-up {:tooltip ds/up-arrow - :command ["up"] + :command ["up" "alt+up"] :subsections [:modify-layers] :fn #(emit-when-no-readonly (dwt/move-selected :up false))} :move-unit-down {:tooltip ds/down-arrow - :command ["down"] + :command ["down" "alt+down"] :subsections [:modify-layers] :fn #(emit-when-no-readonly (dwt/move-selected :down false))} diff --git a/frontend/src/app/main/ui/workspace/context_menu.cljs b/frontend/src/app/main/ui/workspace/context_menu.cljs index c56291be03..87d8a50dd9 100644 --- a/frontend/src/app/main/ui/workspace/context_menu.cljs +++ b/frontend/src/app/main/ui/workspace/context_menu.cljs @@ -568,7 +568,6 @@ [{:keys [shapes]}] (let [single? (= (count shapes) 1) objects (deref refs/workspace-page-objects) - shapes (keep (d/getf objects) shapes) can-make-component (every? true? (map #(ctn/valid-shape-for-component? objects %) shapes)) heads (filter ctk/instance-head? shapes) components-menu-entries (cmm/generate-components-menu-entries heads) diff --git a/frontend/src/app/plugins/register.cljs b/frontend/src/app/plugins/register.cljs index c7865eb6cc..aba49133d8 100644 --- a/frontend/src/app/plugins/register.cljs +++ b/frontend/src/app/plugins/register.cljs @@ -71,9 +71,9 @@ :code code :icon icon :permissions (into #{} (map str) permissions)})] - (if (sm/validate ::ctp/registry-entry manifest) + (if (sm/validate ctp/schema:registry-entry manifest) manifest - (.error js/console (clj->js (sm/explain ::ctp/registry-entry manifest)))))) + (.error js/console (clj->js (sm/explain ctp/schema:registry-entry manifest)))))) (defn save-to-store [] diff --git a/frontend/text-editor/src/editor/content/dom/Content.js b/frontend/text-editor/src/editor/content/dom/Content.js index 8b3f1e8e69..aa550e9724 100644 --- a/frontend/text-editor/src/editor/content/dom/Content.js +++ b/frontend/text-editor/src/editor/content/dom/Content.js @@ -14,6 +14,11 @@ import { } from "./Paragraph.js"; import { isDisplayBlock, normalizeStyles } from "./Style.js"; +const DEFAULT_FONT_SIZE = "14px"; +const DEFAULT_FONT_WEIGHT = 400; +const DEFAULT_FONT_FAMILY = "sourcesanspro"; +const DEFAULT_FILLS = '[["^ ","~:fill-color", "#000000","~:fill-opacity", 1]]'; + /** * Returns if the content fragment should be treated as * inline content and not a paragraphed one. @@ -72,11 +77,26 @@ export function mapContentFragmentFromDocument(document, root, styleDefaults) { } const inline = createInline(new Text(currentNode.nodeValue), currentStyle); const fontSize = inline.style.getPropertyValue("font-size"); - if (!fontSize) console.warn("font-size", fontSize); + if (!fontSize) { + console.warn("font-size", fontSize); + inline.style.setProperty("font-size", styleDefaults?.getPropertyValue("font-size") ?? DEFAULT_FONT_SIZE); + } const fontFamily = inline.style.getPropertyValue("font-family"); - if (!fontFamily) console.warn("font-family", fontFamily); + if (!fontFamily) { + console.warn("font-family", fontFamily); + inline.style.setProperty("font-family", styleDefaults?.getPropertyValue("font-family") ?? DEFAULT_FONT_FAMILY); + } const fontWeight = inline.style.getPropertyValue("font-weight"); - if (!fontWeight) console.warn("font-weight", fontWeight); + if (!fontWeight) { + console.warn("font-weight", fontWeight); + inline.style.setProperty("font-weight", styleDefaults?.getPropertyValue("font-weight") ?? DEFAULT_FONT_WEIGHT) + } + const fills = inline.style.getPropertyValue('--fills'); + if (!fills) { + console.warn("fills", fills); + inline.style.setProperty("--fills", styleDefaults?.getPropertyValue("--fills") ?? DEFAULT_FILLS); + } + currentParagraph.appendChild(inline); currentNode = nodeIterator.nextNode();