mirror of
https://github.com/Eugeny/tabby.git
synced 2025-07-20 02:18:01 +00:00
support for providing commands as toolbar buttons
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
import { marker as _ } from '@biesbjerg/ngx-translate-extract-marker'
|
||||
import axios from 'axios'
|
||||
import { marked } from 'marked'
|
||||
import { Component } from '@angular/core'
|
||||
import { Component, Injector } from '@angular/core'
|
||||
import { BaseTabComponent, TranslateService } from 'tabby-core'
|
||||
|
||||
export interface Release {
|
||||
@@ -22,8 +22,8 @@ export class ReleaseNotesComponent extends BaseTabComponent {
|
||||
releases: Release[] = []
|
||||
lastPage = 1
|
||||
|
||||
constructor (translate: TranslateService) {
|
||||
super()
|
||||
constructor (translate: TranslateService, injector: Injector) {
|
||||
super(injector)
|
||||
this.setTitle(translate.instant(_('Release notes')))
|
||||
this.loadReleases(1)
|
||||
}
|
||||
|
@@ -2,7 +2,7 @@
|
||||
import { marker as _ } from '@biesbjerg/ngx-translate-extract-marker'
|
||||
import * as yaml from 'js-yaml'
|
||||
import { debounce } from 'utils-decorators/dist/esm/debounce/debounce'
|
||||
import { Component, Inject, Input, HostBinding, NgZone } from '@angular/core'
|
||||
import { Component, Inject, Input, HostBinding, NgZone, Injector } from '@angular/core'
|
||||
import {
|
||||
ConfigService,
|
||||
BaseTabComponent,
|
||||
@@ -52,8 +52,9 @@ export class SettingsTabComponent extends BaseTabComponent {
|
||||
private app: AppService,
|
||||
@Inject(SettingsTabProvider) public settingsProviders: SettingsTabProvider[],
|
||||
translate: TranslateService,
|
||||
injector: Injector,
|
||||
) {
|
||||
super()
|
||||
super(injector)
|
||||
this.setTitle(translate.instant(_('Settings')))
|
||||
this.settingsProviders = config.enabledServices(this.settingsProviders)
|
||||
this.settingsProviders = this.settingsProviders.filter(x => !!x.getComponentType())
|
||||
|
Reference in New Issue
Block a user