Prevent form anomalies from resulting in multiple confirm dialogs

Created on 16 September 2025, 2 days ago

Problem/Motivation

A bug was brought to my attention where an edit form could end up having multiple save buttons.

It seems to be exacerbated by a node form that has a media field that has a required alt title field is the only required field left unfilled.

One of my clients us using a gin theme (not sure if this is why) but for some reason there were two save buttons in the form markup, one was hidden and the other was visible. This threw off the javascript.

This was causing issues (multiple dialogs open, cancel one, have to cancel the next).

So I've tightenned up the js to only open one confirmation dialog per click.

Steps to reproduce

See problem/motivation

Proposed resolution

See patch

Remaining tasks

Review patch

User interface changes

Improvement

API changes

N/A

Data model changes

🐛 Bug report
Status

Active

Version

2.0

Component

Code

Created by

🇨🇦Canada joseph.olstad

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

No activities found.

Production build 0.71.5 2024