-
Notifications
You must be signed in to change notification settings - Fork 56
Guided onboarding #475
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
Guided onboarding #475
Conversation
src/services/service.ts
Outdated
| return get(Routes.DASHBOARD_LOGGEDIN); | ||
| } | ||
|
|
||
| export interface LoginCountType extends ResponseType { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please move these to types
src/services/service.ts
Outdated
| } | ||
|
|
||
| export function updateLoginCount(payload): Promise<ResponseType> { | ||
| return post('attributes/user/update', payload) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add routes in constants
| to={`${match.path}/${URLS.GUIDE}`} | ||
| className="no-decor fw-6 cursor cn-9" | ||
| activeClassName="active" | ||
| onClick={() => redirectToDeployGuide(`/${URLS.GUIDE}`)} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please avoid inline functions
| href={DOCUMENTATION.PREVIEW_DEVTRON} | ||
| rel="noreferrer noopener" | ||
| target="_blank" | ||
| onClick={() => OnClickedHandler(POSTHOG_EVENT_ONBOARDING.PREVIEW)} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same here
src/services/service.ts
Outdated
| } | ||
|
|
||
| export function getUserRole(): Promise<UserRole> { | ||
| return get(Routes.USER_CHECK_ROLE); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The same service function is present in userGroup.service.ts. Please use it.
| .deploy-manage__body{ | ||
| height: calc(100vh - 300px); | ||
| .deploy-card:hover{ | ||
| box-shadow: 0 8px 12px 0 rgba(30, 35, 96, 0.1), 0 1px 4px 0 rgba(0, 0, 0, 0.1); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same here
| } | ||
|
|
||
| .deploy__title{ | ||
| position: absolute; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggestion: Try using pre-defined CSS classes wherever possible.
| } from './userGroup.service' | ||
| import { get } from '../../services/api' | ||
| import { getEnvironmentListMin, getProjectFilteredApps } from '../../services/service' | ||
| import { getEnvironmentListMin, getProjectFilteredApps, getUserRole } from '../../services/service' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Revert this change.
src/config/constants.ts
Outdated
| GLOBAL_CONFIG_GIT_ACCESS_LINK: `${DOCUMENTATION_HOME_PAGE}/v/v0.5/getting-started/global-configurations/gitops#4.-git-access-credential`, | ||
| DEVTRON_UPGRADE: `${DOCUMENTATION_HOME_PAGE}/v/v0.5/getting-started/upgrade` | ||
| DEVTRON_UPGRADE: `${DOCUMENTATION_HOME_PAGE}/v/v0.5/getting-started/upgrade`, | ||
| PREVIEW_DEVTRON: 'https://preview.devtron.ai/dashboard', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
move this
src/css/base.scss
Outdated
| line-height: 20px; | ||
| } | ||
|
|
||
| .lh-22{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add prefix - dc__
src/services/service.ts
Outdated
| } | ||
|
|
||
| export function updatePostHogEvent(payload): Promise<PostHog> { | ||
| return post(`${Routes.TELEMETRY_EVENT}`, payload) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Simply say - Routes.TELEMETRY_EVENT
src/services/service.ts
Outdated
| export function updateLoginCount(payload): Promise<LoginCountType> { | ||
| return post(`${Routes.ATTRIBUTES_USER}/${Routes.UPDATE}`, payload) | ||
| } | ||
| interface PostHog extends ResponseType { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rename to PostHogEventResponse
|
|
||
| export const handlePostHogEventUpdate = (e, eventName?: string): void => { | ||
| const payload = { | ||
| eventType: eventName || e.target.dataset.posthog, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we have an optional check on e.target?
| } | ||
|
|
||
| useEffect(() => { | ||
| setExpiryDate(+localStorage.getItem('clickedOkay')) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As discussed, handle undefined scenario
Description
New UI feature added for new users with super admin access with 0 apps.
Base Devtron: Helm apps list
With CI/CD: Devtron apps list
Fixes devtron-labs/devtron#2213 devtron-labs/devtron#2228 devtron-labs/devtron#1972
https://docs.google.com/document/d/16PbZ0s_x9h3tt5jUzVoeRFSagdnBUfH_7CX8QBbEx7Y/edit
https://www.figma.com/file/mg4GcV3QQHU2NNv1SWr2va/Onboarding?node-id=636%3A696
Motivation
Increase product adoption among open-source users.
Proposal

-b3f8-c2a46bb96d1a.png">Fixes devtron-labs/devtron#1972
Type of change
How Has This Been Tested?
Tested out manually