Clean All - Wishlist

Clear the visitor's saved items for one configured post type. Use it as a deliberate list-management action on a wishlist page or saved-content panel, with an optional confirmation popup.

Setup and First Use


Before starting, enable the relevant element or feature family under Bricks → BricksUltimate → General Elements, save, and reopen the Bricks editor. Integrations also require their corresponding plugin to be active.

  1. Enable Favourite/Wishlist and create a working saved-items list first.
  2. Add (BU)Clean All - Wishlist outside the repeated wishlist cards so it appears once.
  3. Set Post type to match the list that should be cleared.
  4. Choose Button type, enter clear Button Text, and set an accurate Aria label.
  5. Enable confirmation modal if clearing the list should require confirmation. Edit its nested content and set Cancel button selector and Confirm button selector to the actual controls.
  6. Style the button, loading feedback, modal, and backdrop; test cancel, confirm, and the final empty state.

Controls and Settings


ControlPurpose and usage
Post typeClears that list, not every wishlist across all post types and not other users' lists.
Button type / Text / Aria labelChoose a normal button or plain-link presentation and make the destructive action clear.
Size / Style / Circle / OutlineButton variants apply when the Button type uses button presentation.
Icon / Loading / HoverCustomize visual states and keep the loading state recognizable.
Enable confirmation modalAdds the confirm/cancel workflow. Use Show preview on builder to edit the popup content.
Cancel / Confirm button selectorMust match the nested controls you actually create. A mismatched selector leaves a visible dialog without a working action.
Modal / BackdropSet background, border, shadow, dimensions, and overlay behavior with narrow viewport checks.

List Scope and AJAX Updates


Clearing the product wishlist should not clear saved articles if their post types differ. Counters and listings must use the same saved-list context to update consistently. Verify AJAX-rendered panels as well as a full page reload after clearing. This is not an admin bulk-delete tool for all customers.

Confirmation and Empty Presentation


Explain the scope in the dialog, for example Remove all saved products? Provide a clear Cancel action and avoid using the same CSS selector for both buttons. After success, display the wishlist's empty state and hide list-only actions where appropriate; an empty frame and active Clear All button are confusing.

Practical Example


Place Remove all saved products above a product wishlist. Enable confirmation, use unique .wishlist-clear-confirm and .wishlist-clear-cancel selectors, then confirm that Cancel changes nothing and Confirm clears the list and counter.

Troubleshooting


  • Nothing clears: check Post type and inspect the AJAX response.
  • Modal opens but buttons do nothing: fix the confirmation selectors.
  • Unexpected list clears: correct the configured post type before publishing.
  • Stale cards remain: inspect the saved-list refresh wrapper and page caching.

Related Documentation