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(paywall blocker): improvements for trial end blocker screen #5756

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
d713b6a
feat: add view templates option to dashboard menu
sharpshooter90 Aug 14, 2024
6984a78
Merge branch 'develop' into develop
pranay01 Aug 16, 2024
ca96423
Merge branch 'develop' into develop
pranay01 Aug 16, 2024
3591e45
feat: increase dropdown overlay width
sharpshooter90 Aug 16, 2024
9d2206d
Merge branch 'SigNoz:develop' into develop
sharpshooter90 Aug 16, 2024
21e09ad
Merge branch 'develop' into develop
sharpshooter90 Aug 20, 2024
2e7dd28
Merge branch 'SigNoz:develop' into develop
sharpshooter90 Aug 21, 2024
2bf5e9a
Merge branch 'SigNoz:develop' into develop
sharpshooter90 Aug 23, 2024
57907be
feat(paywall blocker): improvements for trial end blocker screen
sharpshooter90 Aug 23, 2024
7b462e7
chore: fixed few conditions
sharpshooter90 Aug 23, 2024
698b98c
Merge branch 'develop' into feature/trial-paywall-improvements
pranay01 Aug 23, 2024
e4773f8
Merge branch 'SigNoz:develop' into feature/trial-paywall-improvements
sharpshooter90 Aug 23, 2024
63cbd0f
feat(paywall title): added contact us to modal title
sharpshooter90 Aug 23, 2024
3393b3e
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Aug 23, 2024
8d42972
feat: non admin users communication styles
sharpshooter90 Aug 23, 2024
905c049
chore: added useState for the sidebar collapse state to be false
sharpshooter90 Aug 24, 2024
249cddc
test(WorkspaceLocked): update Jest test to sync with recent UX copy c…
sharpshooter90 Aug 24, 2024
4a58e19
feat(workspaceLocked): added locale
sharpshooter90 Aug 24, 2024
db0c65d
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Aug 29, 2024
8650413
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Aug 29, 2024
fa0b7a4
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Aug 30, 2024
1341e61
feat: reverted the translation for and sidebar collapse fix
sharpshooter90 Sep 2, 2024
2d4708a
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Sep 2, 2024
583e8c5
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Sep 2, 2024
3c0c97b
refactor(workspaceLocked): refactor appLayout component to simplify t…
sharpshooter90 Sep 3, 2024
31e521c
refactor(workspaceLocked): simplify isWorkspaceLocked by converting i…
sharpshooter90 Sep 3, 2024
5af1281
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Sep 4, 2024
6724702
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Sep 4, 2024
013b8c0
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Sep 4, 2024
a60fb98
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Sep 5, 2024
e5b71a8
Merge branch 'develop' into feature/trial-paywall-improvements
sharpshooter90 Sep 6, 2024
96830d7
refactor(workspaceLocked): refactor modal classname and variable
sharpshooter90 Sep 6, 2024
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
22 changes: 22 additions & 0 deletions frontend/public/locales/en-GB/workspaceLocked.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"trialPlanExpired": "Trial Plan Expired",
"gotQuestions": "Got Questions?",
"contactUs": "Contact Us",
"upgradeToContinue": "Upgrade to Continue",
"upgradeNow": "Upgrade now to keep enjoying all the great features you’ve been using.",
"yourDataIsSafe": "Your data is safe with us until",
"actNow": "Act now to avoid any disruptions and continue where you left off.",
"contactAdmin": "Contact your admin to proceed with the upgrade.",
"continueMyJourney": "Continue My Journey",
"needMoreTime": "Need More Time?",
"extendTrial": "Extend Trial",
"extendTrialMsgPart1": "If you have a specific reason why you were not able to finish your PoC in the trial period, please write to us on",
"extendTrialMsgPart2": "with the reason. Sometimes we can extend trial by a few days on a case by case basis",
"whyChooseSignoz": "Why choose Signoz",
"enterpriseGradeObservability": "Enterprise-grade Observability",
"observabilityDescription": "Get access to observability at any scale with advanced security and compliance.",
"continueToUpgrade": "Continue to Upgrade",
"youAreInGoodCompany": "You are in good company",
"faqs": "FAQs",
"somethingWentWrong": "Something went wrong"
}
22 changes: 22 additions & 0 deletions frontend/public/locales/en/workspaceLocked.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"trialPlanExpired": "Trial Plan Expired",
"gotQuestions": "Got Questions?",
"contactUs": "Contact Us",
"upgradeToContinue": "Upgrade to Continue",
"upgradeNow": "Upgrade now to keep enjoying all the great features you’ve been using.",
"yourDataIsSafe": "Your data is safe with us until",
"actNow": "Act now to avoid any disruptions and continue where you left off.",
"contactAdmin": "Contact your admin to proceed with the upgrade.",
"continueMyJourney": "Continue My Journey",
"needMoreTime": "Need More Time?",
"extendTrial": "Extend Trial",
"extendTrialMsgPart1": "If you have a specific reason why you were not able to finish your PoC in the trial period, please write to us on",
"extendTrialMsgPart2": "with the reason. Sometimes we can extend trial by a few days on a case by case basis",
"whyChooseSignoz": "Why choose Signoz",
"enterpriseGradeObservability": "Enterprise-grade Observability",
"observabilityDescription": "Get access to observability at any scale with advanced security and compliance.",
"continueToUpgrade": "Continue to Upgrade",
"youAreInGoodCompany": "You are in good company",
"faqs": "FAQs",
"somethingWentWrong": "Something went wrong"
}
11 changes: 9 additions & 2 deletions frontend/src/container/AppLayout/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,6 @@ function AppLayout(props: AppLayoutProps): JSX.Element {
const pageTitle = t(routeKey);
const renderFullScreen =
pathname === ROUTES.GET_STARTED ||
pathname === ROUTES.WORKSPACE_LOCKED ||
pathname === ROUTES.GET_STARTED_APPLICATION_MONITORING ||
pathname === ROUTES.GET_STARTED_INFRASTRUCTURE_MONITORING ||
pathname === ROUTES.GET_STARTED_LOGS_MANAGEMENT ||
Expand Down Expand Up @@ -282,6 +281,14 @@ function AppLayout(props: AppLayoutProps): JSX.Element {

const isSideNavCollapsed = getLocalStorageKey(IS_SIDEBAR_COLLAPSED);

/**
sharpshooter90 marked this conversation as resolved.
Show resolved Hide resolved
* Note: Right now we don't have a page-level method to pass the sidebar collapse state.
* Since the use case for overriding is not widely needed, we are setting it here
* so that the workspace locked page will have an expanded sidebar regardless of how users
* have set it or what is stored in localStorage. This will not affect the localStorage config.
*/
const isWorkspaceLocked = pathname === ROUTES.WORKSPACE_LOCKED;

return (
<Layout
className={cx(
Expand Down Expand Up @@ -326,7 +333,7 @@ function AppLayout(props: AppLayoutProps): JSX.Element {
licenseData={licenseData}
isFetching={isFetching}
onCollapse={onCollapse}
collapsed={collapsed}
collapsed={isWorkspaceLocked ? false : collapsed}
/>
)}
<div
Expand Down
35 changes: 35 additions & 0 deletions frontend/src/pages/WorkspaceLocked/CustomerStoryCard.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
import './customerStoryCard.styles.scss';

import { Avatar, Card, Space } from 'antd';

interface CustomerStoryCardProps {
avatar: string;
personName: string;
role: string;
message: string;
link: string;
}

function CustomerStoryCard({
avatar,
personName,
role,
message,
link,
}: CustomerStoryCardProps): JSX.Element {
return (
<a href={link} target="_blank" rel="noopener noreferrer">
<Card className="customer-story-card">
<Space size="middle" direction="vertical">
<Card.Meta
avatar={<Avatar size={48} src={avatar} />}
title={personName}
description={role}
/>
{message}
</Space>
</Card>
</a>
);
}
export default CustomerStoryCard;
30 changes: 30 additions & 0 deletions frontend/src/pages/WorkspaceLocked/InfoBlocks.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
import { Col, Row, Space, Typography } from 'antd';

interface InfoItem {
title: string;
description: string;
id: string; // Add a unique identifier
}

interface InfoBlocksProps {
items: InfoItem[];
}

function InfoBlocks({ items }: InfoBlocksProps): JSX.Element {
return (
<Space direction="vertical" size="middle">
{items.map((item) => (
<Row gutter={8} key={item.id}>
<Col span={24}>
<Typography.Title level={5}>{item.title}</Typography.Title>
</Col>
<Col span={24}>
<Typography>{item.description}</Typography>
</Col>
</Row>
))}
</Space>
);
}

export default InfoBlocks;
159 changes: 152 additions & 7 deletions frontend/src/pages/WorkspaceLocked/WorkspaceLocked.styles.scss
Original file line number Diff line number Diff line change
@@ -1,16 +1,161 @@
.workspace-locked-container {
text-align: center;
padding: 48px;
margin: 24px;
$light-theme: 'lightMode';

vikrantgupta25 marked this conversation as resolved.
Show resolved Hide resolved
@keyframes gradientFlow {
0% {
background-position: 0% 50%;
}
50% {
background-position: 100% 50%;
}
100% {
background-position: 0% 50%;
}
}

.workpace-locked-details {
width: 50%;
margin: 0 auto;
.workspace-locked {
&__modal {
.ant-modal-mask {
backdrop-filter: blur(2px);
}
}

&__tabs {
margin-top: 148px;

.ant-tabs {
&-nav {
&::before {
border-color: var(--bg-slate-500);

.#{$light-theme} & {
border-color: var(--bg-vanilla-300);
}
}
}
&-nav-wrap {
justify-content: center;
}
}
}

&__modal {
&__header {
display: flex;
justify-content: space-between;
align-items: center;

&__actions {
display: flex;
align-items: center;
gap: 16px;
}
}
.ant-modal-content {
border-radius: 4px;
border: 1px solid var(--bg-slate-400);
background: linear-gradient(
139deg,
rgba(18, 19, 23, 0.8) 0%,
rgba(18, 19, 23, 0.9) 98.68%
);
box-shadow: 4px 10px 16px 2px rgba(0, 0, 0, 0.2);
backdrop-filter: blur(20px);

.#{$light-theme} & {
border: 1px solid var(--bg-vanilla-300);
background: var(--bg-vanilla-100);
}
}

.ant-modal-header {
background: transparent;
}

.ant-list {
&-item {
border-color: var(--bg-slate-500);

.#{$light-theme} & {
border-color: var(--bg-vanilla-300);
}

&-meta {
align-items: center !important;

&-title {
margin-bottom: 0 !important;
}

&-avatar {
display: flex;
}
}
}
}
&__title {
font-weight: 400;
color: var(--text-vanilla-400);

.#{$light-theme} & {
color: var(--text-ink-200);
}
}
&__cta {
margin-top: 54px;
}
}
&__container {
padding-top: 64px;
}
&__details {
width: 80%;
margin: 0 auto;
color: var(--text-vanilla-400, #c0c1c3);
text-align: center;
font-size: 16px;
font-style: normal;
font-weight: 400;
line-height: 24px; /* 150% */

.#{$light-theme} & {
color: var(--text-ink-200);
}

&__highlight {
color: var(--text-vanilla-100, #fff);
font-style: normal;
font-weight: 700;
line-height: 24px;

.#{$light-theme} & {
color: var(--text-ink-100);
}
}
}
&__title {
background: linear-gradient(
99deg,
#ead8fd 0%,
#7a97fa 33%,
#fd5ab2 66%,
#ead8fd 100%
);
background-size: 300% 300%;
background-clip: text;
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
animation: gradientFlow 24s ease infinite;
margin-bottom: 18px;
}
}

.contact-us {
margin-top: 48px;
color: var(--text-vanilla-400);

.#{$light-theme} & {
color: var(--text-ink-200);
}
}

.cta {
Expand Down
16 changes: 8 additions & 8 deletions frontend/src/pages/WorkspaceLocked/WorkspaceLocked.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,17 @@ describe('WorkspaceLocked', () => {
});

const workspaceLocked = await screen.findByRole('heading', {
name: /workspace locked/i,
name: /upgrade to continue/i,
});
expect(workspaceLocked).toBeInTheDocument();

const gotQuestionText = await screen.findByText(/got question?/i);
expect(gotQuestionText).toBeInTheDocument();

const contactUsLink = await screen.findByRole('link', {
name: /contact us/i,
const contactUsBtn = await screen.findByRole('button', {
name: /Contact Us/i,
});
expect(contactUsLink).toBeInTheDocument();
expect(contactUsBtn).toBeInTheDocument();
});

test('Render for Admin', async () => {
Expand All @@ -42,11 +42,11 @@ describe('WorkspaceLocked', () => {

render(<WorkspaceLocked />);
const contactAdminMessage = await screen.queryByText(
/please contact your administrator for further help/i,
/contact your admin to proceed with the upgrade./i,
);
expect(contactAdminMessage).not.toBeInTheDocument();
const updateCreditCardBtn = await screen.findByRole('button', {
name: /update credit card/i,
name: /continue my journey/i,
});
expect(updateCreditCardBtn).toBeInTheDocument();
});
Expand All @@ -60,12 +60,12 @@ describe('WorkspaceLocked', () => {

render(<WorkspaceLocked />, {}, 'VIEWER');
const updateCreditCardBtn = await screen.queryByRole('button', {
name: /update credit card/i,
name: /Continue My Journey/i,
});
expect(updateCreditCardBtn).not.toBeInTheDocument();

const contactAdminMessage = await screen.findByText(
/please contact your administrator for further help/i,
/contact your admin to proceed with the upgrade./i,
);
expect(contactAdminMessage).toBeInTheDocument();
});
Expand Down
Loading
Loading