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

Investigate plugin for galleries instead of storing images in website #385

Closed
iranzo opened this issue Jun 28, 2019 · 19 comments
Closed

Investigate plugin for galleries instead of storing images in website #385

iranzo opened this issue Jun 28, 2019 · 19 comments
Milestone

Comments

@iranzo
Copy link
Member

iranzo commented Jun 28, 2019

Check https://github.com/La0/pelican-flickr/tree/e1b6dddf2cd12aef4096d2b01e5af6e15d46683a

@talha131 talha131 added this to the Roadmap milestone Jun 28, 2019
@talha131
Copy link
Member

@iranzo can you please look into this issue?

If no one is willing to take this issue in near future then lets close this one.

@iranzo
Copy link
Member Author

iranzo commented Aug 19, 2019

Yes, I have it on my todo to allow 'smaller' websites, thing is that it requires getting flicker ID, etc which makes it harder.

In telegram, instagram galleries are automatically shown with some specifics so wanted to investigate that too

image

Would be great to find some similar way to do that (and no require extra config like API id's, etc), so still under my radar :-)

@talha131
Copy link
Member

Thank you @iranzo for updating us.

@iranzo
Copy link
Member Author

iranzo commented Jan 27, 2020

Tried with liquid for both instagram and flickr and no luck, just one image is shown on the post (even if it works):
image

@iranzo
Copy link
Member Author

iranzo commented Jan 27, 2020

I did a hack with some javascript and I get this:

image

So I can display instagram galleries easily, without any api code, etc with just adding some code to athe article.html and a new 'yaml' preamble tag.

I'll pr to get feedback

@iranzo iranzo changed the title Investigate flickr plugin for galleries instead of storing images in website Investigate plugin for galleries instead of storing images in website Jan 27, 2020
@iranzo
Copy link
Member Author

iranzo commented Jan 27, 2020

For checking PR: please do add to your yaml preamble:

instagram: B6-6UjeqgA-

And using the updated article.html it should work

@iranzo
Copy link
Member Author

iranzo commented Jan 27, 2020

@talha131 here I'll need your help for tuning the css, as I just copied/pasted what I found to get it working.

Also, I had to add jquery when supposedly should be loaded from base.html.

Thanks for your help

@iranzo
Copy link
Member Author

iranzo commented Jan 28, 2020

Instagram inclusion by ID is pretty 'useful', but we could also consider define a json of image data so that we can alternatively link url's in any website by just using that linked file.

For me instagram simplifies the 'storage + referencing' but arbitrary url could also be possible probably via another yaml preamble variable containing the array path

@talha131
Copy link
Member

we could also consider define a json of image data so that we can alternatively link url's in any website by just using that linked file.

Can you please share an example or a dummy json to explain this feature?

@iranzo
Copy link
Member Author

iranzo commented Jan 30, 2020

Check https://github.com/kubevirt/kubevirt.github.io/pull/450/files for an example (in this case the way it's implemented here it's different)

@talha131
Copy link
Member

I see. We would need a plugin to read the JSON file. Secondly, I don't think users would go for it because it is manual and difficult to setup JSON.

@talha131 talha131 modified the milestones: Roadmap, 2020 - Q1 Jan 30, 2020
@talha131
Copy link
Member

I am closing this issue in favor of our ongoing discussion on #560

@iranzo
Copy link
Member Author

iranzo commented Jan 30, 2020

I see. We would need a plugin to read the JSON file. Secondly, I don't think users would go for it because it is manual and difficult to setup JSON.

In this case, the 'plugin' is just a javascript that does the processing/reading so it shoudln't be that 'hard' no need for plugins at pelican level

@talha131
Copy link
Member

No we would need a plugin to get json from the metadata. Pelican metadata does not support JSON. User will have to write the JSON file somewhere else. Plugin will load the JSON file and pass it to the theme.

@iranzo
Copy link
Member Author

iranzo commented Jan 30, 2020

My idea was to use javascript for that, it can issue ajax to get the json file and then parse. Each user would then need to write the json with the image data, etc

@talha131
Copy link
Member

In which case, the user will have to mention the fine URL in the metadata.

Elegant will load the JSON and then render it. It's a good idea, but does not offer much utility over other existing methods.

I would wait for someone to request it specifically before we pour our resources into it.

@iranzo
Copy link
Member Author

iranzo commented Jan 30, 2020

ok!

@iranzo
Copy link
Member Author

iranzo commented Jan 30, 2020

About photoswipe: 'https://photoswipe.com/documentation/faq.html#image-size' Requires to know 'in advance' image dimensions, so additional preprocessing is needed (just FYI)

@talha131
Copy link
Member

Responded here #567 (comment)

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

No branches or pull requests

2 participants