@rspress/plugin-medium-zoom 2.0.0-beta.1 → 2.0.0-beta.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -2,4 +2,4 @@
2
2
 
3
3
  > Medium zoom plugin for rspress
4
4
 
5
- [Documentation](https://rspress.dev/plugin/official-plugins/medium-zoom)
5
+ [Documentation](https://rspress.rs/plugin/official-plugins/medium-zoom)
package/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  import type { PluggableList } from 'unified';
2
+ import type { RehypeShikiOptions } from '@shikijs/rehype';
2
3
  import type { RsbuildConfig } from '@rsbuild/core';
3
4
  import type { RsbuildPlugin } from '@rsbuild/core';
4
5
  import type { ZoomOptions } from 'medium-zoom';
@@ -127,7 +128,7 @@ declare interface DefaultThemeConfig {
127
128
  * Whether to redirect to the closest locale when the user visits the site
128
129
  * @default 'auto'
129
130
  */
130
- localeRedirect?: 'auto' | 'never';
131
+ localeRedirect?: 'auto' | 'never' | 'only-default-lang';
131
132
  /**
132
133
  * Whether to show the fallback heading title when the heading title is not presented but `frontmatter.title` exists
133
134
  * @default true
@@ -296,13 +297,9 @@ declare interface MarkdownOptions {
296
297
  */
297
298
  globalComponents?: string[];
298
299
  /**
299
- * Code highlighter, default is prism for performance reason
300
+ * @type import('@shikijs/rehype').RehypeShikiOptions
300
301
  */
301
- codeHighlighter?: 'prism' | 'shiki';
302
- /**
303
- * Register prism languages
304
- */
305
- highlightLanguages?: (string | [string, string])[];
302
+ shiki?: Partial<PluginShikiOptions>;
306
303
  }
307
304
 
308
305
  declare type Nav = NavItem[] | {
@@ -368,6 +365,8 @@ declare type PageType = 'home' | 'doc' | 'custom' | '404' | 'blank';
368
365
  */
369
366
  export declare function pluginMediumZoom(options?: Options): RspressPlugin;
370
367
 
368
+ declare type PluginShikiOptions = RehypeShikiOptions;
369
+
371
370
  declare type RemoteSearchIndexInfo = string | {
372
371
  value: string;
373
372
  label: string;
@@ -576,7 +575,7 @@ declare interface UserConfig<ThemeConfig = DefaultThemeConfig> {
576
575
  /**
577
576
  * Path to html icon file.
578
577
  */
579
- icon?: string;
578
+ icon?: string | URL;
580
579
  /**
581
580
  * Default language of the site.
582
581
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rspress/plugin-medium-zoom",
3
- "version": "2.0.0-beta.1",
3
+ "version": "2.0.0-beta.10",
4
4
  "description": "A plugin for rspress to zoom images in docs.",
5
5
  "bugs": "https://github.com/web-infra-dev/rspress/issues",
6
6
  "repository": {
@@ -32,19 +32,19 @@
32
32
  "medium-zoom": "1.1.0"
33
33
  },
34
34
  "devDependencies": {
35
- "@microsoft/api-extractor": "^7.52.4",
36
- "@rslib/core": "0.6.5",
37
- "@types/node": "^18.11.17",
38
- "@types/react": "^18.3.20",
39
- "@types/react-dom": "^18.3.6",
35
+ "@microsoft/api-extractor": "^7.52.8",
36
+ "@rslib/core": "0.8.0",
37
+ "@types/node": "^22.8.1",
38
+ "@types/react": "^18.3.22",
39
+ "@types/react-dom": "^18.3.7",
40
40
  "react": "^19.1.0",
41
- "rsbuild-plugin-publint": "^0.3.0",
41
+ "rsbuild-plugin-publint": "^0.3.2",
42
42
  "typescript": "^5.8.2",
43
- "@rspress/shared": "2.0.0-beta.1",
44
- "@rspress/config": "1.0.0"
43
+ "@rspress/config": "1.0.0",
44
+ "@rspress/shared": "2.0.0-beta.10"
45
45
  },
46
46
  "peerDependencies": {
47
- "@rspress/runtime": "^2.0.0-beta.1"
47
+ "@rspress/runtime": "^2.0.0-beta.10"
48
48
  },
49
49
  "engines": {
50
50
  "node": ">=18.0.0"