Skip to content

Commit

Permalink
chore: bump deps (#286)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mister-Hope authored Nov 6, 2024
1 parent cb19379 commit 3e069d0
Show file tree
Hide file tree
Showing 29 changed files with 1,699 additions and 1,682 deletions.
4 changes: 2 additions & 2 deletions docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@
"@vuepress/theme-default": "workspace:*",
"katex": "0.16.11",
"mathjax-full": "3.2.2",
"sass-embedded": "1.80.4",
"sass-loader": "^16.0.2",
"sass-embedded": "1.80.6",
"sass-loader": "^16.0.3",
"vue": "^3.5.12",
"vuepress": "2.0.0-rc.18"
}
Expand Down
6 changes: 3 additions & 3 deletions e2e/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@
"@vuepress/plugin-theme-data": "workspace:*",
"@vuepress/plugin-watermark": "workspace:*",
"@vuepress/theme-default": "workspace:*",
"sass-embedded": "1.80.4",
"sass-loader": "^16.0.2",
"sass-embedded": "1.80.6",
"sass-loader": "^16.0.3",
"vue": "^3.5.12",
"vuepress": "2.0.0-rc.18"
},
"devDependencies": {
"@playwright/test": "^1.48.1"
"@playwright/test": "^1.48.2"
}
}
16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,13 @@
"@lerna-lite/publish": "^3.10.0",
"@rollup/plugin-commonjs": "^28.0.1",
"@rollup/plugin-node-resolve": "^15.3.0",
"@types/node": "^22.7.9",
"@types/node": "^22.9.0",
"@types/webpack-env": "^1.18.5",
"@vitest/coverage-istanbul": "^2.1.3",
"@vitest/coverage-istanbul": "^2.1.4",
"conventional-changelog-cli": "^5.0.0",
"cpx2": "^8.0.0",
"cross-env": "^7.0.3",
"eslint": "^9.13.0",
"eslint": "^9.14.0",
"eslint-config-vuepress": "^5.2.2",
"http-server": "^14.1.1",
"husky": "^9.1.6",
Expand All @@ -52,23 +52,23 @@
"prettier": "^3.3.3",
"prettier-config-vuepress": "^5.0.0",
"rimraf": "^6.0.1",
"rollup": "^4.24.0",
"rollup": "^4.24.4",
"rollup-plugin-dts": "^6.1.1",
"rollup-plugin-esbuild": "^6.1.1",
"rollup-plugin-resolve-shebang": "^1.0.1",
"sass-embedded": "^1.80.4",
"sass-embedded": "^1.80.6",
"sort-package-json": "^2.10.1",
"stylelint": "^16.10.0",
"stylelint-config-hope": "^7.0.4",
"stylelint-config-html": "^1.1.0",
"tsconfig-vuepress": "^5.2.1",
"tsx": "^4.19.1",
"tsx": "^4.19.2",
"typescript": "^5.6.3",
"vite": "~5.4.10",
"vitest": "^2.1.3",
"vitest": "^2.1.4",
"vuepress": "2.0.0-rc.18"
},
"packageManager": "[email protected].2",
"packageManager": "[email protected].3",
"engines": {
"node": ">=18.19.0"
}
Expand Down
1 change: 1 addition & 0 deletions plugins/blog/plugin-comment/src/node/getProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ export const getAlias = (
})

