diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 45fc7ad..a0499e8 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -25,7 +25,11 @@ yarn dev ### i18n -在 `public/i18n/` 下面创建一种语言的 `yml` 文件,例如 `zh-Hans.yml`。然后参考 `zh-CN.yml` 或者 `en.yml` 编写语言文件。并注意,PicGo 会通过语言文件中的 `LANG_DISPLAY_LABEL` 向用户展示该语言的名称。 +1. 在 `public/i18n/` 下面创建一种语言的 `yml` 文件,例如 `zh-Hans.yml`。然后参考 `zh-CN.yml` 或者 `en.yml` 编写语言文件。并注意,PicGo 会通过语言文件中的 `LANG_DISPLAY_LABEL` 向用户展示该语言的名称。 + +2. 在 `src/universal/i18n/index.ts` 里添加一种默认语言。其中 `label` 就是语言文件中 `LANG_DISPLAY_LABEL` 的值,`value` 是语言文件名。 + +3. 如果是对已有语言文件进行更新,请在更新完,务必运行一遍 `yarn gen-i18n`,确保能生成正确的语言定义文件。 ### 提交代码 diff --git a/CONTRIBUTING_EN.md b/CONTRIBUTING_EN.md index b40e501..1f962f6 100644 --- a/CONTRIBUTING_EN.md +++ b/CONTRIBUTING_EN.md @@ -25,7 +25,11 @@ Startup project. ### i18n -Create a `yml` file for a language under `public/i18n/`, e.g. `zh-Hans.yml`. Then refer to `zh-CN.yml` or `en.yml` to write language files. Also note that PicGo will display the name of the language to the user via `LANG_DISPLAY_LABEL` in the language file. +1. Create a language `yml` file under `public/i18n/`, for example `zh-Hans.yml`. Then refer to `zh-CN.yml` or `en.yml` to write language files. Also note that PicGo will display the name of the language to the user via `LANG_DISPLAY_LABEL` in the language file. + +2. Add a default language to `src/universal/i18n/index.ts`. where `label` is the value of `LANG_DISPLAY_LABEL` in the language file, and `value` is the name of the language file. + +3. If you are updating an existing language file, be sure to run `yarn gen-i18n` after the update to ensure that the correct language definition file can be generated. ### Submit code diff --git a/package.json b/package.json index 0d9688d..1e2a04e 100644 --- a/package.json +++ b/package.json @@ -38,7 +38,7 @@ }, "dependencies": { "@picgo/i18n": "^1.0.0", - "@picgo/store": "2.0.1", + "@picgo/store": "^2.0.4", "axios": "^0.19.0", "compare-versions": "^4.1.3", "core-js": "^3.3.2", @@ -48,7 +48,7 @@ "keycode": "^2.2.0", "lodash-id": "^0.14.0", "lowdb": "^1.0.0", - "picgo": "^1.5.0-alpha.5", + "picgo": "^1.5.0-alpha.7", "qrcode.vue": "^1.7.0", "shell-path": "2.1.0", "uuidv4": "^6.2.11", diff --git a/src/main/apis/core/datastore/index.ts b/src/main/apis/core/datastore/index.ts index 0813fb5..2caf12b 100644 --- a/src/main/apis/core/datastore/index.ts +++ b/src/main/apis/core/datastore/index.ts @@ -37,9 +37,12 @@ class ConfigStore { this.read() } - read (flush = false) { - // if flush -> true, read origin file again - this.db.read(flush) + flush () { + this.db = new JSONStore(CONFIG_PATH) + } + + read () { + this.db.read() return this.db } diff --git a/src/main/apis/core/picgo/index.ts b/src/main/apis/core/picgo/index.ts index 0112fc5..e9d5d1b 100644 --- a/src/main/apis/core/picgo/index.ts +++ b/src/main/apis/core/picgo/index.ts @@ -2,6 +2,7 @@ import { dbChecker, dbPathChecker } from 'apis/core/datastore/dbChecker' import pkg from 'root/package.json' import { PicGo } from 'picgo' import db from 'apis/core/datastore' +import debounce from 'lodash/debounce' const CONFIG_PATH = dbPathChecker() @@ -18,12 +19,16 @@ picgo.GUI_VERSION = global.PICGO_GUI_VERSION const originPicGoSaveConfig = picgo.saveConfig.bind(picgo) +function flushDB () { + db.flush() +} + +const debounced = debounce(flushDB, 1000) + picgo.saveConfig = (config: IStringKeyMap) => { originPicGoSaveConfig(config) // flush electron's db - setTimeout(() => { - db.read(true) - }, 0) + debounced() } export default picgo diff --git a/src/main/events/ipcList.ts b/src/main/events/ipcList.ts index d7ed2bb..f354acb 100644 --- a/src/main/events/ipcList.ts +++ b/src/main/events/ipcList.ts @@ -27,7 +27,8 @@ import { OPEN_URL, RELOAD_APP, SHOW_PLUGIN_PAGE_MENU, - SET_MINI_WINDOW_POS + SET_MINI_WINDOW_POS, + GET_PICBEDS } from '#/events/constants' import { uploadClipboardFiles, @@ -151,9 +152,9 @@ export default { } }) - ipcMain.on('getPicBeds', (evt: IpcMainEvent) => { + ipcMain.on(GET_PICBEDS, (evt: IpcMainEvent) => { const picBeds = getPicBeds() - evt.sender.send('getPicBeds', picBeds) + evt.sender.send(GET_PICBEDS, picBeds) evt.returnValue = picBeds }) diff --git a/src/main/events/picgoCoreIPC.ts b/src/main/events/picgoCoreIPC.ts index 61ce1d6..20036a8 100644 --- a/src/main/events/picgoCoreIPC.ts +++ b/src/main/events/picgoCoreIPC.ts @@ -383,6 +383,7 @@ const handleI18n = () => { ipcMain.on(SET_CURRENT_LANGUAGE, (event: IpcMainEvent, language: string) => { i18nManager.setCurrentLanguage(language) const { lang, locales } = i18nManager.getCurrentLocales() + picgo.i18n.setLanguage(lang) if (process.platform === 'darwin') { const trayWindow = windowManager.get(IWindowList.TRAY_WINDOW) trayWindow?.webContents.send(SET_CURRENT_LANGUAGE, lang, locales) diff --git a/src/main/i18n/index.ts b/src/main/i18n/index.ts index 79d98ad..9096be4 100644 --- a/src/main/i18n/index.ts +++ b/src/main/i18n/index.ts @@ -2,6 +2,7 @@ import yaml from 'js-yaml' import { ObjectAdapter, I18n } from '@picgo/i18n' import path from 'path' import fs from 'fs-extra' +import { builtinI18nList } from '#/i18n' class I18nManager { private i18n: I18n | null = null @@ -10,13 +11,7 @@ class I18nManager { private localesMap: Map = new Map() private currentLanguage: string = 'zh-CN' readonly defaultLanguage: string = 'zh-CN' - private i18nFileList: II18nItem[] = [{ - label: '简体中文', - value: 'zh-CN' - }, { - label: 'English', - value: 'en' - }] + private i18nFileList: II18nItem[] = builtinI18nList setOutterI18nFolder (folder: string) { this.outterI18nFolder = folder diff --git a/src/main/utils/beforeOpen.ts b/src/main/utils/beforeOpen.ts index 8e0c8e7..fd1a807 100644 --- a/src/main/utils/beforeOpen.ts +++ b/src/main/utils/beforeOpen.ts @@ -93,18 +93,16 @@ function resolveOtherI18nFiles () { withFileTypes: true }) i18nFiles.forEach(item => { - if (item.isFile()) { - if (item.name.endsWith('.yml')) { - const i18nFilePath = path.join(i18nFolder, item.name) - const i18nFile = fs.readFileSync(i18nFilePath, 'utf8') - try { - const i18nFileObj = yaml.load(i18nFile) as unknown as ILocales - if (i18nFileObj?.LANG_DISPLAY_LABEL) { - i18nManager.addI18nFile(item.name.replace('.yml', ''), i18nFileObj.LANG_DISPLAY_LABEL) - } - } catch (e) { - console.error(e) + if (item.isFile() && item.name?.endsWith('.yml')) { + const i18nFilePath = path.join(i18nFolder, item.name) + const i18nFile = fs.readFileSync(i18nFilePath, 'utf8') + try { + const i18nFileObj = yaml.load(i18nFile) as unknown as ILocales + if (i18nFileObj?.LANG_DISPLAY_LABEL) { + i18nManager.addI18nFile(item.name.replace('.yml', ''), i18nFileObj.LANG_DISPLAY_LABEL) } + } catch (e) { + console.error(e) } } }) diff --git a/src/renderer/i18n/index.ts b/src/renderer/i18n/index.ts index 92c03e0..77d8757 100644 --- a/src/renderer/i18n/index.ts +++ b/src/renderer/i18n/index.ts @@ -2,16 +2,11 @@ import { ipcRenderer } from 'electron' import { ObjectAdapter, I18n } from '@picgo/i18n' import { GET_CURRENT_LANGUAGE, SET_CURRENT_LANGUAGE, FORCE_UPDATE, GET_LANGUAGE_LIST } from '#/events/constants' import bus from '@/utils/bus' +import { builtinI18nList } from '#/i18n' export class I18nManager { private i18n: I18n | null = null - private i18nFileList: II18nItem[] = [{ - label: '简体中文', - value: 'zh-CN' - }, { - label: 'English', - value: 'en' - }] + private i18nFileList: II18nItem[] = builtinI18nList private getLanguageList () { ipcRenderer.send(GET_LANGUAGE_LIST) diff --git a/src/renderer/layouts/Main.vue b/src/renderer/layouts/Main.vue index 73d4549..b166a1d 100644 --- a/src/renderer/layouts/Main.vue +++ b/src/renderer/layouts/Main.vue @@ -160,7 +160,8 @@ import { CLOSE_WINDOW, SHOW_MAIN_PAGE_MENU, SHOW_MAIN_PAGE_QRCODE, - SHOW_MAIN_PAGE_DONATION + SHOW_MAIN_PAGE_DONATION, + GET_PICBEDS } from '~/universal/events/constants' @Component({ name: 'main-page', @@ -183,8 +184,8 @@ export default class extends Vue { choosedPicBedForQRCode: string[] = [] created () { this.os = process.platform - ipcRenderer.send('getPicBeds') - ipcRenderer.on('getPicBeds', this.getPicBeds) + ipcRenderer.send(GET_PICBEDS) + ipcRenderer.on(GET_PICBEDS, this.getPicBeds) this.handleGetPicPeds() ipcRenderer.on(SHOW_MAIN_PAGE_QRCODE, () => { this.qrcodeVisible = true @@ -206,7 +207,7 @@ export default class extends Vue { } handleGetPicPeds = () => { - ipcRenderer.send('getPicBeds') + ipcRenderer.send(GET_PICBEDS) } handleSelect (index: string) { @@ -217,18 +218,24 @@ export default class extends Vue { }) } else { const picBed = index.replace(/picbeds-/, '') - if (this.$builtInPicBed.includes(picBed)) { - this.$router.push({ - name: picBed - }) - } else { - this.$router.push({ - name: 'others', - params: { - type: picBed - } - }) - } + this.$router.push({ + name: 'picbeds', + params: { + type: picBed + } + }) + // if (this.$builtInPicBed.includes(picBed)) { + // this.$router.push({ + // name: picBed + // }) + // } else { + // this.$router.push({ + // name: 'others', + // params: { + // type: picBed + // } + // }) + // } } } @@ -264,7 +271,7 @@ export default class extends Vue { } beforeDestroy () { - ipcRenderer.removeListener('getPicBeds', this.getPicBeds) + ipcRenderer.removeListener(GET_PICBEDS, this.getPicBeds) } } diff --git a/src/renderer/pages/Gallery.vue b/src/renderer/pages/Gallery.vue index 7f8c154..0671929 100644 --- a/src/renderer/pages/Gallery.vue +++ b/src/renderer/pages/Gallery.vue @@ -112,7 +112,7 @@ import gallerys from 'vue-gallery' import { Component, Vue, Watch } from 'vue-property-decorator' import { IResult } from '@picgo/store/dist/types' -import { PASTE_TEXT } from '#/events/constants' +import { PASTE_TEXT, GET_PICBEDS } from '#/events/constants' import { ipcRenderer, clipboard, @@ -157,7 +157,6 @@ export default class extends Vue { picBed: IPicBedType[] = [] @Watch('$route') handleRouteUpdate (to: any, from: any) { - console.log(to, from) if (from.name === 'gallery') { this.clearChoosedList() } @@ -172,8 +171,8 @@ export default class extends Vue { this.updateGallery() }) }) - ipcRenderer.send('getPicBeds') - ipcRenderer.on('getPicBeds', this.getPicBeds) + ipcRenderer.send(GET_PICBEDS) + ipcRenderer.on(GET_PICBEDS, this.getPicBeds) this.updateGallery() } @@ -451,7 +450,7 @@ export default class extends Vue { beforeDestroy () { ipcRenderer.removeAllListeners('updateGallery') - ipcRenderer.removeListener('getPicBeds', this.getPicBeds) + ipcRenderer.removeListener(GET_PICBEDS, this.getPicBeds) } } diff --git a/src/renderer/pages/MiniPage.vue b/src/renderer/pages/MiniPage.vue index dbe69c1..a3b530c 100644 --- a/src/renderer/pages/MiniPage.vue +++ b/src/renderer/pages/MiniPage.vue @@ -55,7 +55,6 @@ export default class extends Vue { this.showError = true } }) - this.getPicBeds() } mounted () { @@ -77,10 +76,6 @@ export default class extends Vue { } } - getPicBeds () { - this.picBed = ipcRenderer.sendSync('getPicBeds') - } - onDrop (e: DragEvent) { this.dragover = false const items = e.dataTransfer!.items @@ -172,7 +167,6 @@ export default class extends Vue { if (e.button === 0) { // left mouse this.openUploadWindow() } else { - this.getPicBeds() this.openContextMenu() } } @@ -184,7 +178,6 @@ export default class extends Vue { beforeDestroy () { ipcRenderer.removeAllListeners('uploadProgress') - ipcRenderer.removeListener('getPicBeds', this.getPicBeds) window.removeEventListener('mousedown', this.handleMouseDown, false) window.removeEventListener('mousemove', this.handleMouseMove, false) window.removeEventListener('mouseup', this.handleMouseUp, false) diff --git a/src/renderer/pages/PicGoSetting.vue b/src/renderer/pages/PicGoSetting.vue index f44f477..606474f 100644 --- a/src/renderer/pages/PicGoSetting.vue +++ b/src/renderer/pages/PicGoSetting.vue @@ -386,7 +386,7 @@ import keyDetect from '@/utils/key-binding' import pkg from 'root/package.json' import { IConfig } from 'picgo' -import { PICGO_OPEN_FILE, OPEN_URL } from '#/events/constants' +import { PICGO_OPEN_FILE, OPEN_URL, GET_PICBEDS } from '#/events/constants' import { ipcRenderer } from 'electron' @@ -483,8 +483,8 @@ export default class extends Vue { created () { this.os = process.platform - ipcRenderer.send('getPicBeds') - ipcRenderer.on('getPicBeds', this.getPicBeds) + ipcRenderer.send(GET_PICBEDS) + ipcRenderer.on(GET_PICBEDS, this.getPicBeds) this.initData() } @@ -614,7 +614,7 @@ export default class extends Vue { this.saveConfig({ 'picBed.list': list }) - ipcRenderer.send('getPicBeds') + ipcRenderer.send(GET_PICBEDS) } handleAutoStartChange (val: boolean) { @@ -763,6 +763,7 @@ export default class extends Vue { this.saveConfig({ 'settings.language': val }) + this.sendToMain(GET_PICBEDS) } goConfigPage () { @@ -774,7 +775,7 @@ export default class extends Vue { } beforeDestroy () { - ipcRenderer.removeListener('getPicBeds', this.getPicBeds) + ipcRenderer.removeListener(GET_PICBEDS, this.getPicBeds) } } diff --git a/src/renderer/pages/Plugin.vue b/src/renderer/pages/Plugin.vue index 2cb9cff..4ba31f7 100644 --- a/src/renderer/pages/Plugin.vue +++ b/src/renderer/pages/Plugin.vue @@ -121,7 +121,8 @@ import { PICGO_HANDLE_PLUGIN_ING, PICGO_TOGGLE_PLUGIN, SHOW_PLUGIN_PAGE_MENU, - DEFAULT_LOGO + DEFAULT_LOGO, + GET_PICBEDS } from '#/events/constants' @Component({ @@ -249,7 +250,7 @@ export default class extends Vue { } }) ipcRenderer.on(DEFAULT_LOGO, (evt: IpcRendererEvent, logoPath) => { - this.defaultLogo = `this.src="${logoPath.replace(/\\/g, '/')}"` + this.defaultLogo = `this.src="file://${logoPath.replace(/\\/g, '/')}"` }) this.getPluginList() this.getSearchResult = debounce(this.getSearchResult, 50) @@ -270,7 +271,7 @@ export default class extends Vue { } getPicBeds () { - ipcRenderer.send('getPicBeds') + ipcRenderer.send(GET_PICBEDS) } installPlugin (item: IPicGoPlugin) { diff --git a/src/renderer/pages/Upload.vue b/src/renderer/pages/Upload.vue index 4740146..1fb2140 100644 --- a/src/renderer/pages/Upload.vue +++ b/src/renderer/pages/Upload.vue @@ -65,7 +65,8 @@ import { import { SHOW_INPUT_BOX, SHOW_INPUT_BOX_RESPONSE, - SHOW_UPLOAD_PAGE_MENU + SHOW_UPLOAD_PAGE_MENU, + GET_PICBEDS } from '~/universal/events/constants' import { isUrl @@ -96,8 +97,8 @@ export default class extends Vue { ipcRenderer.on('syncPicBed', () => { this.getDefaultPicBed() }) - ipcRenderer.send('getPicBeds') - ipcRenderer.on('getPicBeds', this.getPicBeds) + ipcRenderer.send(GET_PICBEDS) + ipcRenderer.on(GET_PICBEDS, this.getPicBeds) this.$bus.$on(SHOW_INPUT_BOX_RESPONSE, this.handleInputBoxValue) } @@ -118,7 +119,7 @@ export default class extends Vue { this.$bus.$off(SHOW_INPUT_BOX_RESPONSE) ipcRenderer.removeAllListeners('uploadProgress') ipcRenderer.removeAllListeners('syncPicBed') - ipcRenderer.removeListener('getPicBeds', this.getPicBeds) + ipcRenderer.removeListener(GET_PICBEDS, this.getPicBeds) } onDrop (e: DragEvent) { diff --git a/src/renderer/pages/picbeds/AliYun.vue b/src/renderer/pages/picbeds/AliYun.vue deleted file mode 100644 index 244ce41..0000000 --- a/src/renderer/pages/picbeds/AliYun.vue +++ /dev/null @@ -1,156 +0,0 @@ - - - diff --git a/src/renderer/pages/picbeds/GitHub.vue b/src/renderer/pages/picbeds/GitHub.vue deleted file mode 100644 index f88cffb..0000000 --- a/src/renderer/pages/picbeds/GitHub.vue +++ /dev/null @@ -1,126 +0,0 @@ - - - diff --git a/src/renderer/pages/picbeds/Imgur.vue b/src/renderer/pages/picbeds/Imgur.vue deleted file mode 100644 index 8ab5468..0000000 --- a/src/renderer/pages/picbeds/Imgur.vue +++ /dev/null @@ -1,118 +0,0 @@ - - - diff --git a/src/renderer/pages/picbeds/Qiniu.vue b/src/renderer/pages/picbeds/Qiniu.vue deleted file mode 100644 index ddf54df..0000000 --- a/src/renderer/pages/picbeds/Qiniu.vue +++ /dev/null @@ -1,145 +0,0 @@ - - - diff --git a/src/renderer/pages/picbeds/SMMS.vue b/src/renderer/pages/picbeds/SMMS.vue deleted file mode 100644 index b3e3f65..0000000 --- a/src/renderer/pages/picbeds/SMMS.vue +++ /dev/null @@ -1,98 +0,0 @@ - - - diff --git a/src/renderer/pages/picbeds/TcYun.vue b/src/renderer/pages/picbeds/TcYun.vue deleted file mode 100644 index 7d505d0..0000000 --- a/src/renderer/pages/picbeds/TcYun.vue +++ /dev/null @@ -1,186 +0,0 @@ - - - diff --git a/src/renderer/pages/picbeds/UpYun.vue b/src/renderer/pages/picbeds/UpYun.vue deleted file mode 100644 index da8072c..0000000 --- a/src/renderer/pages/picbeds/UpYun.vue +++ /dev/null @@ -1,136 +0,0 @@ - - - diff --git a/src/renderer/pages/picbeds/Others.vue b/src/renderer/pages/picbeds/index.vue similarity index 97% rename from src/renderer/pages/picbeds/Others.vue rename to src/renderer/pages/picbeds/index.vue index 43d7df1..b8b4dd9 100644 --- a/src/renderer/pages/picbeds/Others.vue +++ b/src/renderer/pages/picbeds/index.vue @@ -3,7 +3,7 @@
- {{ picBedName }}{{ $T('SETTINGS') }} + {{ picBedName }} {{ $T('SETTINGS') }}
import(/* webpackChunkName: "Qiniu" */ '@/pages/picbeds/Qiniu.vue'), - name: 'qiniu' - }, - { - path: 'tcyun', - component: () => import(/* webpackChunkName: "TcYun" */ '@/pages/picbeds/TcYun.vue'), - name: 'tcyun' - }, - { - path: 'upyun', - component: () => import(/* webpackChunkName: "UpYun" */ '@/pages/picbeds/UpYun.vue'), - name: 'upyun' - }, - { - path: 'github', - component: () => import(/* webpackChunkName: "GitHub" */ '@/pages/picbeds/GitHub.vue'), - name: 'github' - }, - { - path: 'smms', - component: () => import(/* webpackChunkName: "SMMS" */ '@/pages/picbeds/SMMS.vue'), - name: 'smms' - }, - { - path: 'aliyun', - component: () => import(/* webpackChunkName: "AliYun" */ '@/pages/picbeds/AliYun.vue'), - name: 'aliyun' - }, - { - path: 'imgur', - component: () => import(/* webpackChunkName: "Imgur" */ '@/pages/picbeds/Imgur.vue'), - name: 'imgur' - }, - { - path: 'others/:type', - component: () => import(/* webpackChunkName: "Other" */ '@/pages/picbeds/Others.vue'), - name: 'others' + path: 'picbeds/:type', + component: () => import(/* webpackChunkName: "Other" */ '@/pages/picbeds/index.vue'), + name: 'picbeds' }, { path: 'gallery', diff --git a/src/universal/events/constants.ts b/src/universal/events/constants.ts index a32ce81..7cb4a2b 100644 --- a/src/universal/events/constants.ts +++ b/src/universal/events/constants.ts @@ -34,6 +34,7 @@ export const SHOW_MAIN_PAGE_DONATION = 'SHOW_MAIN_PAGE_DONATION' export const FORCE_UPDATE = 'FORCE_UPDATE' export const OPEN_WINDOW = 'OPEN_WINDOW' export const DEFAULT_LOGO = 'DEFAULT_LOGO' +export const GET_PICBEDS = 'GET_PICBEDS' // i18n export const GET_CURRENT_LANGUAGE = 'GET_CURRENT_LANGUAGE' export const GET_LANGUAGE_LIST = 'GET_LANGUAGE_LIST' diff --git a/src/universal/i18n/index.ts b/src/universal/i18n/index.ts new file mode 100644 index 0000000..1f6883c --- /dev/null +++ b/src/universal/i18n/index.ts @@ -0,0 +1,7 @@ +export const builtinI18nList: II18nItem[] = [{ + label: '简体中文', + value: 'zh-CN' +}, { + label: 'English', + value: 'en' +}] diff --git a/yarn.lock b/yarn.lock index f8a61e8..bb42f51 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1346,10 +1346,10 @@ chalk "4.1.2" tslib "^2.3.1" -"@picgo/store@2.0.1": - version "2.0.1" - resolved "https://registry.npmmirror.com/@picgo/store/-/store-2.0.1.tgz#9dce62a6e61e5539c06d261628c1c6c29b8e07eb" - integrity sha512-DLv1/EpSWNec8AAFxVCHSFfArotuU4WdUs3KZePtDK7nwKYIqQMnfcCYOUadoAZn3mn1hS1byv7i26qyIPcKaw== +"@picgo/store@^2.0.2": + version "2.0.2" + resolved "https://registry.npmmirror.com/@picgo/store/-/store-2.0.2.tgz#0b5050f5e8cef7043cf5463fa81ef3c3a19fffc7" + integrity sha512-/nZr6zeLNtlTG+g8iUd5xy5Vtl7iu7SHI3aY9a/+AIlBSs7Io/06MrxGyoAHSWVg9BsB80kJyrNeGyOWiOO5jw== dependencies: "@commonify/lowdb" "^3.0.0" "@commonify/steno" "^2.1.0" @@ -1362,17 +1362,17 @@ lodash-id "^0.14.0" write-file-atomic "^4.0.1" -"@picgo/store@^2.0.2": - version "2.0.2" - resolved "https://registry.npmmirror.com/@picgo/store/-/store-2.0.2.tgz#0b5050f5e8cef7043cf5463fa81ef3c3a19fffc7" - integrity sha512-/nZr6zeLNtlTG+g8iUd5xy5Vtl7iu7SHI3aY9a/+AIlBSs7Io/06MrxGyoAHSWVg9BsB80kJyrNeGyOWiOO5jw== +"@picgo/store@^2.0.4": + version "2.0.4" + resolved "https://registry.npmjs.org/@picgo/store/-/store-2.0.4.tgz#6360ccf7dfaa90f8db6ee5115f96f5e8bf094113" + integrity sha512-QWBF/vxLkCOCwFmjPPwPW8ZJdcko+kFY4dBSJYi8spsKp/7FmKCHmSWIkOpkdH/ww0Gh7UbtSBveKgm5u4t42w== dependencies: "@commonify/lowdb" "^3.0.0" "@commonify/steno" "^2.1.0" "@types/bson" "^4.0.1" "@types/graceful-fs" "^4.1.3" "@types/lodash" "^4.14.182" - comment-json "^4.1.0" + comment-json "^4.2.3" fflate "^0.7.3" lodash "^4.17.21" lodash-id "^0.14.0" @@ -3866,6 +3866,17 @@ comment-json@^4.1.0: has-own-prop "^2.0.0" repeat-string "^1.6.1" +comment-json@^4.2.3: + version "4.2.3" + resolved "https://registry.npmjs.org/comment-json/-/comment-json-4.2.3.tgz#50b487ebbf43abe44431f575ebda07d30d015365" + integrity sha512-SsxdiOf064DWoZLH799Ata6u7iV658A11PlWtZATDlXPpKGJnbJZ5Z24ybixAi+LUUqJ/GKowAejtC5GFUG7Tw== + dependencies: + array-timsort "^1.0.3" + core-util-is "^1.0.3" + esprima "^4.0.1" + has-own-prop "^2.0.0" + repeat-string "^1.6.1" + commitizen@^4.0.3, commitizen@^4.2.3: version "4.2.4" resolved "https://registry.npmjs.org/commitizen/-/commitizen-4.2.4.tgz#a3e5b36bd7575f6bf6e7aa19dbbf06b0d8f37165" @@ -4261,7 +4272,7 @@ core-util-is@1.0.2: resolved "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= -core-util-is@^1.0.2, core-util-is@~1.0.0: +core-util-is@^1.0.2, core-util-is@^1.0.3, core-util-is@~1.0.0: version "1.0.3" resolved "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz#a6042d3634c2b27e9328f837b965fac83808db85" integrity sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ== @@ -9895,10 +9906,10 @@ performance-now@^2.1.0: resolved "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= -picgo@^1.5.0-alpha.5: - version "1.5.0-alpha.5" - resolved "https://registry.npmmirror.com/picgo/-/picgo-1.5.0-alpha.5.tgz#3258efa1aecdb9392405dc77fdb3273d3703b003" - integrity sha512-62F1GoctoHG4lIak91TNls5cw/DeHRt7PGh3SU/vKMacjSaKuIA9eU6FOyXSKtXqBgZFIpEQC6JYEvlTf/aMQA== +picgo@^1.5.0-alpha.7: + version "1.5.0-alpha.7" + resolved "https://registry.npmjs.org/picgo/-/picgo-1.5.0-alpha.7.tgz#e334a5d736a54c45432a88288e964e71b36912db" + integrity sha512-MN0aBTF8u2fbdOaR8acTek9nEaCcWd3M1KGdu4Xp3aYqMakpF/meWItNYJYr8wwc4eCcQ7vC7aJ0ZIXsua6uVA== dependencies: "@picgo/i18n" "^1.0.0" "@picgo/store" "^2.0.2" @@ -9914,6 +9925,7 @@ picgo@^1.5.0-alpha.5: image-size "^0.8.3" inquirer "^6.0.0" is-wsl "^2.2.0" + js-yaml "^4.1.0" lodash "^4.17.21" md5 "^2.2.1" mime-types "2.1.33"