samvera / samvera.org

Static built NextJS web app for samvera.org
https://samvera.org
1 stars 1 forks source link

CMS Blog Posts, CMS Application Types, set up Unit Tests #123

Closed adamjarling closed 7 months ago

adamjarling commented 7 months ago

What does this do?

@heathergreerklein So there is a LOT in this PR. Please don't merge it (I'll handle that after @mathewjordan puts some eyes on it for a sanity check). Also we should go over what content has now moved to Contentful. Maybe we can do a quick chat this week via Slack?

Essentially if you log into Contentful, you'll now see BlogPost entries, and this is where you should enter new Blog Posts (News and Event postings) from this point forward.

And now back to what this PR does:

  1. Creates new UI display to render Blog Posts which are fed from the Contentful CMS
  2. Renders existing Markdown "News" page .md files in the new Blog Post UI
  3. Adds Blog Posts (ie. News and Events) to the samvera.org homepage
  4. Creates new UI to render "Application Types" on the home page. Previously this was a slider (not great for accessibility), and a cleaner look using TailwindUI components
  5. Wires up Jest unit tests into the app, with a starter pattern for how to test a component, and mock data.
  6. Adds Unit Tests to Continuous Integration pipeline in Github Actions

Home page screen shot

image

New Application Types UI on homepage (replaces the slider)

image

Application Types New page

image

Update Community Banner on homepage

image

Updated News and Events page

image

Individual News and Event (Blog) page

image

To run tests (if you're a dev and comfortable with this), on the command line, run:

pnpm run test

And notice here that Github Actions are now running tests on PRs to main branch (this PR is first time):

https://github.com/samvera/samvera.org/actions

adamjarling commented 7 months ago

Good call here @mathewjordan I'm updating OpenGraph data in other core pages as well. Thanks!