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

allow dropping & replacing main thumbnail #238

Merged
merged 3 commits into from
Aug 2, 2019

Conversation

whyboris
Copy link
Owner

@whyboris whyboris commented Aug 2, 2019

⚠️ TODO: document the feature in FAQ !!!

Closes #206

@whyboris whyboris added ⛑️ WIP Work in progress 2.0.0 Priority for v2.0.0 release labels Aug 2, 2019
@whyboris whyboris requested a review from cal2195 August 2, 2019 19:37
@whyboris whyboris added enhancement Improves existing features and removed ⛑️ WIP Work in progress labels Aug 2, 2019
@whyboris whyboris merged commit cc11a67 into master Aug 2, 2019
@whyboris whyboris deleted the drop-jpg-to-replace-thumb branch August 2, 2019 21:46
Copy link
Collaborator

@cal2195 cal2195 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I might also support the idea I had suggested! 😄

*/
droppedSomethingOverVideo(event, galleryItem: ImageElement) {
const pathToNewJpg: string = event.dataTransfer.files[0].path;
if (pathToNewJpg.endsWith('.jpg') && galleryItem.cleanName !== '*FOLDER*') {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

.JPG .JPEG .jPeG? 😄
Can we support other image types?

Copy link
Owner Author

@whyboris whyboris Aug 17, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks! I forgot the toLowerCase() 😅

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed with #256

main-extract.ts Outdated
const width: number = Math.floor(height * (16 / 9));

// desired command:
// ffmpeg -y -i IN.png -vf "scale=1280:720:force_original_aspect_ratio=decrease,pad=1280:720:(ow-iw)/2:(oh-ih)/2" OUT.jpg
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see .png here!

(
pathToNewJpg.endsWith('.jpg')
|| pathToNewJpg.endsWith('.jpeg')
|| pathToNewJpg.endsWith('.png')
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, disregard last comment! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.0.0 Priority for v2.0.0 release enhancement Improves existing features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Choose preview image if desired
2 participants