MCPcopy Create free account
hub / github.com/obgnail/typora_plugin / closeLeft

Method closeLeft

plugin/window_tab.js:183–191  ·  view source on GitHub ↗
(idx)

Source from the content-addressed store, hash-verified

181 }
182
183 closeLeft(idx) {
184 const originPath = this.current?.path
185 this._tabs.splice(0, idx)
186 if (!originPath || this._findIndexByPath(originPath) === -1) {
187 this.switch(0)
188 } else {
189 this.switchByPath(originPath)
190 }
191 }
192
193 closeRight(idx) {
194 const originPath = this.current?.path

Callers 2

onClickMenuItemMethod · 0.80
window_tab.test.jsFile · 0.80

Calls 4

_findIndexByPathMethod · 0.95
switchMethod · 0.95
switchByPathMethod · 0.95
spliceMethod · 0.80

Tested by

no test coverage detected