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(settings-security): add feature flag for trusted domains #10338

Conversation

AMoreaux
Copy link
Contributor

Introduce a new feature flag, IsTrustedDomainsEnabled, to control the visibility of the trusted domains section in security settings. Updated back-end seeds, enums, and front-end logic to support this change.

Introduce a new feature flag, IsTrustedDomainsEnabled, to control the visibility of the trusted domains section in security settings. Updated back-end seeds, enums, and front-end logic to support this change.
@AMoreaux AMoreaux self-assigned this Feb 19, 2025
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This PR adds a new feature flag IsTrustedDomainsEnabled to control the visibility of trusted domains functionality in the security settings section.

  • Added new feature flag in /packages/twenty-server/src/database/typeorm-seeds/core/feature-flags.ts with default value false
  • Implemented conditional rendering in /packages/twenty-front/src/pages/settings/security/SettingsSecurity.tsx using the new feature flag
  • Added IsTrustedDomainsEnabled to FeatureFlagKey enum in /packages/twenty-server/src/engine/core-modules/feature-flag/enums/feature-flag-key.enum.ts
  • Updated GraphQL types in /packages/twenty-front/src/generated/graphql.tsx to include the new feature flag

4 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile

Introduce a new enum flag IsTrustedDomainsEnabled in the GraphQL metadata. This addition supports feature toggling for trusted domain functionality.
Copy link
Member

@FelixMalfait FelixMalfait left a comment

Choose a reason for hiding this comment

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

maybe rename as discussed before merging? Good for me otherwise!

…ture-flag-for-trusted-domains

# Conflicts:
#	packages/twenty-front/src/pages/settings/security/SettingsSecurity.tsx
Renamed the feature flag key IsTrustedDomainsEnabled to IsApprovedAccessDomainsEnabled across the codebase. Updated all relevant enums, seeds, GraphQL types, and usage references to align with the new terminology. This change improves clarity and better reflects the intended functionality.
…d-domains' into feat/add-feature-flag-for-trusted-domains
Removed the WorkspaceTrustedDomainResolver and WorkspaceTrustedDomainService, along with their associated methods and dependencies. This change simplifies the codebase by eliminating unused or redundant functionality.
…10346)

Added support for validating trusted domains during user sign-in and
sign-up processes. Updated services to check trusted domains and ensure
proper access control. Adjusted tests and mocks to align with the new
functionality.
@AMoreaux AMoreaux merged commit 6fbb8b6 into feat/frontend-manage-trusted-domains Feb 21, 2025
45 checks passed
@AMoreaux AMoreaux deleted the feat/add-feature-flag-for-trusted-domains branch February 21, 2025 15:45
Copy link
Contributor

Thanks @AMoreaux for your contribution!
This marks your 97th PR on the repo. You're top 1% of all our contributors 🎉
See contributor page - Share on LinkedIn - Share on Twitter

Contributions

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.

2 participants