Change order of global buttons

This commit is contained in:
dimitrievgs 2025-10-20 21:42:04 +03:00
parent 220e6cd2ad
commit aa805a5505
2 changed files with 18 additions and 18 deletions

18
main.js

File diff suppressed because one or more lines are too long

View File

@ -238,6 +238,15 @@ export class GraphView extends ItemView {
});
this.deleteSelectedButton.addEventListener('click', this.handleDeleteSelectedNodes.bind(this));
this.graphSettingsButton = toolbar.createEl('button', {
cls: 'global-action-button',
attr: { 'aria-label': 'Настройки графа', 'data-tooltip': 'Настроить системный промпт для текущего графа' },
text: '⚙️' // Иконка шестеренки
});
this.graphSettingsButton.addEventListener('click', this.handleGraphSettingsClick.bind(this));
// Деактивируем кнопку по умолчанию, пока граф не выбран
this.graphSettingsButton.setAttr('disabled', 'true');
this.newIndependentChatActionButton = toolbar.createEl('button', {
cls: 'global-action-button',
attr: { 'aria-label': 'Новый независимый чат', 'data-tooltip': 'Начать новую беседу, формируя отдельный, независимый подграф' },
@ -247,15 +256,6 @@ export class GraphView extends ItemView {
// Эмитируем новое событие, которое будет слушать ТОЛЬКО ChatView
this.plugin.eventBus.emit('start-new-independent-chat');
});
this.graphSettingsButton = toolbar.createEl('button', {
cls: 'global-action-button',
attr: { 'aria-label': 'Настройки графа', 'data-tooltip': 'Настроить системный промпт для текущего графа' },
text: '⚙️' // Иконка шестеренки
});
this.graphSettingsButton.addEventListener('click', this.handleGraphSettingsClick.bind(this));
// Деактивируем кнопку по умолчанию, пока граф не выбран
this.graphSettingsButton.setAttr('disabled', 'true');
}
// ----------------------------------------------- Graph Panel Integration --------------------------------------------------