Summary
Allow host applications to inject custom form sections (cards) into the team settings view. Currently team settings only shows name, members, and invitations. Apps need a way to add project-specific settings (billing, integrations, preferences, etc.) without overriding the entire view.
Current Behavior
- Team settings view (
MagicStarterTeamSettingsView) renders three fixed sections: General (name), Members, Invitations
- The only extensibility option is full view override via
MagicStarter.view.register('teams.settings', ...), which forces the app to reimplement all existing sections
Proposed Behavior
Add a section registration API that lets host apps append custom SectionCard widgets to the team settings page:
MagicStarter.teamSettings.registerSection(
key: 'billing',
order: 10,
builder: (context, team) => SectionCard(
title: 'Billing',
children: [
// Custom billing form fields
],
),
);
- Sections are rendered after the built-in sections, ordered by
order value
- Each section receives the current team context
- Sections can be removed by key:
MagicStarter.teamSettings.removeSection('billing')
- Registration happens in the app's service provider
boot(), before navigation renders
Acceptance Criteria
Summary
Allow host applications to inject custom form sections (cards) into the team settings view. Currently team settings only shows name, members, and invitations. Apps need a way to add project-specific settings (billing, integrations, preferences, etc.) without overriding the entire view.
Current Behavior
MagicStarterTeamSettingsView) renders three fixed sections: General (name), Members, InvitationsMagicStarter.view.register('teams.settings', ...), which forces the app to reimplement all existing sectionsProposed Behavior
Add a section registration API that lets host apps append custom
SectionCardwidgets to the team settings page:ordervalueMagicStarter.teamSettings.removeSection('billing')boot(), before navigation rendersAcceptance Criteria
MagicStarter.teamSettings.registerSection(key:, order:, builder:)API existsorder(lower = higher on page)removeSection(key)removes a registered sectionhasTeamFeatures())