feat(#571): share dialog — people and groups, internal link, public link #581
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix-571dlg"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The dialog from the approved mockup. Three sections in the agreed order, backed entirely by what #573–#576 already shipped.
The policy rule is the tested part.
pure:share-sectionsencodes what we settled in rev 2:share-sections.test.jsalso pins the claim most likely to be "tidied" away by someone wiring all three sections to one flag: the internal link survives every combination, because it grants nothing on its own.The internal link is not a new invention. Line 6639 already builds one for the copy-location feature:
and the
loc:hash handler probes access and sayslocNoAccesswhen the viewer has none. That is precisely "grants nothing, resolves only for people who already have access" — so the section reuses the proven format rather than a guess.Two things the implementation decides, both deliberate:
Surgical notes. The existing markup was moved, not rewritten: the protection, expiry, password, upload and result blocks are captured verbatim by id and re-parented into the new Public link section, because those lines carry shipped i18n copy and em-dashes that retyping would silently alter. Every id the current submit handler depends on is unchanged, so link creation is untouched. The
#sharedlg.shareoffCSS is removed — nothing applies that class any more, the sections carry their own state.Federated send needed no work: line 872 already carries
#sharedlg-fed{display:none !important}, so the surface #572 exists to relocate is already dark.17 new i18n keys ×4.
What I have not verified, and cannot. These tests cover the policy rule, JS syntax and the #389 desktop-invariant fence — not appearance, and not a live round-trip against the grant API. The dialog is substantially restructured and I have not seen it render. It wants a look on the dogfood before it is trusted.
Verified:
share-sections.test.jsgreen (red witnessed first — the block did not exist), all ten web tests green,extract.js+node --checkgreen,\\uescape guard green, full Go suite green.