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

Frontend Rewrite #219

Closed
wants to merge 27 commits into from
Closed

Frontend Rewrite #219

wants to merge 27 commits into from

Conversation

unseen-ninja
Copy link
Collaborator

@unseen-ninja unseen-ninja commented Jan 28, 2024

Cheers! o/

I've wanted to do this for a while since there are a few things that bug me about the current state of the frontend – I was young and naive back when I did those things. :^)

With this PR I'm proposing a rewrite of the frontend using Astro in order to generate fully static files in order to reduce all the clientside efforts currently in place.

As of right now this breaks two things:

  • Search: Which so far is intended as I feel like the search is lacking anyway – which is more due to lazy tagging by theme authors than anything else. I have instead opted for visible tags on each theme's card.
  • Theming (partially): The CSS is set up to follow the users preferred (browser-set) colour scheme to avoid placing things in local storage in order to avoid GDPR issues.

Besides that I've improved a couple visual things and I intentionally split the most recent themes from the rest and placed two cards inbetween to guide users to other resources.

A live preview of everything is available on GitHub Pages.

ffcss-dark

ffcss-light

@unseen-ninja unseen-ninja added the enhancement New feature or request label Jan 28, 2024
@BeyondMagic
Copy link
Collaborator

BeyondMagic commented Jan 28, 2024

Pretty darn beautiful! Good work!

@Zabooby
Copy link

Zabooby commented Jan 28, 2024

Wow this looks amazing!

@Neikon
Copy link
Contributor

Neikon commented Jan 28, 2024

Looks awesome, good job.

I tried the live preview you made and went straight into the dark version without doing anything (I have everything on dark) so I think that part works, at least for me.

@unseen-ninja
Copy link
Collaborator Author

I'm glad this is well received. c:

There still are a couple quirks to iron out, as well as all the build and test process stuff – not sure if and what has to be changed for that to work. And once that's done I'll have to rethink the search. I surely am not looking forward to that, but I guess it's a feature that we wanna keep?

I tried the live preview you made and went straight into the dark version without doing anything (I have everything on dark) so I think that part works, at least for me.

This has been supported in browsers for a while, so I guess it shouldn't really conflict with anything. And in case it's not supported or the user doesn't allow access to that information it will just default to light – tho that could also just be switched around in case we would prefer that.

@Neikon
Copy link
Contributor

Neikon commented Jan 28, 2024

I'm glad this is well received. c:

There still are a couple quirks to iron out, as well as all the build and test process stuff – not sure if and what has to be changed for that to work. And once that's done I'll have to rethink the search. I surely am not looking forward to that, but I guess it's a feature that we wanna keep?

If possible, I would like to have a search engine. Because we already have 100 topics and several to come. It can be a bit complex to find something among so many candidates.
Although... it occurs to me right now as I write that at a bad time. You could make the tags visible under the topics and tell the user to use ctrl+F to search.

@Zabooby
Copy link

Zabooby commented Jan 28, 2024

I'm glad this is well received. c:

There still are a couple quirks to iron out, as well as all the build and test process stuff – not sure if and what has to be changed for that to work. And once that's done I'll have to rethink the search. I surely am not looking forward to that, but I guess it's a feature that we wanna keep?

I tried the live preview you made and went straight into the dark version without doing anything (I have everything on dark) so I think that part works, at least for me.

This has been supported in browsers for a while, so I guess it shouldn't really conflict with anything. And in case it's not supported or the user doesn't allow access to that information it will just default to light – tho that could also just be switched around in case we would prefer that.

With so many themes now on the store I think it would be great to be able to filter by "recently updated", so users can find working themes much quicker.

@Neikon
Copy link
Contributor

Neikon commented Jan 28, 2024

With so many themes now on the store I think it would be great to be able to filter by "recently updated", so users can find working themes much quicker.

That's not possible, I would need to monitor each and every theme or tell the authors to send status updates to our repo and neither option is really feasible in the long run.

In fact, although we should do some review from time to time to see if a theme has been abandoned. Ideally, when a user detects it, he should send us an issue to delete the theme.

@Zabooby
Copy link

Zabooby commented Jan 28, 2024

Maybe do a review at the end of each month or two?

@Neikon
Copy link
Contributor

Neikon commented Jan 28, 2024

Maybe do a review at the end of each month or two?

If someone wants to do it, I won't be the one to stop them XD.

15 mints per theme for 100 themes = 25 hours of work reviewing themes.

P.D: Sorry, I don't know how I ended up editing your post instead of writing a reply. I tried to leave it as it was, but I didn't remember the replies I had chained, sorry.

@Zabooby
Copy link

Zabooby commented Jan 28, 2024

Would it really take 15 minutes per theme?

Couldn't you just check when the repo was last updated, maybe have a cutoff point of ~1 year?

@BeyondMagic
Copy link
Collaborator

Couldn't you just check when the repo was last updated, maybe have a cutoff point of ~1 year?

We could make a script to organise it automatically, and I have no problem making and taking care of it myself.

I think these ideas would be better suited for an issue rather than polluting this PR, care to create one?

@Neikon Neikon mentioned this pull request Jan 28, 2024
2 tasks
@unseen-ninja
Copy link
Collaborator Author

I think the most important thing that happened over the latest commits is that I've put the asset handling entirely in Astro's hands. This means that we don't have to explicitly have the .wepb filetype in themes.json as Astro will handle all that. (meaning we no longer need to run img-switch.sh.) All CI steps are updated accordingly.

This changes the notation inside the themes.json which is now located in the src directory. All images are now stored in src/assets.

[]
  "image": "/src/assets/*.{webp,jpeg,jpg,png,gif}",
[]

@Neikon

You could make the tags visible under the topics and tell the user to use ctrl+F to search.

I've highlighted the tags a little more using a similar style as GitHub with the pills. I'll still look into the search, but it's probably not as easy as it was previously since everything is static now. :/

@Zabooby
Copy link

Zabooby commented Jan 28, 2024

Is the red colour scheme final? I love the blue on the current site, it would fit with the logo too.

@unseen-ninja
Copy link
Collaborator Author

unseen-ninja commented Jan 28, 2024

The colour scheme is more or less fixed in the sense that I'm using Rosé Pine. But that doesn't mean that we can't change the colour we use for links, or even introduce a completely new one. I just picked love because the contrast fits well. c:

In case we decide to go with a custom blue I'd suggest to go with these two:
Screenshot 2024-01-28 at 23 44 33 Screenshot 2024-01-28 at 23 44 47
image

@unseen-ninja unseen-ninja closed this by deleting the head repository May 11, 2024
@BeyondMagic
Copy link
Collaborator

Oh, unbeknownst to me, but did you want to close it, @unseen-ninja?

@unseen-ninja
Copy link
Collaborator Author

Oh, shit. I've done some cleanup, and I forgot to whiteolist my original repo and it got deleted. This is entirely by accident. I do have a local copy tho. I'll re-open another PR, I guess. D:

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 this pull request may close these issues.

4 participants