Skip to content

feat: add preference to show full file path in data links; add labels for UI display to data links#344

Open
allison-truhlar wants to merge 15 commits intomainfrom
transparent-links
Open

feat: add preference to show full file path in data links; add labels for UI display to data links#344
allison-truhlar wants to merge 15 commits intomainfrom
transparent-links

Conversation

@allison-truhlar
Copy link
Copy Markdown
Collaborator

Clickup ids: 86abc1mrr; 86a9drafp

This PR adds two features:

  • Transparent links — a URL construction mode. When enabled the full relative path appears in the URL instead of just the basename. Set at creation time, immutable. Can be enabled by the user via the preferences page (anytime) or the data link creation dialog (only when automatic data link creation is off).
  • Data link labels (sharing_name) — a display-only label for the data link (shown in the "Label" column on the Links page). The variable name sharing_name is kept throughout the codebase; only the UI label changes to "Label". Editable at any time without breaking the link. Defaults to path_basename, as previously done for the sharing_name value. The user can access the edit dialog via the properties panel in the file browser (when navigated to a directory with a data link) or via the action menu for a given link row in the data link table on the /links page.

Collapse /files/{key}/{sharing_name}/{path} into /files/{key}/{path}. _get_file_proxy_client now resolves subpath by matching captured_path against stored path or basename with boundary guards. This is backwards compatible with existing links because {sharing_name} used to just be the name of the directory the data link was being created for (now called a non-transparent link)
also needed to update the mock for /api/proxied-path for the DataLinkDialog test
New mutation with optimistic rollback for PUT /api/proxied-path/:key.
also change the column heading on the data link table from "name" to "label"
@allison-truhlar allison-truhlar requested a review from krokicki April 8, 2026 17:15
Copy link
Copy Markdown
Member

@krokicki krokicki left a comment

Choose a reason for hiding this comment

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

I like the data labels!

For the transparent URLs, it shows me that the link will look like this:
https://.../<key>/annotations/jrc_P3-E5-D1-N2_v2_destreaked/crop12/crop12cell_labels_for_ML/amira_export.zarr

It needs to include the full path (i.e. mount path of the FSP at the beginning) to be fully transparent.

sharing_key: proxiedPathByFspAndPathQuery.data!.sharing_key,
sharing_name: newLabel
});
toast.success('Data link label updated');
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think this is the same code as handleConfirmLabel in linksColumn. Is there a way to reuse it?

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.

2 participants