Skip to content

feat: integrations onboarding #5497

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

Draft
wants to merge 87 commits into
base: main
Choose a base branch
from
Draft

Conversation

kyle-ssg
Copy link
Member

@kyle-ssg kyle-ssg commented May 27, 2025

Thanks for submitting a PR! Please check the boxes below:

  • I have added information to docs/ if required so people know about the feature!
  • I have filled in the "Changes" section below?
  • I have filled in the "How did you test this code" section below?
  • I have used a Conventional Commit title for this Pull Request

Changes

image

How did you test this code?

Please describe.

# Conflicts:
#	frontend/common/utils/utils.tsx
# Conflicts:
#	frontend/web/styles/_variables.scss
# Conflicts:
#	frontend/common/types/requests.ts
#	frontend/common/types/responses.ts
# Conflicts:
#	frontend/common/types/responses.ts
# Conflicts:
#	frontend/common/types/requests.ts
#	frontend/common/types/responses.ts
#	frontend/common/utils/utils.tsx
#	frontend/web/components/pages/HomeAside.tsx
#	frontend/web/components/pages/HomePage.js
#	frontend/web/project/api.js
Copy link

flagsmith bot commented Jun 3, 2025

Flagsmith feature linked: integration_onboarding
Default Values:

Environment Enabled Value Last Updated (UTC)
Production ❌ Disabled 2025-06-03 15:45:36
Staging ❌ Disabled 2025-06-03 15:45:36
Demo ❌ Disabled 2025-06-03 15:45:36
Self hosted defaults ❌ Disabled 2025-06-03 15:45:36
Demo2 ❌ Disabled 2025-06-03 15:45:36

Copy link

flagsmith bot commented Jun 3, 2025

Flagsmith Feature integration_onboarding has been updated:

Environment Enabled Value Last Updated (UTC)
Staging ✅ Enabled 2025-06-03 15:53:17

@github-actions github-actions bot added feature New feature or request and removed feature New feature or request labels Jun 3, 2025
Base automatically changed from feat/welcome-page to main June 4, 2025 08:42
Copy link
Contributor

@Zaimwa9 Zaimwa9 left a comment

Choose a reason for hiding this comment

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

A couple of comments, not critical but if maybe you have time to split up a bit the component. Then it should be quickly good to go

I just looked at IntegrationSelect, it needs rebased to remove the welcome page diff

onClick={() => {
setShowCustomTool(false)
setSelected(selected.concat([customTool]))
}}
Copy link
Contributor

Choose a reason for hiding this comment

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

I'd just reset the state setCustomTool here so if you open it again it's empty

</div>
</div>
<hr className='mb-5 mt-0' />
<div className='sticky d-flex justify-content-end gap-4'>
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't know why the stickiness is not working when on a sub category. So we don't see the buttons it can be a bit confusing if you have some time to get why

image

Comment on lines +198 to +211
const skip = () =>
updateTools({
tools: {
completed: true,
integrations: [],
},
}).then(onComplete)
const submit = () =>
updateTools({
tools: {
completed: true,
integrations: selected,
},
}).then(onComplete)
Copy link
Contributor

Choose a reason for hiding this comment

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

Are you fine with using async await syntax here ?

onComplete: () => void
}

const integrationSummaries: IntegrationSummary[] = [
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we put them in a separate data/constant file to light up the file ?

title: 'SumoLogic',
},
]
const categoryDescriptions: Record<
Copy link
Contributor

Choose a reason for hiding this comment

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

same for this one

if (!integrationsData) {
return [] as typeof integrationSummaries
}
const parsed = Object.values(JSON.parse(integrationsData)).concat(
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we find a more self-explanatory name like parsedCategories

// Initialize search as an empty string
const [search, setSearch] = useState<string>('')
const integrationsData = Utils.getFlagsmithValue('integration_data')
const [category, setCategory] = useState<string>(ALL_CATEGORY)
Copy link
Contributor

Choose a reason for hiding this comment

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

We could rename it to selectedCategory, setSelectedCategory do not mix in case of using a map

return sortBy(filtered, 'title') as typeof integrationSummaries
}, [integrationsData, category, search])

const [selected, setSelected] = useState<string[]>([])
Copy link
Contributor

Choose a reason for hiding this comment

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

Same if you don't mind to rename to something like selectedIntegrations

Comment on lines +282 to +290
if (isSelected) {
setSelected(
selected.filter(
(selectedItem) => selectedItem !== v.title,
),
)
} else {
setSelected(selected.concat(v.title))
}
Copy link
Contributor

Choose a reason for hiding this comment

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

We might put it in its own handler above to have the logic isolated

kyle-ssg added 2 commits June 24, 2025 11:50
# Conflicts:
#	frontend/common/types/requests.ts
#	frontend/common/types/responses.ts
#	frontend/e2e/tests/initialise-tests.ts
#	frontend/web/components/App.js
#	frontend/web/components/onboarding/GettingStartedResource.tsx
#	frontend/web/components/onboarding/data/onboarding.data.tsx
#	frontend/web/components/pages/CreateOrganisationPage.js
#	frontend/web/components/pages/GettingStartedPage.tsx
#	frontend/web/components/pages/HomeAside.tsx
#	frontend/web/components/pages/IntegrationsPage.tsx
#	frontend/web/styles/project/_project-nav.scss
#	frontend/web/styles/project/_utils.scss
Copy link

flagsmith bot commented Jun 24, 2025

Flagsmith Feature integration_onboarding has been updated:

Environment Enabled Value Last Updated (UTC)
Demo ✅ Enabled 2025-06-24 13:44:41

Copy link

flagsmith bot commented Jun 24, 2025

Flagsmith Feature integration_onboarding has been updated:

Environment Enabled Value Last Updated (UTC)
Demo ❌ Disabled 2025-06-24 13:44:53

Copy link

flagsmith bot commented Jun 24, 2025

Flagsmith Feature integration_onboarding has been updated:

Segment flagsmith_team values:

Environment Enabled Value Last Updated (UTC)
Production ✅ Enabled 2025-06-24 13:45:22

@github-actions github-actions bot added feature New feature or request and removed feature New feature or request labels Jun 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request flagsmith flag The Issue/PR has a linked feaature flag in Flagsmith front-end Issue related to the React Front End Dashboard
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Get / Set favourite tools
2 participants