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

Shows default image in the frontend #91

Merged
merged 2 commits into from
Jan 30, 2017

Conversation

hermzz
Copy link
Collaborator

@hermzz hermzz commented Jan 26, 2017

Because finding a new logo image is outside of the scope of this PR I've just created a placeholder for the time being.

Fixes #82.

@hermzz hermzz requested a review from RyanNoelk January 26, 2017 22:04
Copy link
Owner

@RyanNoelk RyanNoelk left a comment

Choose a reason for hiding this comment

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

We should also drop the default image: api/base/default.png and the management command folder: api/base/management. We are not using them anymore

showRecipeImageThumb: function() {
if (this.props.data.photo_thumbnail) {
return (
<img className="img-responsive" src={ this.props.data.photo_thumbnail } />
Copy link
Owner

Choose a reason for hiding this comment

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

I think we should also show the default image here as well. Just doesn't look as good without it, IMO.

id: 'recipe.photo_placeholder',
description: 'Photo placeholder',
defaultMessage: 'Generic placeholder thumbnail'
}
});

return (
<div className="recipe-details">
<h1 className="title hidden-xs">{this.props.data.title}</h1>
Copy link
Owner

Choose a reason for hiding this comment

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

Should we only show this header if there is an Image? Looks weird to have it twice so quickly. Thoughts?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good point, but now that I've had a good look, I'm not convinced the current layout makes a lot of sense. If the image exists, we show the image twice, which looks kinda weird. And if there is no image, then we show the title of the recipe in a different place and a useless placeholder. I feel like we should either just show the large image first and no first header or thumbnail. Or just the thumbnail (with a placeholder if no image) and have the green title always be the header. Or maybe the large image appears under the green title?

I'm going to remove the first title if the image doesn't exist for the time being, and we can open a separate issue to see if we can improve this page.

Copy link
Owner

Choose a reason for hiding this comment

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

I'm by no means a UX/UI expert. If you have some ideas, I'd love to see them

@hermzz hermzz force-pushed the default-recipe-images branch 2 times, most recently from c55a317 to 78be059 Compare January 27, 2017 15:27
Copy link
Owner

@RyanNoelk RyanNoelk left a comment

Choose a reason for hiding this comment

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

I'm still seeing the default image in the api api/base/default.png. I'm not 100% sure of the license for that, we should drop it.

Otherwise LGTM!

@hermzz
Copy link
Collaborator Author

hermzz commented Jan 30, 2017

Good point, deleted!

@RyanNoelk
Copy link
Owner

Maybe I'm crazy but I'm not seeing the image as deleted. Did you forget to push a commit?

@hermzz
Copy link
Collaborator Author

hermzz commented Jan 30, 2017

Not crazy, I'm a moron. Commit pushed for reals this time.

@RyanNoelk RyanNoelk merged commit 6e4143f into RyanNoelk:dev Jan 30, 2017
@hermzz hermzz deleted the default-recipe-images branch January 31, 2017 13:55
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

Successfully merging this pull request may close these issues.

2 participants