Skip to content
This repository has been archived by the owner on Oct 21, 2024. It is now read-only.

Commit

Permalink
#218a - Migrate Privacy Policy to Next.js (#223)
Browse files Browse the repository at this point in the history
* set up next.js environment and add workflows

* testing that branch protection rule works when jest tests fail

* updated ci test script to use -u flag

* testing that failed tests prevent pushing

* retesting branch protection rule

* testing that lack of code coverage causes push to fail

* testing that successful tests allow the push

* testing failing tests

* all tests should now pass

* added .env* to gitignore

* added header, user model, and user context

* split links into separate components for each user type and activeUser state

* updated header to leverage react context api

* created header context, completed header, hamburger menu, signout modal and popup modal

* added unit tests for header and related components

* add footer, minor styling updates to page container, home page

* ported privacy policy

* updated header links to link to privacy-policy

* updated player links to link to privacy policy
  • Loading branch information
dvorakjt authored Dec 3, 2023
1 parent b4673ef commit 02fea37
Show file tree
Hide file tree
Showing 17 changed files with 289 additions and 26 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ exports[`Header renders the header unchanged 1`] = `
<li>
<a
class="link_sm_top"
href="/privacy"
href="/privacy-policy"
>
Privacy Policy
</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ exports[`ChallengerLinks renders challenger links unchanged 1`] = `
<li>
<a
class="link_sm_top"
href="/privacy"
href="/privacy-policy"
>
Privacy Policy
</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ exports[`HybridLinks renders hybrid links unchanged 1`] = `
<li>
<a
class="link_sm_top"
href="/privacy"
href="/privacy-policy"
>
Privacy Policy
</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ exports[`Links--Challenger renders challenger links unchanged 1`] = `
<li>
<a
class="link_sm_top"
href="/privacy"
href="/privacy-policy"
>
Privacy Policy
</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ exports[`Links--Hybrid renders hybrid links unchanged 1`] = `
<li>
<a
class="link_sm_top"
href="/privacy"
href="/privacy-policy"
>
Privacy Policy
</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ exports[`Links--Player renders player links unchanged 1`] = `
<li>
<a
class="link_sm_top"
href="/privacy"
href="/privacy-policy"
>
Privacy Policy
</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ exports[`Links--Signed Out renders signed out links unchanged 1`] = `
<li>
<a
class="link_sm_top"
href="/privacy"
href="/privacy-policy"
>
Privacy Policy
</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ exports[`PlayerLinks renders player links unchanged 1`] = `
<li>
<a
class="link_sm_top"
href="/privacy"
href="/privacy-policy"
>
Privacy Policy
</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ exports[`SignedOutLinks renders signed out links unchanged 1`] = `
<li>
<a
class="link_sm_top"
href="/privacy"
href="/privacy-policy"
>
Privacy Policy
</a>
Expand Down
94 changes: 94 additions & 0 deletions src/__tests__/pages/__snapshots__/privacy-policy.snapshot.tsx.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`PrivacyPolicy renders the privacy policy unchanged. 1`] = `
<div>
<div
class="outer_container"
>
<div
class="inner_container"
>
<div
class="container"
>
<h1
class="underline"
>
Privacy Policy
</h1>
<p>
This website and associated tools, such as subscribing for emails, is owned and operated by 8by8 Inc. and we have a firm commitment to your privacy and Internet privacy in general. We are committed to protecting the privacy of our visitors and users while they interact with the content and services on this site (www.app.8by8.us, the “Site”). This Privacy Policy applies to the Site and 8by8 owned services only. It does not apply to other websites to which we may link. We do gather certain types of information about our users, so we want you to understand what information we collect about you, how we collect it, how that information is used, and how you can control our disclosure of it. You agree that your use of the Site signifies your assent to this Privacy Policy. If you do not agree with this Privacy Policy, please do not use this Site.
</p>
<h2>
Information collected
</h2>
<p>
We collect two (2) types of information from you: 1) information that you voluntarily supply in form fields on this Site (e.g., sign-up for email); and 2) information that may be derived through automated tracking mechanisms.
</p>
<h2>
Voluntary Information for Services and Features
</h2>
<p>
We collect personally identifiable information when you choose to use certain other features of the Site, including a) consenting to receive email, and b) participating in any social media interaction as part of the Site. When you choose to use these additional features, we may require you to provide your “Contact Information” in addition to other personal information that may be required to complete a transaction.
</p>
<h2>
Cookies
</h2>
<p>
The Site uses “cookies” and other web tracking technologies. Cookies enable us to serve secure pages to our users without asking them to sign in repeatedly. Most browsers allow you to control cookies, including whether or not to accept them and how to remove them. If a user’s system is idle for a defined time, the cookie may expire, and if so, forcing the user to sign in again to continue their session. This prevents unauthorized access to the user’s information while they are away from their computer. You may set most browsers to notify you if you receive a cookie, or you may choose to block cookies with your browser.
</p>
<h2>
How We Use Your Information
</h2>
<p>
8by8 Inc. only uses your personal information for the original purposes it was given. 8by8 Inc. will not sell any personal information to third parties. Some information on our supporter lists, such as names, email addresses, and addresses, may be exchanged with named partners and other organizations with principles and/or missions that overlap with those of 8by8 Inc. Supporters may opt out of such supporter list exchanges at any time.
</p>
<p>
Please note that personally identifiable information is used only to provide you with a more enjoyable, convenient online experience and to help us identify and/or provide information that may be of interest to you. We use your personally identifiable information to support and enhance your use of the Site and its features, including without limitation: tracking email we send to you, and otherwise supporting your use of the Site.
</p>
<p>
We may permit certain trusted third parties to track usage, analyze data such as the source address that a page request is coming from, your IP address or domain name, the date and time of the page request, the referring Web site (if any) and other parameters in the URL. This is collected in order to better understand our Web site usage, and enhance the performance of services to maintain and operate the Site and certain features on the Site. We may use third parties to host the Site; operate various features available on the Site; send you email; analyze data; provide search results and links and assist in fulfilling your orders.
</p>
<p>
8by8 Inc. may disclose Contact Information in special cases where we have reason to believe that disclosing this information is necessary to identify, contact or bring legal action against someone who may be violating our terms and conditions of use or may be causing injury or interference with our rights, property, our customers or anyone who could be harmed by such activities.
</p>
<p>
We are not liable or responsible for personally identifiable or other information you choose to submit on any publicly accessible area of the Site.
</p>
<p>
You will receive notice when your personally identifiable information might be provided to any third party for any reason other than as set forth in this Privacy Policy, and you will have an opportunity to request that we not share such information.
</p>
<p>
We use non-identifying and aggregate information to better design the Site and for business and administrative purposes. We may also use or share with third parties for any purpose aggregated data that contains no personally identifiable information.
</p>
<h2>
Disclaimer to Security
</h2>
<p>
By consenting to the Privacy Policy, you consent that no data transmission over the Internet is completely secure. We cannot guarantee or warrant the security of any information you provide to us, and you transmit such information to us at your own risk.
</p>
<h2>
Notification of Changes
</h2>
<p>
8by8 Inc. reserves the right to change this Privacy Policy from time to time at its sole discretion. If at some point in the future, there is a change to our Privacy Policy, unless we obtain your express consent, such change will only apply to information collected after the revised Privacy Policy took effect. Your continued use of the Site indicates your assent to the Privacy Policy as posted.
</p>
<h2>
Contact Information
</h2>
<p>
If you have any questions or concerns regarding this Privacy Policy, please contact us at
<a
class="link"
href="mailto: [email protected]"
>
[email protected]
</a>
.
</p>
</div>
</div>
</div>
</div>
`;
11 changes: 11 additions & 0 deletions src/__tests__/pages/privacy-policy.snapshot.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import {render, cleanup} from '@testing-library/react';
import '@testing-library/jest-dom';
import PrivacyPolicy from '@/pages/privacy-policy';

describe('PrivacyPolicy', () => {
afterEach(cleanup);
it('renders the privacy policy unchanged.', () => {
const { container } = render(<PrivacyPolicy />);
expect(container).toMatchSnapshot();
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ export default function ChallengerLinks() {
>
My Challenge
</HamburgerLink>
<HamburgerLink href={"/why8by8"} className={styles.link_lg}>Why 8by8</HamburgerLink>
<HamburgerLink href={"/rewards"} className={styles.link_lg}>Rewards</HamburgerLink>
<HamburgerLink href={"/faq"} className={styles.link_lg}>FAQS</HamburgerLink>
<HamburgerLink href="/privacy" className={styles.link_sm_top}>Privacy Policy</HamburgerLink>
<HamburgerLink href="/why8by8" className={styles.link_lg}>Why 8by8</HamburgerLink>
<HamburgerLink href="/rewards" className={styles.link_lg}>Rewards</HamburgerLink>
<HamburgerLink href="/faq" className={styles.link_lg}>FAQS</HamburgerLink>
<HamburgerLink href="/privacy-policy" className={styles.link_sm_top}>Privacy Policy</HamburgerLink>
<HamburgerLink href="/settings" className={styles.link_sm}>Settings</HamburgerLink>
<SignoutBtn />
</>
Expand Down
14 changes: 7 additions & 7 deletions src/components/header/hamburger-menu/links/hybrid-links.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ import styles from '@/styles/modules/components/header/hamburger-menu/links/hybr
export default function HybridLinks() {
return (
<>
<HamburgerLink href={"/progress"} className={styles.link_lg_top}>My Challenge</HamburgerLink>
<HamburgerLink href={"/actions"} className={styles.link_lg}>Take Action</HamburgerLink>
<HamburgerLink href={"/share"} className={styles.link_lg}>Share</HamburgerLink>
<HamburgerLink href={"/why8by8"} className={styles.link_lg}>Why 8by8</HamburgerLink>
<HamburgerLink href={"/rewards"} className={styles.link_lg}>Rewards</HamburgerLink>
<HamburgerLink href={"/faq"} className={styles.link_lg}>FAQS</HamburgerLink>
<HamburgerLink href="/privacy" className={styles.link_sm_top}>Privacy Policy</HamburgerLink>
<HamburgerLink href="/progress" className={styles.link_lg_top}>My Challenge</HamburgerLink>
<HamburgerLink href="/actions" className={styles.link_lg}>Take Action</HamburgerLink>
<HamburgerLink href="/share" className={styles.link_lg}>Share</HamburgerLink>
<HamburgerLink href="/why8by8" className={styles.link_lg}>Why 8by8</HamburgerLink>
<HamburgerLink href="/rewards" className={styles.link_lg}>Rewards</HamburgerLink>
<HamburgerLink href="/faq" className={styles.link_lg}>FAQS</HamburgerLink>
<HamburgerLink href="/privacy-policy" className={styles.link_sm_top}>Privacy Policy</HamburgerLink>
<HamburgerLink href="/settings" className={styles.link_sm}>Settings</HamburgerLink>
<SignoutBtn />
</>
Expand Down
10 changes: 5 additions & 5 deletions src/components/header/hamburger-menu/links/player-links.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ export default function PlayerLinks() {
<HamburgerLink href="/challengerwelcome" className={styles.take_the_challenge_btn}>
Take The Challenge
</HamburgerLink>
<HamburgerLink href={"/actions"} className={styles.link_lg_top}>
<HamburgerLink href="/actions" className={styles.link_lg_top}>
Take Action
</HamburgerLink>
<HamburgerLink href={"/why8by8"} className={styles.link_lg}>Why 8by8</HamburgerLink>
<HamburgerLink href={"/rewards"} className={styles.link_lg}>Rewards</HamburgerLink>
<HamburgerLink href={"/faq"} className={styles.link_lg}>FAQS</HamburgerLink>
<HamburgerLink href="/privacy" className={styles.link_sm_top}>Privacy Policy</HamburgerLink>
<HamburgerLink href="/why8by8" className={styles.link_lg}>Why 8by8</HamburgerLink>
<HamburgerLink href="/rewards" className={styles.link_lg}>Rewards</HamburgerLink>
<HamburgerLink href="/faq" className={styles.link_lg}>FAQS</HamburgerLink>
<HamburgerLink href="/privacy-policy" className={styles.link_sm_top}>Privacy Policy</HamburgerLink>
<HamburgerLink href="/settings" className={styles.link_sm}>Settings</HamburgerLink>
<SignoutBtn />
</>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export default function SignedOutLinks() {
<HamburgerLink href="/why8by8" className={styles.link_lg}>Why 8by8</HamburgerLink>
<HamburgerLink href="/rewards" className={styles.link_lg}>Rewards</HamburgerLink>
<HamburgerLink href="/faq" className={styles.link_lg}>FAQS</HamburgerLink>
<HamburgerLink href="/privacy" className={styles.link_sm_top}>Privacy Policy</HamburgerLink>
<HamburgerLink href="/privacy-policy" className={styles.link_sm_top}>Privacy Policy</HamburgerLink>
<HamburgerLink href="/settings" className={styles.link_sm}>Settings</HamburgerLink>
<HamburgerLink href="/signup" className={styles.link_sm}>Sign up</HamburgerLink>
</>
Expand Down
Loading

0 comments on commit 02fea37

Please sign in to comment.