Skip to content

[PER-10476] Migrate publish dialog and fix title crash for Stela folders#1090

Draft
aasandei-vsp wants to merge 1 commit into
PER-10476-replace-navigate-lean-v2from
PER-10476-replace-navigate-lean-v3
Draft

[PER-10476] Migrate publish dialog and fix title crash for Stela folders#1090
aasandei-vsp wants to merge 1 commit into
PER-10476-replace-navigate-lean-v2from
PER-10476-replace-navigate-lean-v3

Conversation

@aasandei-vsp

@aasandei-vsp aasandei-vsp commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Issue: PER-10476
Subtask: https://permanent.atlassian.net/browse/PER-10679

Do not merge before #1089

Manual test cases — Publish dialog migration and title crash fix

Setup: log in on an archive with at least one private folder (with items), one private record, and one already-published item.
EXPECTED: only the Publish dialog is affected by this PR — opening it, its title, and the folder publish flow.


Dialog title — private items

  1. Open Publish on a private folder and keep the browser console open.
    • EXPECTED: The title reads "Publish " and no TypeErrors appear in the console. (Bug fix — the template read folder_linkType unguarded, which folders loaded through the Stela API don't have, causing a repeating TypeError on every change detection cycle.)
  2. Open Publish on a private record.
    • EXPECTED: The title reads "Publish " with no console errors.

Dialog title — already-public item

  1. Open Publish on an item that is already public.
    • EXPECTED: The title reads "Get public link for " and the public link is shown immediately.
  2. Click "Copy link".
    • EXPECTED: The link is copied and the button changes to "Link copied".

Publishing a folder

  1. Open Publish on a private folder with items and click Publish.
    • EXPECTED: The spinner resolves and a public link appears (the dialog polls the Public workspace through the new endpoint to find the copy).
  2. Follow the generated link.
    • EXPECTED: The public copy opens. (Known open issue: the copy may appear empty — under investigation with the backend team; if it reproduces, capture the v2/folder/{id}/children response.)

Publishing a record

  1. Open Publish on a private record and click Publish.
    • EXPECTED: A public link appears; following it opens the record in the public view.

Replace navigateLean with getWithChildren in the publish polling
loop. Compute the dialog title from a component property that also
checks the item type, since folders loaded through the Stela API
have no folder_linkType and the raw template access threw a
TypeError on every change detection cycle.

Issue: PER-10476
@aasandei-vsp aasandei-vsp self-assigned this Jul 16, 2026
@aasandei-vsp
aasandei-vsp marked this pull request as draft July 16, 2026 12:19
@codecov

codecov Bot commented Jul 16, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 60.00000% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 52.32%. Comparing base (5bbdd9f) to head (578d1b8).

Files with missing lines Patch % Lines
...le-browser/components/publish/publish.component.ts 60.00% 2 Missing ⚠️
Additional details and impacted files
@@                          Coverage Diff                           @@
##           PER-10476-replace-navigate-lean-v2    #1090      +/-   ##
======================================================================
- Coverage                               52.32%   52.32%   -0.01%     
======================================================================
  Files                                     355      355              
  Lines                                   12130    12133       +3     
  Branches                                 2190     2191       +1     
======================================================================
+ Hits                                     6347     6348       +1     
- Misses                                   5553     5559       +6     
+ Partials                                  230      226       -4     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant