Skip to content

Paste saved linked designs at the viewport pointer (#2430) - #2433

Merged
jyviko merged 15 commits into
tangency-labs:mainfrom
amolinari-autotex:feat/linked-design-clipboard
Oct 20, 2026
Merged

jyviko merged 15 commits into
tangency-labs:mainfrom
amolinari-autotex:feat/linked-design-clipboard

Conversation

@amolinari-autotex

@amolinari-autotex amolinari-autotex commented Oct 18, 2026 •

Copy link
Copy Markdown
Contributor

Claims #2430. Related to #2250.

Change

Copy a saved, unmodified design root, switch document tabs and paste. Paste inserts an ungrounded linked occurrence, reuses its component definition on repeated pastes, and opens that document's Move/Copy controls.

The source origin now lands on the surface under the viewport pointer. Over empty space it uses the active parent's XY plane; absent, parallel, behind-camera or invalid rays fall back to the parent origin. Placement is converted into the parent's coordinates and belongs to the paste's single undo step. The source is unchanged.

The pre-existing occurrence arrow input repair is maintained separately in #3015 / #3014. This PR contains pointer placement and numeric-placement regression coverage; it does not duplicate the shared viewport patch.

Validation

  • Windows integration: UI library 1,224 passed, 0 failed, one existing ignored test and the known upstream Windows file-URI fixture excluded. Strict workspace/all-target Clippy, formatting and WebAssembly checks (12 crates) passed.
  • Native app and CLI builds passed. The actual five implementation heads were merged normally into the trial; its source tree is identical to the tested tree.
  • Asset attribution, licences, sorted lists and dependency layering passed.
  • Full cargo xtask ci was attempted. This Windows checkout stops at unchanged SVG master/review hash checks caused by checkout line endings. No icon artwork or acceptance hashes were changed. No full-workspace or GitHub CI pass is claimed.

Native Ctrl+V across two document tabs placed the source origin at [40,25,8] on a plate without moving the camera. Undo/redo retained the initial placement and the source file hash was unchanged. Combined QA also exercised the separately supplied arrow fix. Regression coverage checks rotated-parent coordinates, missing/off-viewport pointer fallbacks, linked reuse, document-local movement state and refusal of invalid sources.

Screenshots of the behavior (when observable)

Actual native PNGs from small public-safe examples were captured and visually inspected locally, including before/after evidence where useful. Public media attachments remain pending; generated screenshots were not committed as repository assets.

Integration status

Validated on upstream 34cb3167 with the combined contributions, trial commit b59369cb. Latest checked main was 3a9b053f; local merge simulations for all five branches completed without conflicts. Maintainer commits and published history were preserved with normal merges and pushes.

The user verified and accepted this behavior in the frozen integrated trial (b59369cb), matching the published head. This PR is ready for review. No merge or release was performed; no full GitHub CI pass is claimed.

@bherbruck bherbruck left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks!

@bherbruck bherbruck added the approved-for-ci Reviewed: run the full PR CI (build, tests, goldens, Clippy) label Oct 19, 2026
@amolinari-autotex
amolinari-autotex marked this pull request as draft October 19, 2026 09:51
@amolinari-autotex amolinari-autotex changed the title Paste a saved design into an assembly as a linked component (#2430) Paste saved linked designs at the viewport pointer (#2430) Oct 19, 2026
@amolinari-autotex
amolinari-autotex marked this pull request as ready for review October 19, 2026 12:13
@jyviko
jyviko added this pull request to the merge queue Oct 19, 2026
Merged via the queue into tangency-labs:main with commit 07be3f8 Oct 20, 2026
35 checks passed
BrunIF pushed a commit to BrunIF/solidcraft that referenced this pull request Oct 20, 2026
… (tangency-labs#2433)

* claim: tangency-labs#2430

* feat: copy saved designs between documents as linked components

* fix: keep occurrence movement controls with their document tab

* test: cover linked design clipboard across tabs

* fix: place linked design pastes at the viewport pointer

---------

Co-authored-by: bherbruck <brennen.herbruck@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved-for-ci Reviewed: run the full PR CI (build, tests, goldens, Clippy)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants