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: add w3up-launch announcement banner (when env.NEXT_PUBLIC_W3UP_LAUNCH_SUNSET_ANNOUNCEMENT_START is set) #2319

Merged
merged 10 commits into from
Nov 8, 2023

Conversation

gobengo
Copy link
Contributor

@gobengo gobengo commented Nov 8, 2023

Motivation:

Tactics:

  • there is a new env var NEXT_PUBLIC_W3UP_LAUNCH_SUNSET_ANNOUNCEMENT_START that is an ISO8601 datetime of when the announcement should appear. If unset, the announcement will never appear. My intention is to set it only on the staging environment for acceptance testing. Once we're happy on staging, we can enable it on production by setting this var to whatever datetime we want it to appear.

Scope:

  • when enabled at after the appropriate time, the banner should appear on the following routes
    • /
    • /account
    • /account/payment
    • /docs
  • the github actions website workflow now uses github environments. This is because I want to use them to configure the staging environment to have a particular value for NEXT_PUBLIC_W3UP_LAUNCH_SUNSET_ANNOUNCEMENT_START

@gobengo gobengo requested review from a team as code owners November 8, 2023 17:21
Copy link
Contributor

github-actions bot commented Nov 8, 2023

@gobengo gobengo changed the title add w3up-launch announcement banner to /account/payment/ feat: add w3up-launch announcement banner to /account/payment/ (when env.NEXT_PUBLIC_W3UP_LAUNCH_SUNSET_ANNOUNCEMENT_START is set) Nov 8, 2023
@gobengo gobengo changed the title feat: add w3up-launch announcement banner to /account/payment/ (when env.NEXT_PUBLIC_W3UP_LAUNCH_SUNSET_ANNOUNCEMENT_START is set) feat: add w3up-launch announcement banner (when env.NEXT_PUBLIC_W3UP_LAUNCH_SUNSET_ANNOUNCEMENT_START is set) Nov 8, 2023
<main className="page page-index">
{sections.map((section, index) => (
<BlockBuilder id={`section_${index + 1}`} key={`section_${index + 1}`} subsections={section} />
))}
</main>

<Scroll2Top />
Copy link
Contributor Author

Choose a reason for hiding this comment

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

When this was present, it was weirdly somehow resulting in an element from inside the scroll2top component getting mixed up with the PageBanner children. It happened in firefox and chrome, and I have no idea how.... The scroll2top component code seems relatively innocuous so I don't know why it would affect dom manip. The only way to fix was to not use the component here. I know its dumb, but without this, the bug in the dom that react rendered made the home page banner not render at all.

workaround: remove this Scroll2Top for now. We can add it back in later if we really need it, but we probably don't, and this whole website is being sunset anyway!

@gobengo gobengo merged commit f3d5b97 into main Nov 8, 2023
22 checks passed
@gobengo gobengo deleted the w3up-launch-banner-1699463175 branch November 8, 2023 22:39
gobengo pushed a commit that referenced this pull request Nov 9, 2023
🤖 I have created a release *beep* *boop*
---


##
[2.37.0](website-v2.36.3...website-v2.37.0)
(2023-11-09)


### Features

* add w3up-launch announcement banner (when
env.NEXT_PUBLIC_W3UP_LAUNCH_SUNSET_ANNOUNCEMENT_START is set)
([#2319](#2319))
([f3d5b97](f3d5b97))
* remove 'whats the data layer?' cta2 from website homepage
([#2322](#2322))
([7975fdf](7975fdf))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
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.

2 participants