Repository navigation
Let deployments add their own tabs to the organization page (7.21.0) - #893
Merged
Merged
Conversation
ORGANIZATION.CUSTOM_TABS lists extra tabs shown after the built-in ones, each a custom element given by NAME, LABEL, SCRIPT_URL, STYLE_URL and COMPONENT_TAG, the same shape as the sidebar and dashboard custom components. ?tab=<NAME> opens one, and a name that clashes with a built-in tab is ignored. Override SingleOrganization.get_organization_custom_tabs() to build them per organization. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The organization page can show a deployment's own tabs, configured with ORGANIZATION.CUSTOM_TABS. Co-Authored-By: Claude Opus 5.5 <[email protected]>
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.
Summary
Adds
ORGANIZATION.CUSTOM_TABSso a deployment can show its own tabs on an organization's page. These are for settings that belong to the organization but not to the library, such as a payment provider connection. Inbox Academy will use it for a Stripe Integrations tab, which Stripe's app review requires.NAME,LABEL,SCRIPT_URL,STYLE_URLandCOMPONENT_TAG. This is the same shape as the sidebar and dashboard custom components.?tab=<NAME>opens one, so it can be linked to. A name that clashes with a built-in tab (general_info,members,newsletters,api_keys) is ignored.sanitizeComponentHtmlas the dashboard components, which strips event handlers and scripts. The tab's script and style URLs go into the same deduped list in the page head as the navbar and dashboard components.SingleOrganization.get_organization_custom_tabs(organization), for example to put the organization's id on the tag.docs/source/installation.rstand the CHANGELOG. Bumps the version to 7.21.0.Testing
pytest tests/platform: 628 passed. The coverage gate fails on this subset run only.vitestOrganization.test.jsx: 16 passed, including 4 new tests. They cover rendering a tab and its component, opening one from?tab=, ignoring a name that clashes with a built-in tab, and stripping event handlers.🤖 Generated with Claude Code