icons from extensions, settings-based tab ordering, static context tabs
Icons now declared on TabContribution via the icon field — the hardcoded switch in _BottomRail is a fallback only. All sidebar and context extensions set their Phosphor icon explicitly. PanelRegistry supports setTabOrder(slot, List<String>) — tabs render in the order specified by project.layout.sidebar.order / context.order in settings.yaml. Falls back to registration order. Priority field removed from all contributions. Context tabs are static again — persist with their last content, selection just loads new data and switches focus. No spawn/despawn. Tickets sidebar priority set to -200 (leftmost, default open). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -120,6 +120,14 @@ class DefaultLayoutExtension extends ClideExtension {
|
||||
|
||||
void _restoreLayout(ClideExtensionContext ctx) {
|
||||
final s = ctx.settings;
|
||||
final sidebarOrder = s.get<List>('project.layout.sidebar.order');
|
||||
if (sidebarOrder != null) {
|
||||
ctx.panels.setTabOrder(Slots.sidebar, sidebarOrder.cast<String>());
|
||||
}
|
||||
final contextOrder = s.get<List>('project.layout.context.order');
|
||||
if (contextOrder != null) {
|
||||
ctx.panels.setTabOrder(Slots.contextPanel, contextOrder.cast<String>());
|
||||
}
|
||||
final sidebarCollapsed = s.get<bool>(_kSidebarCollapsed);
|
||||
if (sidebarCollapsed != null) {
|
||||
ctx.arrangement.setCollapsed(Slots.sidebar, sidebarCollapsed);
|
||||
|
||||
Reference in New Issue
Block a user