Skip to content

Improved logged out experience (NGX)#9203

Merged
jonbell-lot23 merged 2 commits intoreplayio:mainfrom
jonbell-lot23:2023-05-16-ngx-tour
May 16, 2023
Merged

Improved logged out experience (NGX)#9203
jonbell-lot23 merged 2 commits intoreplayio:mainfrom
jonbell-lot23:2023-05-16-ngx-tour

Conversation

@jonbell-lot23
Copy link
Copy Markdown
Contributor

Old version

  1. We'd put a documentation link up in all situations
  2. The documentation link (aka "fuchsia hat") wasn't dismissible

image

New version

  1. If there are comments, we default to that tab with special copy
  2. ... and when you click onto any other tab, the "fuchsia hat" goes away (localStorage is used for this)
  3. If there are no comments, we show the standard documentation link
  4. ... but when you click into any other tab, the "fuchsia hat" goes away

image

Here's a little demo:
https://www.loom.com/share/445b9aab2f7144ef9a481c7f470c8220

@vercel
Copy link
Copy Markdown

vercel Bot commented May 16, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
devtools ❌ Failed (Inspect) May 16, 2023 8:51pm

@jonbell-lot23 jonbell-lot23 requested a review from bvaughn May 16, 2023 02:29
@jonbell-lot23
Copy link
Copy Markdown
Contributor Author

@replay-io
Copy link
Copy Markdown

replay-io Bot commented May 16, 2023

E2E Tests

63 replays were recorded for 2a68d86.

image 0 Failed
image 63 Passed

View test run on Replay ↗︎

Snapshot Tests

2 replays were recorded for 12ac4db.

image 2 Failed
image 0 Passed

View test run on Replay ↗︎

@replay-delta
Copy link
Copy Markdown

replay-delta Bot commented May 16, 2023

@jonbell-lot23 jonbell-lot23 changed the title Improved logged out Tour Improved logged out experience (NGX) May 16, 2023
Comment thread src/ui/components/SidePanel.tsx Outdated
Comment on lines +45 to +51
recording && isTestSuiteReplay(recording)
? "cypress"
: showTour
? "tour"
: !isAuthenticated && comments.length > 0
? "comments"
: "events";
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think nested statements like this generally considered to be pretty hard to read. Something like this might be clearer:

Suggested change
recording && isTestSuiteReplay(recording)
? "cypress"
: showTour
? "tour"
: !isAuthenticated && comments.length > 0
? "comments"
: "events";
let initialPrimaryPanel;
if (recording && isTestSuiteReplay(recording)) {
initialPrimaryPanel = "cypress";
} else if (showTour) {
initialPrimaryPanel = "tour";
} else if (!isAuthenticated && comments.length > 0) {
initialPrimaryPanel = "comments";
} else {
initialPrimaryPanel = "events";
}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Thanks!

Comment thread src/ui/components/SidePanel.tsx
@jonbell-lot23
Copy link
Copy Markdown
Contributor Author

TSC issues, followed up successfully here: #9207

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.

3 participants