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

Add Preview images for Snippets #222

Closed
kyrie25 opened this issue Jun 8, 2022 · 4 comments Β· Fixed by #226
Closed

Add Preview images for Snippets #222

kyrie25 opened this issue Jun 8, 2022 · 4 comments Β· Fixed by #226
Assignees
Labels
πŸ’« enhancement New feature or request

Comments

@kyrie25
Copy link
Member

kyrie25 commented Jun 8, 2022

πŸ“ Provide a description of the new feature

Add Preview images similar to Extensions/Themes for Snippets in addition to the description.

βž• Additional Information

No response

@theRealPadster theRealPadster added the πŸ’« enhancement New feature or request label Jun 8, 2022
@theRealPadster theRealPadster self-assigned this Jun 9, 2022
@theRealPadster
Copy link
Member

theRealPadster commented Jun 10, 2022

image

  • I've started work on this. I'll need preview images for all our default snippets.
  • Also need to decide what to do if there is no image for a snippet.
  • And we could potentially allow the user to upload an image for their own custom snippets, either via a URL or by storing the image as base64 in the localstorage data. Not sure if worth it though.

@kyrie25
Copy link
Member Author

kyrie25 commented Jun 10, 2022

For the non-images one, I'm sure a placeholder like the Spicetify logo would do.
As for the base64 encoded images, I'd prefer using a GitHub Raw URL to fetch the images as it'd be easier to update and maintain without changing too much data on the user's side. But if there is no need to update them then base64 would do.

@theRealPadster
Copy link
Member

As for the base64 encoded images, I'd prefer using a GitHub Raw URL to fetch the images as it'd be easier to update and maintain without changing too much data on the user's side. But if there is no need to update them then base64 would do.

I just meant for user-added snippets, we could use an HTML file upload input and store the image as base64 so they don't need to go and host their image somewhere and then paste the URL in.

@kyrie25
Copy link
Member Author

kyrie25 commented Jun 10, 2022

Oh I see, that would be the optimal solution I agree. Need to add a base64 converter into util also so that it can be used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
πŸ’« enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants