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

feat: Display current announcements #924

Merged
merged 23 commits into from
Feb 22, 2023
Merged

Conversation

jcbcapps
Copy link
Contributor

@jcbcapps jcbcapps commented Feb 8, 2023

SC-1083

Proposed changes

Adds filtering to only display announcements up until the current date, so that anything with a published date in the future is not shown.


Reviewer notes

You will need to also have sc-1083/announcement-scheduler checked out in the CMS to view these changes

Also please review:

Setup

Run everything as usual
In the CMS: yarn services:up && yarn dev
In the portal: yarn dev

Create an announcement with a published date in the future, and make sure that it does not display in the portal.


Code review steps

As the original developer, I have

  • Met the acceptance criteria, or will meet them in subsequent PRs or stories
    • ...
  • Created new stories in Storybook if applicable
    • Checked that all Storybook accessibility checks are passing
  • Created/modified automated unit tests in Jest
    • Including jest-axe checks when UI changes
  • Created/modified automated E2E tests in Cypress
    • Including cypress-axe checks when UI changes
    • Checked that the E2E test build is not failing
  • Performed a11y testing:
    • Checked responsiveness in mobile, tablet, and desktop
    • Checked keyboard navigability
    • Tested with VoiceOver in Safari
    • Checked VO's rotor menu for landmarks, page heading structure and links
    • Used a browser a11y tool to check for issues (WAVE, axe, ANDI or Accessibility addon tab for Storybook)
  • Requested a design review for user-facing changes
  • For any new migrations/schema changes:
    • Followed guidelines for zero-downtime deploys

As code reviewer(s), I have

  • Pulled this branch locally and tested it
  • Reviewed this code and left comments
  • Checked that all code is adequately covered by tests
    • Checked that the E2E test build is not failing
  • Made it clear which comments need to be addressed before this work is merged
  • Considered marking this as accepted even if there are small changes needed
  • Performed a11y testing:
    • Checked responsiveness in mobile, tablet, and desktop
    • Checked keyboard navigability
    • Tested with VoiceOver in Safari
    • Checked VO's rotor menu for landmarks, page heading structure and links
    • Used a browser a11y tool to check for issues (WAVE, axe, ANDI or Accessibility addon tab for Storybook)

As a designer reviewer, I have

  • Checked in the design translated visually
  • Checked behavior
  • Checked different states (empty, one, some, error)
  • Checked for landmarks, page heading structure, and links
  • Tried to break the intended flow
  • Performed a11y testing:
    • Checked responsiveness in mobile, tablet, and desktop
    • Checked keyboard navigability
    • Tested with VoiceOver in Safari
    • Checked VO's rotor menu for landmarks, page heading structure and links
    • Used a browser a11y tool to check for issues (WAVE, axe, ANDI or Accessibility addon tab for Storybook)

As a test user, I have

  • Run through the Test Script:
    • On commercial internet in IE11 / Edge
    • On commercial internet in Firefox
    • On commercial internet in Chrome
    • On commercial internet in Safari
    • On NIPR in IE11
    • On NIPR in Firefox
    • On NIPR in Chrome
    • On NIPR in Safari
    • On a mobile device in Firefox
    • On a mobile device in Chrome
    • On a mobile device in Safari
  • Added any anomalous behavior to this PR

Screenshots

@shortcut-integration
Copy link

This pull request has been linked to Shortcut Story #1083: Announcement scheduler.

@jcbcapps jcbcapps marked this pull request as ready for review February 9, 2023 00:05
@jcbcapps jcbcapps requested a review from a team as a code owner February 9, 2023 00:05
Copy link
Contributor

@gidjin gidjin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree with you that we should update the query, so marking this as requested changes for now.

@jcbcapps jcbcapps requested review from gidjin and abbyoung February 13, 2023 15:59
@jbecker01
Copy link
Contributor

Looks good!

Copy link
Contributor

@gidjin gidjin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@jcbcapps jcbcapps force-pushed the sc-1083/announcement-scheduler branch from 9ee0bf8 to 318eb2f Compare February 22, 2023 14:21
jcbcapps and others added 18 commits February 22, 2023 08:34
* Add LD dependencies we were using previously

* Add withLDProvider to export

* Add env variable and feature flag

