Skip to content

Commit

Permalink
Open any link with _popup=1 query-string parameter in a modal window.
Browse files Browse the repository at this point in the history
  • Loading branch information
fabiocaccamo committed Feb 14, 2024
1 parent 979c8c5 commit 3d5d5ae
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,9 @@ if (typeof(django) !== 'undefined' && typeof(django.jQuery) !== 'undefined')
// show_change_link=True support
presentRelatedObjectModalOnClickOn('a.inlinechangelink');

// any link with _popup=1 parameter support
presentRelatedObjectModalOnClickOn('a[href*="_popup=1"]');

// django-streamfield support
// https://github.com/raagin/django-streamfield/
presentRelatedObjectModalOnClickOn('.streamfield_app a.stream-btn[href*="_popup=1"]');
Expand Down

0 comments on commit 3d5d5ae

Please sign in to comment.