mirror of
https://github.com/Eugeny/tabby.git
synced 2025-09-08 17:41:50 +00:00
bumped eslint
This commit is contained in:
@@ -12,7 +12,7 @@ export class RenameTabModalComponent {
|
||||
@ViewChild('input') input: ElementRef
|
||||
|
||||
constructor (
|
||||
private modalInstance: NgbActiveModal
|
||||
private modalInstance: NgbActiveModal,
|
||||
) { }
|
||||
|
||||
ngOnInit () {
|
||||
|
@@ -64,7 +64,7 @@ export class SelectorModalComponent<T> {
|
||||
this.filteredOptions = this.options.slice().sort(
|
||||
firstBy<SelectorOption<T>, number>(x => x.weight ?? 0)
|
||||
.thenBy<SelectorOption<T>, string>(x => x.group ?? '')
|
||||
.thenBy<SelectorOption<T>, string>(x => x.name)
|
||||
.thenBy<SelectorOption<T>, string>(x => x.name),
|
||||
)
|
||||
.filter(x => !x.freeInputPattern)
|
||||
} else {
|
||||
|
@@ -74,7 +74,7 @@ export class SplitTabPaneLabelComponent extends SelfPositioningComponent {
|
||||
tabElement.offsetTop,
|
||||
tabElement.clientWidth,
|
||||
tabElement.clientHeight,
|
||||
'px'
|
||||
'px',
|
||||
)
|
||||
}
|
||||
}
|
||||
|
@@ -77,14 +77,14 @@ export class SplitTabSpannerComponent extends SelfPositioningComponent {
|
||||
this.container.x,
|
||||
this.container.y + this.container.h * this.container.getOffsetRatio(this.index),
|
||||
this.container.w,
|
||||
0
|
||||
0,
|
||||
)
|
||||
} else {
|
||||
this.setDimensions(
|
||||
this.container.x + this.container.w * this.container.getOffsetRatio(this.index),
|
||||
this.container.y,
|
||||
0,
|
||||
this.container.h
|
||||
this.container.h,
|
||||
)
|
||||
}
|
||||
}
|
||||
|
@@ -41,7 +41,7 @@ export class ConfigProxy {
|
||||
enumerable: true,
|
||||
configurable: false,
|
||||
get: () => proxy,
|
||||
}
|
||||
},
|
||||
)
|
||||
} else {
|
||||
Object.defineProperty(
|
||||
@@ -54,7 +54,7 @@ export class ConfigProxy {
|
||||
set: (value) => {
|
||||
this.__setValue(key, value)
|
||||
},
|
||||
}
|
||||
},
|
||||
)
|
||||
}
|
||||
}
|
||||
|
@@ -47,7 +47,7 @@ export class FileProvidersService {
|
||||
providers.map(p => ({
|
||||
name: p.name,
|
||||
result: p,
|
||||
}))
|
||||
})),
|
||||
)
|
||||
}
|
||||
}
|
||||
|
@@ -52,7 +52,7 @@ export class HomeBaseService {
|
||||
if (!window.localStorage.analyticsUserID) {
|
||||
window.localStorage.analyticsUserID = uuidv4()
|
||||
}
|
||||
this.mixpanel = mixpanel.init('bb4638b0860eef14c04d4fbc5eb365fa')
|
||||
this.mixpanel = (mixpanel as any).init('bb4638b0860eef14c04d4fbc5eb365fa')
|
||||
if (!window.localStorage.installEventSent) {
|
||||
this.mixpanel.track('freshInstall', this.getAnalyticsProperties())
|
||||
window.localStorage.installEventSent = true
|
||||
|
@@ -218,7 +218,7 @@ export class HotkeysService {
|
||||
let matched = true
|
||||
for (const item of sequence) {
|
||||
const nextOffset = currentSequence.slice(lastIndex).findIndex(
|
||||
x => x.toLowerCase() === item.toLowerCase()
|
||||
x => x.toLowerCase() === item.toLowerCase(),
|
||||
)
|
||||
if (nextOffset === -1) {
|
||||
matched = false
|
||||
@@ -274,7 +274,7 @@ export class HotkeysService {
|
||||
return (
|
||||
await Promise.all(
|
||||
this.config.enabledServices(this.hotkeyProviders)
|
||||
.map(async x => x.provide())
|
||||
.map(async x => x.provide()),
|
||||
)
|
||||
).reduce((a, b) => a.concat(b))
|
||||
}
|
||||
|
@@ -67,7 +67,7 @@ export class TranslateServiceWrapper extends TranslateService {
|
||||
}
|
||||
this.translations[this.defaultLang][key] ??= this.compiler.compile(
|
||||
this._defaultTranslation[key] || key,
|
||||
this.defaultLang
|
||||
this.defaultLang,
|
||||
)
|
||||
return super.getParsedResult(translations, key, interpolateParams ?? {})
|
||||
}
|
||||
|
@@ -14,7 +14,7 @@ export class TabRecoveryService {
|
||||
private constructor (
|
||||
@Inject(TabRecoveryProvider) private tabRecoveryProviders: TabRecoveryProvider<BaseTabComponent>[]|null,
|
||||
private config: ConfigService,
|
||||
log: LogService
|
||||
log: LogService,
|
||||
) {
|
||||
this.logger = log.create('tabRecovery')
|
||||
}
|
||||
@@ -25,8 +25,8 @@ export class TabRecoveryService {
|
||||
}
|
||||
window.localStorage.tabsRecovery = JSON.stringify(
|
||||
(await Promise.all(
|
||||
tabs.map(async tab => this.getFullRecoveryToken(tab, { includeState: true }))
|
||||
)).filter(token => !!token)
|
||||
tabs.map(async tab => this.getFullRecoveryToken(tab, { includeState: true })),
|
||||
)).filter(token => !!token),
|
||||
)
|
||||
}
|
||||
|
||||
|
@@ -34,15 +34,9 @@ export function wrapPromise <T> (zone: NgZone, promise: Promise<T>): Promise<T>
|
||||
}
|
||||
|
||||
export class ResettableTimeout {
|
||||
private fn: () => void
|
||||
private timeout: number
|
||||
private id: any
|
||||
private id: any = null
|
||||
|
||||
constructor (fn: () => void, timeout: number) {
|
||||
this.fn = fn
|
||||
this.timeout = timeout
|
||||
this.id = null
|
||||
}
|
||||
constructor (private fn: () => void, private timeout: number) {}
|
||||
|
||||
set (timeout?: number): void {
|
||||
this.clear()
|
||||
|
Reference in New Issue
Block a user