* Version lock

* Update storybook add ons and move flag to PageHeader

* Update storybook to toggle Search w/ LD

* Update to remove SearchOff

* Remove disableSearch prop

* Fix dark mode styles

* Update text color

* Add missing ComponentType

* Add launchDarklyContext w/ localfile config

* Add test

* Add disabled prop back
## [4.14.0](4.13.0...4.14.0) (2023-02-08)


### Features

* Add LaunchDarkly back and put Search behind feature flag ([#912](#912)) ([f235860](f235860))
* Fetch documents page data from cms

* update unit test for documentation page

* address feedback for dark mode, loading expanded state

* fix docs page to handle errors

* Add LD flag to docs page

* adding unit test coverage

* rearranging layout so right sidebar displays correctly

* test: correct bad test check with correct one

---------

Co-authored-by: John Gedeon <[email protected]>
* dev: add luxon to handle date operations

* feat: an article published in the future should return 404

* feat: pass current date to InternalNews queries

* feat: pass publishedDate to ORBITBlog queries

---------

Co-authored-by: Abigail Young <[email protected]>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
…theme refactoring (#933)

* uploads light background img

Signed-off-by: Shauna Keating <[email protected]>

* adds in background img for dark background

* creates variables for background images

* adds new variables into default layouts module to allow to multiple backgrounds

* adds in light gradient

* adds in light bacgkround image

* adds in positioning and size properties for background image

* addresses performance issue with sattelight image background, switches to png

* connects dark mode variables

* removes page header background

* removes page header background image code

* adjusts breadcrumb link color to have passing color contrast on light mode

* chore(deps): update github/codeql-action digest to 17573ee (#928)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update docker/build-push-action digest to 1104d47 (#919)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update github-actions (#929)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* removes more page header background code

* changes myspace bg varibale to be a general widget bg fill, adds to epubs card

* adds background fill to feedback card

* adds background fill on sites and application page components missing it

* adjusts the settings and connects breadcrumbs to theme

* adds background fill to about us page sidebar

* replaces background image with lower opacity image

* replaces light mode bacground with lower opacity to improve legibility on about and news and annoucments

* changes search results banner to themed backgorund color

* adds color themeing to search error background

* removes dark background lock on breadcrumb nav story

* changes link color selector

* adjusts storybook view of news and annousements header to reflect what is on production:

* removes non-applicable items from typography page

* test: add tests for branch in NewsItem

* test: simplify this check to reduce the number of branches

* test: add test for ThemeToggle when user not logged in

---------

Signed-off-by: Shauna Keating <[email protected]>
Co-authored-by: Shauna Keating <[email protected]>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: John Gedeon <[email protected]>
* chore(deps): bump undici from 5.11.0 to 5.20.0

Bumps [undici](https://github.com/nodejs/undici) from 5.11.0 to 5.20.0.
- [Release notes](https://github.com/nodejs/undici/releases)
- [Commits](nodejs/undici@v5.11.0...v5.20.0)

---
updated-dependencies:
- dependency-name: undici
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>

* Empty-Commit

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: minh-truss <[email protected]>
@jcbcapps jcbcapps force-pushed the sc-1083/announcement-scheduler branch from fe9427a to 8f16df8 Compare February 22, 2023 14:37
@jcbcapps jcbcapps requested a review from a team as a code owner February 22, 2023 14:37
@jcbcapps jcbcapps merged commit 4ad1f8d into main Feb 22, 2023
@jcbcapps jcbcapps deleted the sc-1083/announcement-scheduler branch February 22, 2023 17:30
@gidjin gidjin mentioned this pull request Feb 22, 2023
gidjin added a commit that referenced this pull request Feb 23, 2023
## [4.15.0](4.14.0...4.15.0) (2023-02-23)


### Features

* Connect documents page to cms ([#921](#921)) ([616f5ee](616f5ee))
* Display current announcements ([#924](#924)) ([4ad1f8d](4ad1f8d)), closes [#912](#912) [#925](#925) [#912](#912) [#921](#921)
* Support article scheduling ([#922](#922)) ([d4dc1a4](d4dc1a4))
* support preview of unpublished articles by keystone cms users ([#934](#934)) ([55615b7](55615b7))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants