Skip to content

Warn about shared elements in the delete confirmation dialog - #958

Open
flomillot wants to merge 3 commits into
mainfrom
feat/warn-about-shared-elements-on-delete
Open

Warn about shared elements in the delete confirmation dialog#958
flomillot wants to merge 3 commits into
mainfrom
feat/warn-about-shared-elements-on-delete

Conversation

@flomillot

@flomillot flomillot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

When deleting elements in GridExplore, the confirmation dialog now tells whether the selection contains elements shared with other elements, along with their number of sharing links.

An element is considered shared as soon as its references array is not empty, each reference being a sharing link — the same criterion as the "Display sharing links" contextual menu entry.

The delete button is disabled as long as the selection holds a shared element, so a deletion that would break the referencing elements cannot be confirmed. Marked with a TODO, to be removed once the deletion of shared elements is handled.

Display the sharing links of the selected elements in the deletion
confirmation, so that permanently deleting an element used elsewhere is
not done unknowingly.

A single selected element gets a plain sentence, a multiple selection
gets the list of the shared elements with their number of sharing links.

Signed-off-by: Florent MILLOT <florent.millot_externe@rte-france.com>
@coderabbitai

coderabbitai Bot commented Aug 18, 2026

Copy link
Copy Markdown

Important

Review available on request

  • 🔍 Trigger review

Reviews should be triggered manually for repositories with fewer than 10 stars. Select Trigger review above or comment @coderabbitai review to review the latest changes. For a full review, comment @coderabbitai full review.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 295148ef-a8d2-429f-acdd-1e12312bae93


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Deleting an element still referenced elsewhere breaks the referencing
elements, so the confirmation only informs about the sharing links and
no longer allows the deletion.

Signed-off-by: Florent MILLOT <florent.millot_externe@rte-france.com>
Signed-off-by: Florent MILLOT <florent.millot_externe@rte-france.com>
@sonarqubecloud

Copy link
Copy Markdown

@ghazwarhili
ghazwarhili self-requested a review August 19, 2026 09:36
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