export const getProviderPackage = (provider?: string): string | null => {
// eslint-disable-next-line @typescript-eslint/switch-exhaustiveness-check
switch (provider) {
case 'Artalk':
return 'artalk'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"clean": "rimraf --glob ./lib ./*.tsbuildinfo"
},
"dependencies": {
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"vue": "^3.5.12"
},
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion plugins/development/plugin-theme-data/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"copy": "cpx \"src/**/*.d.ts\" lib"
},
"dependencies": {
"@vue/devtools-api": "^7.5.4",
"@vue/devtools-api": "^7.6.3",
"vue": "^3.5.12"
},
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion plugins/features/plugin-back-to-top/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
},
"dependencies": {
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"vue": "^3.5.12"
},
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion plugins/features/plugin-copy-code/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
},
"dependencies": {
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"vue": "^3.5.12"
},
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion plugins/features/plugin-copyright/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
},
"dependencies": {
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"vue": "^3.5.12"
},
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion plugins/features/plugin-notice/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
},
"dependencies": {
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"vue": "^3.5.12"
},
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion plugins/features/plugin-photo-swipe/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
},
"dependencies": {
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"photoswipe": "^5.4.4",
"vue": "^3.5.12"
},
Expand Down
2 changes: 1 addition & 1 deletion plugins/markdown/plugin-markdown-hint/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
"@mdit/plugin-container": "^0.13.1",
"@types/markdown-it": "^14.1.2",
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0"
"@vueuse/core": "^11.2.0"
},
"peerDependencies": {
"vuepress": "2.0.0-rc.18"
Expand Down
2 changes: 1 addition & 1 deletion plugins/markdown/plugin-markdown-tab/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
"@mdit/plugin-tab": "^0.13.2",
"@types/markdown-it": "^14.1.2",
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"vue": "^3.5.12"
},
"peerDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion plugins/markdown/plugin-revealjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
"@types/markdown-it": "^14.1.2",
"@types/reveal.js": "^5.0.4",
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"reveal.js": "^5.1.0",
"vue": "^3.5.12"
},
Expand Down
6 changes: 3 additions & 3 deletions plugins/markdown/plugin-shiki/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@
"style": "sass src:lib --embed-sources --style=compressed"
},
"dependencies": {
"@shikijs/transformers": "^1.22.1",
"@shikijs/transformers": "^1.22.2",
"@vuepress/helper": "workspace:*",
"@vuepress/highlighter-helper": "workspace:*",
"nanoid": "^5.0.7",
"shiki": "^1.22.1"
"nanoid": "^5.0.8",
"shiki": "^1.22.2"
},
"peerDependencies": {
"vuepress": "2.0.0-rc.18"
Expand Down
6 changes: 3 additions & 3 deletions plugins/pwa/plugin-pwa/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@
},
"dependencies": {
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"mitt": "^3.0.1",
"register-service-worker": "^1.7.2",
"vue": "^3.5.12",
"workbox-build": "^7.1.1"
"workbox-build": "^7.3.0"
},
"peerDependencies": {
"vuepress": "2.0.0-rc.18"
Expand All @@ -56,6 +56,6 @@
"access": "public"
},
"devDependencies": {
"rollup": "^4.24.0"
"rollup": "^4.24.4"
}
}
10 changes: 6 additions & 4 deletions plugins/search/plugin-docsearch/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,17 +40,19 @@
"copy": "cpx \"src/**/*.css\" lib"
},
"dependencies": {
"@docsearch/css": "^3.6.2",
"@docsearch/js": "^3.6.2",
"@docsearch/react": "^3.6.2",
"@docsearch/css": "^3.7.0",
"@docsearch/js": "^3.7.0",
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"ts-debounce": "^4.0.0",
"vue": "^3.5.12"
},
"peerDependencies": {
"vuepress": "2.0.0-rc.18"
},
"devDependencies": {
"algoliasearch": "5.12.0"
},
"publishConfig": {
"access": "public"
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import type { SearchParamsObject } from 'algoliasearch'
import type { PropType } from 'vue'
import { computed, defineComponent, h, onMounted, ref, watch } from 'vue'
import { usePageLang, useRouteLocale } from 'vuepress/client'
Expand Down Expand Up @@ -53,15 +54,19 @@ export const DocSearch = defineComponent({
*/
const initialize = async (): Promise<void> => {
const { default: docsearch } = await import('@docsearch/js')

const { indexName, searchParameters } = options.value

docsearch({
...docsearchShim,
...options.value,
container: `#${props.containerId}`,
searchParameters: {
...options.value.searchParameters,
...searchParameters,
indexName,
facetFilters: getFacetFilters(
lang.value,
options.value.searchParameters?.facetFilters,
(searchParameters as SearchParamsObject | undefined)?.facetFilters,
),
},
})
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type { DocSearchProps } from '@docsearch/react'
import { debounce } from 'ts-debounce'
import { useRouter } from 'vuepress/client'
import { removeLeadingSlash, resolveRoutePathFromUrl } from 'vuepress/shared'
import type { DocSearchProps } from '../../shared/index.js'

declare const __DOCSEARCH_INDEX_BASE__: string

Expand Down Expand Up @@ -65,10 +65,11 @@ export const useDocSearchShim = (): Partial<DocSearchProps> => {
// add search debounce
transformSearchClient: (searchClient) => {
const searchWithDebounce = debounce(searchClient.search, 500)

return {
...searchClient,
search: async (...args) => searchWithDebounce(...args),
}
},
} as Partial<DocSearchProps>
}
}
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
import type { DocSearchProps } from '@docsearch/react'
import { deepAssign, isFunction } from '@vuepress/helper/client'
import type { App, ComputedRef, InjectionKey, MaybeRefOrGetter, Ref } from 'vue'
import { computed, inject, isRef, ref, watch } from 'vue'
import { useRouteLocale } from 'vuepress/client'
import type { DocSearchOptions } from '../../shared/index.js'
import type { DocSearchOptions, DocSearchProps } from '../../shared/index.js'

declare const __VUEPRESS_DEV__: boolean
declare const __DOCSEARCH_OPTIONS__: DocSearchOptions

const docSearchOptions: Partial<DocSearchProps> = __DOCSEARCH_OPTIONS__

const docsearch: Ref<DocSearchProps> = ref(docSearchOptions as DocSearchProps)
const docsearch = ref(docSearchOptions as DocSearchProps)

const docsearchSymbol: InjectionKey<
Ref<
Expand Down Expand Up @@ -41,6 +40,7 @@ export const defineDocSearchConfig = (
docsearch.value = deepAssign({}, docSearchOptions, value)
})
} else {
// @ts-expect-error: Types loop back
docsearch.value = deepAssign({}, docSearchOptions, options)
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
import type { DocSearchOptions } from '../../shared/index.js'

type FacetFilters =
Required<DocSearchOptions>['searchParameters']['facetFilters']
import type { FacetFilters } from 'algoliasearch'

/**
* Get facet filters for current lang
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
import type { DocSearchTranslations } from '@docsearch/react'
import type { DocSearchProps } from '../../shared/index.js'

type DocSearchTranslation = Exclude<DocSearchProps['translations'], undefined>

/**
* Get the search button template
Expand All @@ -10,5 +12,5 @@ import type { DocSearchTranslations } from '@docsearch/react'
export const getSearchButtonTemplate = ({
buttonText = 'Search',
buttonAriaLabel = buttonText,
}: DocSearchTranslations['button'] = {}): string =>
}: DocSearchTranslation['button'] = {}): string =>
`<button type="button" class="DocSearch DocSearch-Button" aria-label="${buttonAriaLabel}"><span class="DocSearch-Button-Container"><svg width="20" height="20" class="DocSearch-Search-Icon" viewBox="0 0 20 20"><path d="M14.386 14.386l4.0877 4.0877-4.0877-4.0877c-2.9418 2.9419-7.7115 2.9419-10.6533 0-2.9419-2.9418-2.9419-7.7115 0-10.6533 2.9418-2.9419 7.7115-2.9419 10.6533 0 2.9419 2.9418 2.9419 7.7115 0 10.6533z" stroke="currentColor" fill="none" fill-rule="evenodd" stroke-linecap="round" stroke-linejoin="round"></path></svg><span class="DocSearch-Button-Placeholder">${buttonText}</span></span><span class="DocSearch-Button-Keys"><kbd class="DocSearch-Button-Key"><svg width="15" height="15" class="DocSearch-Control-Key-Icon"><path d="M4.505 4.496h2M5.505 5.496v5M8.216 4.496l.055 5.993M10 7.5c.333.333.5.667.5 1v2M12.326 4.5v5.996M8.384 4.496c1.674 0 2.116 0 2.116 1.5s-.442 1.5-2.116 1.5M3.205 9.303c-.09.448-.277 1.21-1.241 1.203C1 10.5.5 9.513.5 8V7c0-1.57.5-2.5 1.464-2.494.964.006 1.134.598 1.24 1.342M12.553 10.5h1.953" stroke-width="1.2" stroke="currentColor" fill="none" stroke-linecap="square"></path></svg></kbd><kbd class="DocSearch-Button-Key">K</kbd></span></button>`
8 changes: 7 additions & 1 deletion plugins/search/plugin-docsearch/src/shared/types.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
import type { DocSearchProps } from '@docsearch/react'
import type docsearch from '@docsearch/js'
import type { LocaleConfig } from 'vuepress/shared'

export type DocSearchProps = typeof docsearch extends (
options: infer T,
) => unknown
? T
: never

export type DocSearchLocaleOptions = Partial<
Pick<
DocSearchProps,
Expand Down
2 changes: 1 addition & 1 deletion plugins/tools/plugin-redirect/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
},
"dependencies": {
"@vuepress/helper": "workspace:*",
"@vueuse/core": "^11.1.0",
"@vueuse/core": "^11.2.0",
"cac": "^6.7.14",
"vue": "^3.5.12"
},
Expand Down
Loading

0 comments on commit 3e069d0

Please sign in to comment.