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 Custom Placeholder Image for Recipes by Utilizing User-Uploaded Images #448

Open
aaron-r-campbell opened this issue Oct 8, 2024 · 0 comments
Labels
enhancement New feature or request frontend Go HTML templates go Pull requests that update Go code
Milestone

Comments

@aaron-r-campbell
Copy link

Suggested Improvement

Given that the app supports user-uploaded images in the ~/.configs/Recipya/Images/ directory, it would be logical to store placeholder.webp there as well.

Current Behavior

Currently, recipes without an assigned image display a hard-coded placeholder from the binary:
http(s)://hostname/static/img/recipes/placeholder.webp.

Proposed Behavior

  1. Check if placeholder.webp exists in the ~/.configs/Recipya/Images/ directory.
    • If it does not exist: Copy the existing hard-coded image from the binary to this folder as placeholder.webp.
    • If it exists: Use this image as the placeholder for recipes without an assigned image.

Benefits

  • Improved Customization: Users can set their own placeholder, making the app feel more personal.
  • Consistency: The placeholder can match the style of user-uploaded images, enhancing the overall aesthetic.

Additional Considerations

  • Ensure that the app checks for updates to the placeholder.webp if the user wants to change it.
  • Implement logging to track when the app copies the default placeholder.webp to the user’s directory.
@aaron-r-campbell aaron-r-campbell added the enhancement New feature or request label Oct 8, 2024
@reaper47 reaper47 added go Pull requests that update Go code frontend Go HTML templates labels Oct 9, 2024
@reaper47 reaper47 added this to the v1.3.0 milestone Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request frontend Go HTML templates go Pull requests that update Go code
Projects
Status: No status
Development

No branches or pull requests

2 participants