Skip to content

Commit

Permalink
1.2.4
Browse files Browse the repository at this point in the history
  • Loading branch information
whosydd committed Oct 14, 2021
1 parent 5908341 commit a0b4aa5
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 24 deletions.
8 changes: 0 additions & 8 deletions .vscode/extensions.json

This file was deleted.

4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 1.2.4 (2021-10-14)

- 修复:移除主题时,没有选择会弹出‘移除 undefined 的提示’

## 1.2.3 (2021-09-21)

- 修改 "debugConsole.warningForeground": "#dfbb74"
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "ayu-mirage-plus",
"displayName": "Ayu Mirage Plus",
"description": "This theme is basic on Ayu Mirage, just for fun! :)",
"version": "1.2.3",
"version": "1.2.4",
"publisher": "GY",
"repository": {
"type": "git",
Expand Down
6 changes: 3 additions & 3 deletions src/extension.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as vscode from 'vscode'
import add from './add'
import remove from './remove'
import reset from './reset'
import add from './utils/add'
import remove from './utils/remove'
import reset from './utils/reset'

export function activate(context: vscode.ExtensionContext) {
// 生成主题
Expand Down
2 changes: 1 addition & 1 deletion src/add.ts → src/utils/add.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as fs from 'fs'
import * as vscode from 'vscode'
import settings from './config/settings'
import settings from '../config/settings'

const { foregroundColors, themeColors, borderColors, highlightColors } = settings

Expand Down
23 changes: 13 additions & 10 deletions src/remove.ts → src/utils/remove.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,18 @@ export default async () => {
const res = themes.filter(item => !rmThemeList?.includes(item))
packageFile.contributes.themes = res
fs.writeFileSync(`${__dirname}/../package.json`, JSON.stringify(packageFile))
vscode.window
.showInformationMessage(
`${rmThemeList?.map(item => item.label).toString()} has been removed!`,
'Reload Window'
)
.then(value =>
value === 'Reload Window'
? vscode.commands.executeCommand('workbench.action.reloadWindow')
: null
)

if (rmThemeList !== undefined) {
vscode.window
.showInformationMessage(
`${rmThemeList?.map(item => item.label).toString()} has been removed!`,
'Reload Window'
)
.then(value =>
value === 'Reload Window'
? vscode.commands.executeCommand('workbench.action.reloadWindow')
: null
)
}
})
}
2 changes: 1 addition & 1 deletion src/reset.ts → src/utils/reset.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as fs from 'fs'
import * as vscode from 'vscode'
import settings from './config/settings'
import settings from '../config/settings'

const { foregroundColors, themeColors, borderColors, highlightColors } = settings

Expand Down

0 comments on commit a0b4aa5

Please sign in to comment.