discourse/app/assets
Ted Johansson 1b132dad0d
FIX: Correctly pre-select first option in bookmark notification drop-down (#20976)
When selecting the "Keep bookmark" in the user preference for what to do after a bookmark reminder is sent, it does not propagate to the drop-down in the "Create bookmark" modal. Instead it defaults to "Keep bookmark and clear reminder". All other options work fine.

We set a default ("Keep bookmark and clear reminder") if no user preference is found, However, this uses the index of the option, and the index of the first option ("Keep bookmark") is 0, which is treated as falsey in JavaScript, thus causing the default to be selected.

This change switches from logical "or" conditional `||` operator to nullish coalescing `??` operator.
2023-04-06 14:58:40 +08:00
..
images FIX: fallback to default push notification icon if none exists (#16961) 2022-06-01 12:00:05 +10:00
javascripts FIX: Correctly pre-select first option in bookmark notification drop-down (#20976) 2023-04-06 14:58:40 +08:00
stylesheets UX: fix spacing between assign tags (#20967) 2023-04-04 17:26:06 -04:00