roxiness / stackmix

A collection of templates for Routify.
22 stars 2 forks source link

Auth fragment styling #21

Open alesvaupotic opened 3 years ago

alesvaupotic commented 3 years ago

I did what I could with styling to not change the whole concept. Protected page was set up with inverted theme and some global styles also messed with inputs.

We might think of a global css which can be deleted or updated on demand and each fragment would contribute to initially. It's a simple and quick way to replace styling in general on a new project.

Added a link to /protected route as there was none.

diepoe commented 3 years ago

Yeah, I like the idea. So what do you think about adding something like a CSS property to the blueprint?

alesvaupotic commented 3 years ago

Jakob will chime in on this one, with v3 in mind maybe.

jakobrosenberg commented 3 years ago

We might think of a global css which can be deleted or updated on demand and each fragment would contribute to initially. It's a simple and quick way to replace styling in general on a new project.

I much agree. I've been looking for a minimal-class kinda framework that can provide default styling and easily be removed without leaving a mess of unused classes. Currently I like Milligram but am open to alternatives or adding some stackmix specific CSS.

jakobrosenberg commented 3 years ago

Before I merge this what does the PR fix?

This is what I get with vite-navigation-auth-markdown-milligram-app

screenshots ![image](https://user-images.githubusercontent.com/4153004/115546749-b1ba1d00-a2a5-11eb-91b1-48b15094e004.png) ![image](https://user-images.githubusercontent.com/4153004/115546802-c26a9300-a2a5-11eb-8082-207261268fdf.png) ![image](https://user-images.githubusercontent.com/4153004/115546707-a36c0100-a2a5-11eb-93b8-a4f25e25eb29.png) ![image](https://user-images.githubusercontent.com/4153004/115546728-a961e200-a2a5-11eb-9e32-ad8ccdcb76d6.png) ![image](https://user-images.githubusercontent.com/4153004/115546915-e75f0600-a2a5-11eb-84de-0f9d6009d44b.png) ![image](https://user-images.githubusercontent.com/4153004/115546881-d910ea00-a2a5-11eb-8527-609c99ec5c00.png)
alesvaupotic commented 3 years ago

Oh, sorry, with milligram you got styling. Never used that before. With just auth,vite I get the what was discussed in discord: image

alesvaupotic commented 3 years ago

Jakob, milligram looks just fine. How about including it into base, it's 2KB and really brings a lot to the table? Even being a Tailwind user myself, I can see benefits of including a lib like that to introduce some styling for the user. I mean, we import all these testing libs and stuff, it wont affect npm install times at all.

jakobrosenberg commented 3 years ago

@alesvaupotic it should be already included by default. Should we add a comment to it that clarifies its purpose?

alesvaupotic commented 3 years ago

@jakobrosenberg Just ran npx stackmix -f auth,vite and I see no reference to milligram anywhere in generated source code.

jakobrosenberg commented 3 years ago

Ah. You only get it by default if you run npx stackmix.

The -f is for unattended installs, so it'll assume you only want what you include.

alesvaupotic commented 3 years ago

OK, but you can't assume either that preselected fragments will end up in the user's output. I always deselect milligram in favor of tailwind, this is what I get:

image

So, it would be of great help if either some general styling is applied for any output generated by stackmix or there is no styling at all. I haven't digged thru repository to see when Auth fragment got internal styles, but now it's a mess.