Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mixed content html/img/iframe galleries don't use the correct filter type #421

Open
3 tasks
chris-twiner opened this issue Sep 14, 2021 · 2 comments
Open
3 tasks

Comments

@chris-twiner
Copy link

What kind of issue is this? (put 'x' between the square brackets)

Inserting the following to featherlight.js line 227:

if (data === '' && !filter) {
  var typeValue = readTargetAttr('data-featherlight-type');
  data = typeValue || '';
}

allows attributes to use the data-featherlight-type to bind when directly clicked the correct type and during gallery navigation when started from another 'slide'. Noticeable in the case of this attribute being iframe as ajax is the default contentFilter it will load the entire iframe page and insert the elements directly instead of an iframe when navigated to.

@chris-twiner
Copy link
Author

apologies for an incomplete ticket, I didn't want to forget to raise it. I'll add the example later.

@chris-twiner
Copy link
Author

found further inconsistent handling of mixed galleries, (could still be an rtfm issue of course):

var typeValue = readTargetAttr('data-featherlight-type');
if ( (data === '' && typeValue) &&
   (!filter || !(filter === filters[typeValue]))) {
    data = typeValue;
    filter = undefined;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant