11 Commits
Author SHA1 Message Date
Paul MelnikowandGitHub c3bc0ac96f Take the Endpoint badge out of beta (#3405)
Close #2838
2019-05-01 23:05:34 -04:00
Paul MelnikowandCaleb Cartwright b288c99a29 Fix console error before applying a frontend route redirect (#3176) 2019-03-07 19:34:27 -06:00
Paul MelnikowandGitHub cd49bda968 Improve coverage in frontend and remove some dead code (#3031) 2019-02-22 00:08:11 -05:00
Paul MelnikowandGitHub ab18bc0f09 Shorten [endpoint] URL (#3050)
Ref https://github.com/badges/shields/issues/2838#issuecomment-461794344
2019-02-22 00:01:56 -05:00
Paul MelnikowandGitHub 9e4a8cec09 Consolidate badge URL generation functions (#3032)
This consolidates all the badge URL generation functions into a single place, and updates the rest of the calling code to use it. It renames some things and updates labels to bring the names into alignment with the current API.

Resolve #2027
2019-02-21 21:07:27 -05:00
Paul MelnikowandGitHub 5fda6ac11e Alphabetize JSX props in the frontend (#3055)
I'm game to give this a shot.

Ref #2701
2019-02-20 18:58:24 -05:00
Paul MelnikowandGitHub bc523e3aae Fix your-badge link (#3058)
Fix #1954
2019-02-20 16:34:50 -05:00
mbarkhauandPaul Melnikow 6e2992a3e3 Rename colorB -> color; colorA -> labelColor (#3012)
This makes it possible to override the parameters `color` and `labelColor`.

ref #2673
2019-02-19 22:03:45 -05:00
Ville SkyttäandPaul Melnikow 0d4a74bd6b Spelling fixes (#3013) 2019-02-17 14:10:06 -05:00
Paul MelnikowandCaleb Cartwright 90f8ad5b73 Endpoint customizer (#2908)
* Endpoint page: improve formatting

Cherry-picked from #2906 (conflicts with that)

Partly addresses #2837 but does not resolve it

* Add badge customizer to the endpoint page

* Clean lint
2019-02-14 19:08:56 -06:00
Paul MelnikowandGitHub d8ce045ead Adopt Gatsby (#2906)
While Next.js can handle static sites, we've had a few issues with it, notably a performance hit at runtime and some bugginess around routing and SSR. Gatsby being fully intended for high-performance static sites makes it a great technical fit for the Shields frontend. The `createPages()` API should be a really nice way to add a page for each service family, for example.

This migrates the frontend from Next.js to Gatsby. Gatsby is a powerful tool, which has a bit of downside as there's a lot to dig through. Overall I found configuration easier than Next.js. There are a lot of plugins and for the most part they worked out of the box. The documentation is good.

Links are cleaner now: there is no #. This will break old links though perhaps we could add some redirection to help with that. The only one I’m really concerned about `/#/endpoint`. I’m not sure if folks are deep-linking to the category pages.

There are a lot of enhancements we could add, in order to speed up the site even more. In particular we could think about inlining the SVGs rather than making separate requests for each one.

While Gatsby recommends GraphQL, it's not required. To keep things simple and reduce the learning curve, I did not use it here.

Close #1943 
Fix #2837 Fix #2616
2019-02-06 16:37:55 -05:00