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

Add information on how to verify if a user is part of 1% experimental group #543

Merged
merged 17 commits into from
Apr 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions packages/extension/src/store/utils/deriveBlockingStatus.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,12 @@ import {
*/
function deriveInboundBlocking(respEvents: responsEvent[]): BLOCK_STATUS {
// if there are not response events the cookie must be stored in a previous visit
// Or there is a javascript not used in the request header.
if (respEvents.length === 0) {
return BLOCK_STATUS.NOT_BLOCKED;
}

// Number of responses in which the cookie was blocked.
const numBlocked: number = respEvents.reduce((acc, event) => {
if (event.blocked) {
return acc + 1;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,11 @@
import React from 'react';
import { addUTMParams } from '@ps-analysis-tool/common';

const EXPERIMENT_GROUP = 'Membership in Experiment Group';

const INFO_CARDS_DATA = [
{
heading: 'Membership in Experiment Group',
heading: EXPERIMENT_GROUP,
content: `To prepare for third-party cookie deprecation, we will be providing Chrome-facilitated testing modes that allow sites to preview how site behavior and functionality work without third-party cookies. Check <a class="text-bright-navy-blue dark:text-jordy-blue hover:opacity-80 underline"
href="${addUTMParams(
'https://developers.google.com/privacy-sandbox/setup/web/chrome-facilitated-testing'
Expand Down Expand Up @@ -72,6 +74,15 @@ const InfoCards = () => {
className="text-sm break-words"
dangerouslySetInnerHTML={{ __html: card.content }}
/>
{card.heading === EXPERIMENT_GROUP && (
<div className="p-3 flex-1 bg-anti-flash-white dark:bg-charleston-green rounded-md">
<p>
For browsers in the 1% group, users will get a new
chrome://settings/trackingProtection page instead of
chrome://settings/cookies
</p>
</div>
)}
</div>
</div>
</li>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@
*/
import React from 'react';
import { LandingPage } from '@ps-analysis-tool/design-system';

/**
* Internal dependencies.
*/
import FacilitatedTestingContent from './faciliatedTestingContent';

const FacilitatedTesting = () => (
Expand Down
Loading