The flex gap overlay built a lazy map over every object on the page on
each render. It re-renders on every viewport change, so with a flex
board selected panning became very slow, e.g. on the mem_benchmark file.
The layout calculation only needs to look up the frame and its
desendants, so limit it to just that subtree. Panning a page of 50k
shapes goes from ~30fps -> 60fps.
AI-assisted-by: claude-opus-5-5
A job output whose value matches a secret is redacted by GitHub, so the
registry arrived empty wherever it was read through needs.*.outputs. The
admin-console retag step failed with "invalid reference format" on an
image name that began with a slash, and the image tags in build-docker
had the same defect waiting.
Each job now resolves the registry from the secrets directly, which is
also one less piece of state to thread through. For the same reason the
artifact published by the admin-console build carries only the build key:
the caller composes the full reference with its own copy of the registry,
so the secret never travels between repositories.
The dispatcher needs those secrets declared to compose that reference, so
its existing callers pass DOCKER_REGISTRY as well.
AI-assisted-by: claude-opus-5
Signed-off-by: David Barragán Merino <david.barragan@kaleidos.net>
* 🐛 Allow apostrophes in custom font family names
Fonts like "Suisse Int'l" failed to upload since 2.15: the family name
schema only allowed letters, digits, spaces, hyphens, underscores and
dots, to stop CSS injection through the name.
The schema now also allows straight and typographic apostrophes. The
frontend escapes backslashes and apostrophes where it writes the name
into the single-quoted @font-face string, so the name can't end the
string early. Other unsafe characters stay rejected.
The dashboard now shows the invalid characters message instead of the
generic bad font notice when the backend would reject the name, and
clears the uploading state when an upload fails.
Closes#10710
AI-assisted-by: claude-opus-5-5
* 🐛 Keep fonts that fail on Upload all in the list
Upload all removed a font from the list when its upload failed, so a
font with an invalid family name vanished and its name could not be
fixed. A single upload keeps it. Now Upload all keeps failed fonts too.
The Upload all stream moves to a private upload-fonts fn, and new tests
cover the invalid characters notice, that an invalid family is never
sent, and that a failed font comes back without a font.
AI-assisted-by: claude-opus-5-5
* ♻️ Use the DS select for the shadow type
The Drop shadow / Inner shadow select of each shadow row (Design tab)
moves from the legacy select to the DS select*. The wrapper grows in
the row and the select keeps its square left corners, joined to the
options button.
A zero-tolerance visual test adds a shadow and captures the select
closed, on hover, open, with an option on hover, after changing to
Inner shadow and disabled when the shadow is hidden.
AI-assisted-by: claude-opus-5-5
* ♻️ Say why the shadow row styles keep the deprecated import
The legacy select needed nothing from refactor/; the import stays only
for %input-element in the offset, blur and spread inputs, which move to
the DS with the numeric inputs group. A comment above the @use says so.
AI-assisted-by: claude-opus-5-5
Preview environments run on their own cluster, which cannot reuse the
published registry: every pull would cross a network boundary that costs
money, and the cluster would have to hold credentials that rotate. So
previews publish to a registry of their own.
build-docker.yml gains preview, platforms, images, attestations and
move_branch_tags, every one of them defaulting to exactly what happens
today. _DEVELOP, _STAGING, _TAG and _ADHOC produce the same artefacts as
before. The registry address comes from the PREVIEW_REGISTRY_URL secret
rather than travelling as a parameter.
Two registries keep the image tags apart on their own: the build key
comes from the commit and the version, not the branch, so a preview and a
published build of the same commit would otherwise write the same tag.
The bucket is shared, though, and the completion marker lives there. A
preview writing the canonical marker would make a later published build
of that commit skip its work and leave production without arm64, so
previews write their own. The canonical key keeps its current shape, so
the markers already in S3 stay valid and nothing is rebuilt when this
lands.
move_branch_tags is the other guard. A preview that moved them would
repoint the tags the fixed environments deploy from.
The admin-console dispatcher propagates the same settings and retrieves
the built reference from the artifact nitrate publishes, since a
dispatched run cannot return outputs across repositories.
_PREVIEW fixes all of it rather than exposing it: the chatops will run
this many times a day, and a wrong value produces an environment that
fails in ways nobody can explain. _ADHOC stays as the way to build an
arbitrary branch for the fixed environments.
The bundle is untouched. It is keyed by commit and version, so a preview
of a ref already bundled compiles nothing, and it is the identical
artefact a published build would use.
The concurrency group carries the mode as well. Without it a preview and a
release build of the same ref land in the same group with
cancel-in-progress, so one kills the other and the dead run can leave images
pushed with no marker.
The inputs that change what gets built are reachable only through
workflow_call. The marker records the commit, not the image set or the
architectures, so a manual run with fewer images would let a later full
build skip its work; each caller fixes them instead. The image list is
validated before the matrix is built, so a bad value fails where it was
given rather than as a missing Dockerfile.
AI-assisted-by: claude-opus-5
Signed-off-by: David Barragán Merino <david.barragan@kaleidos.net>
* 🐛 Show the hint of the dashboard progress notification
Restoring or deleting files from the trash showed the progress
notification with no text, and every update would mark it as slow:
- The dashboard passed its hints as :progress, but the progress events
read :normal.
- update-progress read the threshold from :slow-progress-threshold,
while initialize-progress stores it as :threshold, so the time check
was always false.
- update-progress checked its params against the initialize schema,
which requires :hints, so dev builds threw on every update.
Unit tests cover the initial hint and the healthy and slow updates.
AI-assisted-by: claude-opus-5-5
* ♻️ Use DS controls in the dashboard progress notification
The close button of the progress notification (restore or delete from
the trash) becomes a DS ghost icon button with a label and a top-left
tooltip, and its status icons move from the old icon set to the DS
icon*. The close column grows to the button, so the X stays where it
was.
A zero-tolerance visual test holds a restore open and captures the
notification at rest and with the close button on hover, then closes
it.
AI-assisted-by: claude-opus-5-5
* ♻️ Move the progress notification styles to the DS
progress.scss drops the refactor/ import: DS spacing, sizes, borders
and typography, the alert and modal aliases resolved to their DS
colors, and the notification z-index token (300 to 500).
The retry link takes body-small (line height 1.4 to 1.3); it only
shows on errors.
Removed (no use left in frontend/src): .progress-widget and
.close-icon.
AI-assisted-by: claude-opus-5-5
* ♻️ Use the action variant for the progress notification close
The ghost close button is 32px tall and made the notification 11px
taller. The action variant is 24px, so it grows only 3px, and the X
keeps its place with a 4px end margin.
AI-assisted-by: claude-opus-5-5
* ♻️ Use the DS select for the constraints selects
The horizontal and vertical selects of the Constraints section (Design
tab) move from the legacy select to the DS select*. Mixed values get
their own "multiple" id, so the select shows "Mixed" as before and
picking it changes nothing. The unused cuerdas require goes away.
A zero-tolerance visual test captures the selects closed, on hover,
open, with an option on hover, after changing the horizontal one, and
mixed (closed and open) with two shapes selected.
AI-assisted-by: claude-opus-5-5
* ♻️ Move the constraints select styles to the DS
The column of the two selects takes the DS spacing token and its width
px2rem(124); the padding: 0 did nothing on a plain div and goes away.
refactor/ stays for the constraints widget (raw buttons) and the "Fix
when scrolling" checkbox, which moves with the checkboxes group; a
comment above the @use says so.
AI-assisted-by: claude-opus-5-5
Every run of manage.sh executes
git config --global --add safe.directory /home/penpot/penpot
and --add appends unconditionally, so N invocations leave N copies of
the entry in the developer's global git config: after a few months of
daily devenv use, my ~/.config/git/config held 22 duplicates. Ask git
first and add the entry only when it is missing, so the devenv behaves
exactly as before and the host-side global config stops growing.
AI-assisted-by: glm-5.3-flash
Signed-off-by: Álvaro Tejero Cantero <alvorithm@teje.ro>
On develop, pcb/update-component only puts the component :objects in
the change when called with :objects? true (#12308). The variant
repairs merged from staging (#12961) still change :objects through it
without that option, so the change dropped their edits: the label of
a deleted variant main kept its stale name, and the stored shapes of
a live component were not removed. 21 assertions of repair_test
failed on develop since the merge a0bbafaf12.
Both repairs now pass :objects? true, as the other repairs that
rewrite the stored shapes already do.
AI-assisted-by: claude-opus-5-5
* ♻️ Use the DS select for the font variant
The font variant select of the typography options (Design tab) moves
from the legacy select to the DS select*. Its options are memoized on
the font and the mixed flag; mixed variants keep a blank option, which
the DS select shows as "--". The select only renders when the font has
variants, since select* needs at least one option.
A zero-tolerance visual test captures the select closed, on hover,
open, with an option on hover, and mixed (closed and open). Its fixture
is a copy of the text multiple selection file with variant ids that
Rufina has (regular and 700), so the select shows a value.
AI-assisted-by: claude-opus-5-5
* ♻️ Drop a no-op padding from the font variant options
The font variant options wrapper is a plain div, so its padding: 0
did nothing. The rest of typography.scss keeps refactor/ only for the
line height and letter spacing inputs, as its TODO says.
AI-assisted-by: claude-opus-5-5
Keep a test JVM running for fast backend test and evaluation cycles.
Expose the commands as MCP developer tools and report nREPL failures,
timeouts, and stale sessions reliably.
Start the lockout tests with the test configuration and document the
warm test workflow. The original changes were authored by Álvaro Tejero
Cantero.
AI-assisted-by: claude-opus-5-5
AI-assisted-by: gpt-6.1-terra
Chromium now sends the host's user agent, so on macOS Penpot binds its
shortcuts to Command and reads metaKey for ctrl-click selection. Specs
that pressed a literal Control stopped working there.
Switch those presses and click modifiers to ControlOrMeta. Keep Control
where Penpot binds a bare key (zoom) or where the spec records a raw
combo in the shortcut editor.
Document the rule in the frontend developer guide, the Playwright
memories and the migrate-ds-area skill.
AI-assisted-by: claude-opus-5-5
This PR contains two fixes.
The first is that some of the render-wasm specs fail on macOS because
the `devices["Desktop Chrome"]` playwright preset uses a Windows user
agent by default. So penpot registers ctrl shortcuts, but Playwright
sends Meta via the ControlOrMeta command if the tests are running on
macOS.
The `platform === 'darwin'` check didn't work due to a typo (I believe
it should be `platform() == 'darwin'`. But removing the preset also
fixes it by letting the browser send its own user agent, which matches
the host OS.
The second is that the "Renders background blur under strokes on
rects, paths and texts" spec failed because this.pageName matched
multiple elements, and playwright complained in strict mode. This
fixes it by using .first() in a few places and making
waitForWebSocketReadiness match the exact name. It also means we can
remove the workaround in rename-page.spec.js.
AI-assisted-by: claude-opus-5-5
* ✨ Leave the opacity shortcuts without a default key
Number keys set the opacity of the selection and were easy to press by
accident, for example after an input lost the focus. The opacity
shortcuts stay, with no default key: users who want them assign a key in
Settings.
The settings rows show the no-key icon for any shortcut without a key,
and the reset notice shows it when the default has none.
Closes#13303
AI-assisted-by: claude-opus-5-5
* 📚 Document the opacity shortcuts without a default key
The shortcuts page listed the number keys for the opacity shortcuts.
Show one row with no default keys, linked to the customize section, and
drop the AZERTY note about those keys.
AI-assisted-by: claude-opus-5-5
* 🐛 Preserve effective center alignment on imported SVG strokes
Imported strokes without explicit alignment render as centered in
the sidebar, geometry and renderers, but stroke mutations
materialized them as inner via build-stroke-style-attrs. Split the
fallback: existing strokes keep center, genuinely new strokes keep
the inner default. Restores the Taiga #7673 regression guard and
locks both lifecycles with focused tests.
Closes#11581
AI-assisted-by: muse-spark
Signed-off-by: makesomethingshit <junsoo1172@gmail.com>
* 🐛 Cover explicit inner stroke color updates
Verify that changing an existing inner stroke color preserves its
alignment, and clarify the missing-stroke default.
AI-assisted-by: gpt-6
Signed-off-by: makesomethingshit <junsoo1172@gmail.com>
---------
Signed-off-by: makesomethingshit <junsoo1172@gmail.com>
The copy button for the MCP server URL in Settings > Integrations showed
the "copied" toast without waiting for the clipboard write, and left the
rejected promise unhandled when the write failed. Error reports show this
on SaaS over HTTPS too, with NotAllowedError (write permission denied).
Wait for the write, show the success toast and track the event only when
it resolves, and show an error toast when it rejects, as the token copy
button in the same file already does.
AI-assisted-by: claude-opus-5-5
Signed-off-by: Gabriel Ribeiro <267068126+gabrielribeiro3105@users.noreply.github.com>
GitHub refuses pull request diffs over 20,000 lines. Build the same
merge-base diff with git in that case, fetching only the merge base and
head in a shallow checkout.
AI-assisted-by: claude-opus-5-5
* ♻️ Use a DS secondary button in the request access dialog
The "Go to Personal Projects" button of the request access dialog (no
permission to a file or team, SSO error) was a raw button styled by
hand. It is now a DS secondary button next to the primary one. The
space between them moves from the button margin to a gap on the
actions row.
A zero-tolerance visual test covers both buttons at rest and on hover.
AI-assisted-by: claude-opus-5-5
* ♻️ Drop the unused cancel button styles of the request dialog
The request access dialog uses a DS button now, so its hand-made
button styles go away.
Removed (no use left in frontend/src): .cancel-button inside
.overlay .dialog .sign-info and .overlay .dialog-login .sign-info.
AI-assisted-by: claude-opus-5-5
* ♻️ Use DS icon buttons for the Measures toggles
"Clip content" and "Show in view mode" were labels over hidden
checkboxes, styled with the deprecated %button-tertiary. They become
ghost icon-button* with aria-pressed: real buttons with a name, the DS
tooltip instead of the browser title, and the DS pressed corners. The
handlers toggle the current value instead of reading the checkbox, and
the two unused refs go away.
The ratio lock, already an icon-button*, marks its state with
aria-pressed instead of the legacy .selected class; it looks the same.
A zero-tolerance visual test shows both toggles at rest, on hover and
turned off, and the ratio lock off and on.
AI-assisted-by: claude-opus-5-5
* ♻️ Drop the unused button styles of the Measures menu
The toggles and the ratio lock no longer use the legacy button
styles, so these selectors match nothing and go away: .lock-size-btn,
.lock-ratio-icon, .clip-content, .show-in-viewer, .clip-content-input,
.clip-content-label, .selected and .checkbox-button. Also
.numeric-input-measures, which no module uses. A grep over frontend/src
found no other use of any of them.
.clip-show takes the DS spacing token. The refactor/ import stays for
the presets dropdown and the inputs, which move to the DS with the
selects and inputs groups. The visual test shows 0 px against the
previous commit.
AI-assisted-by: claude-opus-5-5
* ♻️ Use the DS button in the Design tab export menu
The "Export N elements" button of the Export menu was a raw button with
the deprecated %button-secondary placeholder. It becomes a secondary
button*, as the Inspect export button already is, so it takes the DS
label, hover and disabled look. The btn-disabled class goes away: the
.scss never defined it, and button* styles the disabled state.
A zero-tolerance visual test shows the button at rest, on hover and
while exporting (the export request is held so the state stays), and
the export row, which the styles commit that follows must not change.
AI-assisted-by: claude-opus-5-5
* ♻️ Move the Design tab export menu styles to the DS
exports.scss drops the deprecated spacing, flex-row and typography
mixins and the %mixed-bar placeholder: DS sizes, borders, spacing
tokens and px2rem take their place, with logical properties. The
mixed bar colors resolve to their DS tokens. The format and size
selects share one rule. The refactor/ import stays only for
%input-element, which the suffix input keeps until the text inputs
group moves it.
The mixed bar and the suffix input take body-small (line height 1.4
to 1.3). The visual test shows 0 px against the previous commit; the
mixed bar is not in it, because the test file cannot reach that state.
AI-assisted-by: claude-opus-5-5
* ✨ Focus a new page when it is added from the Pages list
The "+" button added the page at the end of the list, often out of view,
so nothing showed that it was created. It now opens the new page, scrolls
the list to it and starts renaming it with the default name selected. A
collapsed Pages section expands first.
The new add-page event waits for the page to initialize before it starts
the rename, because page initialization replaces :workspace-local. Only
the user who adds the page gets the focus; other users get the page as a
change. create-page stays as it was for the plugin API. The rename events
move to the pages namespace so add-page can use them.
Closes#12474
AI-assisted-by: claude-opus-5-5
* ✨ Skip the rename commit when a page keeps its name
From the review: a new page now starts in rename mode, so pressing Enter
without changes committed a rename to the same name, and the next undo
did nothing visible instead of removing the page. Renaming a page to its
current name commits nothing now.
Rename add-page to create-page-and-focus, which says what it does and
does not collide with pcb/add-page.
AI-assisted-by: claude-opus-5-5
When an organization owner changes a member's org role, the admin console
audit log missed several entries:
- The consumers rework dropped update-organization-member-role and
transfer-team-ownership from the admin console allowlist, so no org role
change and no team passed to the organization owner reached it.
- set-organization-member-viewer turned pending editor and admin team
invitations into viewer invitations without leaving an event.
- The org role entry identified the member by id and email only.
Both names are back on the allowlist. set-organization-member-viewer now
records each invitation it downgrades as update-team-invitation-role, the
event of the same change made by hand, attributed to the organization
owner, inside its transaction. It takes an optional organization-id and
puts it in those events, so a team moved to another organization before
the event is archived cannot misroute it. The admin console consumer fills
:member-name from :member-id for update-organization-member-role only, from
the profile it already loads, so the role change waits on no lookup.
AI-assisted-by: claude-opus-5-5
* 🐛 Keep context menu submenus inside the window
A submenu opens at the height of its entry, so one opened from an entry
near the bottom of the window ran past it and its last entries could
not be reached. It now moves up to end 8px above the window's bottom.
Signed-off-by: Florian Schroedl <flo.schroedl@gmail.com>
Signed-off-by: Thomas Ramé <thomas@rame.fr>
* 🐛 Keep nested context submenus inside the window
* ♻️ Compute the context submenu position in a testable function
---------
Signed-off-by: Florian Schroedl <flo.schroedl@gmail.com>
Signed-off-by: Thomas Ramé <thomas@rame.fr>
Co-authored-by: Florian Schroedl <flo.schroedl@gmail.com>
Skia listed Color Emoji too early and treated broad SMP ranges as
emoji, so text-default symbols rendered in color and FE0F could stay
monochrome. Empty spans also stopped pushing styles.
Split spans by Unicode Emoji_Presentation and variation selectors,
use emoji-first stacks only for emoji runs, keep Color Emoji last on
text runs, and always push a style for empty spans. Closes#13271.
* ✨ Add on-demand pull request reviews
Run Claude Code, Copilot CLI and OpenCode Go from PR slash commands in the
official development image. Let maintainers configure a default model and
effort for each reviewer and override both in a comment. Configure MCP
for code navigation and reply to inline questions in their original thread.
AI-assisted-by: gpt-6
Signed-off-by: Michael Panchenko <michael.panchenko@oraios-ai.de>
* ✨ Add a local runner for pull request reviews
Run the CI review scripts for a PR on a local machine and print the
review instead of posting it. Use the local Claude login when no OAuth
token is set, start Serena through uvx when it is not installed, and
show OpenCode errors when it returns no answer.
AI-assisted-by: claude-opus-5-5
* ✨ Add /review and default OpenCode to DeepSeek V4.1 Flash
Accept /review at the start of a comment as an alias for /oc with the
repository defaults, and keep the typed command as the native agent's
mention. Use deepseek-v4.1-flash when no OPENCODE_MODEL is configured.
AI-assisted-by: claude-opus-5-5
* 🔧 Default OpenCode reviews to high effort
Use high effort for DeepSeek V4.1 Flash when no OPENCODE_EFFORT is
configured, in CI and in the local runner.
AI-assisted-by: claude-opus-5-5
---------
Signed-off-by: Michael Panchenko <michael.panchenko@oraios-ai.de>
Co-authored-by: alonso.torres <alonso.torres@kaleidos.net>
* 📚 Fix Clear undo keys and snap labels in shortcuts docs
Clear undo is bound to alt+q on every platform, not Ctrl+Q on Linux and
Windows. The two snap rows used labels that do not match the actions
their keys toggle: Ctrl+Shift+' is "Snap to guides" and Ctrl+Shift+G is
"Snap to ruler guides" in the app.
AI-assisted-by: claude-opus-5-5
* 📚 Align guide shortcut labels and macOS keys in the user guide
Rename "Show/hide grid" to "Show/hide guides" to match the app label for
Ctrl+'. Use the macOS option symbol for Copy link to board and in the
shortcut recording note. Keep the snap rows in alphabetical order.
Fix the ruler guides shortcut in Workspace basics: ruler guides show
only while rulers (Ctrl+Shift+R) and guides (Ctrl+') are both visible.
Document Ctrl+Shift+G to toggle snap to ruler guides.
AI-assisted-by: claude-opus-5-5
* 📚 Note that toggling guides also hides board guides
Ctrl+' hides ruler guides and board guides alike, since both depend on
the same display-guides setting.
AI-assisted-by: claude-opus-5-5
---------
Co-authored-by: Roshan Ramani <roshanramani.dev@gmail.com>
* 🐛 Normalize legacy svg attrs of pasted shapes
Shapes copied from a version before 2.20 can hold camelCase svg attrs,
for example :strokeLinejoin. Files get them normalized by migration
0037 when they load, but clipboard data skips the migrations, so the
closed SvgAttrs schema rejected the pasted shape and the whole paste was
cancelled.
Move the shape normalization of migration 0037 to csvg/normalize-shape
and run it on every pasted shape in paste-shapes.
Closes#13327
AI-assisted-by: claude-opus-5-5
* 📚 Name the shared svg repair in the data model checklist
From the review: the checklist still named the withdrawn migration 0035
as the svg repair site. Point it to csvg/normalize-shape, used by
migration 0037 and by paste-shapes.
AI-assisted-by: claude-opus-5-5
* ✨ Count the trips of a throttled update loop before reporting it
The report of a throttled update loop could not tell a loop that goes
on from a long chain of updates that ends. It now waits five seconds
and reports how many times the scheduler tripped meanwhile, the stack
of the last trip and the number of objects of the page. The trace still
shows the first trip.
Relates #12580
AI-assisted-by: claude-opus-5-5
* ♻️ Drop the bang suffix from the update loop report function
Review asked for no new functions with a ! suffix.
AI-assisted-by: claude-opus-5-5
Variants.properties and currentValues() went through a set, which loses
order past eight items, so index-based removeProperty/renameProperty from a
plugin hit the wrong property. Use distinct to keep the order.
In the sidebar, input-with-meta* kept the input node after a real blur and
replayed a stale rename with an old position when its row unmounted,
undoing a property removal. Clear the node in on-stop-edit.
Add a unit test, a plugin-api-test-suite case and a plugins changelog entry.
Closes#13247
Dragging a shape into a board sets its constraints to the default for
that place (left/top, or scale inside a group) without marking them
touched. A component main on the canvas has no constraints, so the
sync saw nil against left/top and wrote nil over the copy. With nested
components that sync writes into the middle library, so any change to
the inner component, even a 1px move, showed an update banner in every
file that uses it.
Treat a missing constraint as the default for the placement of the
shape being written when comparing during sync.
Closes#12719
AI-assisted-by: claude-opus-5-5
color-att->text built the text fill without the :image of the color,
so picking an image in Selected colors left a fill with only
:fill-opacity. The backend rejected the text as an invalid shape. The
same gap made an image fill impossible to match, so changing it back
to a plain color did nothing.
AI-assisted-by: claude-opus-5-5
Validation compared each variant's property names with the first child
of its board, so it missed forbidden characters, too-long text and
repeated names, and never checked labels in deleted components. Repair
cut every variant down to the first child's names, which dropped
values, and left the file invalid.
Validation now checks the members of each board as one set: cleaned
text, and the same names in the same order, in layers-panel order as in
migration 0038. Repeated value combinations stay valid, as the editor
allows them. It also checks boards that exist only in a component's
objects, variant components that belong to no board, and the whole
board when a save touches only one of its members.
Repair writes the aligned properties and labels on each component and
its main. A live variant main outside its board is reported as
:variant-main-outside-board and detached, as the editor does, instead
of turning its parent into a board. :main-instance-not-a-variant now
repairs the main of a deleted component inside its objects.
Moving a shape or component into a board now cuts property values taken
from its name or path to 60 characters, as the schema requires.
Closes#13238
AI-assisted-by: claude-opus-5-5
Since #13266, a padding change on a layout without padding fills the
four sides, so the sides not chosen become 0 instead of staying nil.
The test from #13215 still expected nil and failed on develop.
AI-assisted-by: claude-opus-5-5
* 🔧 Add a render test for group shadows on nested text
The snapshot records the shadow of a group on the texts and shapes
inside it, as rendered today. Stroked text gets the shadow twice (G, I,
J, L) or partly twice (H, K), while plain text (B to F) gets it once.
The next commit fixes this and updates the snapshot.
AI-assisted-by: claude-opus-5-5
* 🐛 Remove nested_shadows, and fix double group shadows on text
The nested_shadows state is only used by text shapes to draw drop
shadows that it inherits from its parents. There's a bug where only
groups pushed onto the stack but both groups and frames popped it.
But when trying to fix this I noticed that
`render_drop_shadow_child_silhouettes` will already render the text
shapes shadow in the parent. So compared to the SVG renderer we were
applying the shadows twice.
We can just remove the stack and let the parent render the shadow
once, which brings text in line with other shapes. In the render
test, stroked text now gets the shadow once (G to L).
There's some other divergences from the SVG renderer in
`render_drop_shadow_child_silhouettes` to do with non-flattened
containers, which text shapes will now be exposed to. I hope to post a
PR after this to address these.
AI-assisted-by: claude-opus-5-5
With the WebGL renderer, applying a typography changed the text but left
its box at the old size, because nothing asked the renderer to measure
the text again. apply-typography now waits for the new font and resizes
the auto-grow texts inside its undo step, as the Design tab does.
The typography bar at the bottom of the canvas had its own copy of this
logic, with no resize and no undo step: the font-load heal resized the
box later without recording undo, so Ctrl+Z left the new size. It now
calls apply-typography.
Closes#13124
AI-assisted-by: claude-opus-5-5
* 🐛 Submit the import audit events from the import job
Since 2.20 the dashboard imports .penpot files through the
:import-binfile job, which submitted no audit event. The outcome of
an import and the files it created were lost, so analytics could no
longer tell completed imports from failed ones.
The job now submits the import-binfile event with the name and props
of the legacy RPC event (status, file-ids, file-count, project,
version, generated-by, referer), plus the job id, the team id, the
package size and the elapsed time. A cancelled job reports the
cancelled status. A completed import also submits a create-file event
per imported file, as the legacy RPC does. As in the RPC, an import
refused by the permission check submits no event.
Closes#13148
AI-assisted-by: claude-opus-5-5
* 🐛 Audit import jobs at their terminal transition
Run optional terminal hooks in the winning job transaction and use one
for import audit events. Preserve the separate import transaction and
cover cancellation, rollback, RPC paths, and dispatcher aborts.
AI-assisted-by: gpt-6.1-terra
* ♻️ Simplify the terminal job hook contract
Pass a semantic terminal job to the hook with its final status and
decoded parameters, result or error. Adapt the import audit and tests.
AI-assisted-by: gpt-6.1-terra
* 🐛 Keep import jobs bound to their original team
Freeze the destination team when creating an import job and serialize
imports with project moves. Use the frozen team for audit and webhook
events, and keep compatibility with existing jobs.
Select import audit props explicitly to prevent new job parameters from
being included in events by default.
AI-assisted-by: gpt-6.1-terra
* 📚 Document the import team fallback removal
Mark the legacy job audit fallback for removal in version 2.21.0.
AI-assisted-by: gpt-6.1-terra
* 🔧 Validate canonical AI model IDs in commit trailers
Require bare lowercase model IDs in AI-assisted-by trailers and cover
the validation with tests. Align the commit and PR workflows with the
same attribution rules.
AI-assisted-by: gpt-6.1-terra
---------
Co-authored-by: Andrey Antukh <niwi@niwi.nz>
* ✨ Honor trusted alternate origins for backend links and OIDC
Add PENPOT_TRUSTED_ORIGINS, an optional list of bare scheme://host[:port]
alternate origins. A request whose Origin matches (exact, trimmed and
lowercased) uses that origin as the base for links generated while serving
it: emails, asset URLs, audit and webhook link fields, and redirects.
Unlisted origins, requests without Origin, and background or server-to-server
work keep the canonical public-uri (fail-closed). Malformed entries warn at
startup and never match.
Stamp the trusted origin on the request with a global http middleware that
binds config public-uri for the request extent; expose the chain as
root-middleware so tests assert it runs before auth and errors. Build every
backend link through the canonical cf/get-public-uri.
Carry the origin in the signed OIDC state (auth and organization SSO) so the
callback, a navigation without Origin, re-applies it with with-public-uri for
the token-exchange redirect_uri and every redirect, including logout. Verify
the state token once per callback and reuse the claims; build redirect URIs
with ensure-path-slash plus join and append-query-param for hash routes. A
removed origin does not invalidate states signed before it (up to four hours).
Bring MCP OAuth into scope: wrap its routes, stage the origin in the Redis
request record at authorize time, and re-apply it in decision so issuer,
resource, the approval redirect and the code-exchange iss agree on one base.
Keep the log-capture watch installed while waiting for the async rejection
record in the save tests; a watch removed first lost late records and read
nil. Add a delayed-executor regression test that makes the race deterministic
and document the rule in the backend testing memory.
Closes#11625
AI-assisted-by: deepseek-v4.1-flash
AI-assisted-by: qwen3.7-plus
AI-assisted-by: gpt-5.6-luna
AI-assisted-by: muse-spark-1.3-contributor
* ✨ Serve trusted alternate origins across frontend and backend
Let one installation serve a canonical domain plus trusted alternate
origins, without letting request headers pick arbitrary link bases.
The backend normalizes `PENPOT_TRUSTED_ORIGINS` on load: it drops malformed
entries with a warning and warns about HTTP origins outside localhost. It
selects the first trusted origin from `X-Penpot-Origin`, then `Origin`, and
applies only scheme, host and port to the public URI, keeping the configured
path. MCP OAuth keeps the canonical base because its authorize navigation
has no usable origin.
The frontend reads the same list from `config.js`, filled by the container
entrypoint, and selects the browser origin only on an exact match. It sends
`X-Penpot-Origin` on RPC calls (including GETs and multipart) and OIDC
initiation, not on asset, font or external requests. SSE captures the request
bindings, and export jobs store the effective base so the download link uses
it after the request ends. A closed export creation schema excludes
`:public-uri`, which the backend adds only after validation.
Register the OIDC callback for each alias. Removing an alias does not stop
already signed OIDC state, queued mail or export jobs from using it.
Add regression tests across backend, frontend and the nginx entrypoint, and
document the proxy setup, worker upgrade and rollback, and alias retirement.
Refs #11625
AI-assisted-by: hy4-flash-free
AI-assisted-by: gpt-6-luna
AI-assisted-by: gpt-6.2-sol
* ✨ Add an options button to color assets
Color assets could only be renamed, edited, duplicated or deleted from
the right-click menu, which tablet users can't open. Add a three-dot
options button, like the one on typography assets, that opens the same
menu below the button. It shows on hover and focus, and stays visible on
devices without hover.
Closes#12618
AI-assisted-by: Claude Opus 5.5
* 🐛 Keep the color asset options button reachable by keyboard
The options button was hidden with visibility, which also takes it out
of the tab order, so :focus-within could never reveal it from the
keyboard. Hide it with opacity instead, so Tab reaches the button and
shows it.
Open the menu through one helper for both the right click and the
button, so both keep clearing the selection first.
AI-assisted-by: Claude Opus 5.5
* 🐛 Toggle the color asset menu and fix its row and focus
---------
Co-authored-by: Luis de Dios <luis.dedios@kaleidos.net>
* 🐛 Keep all padding sides when setting one on a layout without padding
Setting one padding side on a board whose layout had no stored padding
(made through the API or MCP) saved only that side, for example {:p1 12}.
The backend rejected the shape as invalid.
Start a padding change from the four sides at 0 when the shape has no
padding yet.
Closes#13265
AI-assisted-by: claude-opus-5-5
* 🐛 Complete the layout padding after patching it
From the review: fill the four padding sides after the patch instead of
before, so a side cleared to nil also becomes 0, and any layout change
completes a partial padding saved before the fix.
AI-assisted-by: claude-opus-5-5
* 🐛 Leave gradient mode when undo removes a stroke gradient
Undoing a gradient with the color picker open sent a plain color.
The picker dropped the stops but stayed in gradient mode, so adding
a stop built a gradient with no coordinates or colors and applied it
to the stroke. The backend rejected it as an invalid shape.
Switch the picker to color (or image) when the color is no longer a
gradient, and skip invalid gradients before applying them.
Closes#13261
AI-assisted-by: claude-opus-5-5
* 🐛 Cover more colorpicker cases in the stroke gradient tests
From the review: plain and image colors still reach on-change through
the gradient guard, both gradient types leave the gradient tab, and a
plain color keeps the color tab. The image tab test is renamed after
what it checks.
AI-assisted-by: claude-opus-5-5
The legacy editor writes the attrs it gets into the data of an empty
paragraph, nil values included, so turning off a text decoration there
leaves :text-decoration nil. finalize-editor-state copied that data into
the shape content as it was, the only commit path that skipped
ensure-valid-text-content, and the backend rejected the shape. Build the
content with a helper that runs it, shared by both renderer branches.
Closes#13252
AI-assisted-by: claude-opus-5-5