Don't show again not taken into account when left button is used

Created on 7 February 2025, about 2 months ago

Just wandering: is it normal that when 'Don't show again' is checked and left button is used to dismiss the modal, 'Don't show again' is not saved and the next time, the modal appears again?

💬 Support request
Status

Active

Version

5.1

Component

Miscellaneous

Created by

🇫🇷France gbmapo

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

Merge Requests

Comments & Activities

  • Issue created by @gbmapo
  • 🇧🇷Brazil renatog Campinas

    It's a really interesting point

    When created we assumed that the right button was the "OK button" and left button was like a "Cancel button"

    For this reason the "Don't show again" was working only with the right button, you know?

    However I think it's a interesting feature

    Like, inside of configuration of "Don't show again" we can set if it would be applied by right button, left button or maybe both buttons

    What do you think, is that makes sense?

  • 🇫🇷France gbmapo

    I'd say it really makes sense.
    Knowing that the right button allows to redirect to another URL, the important thing should be: Did I check the 'Don't show again' box, whatever button I choose to close the modal.
    It would be nice to implement this feature. Thanks.

  • 🇧🇷Brazil renatog Campinas

    Knowing that the right button allows to redirect to another URL, the important thing should be: Did I check the 'Don't show again' box, whatever button I choose to close the modal

    Good catch

    There is also a scenario where the end-users can mark the "don't show again" and closing the Modal using the ESC key or clicking outside. So it'll be closed without clicking in right or left button

    I think would be great if has an option to consider the "don't show again" on these cases as well

    I'm converting this issue into a "feature request" so we can have this idea mapped to be implemented in the future

  • I've raised the MR for the same please review.

  • 🇧🇷Brazil renatog Campinas

    Thanks for your effort on this! It's amazing

    But the AJAX url has been removed intentionally?

    /modal/ajax/hook-modal-submit

  • Sorry @renatog for removing the AJAX URL by mistake.
    I have added that back and working fine for me please review.

  • 🇧🇷Brazil renatog Campinas

    Sorry @renatog for removing the AJAX URL by mistake

    No problems at all

    I have added that back and working fine for me please review

    Thank you so much! It's really a great start!

    However I was thinking about an checkbox in the admin area
    Example:
    Go to accordion "Don't show again"
    A new dropdown called: "Don't show again when:"
    Two options:

    1. Marked the checkbox and right button clicked (default)
    2. Marked the checkbox and Modal closed by any means

    The option #1 will continue as today (apply cookie only if checkbox is Marked and clicked in the right button)
    If the user selects option #2 when close the Modal the logic on this MR would be applied, you know?

Production build 0.71.5 2024