feat: per-branding disabledFeatures#10968
Open
jcasimir wants to merge 1 commit into
Open
Conversation
Allow multi-host installations to disable features per branding entry in addition to the installation-wide DISABLED_FEATURES env. A branding entry may carry disabledFeatures (same comma-separated format); the two lists are merged at client bootstrap (web and desktop), so the env remains the baseline and brandings can only extend it. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Connected to Huly®: UBERF-16643 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Allows multi-host (branded) installations to disable features per branding entry, in addition to the installation-wide
DISABLED_FEATURESenv var.A branding entry (the JSON served at
BRANDING_URL, keyed by host) may now carry adisabledFeatureskey using the same comma-separated format:{ "tracker.example-client.com": { "title": "Example Client Tracker", "disabledFeatures": "recruit,lead,inventory,training" } }At client bootstrap (web and desktop) the branding list is merged with
DISABLED_FEATURES, feeding bothpresentation.metadata.DisabledFeaturesand the modelExtraFilter— so the env var remains the installation-wide baseline and brandings can only extend it, never re-enable.Why
Self-hosters serving multiple clients/brands from one installation (one workspace per client, one entry host per client) often want different feature surfaces per client — e.g. a lean tracker-only experience for one client while another uses recruiting. Today
DISABLED_FEATURESis all-or-nothing per installation.This reuses the existing branding mechanism (already per-host and already consulted at the same bootstrap points), so the change is small and purely additive: no schema, server, or behavior changes for installations that don't set the key.
Changes
dev/prod/src/platform.ts—disabledFeatures?: stringonBranding; merge withconfig.DISABLED_FEATURESdesktop/src/ui/types.ts— same field on desktopBrandingdesktop/src/ui/platform.ts— same mergedocs/disableFeatures.md— documentationTesting
Verified on a self-hosted v0.7.426 installation serving two hosts (two brands, one deployment) with the web bundle built from this branch:
window.location.hostas before (titles verified in the UI)."disabledFeatures": "calendar"on one host's branding entry only, CDP-captured bootstrap on that host logsloaded branding {key, title, disabledFeatures: "calendar"}while the other host's branding loads without the key — same bundle, host-differentiated feature list feeding the existingDisabledFeatures/ExtraFilterpath.🤖 Generated with Claude Code