@rspress/core 2.0.17 → 2.0.18

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.
Files changed (94) hide show
  1. package/dist/0~execa.js +1 -1
  2. package/dist/{7448.js → 3553.js} +2 -2
  3. package/dist/{8629.js → 5871.js} +3 -3
  4. package/dist/cli/index.js +2 -2
  5. package/dist/config/loadConfigFile.js +1 -1
  6. package/dist/eject-theme/components/DocContent/docComponents/title.tsx +1 -1
  7. package/dist/eject-theme/components/HomeFeature/index.scss +1 -0
  8. package/dist/eject-theme/components/HomeFeature/index.tsx +1 -1
  9. package/dist/eject-theme/components/HoverGroup/index.scss +9 -0
  10. package/dist/eject-theme/components/Llms/LlmsHiddenHint.test.tsx +23 -0
  11. package/dist/eject-theme/components/Llms/LlmsHiddenHint.tsx +15 -0
  12. package/dist/eject-theme/components/Llms/LlmsOpenRow.tsx +51 -64
  13. package/dist/eject-theme/components/Llms/LlmsViewOptions.tsx +65 -51
  14. package/dist/eject-theme/components/Llms/index.tsx +6 -1
  15. package/dist/eject-theme/components/Outline/index.tsx +1 -1
  16. package/dist/index.d.ts +1 -1
  17. package/dist/node/PluginDriver.js +1 -1
  18. package/dist/node/auto-nav-sidebar/index.js +1 -1
  19. package/dist/node/auto-nav-sidebar/locales.js +1 -1
  20. package/dist/node/auto-nav-sidebar/normalize.js +1 -1
  21. package/dist/node/auto-nav-sidebar/utils.js +1 -1
  22. package/dist/node/auto-nav-sidebar/walk.js +1 -1
  23. package/dist/node/constants.js +1 -1
  24. package/dist/node/eject.js +1 -1
  25. package/dist/node/initRsbuild.js +16 -5
  26. package/dist/node/llms.d.ts +3 -0
  27. package/dist/node/llms.js +8 -0
  28. package/dist/node/route/RoutePage.js +5 -3
  29. package/dist/node/route/RouteService.js +8 -3
  30. package/dist/node/route/extractPageData.js +1 -1
  31. package/dist/node/route/normalizeRoutePath.js +1 -1
  32. package/dist/node/route/routeChunkAssets.d.ts +15 -0
  33. package/dist/node/route/routeChunkAssets.js +56 -0
  34. package/dist/node/runtimeModule/i18n.js +1 -1
  35. package/dist/node/runtimeModule/pageData/createPageData.js +1 -1
  36. package/dist/node/runtimeModule/pageData/rsbuildPlugin.js +1 -1
  37. package/dist/node/runtimeModule/searchHooks.js +1 -1
  38. package/dist/node/runtimeModule/siteData/createSiteData.js +1 -1
  39. package/dist/node/runtimeModule/siteData/normalizeThemeConfig.js +1 -1
  40. package/dist/node/runtimeModule/siteData/rsbuildPlugin.js +1 -1
  41. package/dist/node/serve.js +1 -1
  42. package/dist/node/ssg/alternateLinks.d.ts +7 -0
  43. package/dist/node/ssg/alternateLinks.js +40 -0
  44. package/dist/node/ssg/htmlFile.js +1 -1
  45. package/dist/node/ssg/renderHtmlTemplate.d.ts +3 -1
  46. package/dist/node/ssg/renderHtmlTemplate.js +25 -3
  47. package/dist/node/ssg/renderPage.d.ts +3 -1
  48. package/dist/node/ssg/renderPage.js +3 -3
  49. package/dist/node/ssg/renderPageWorker.js +4 -4
  50. package/dist/node/ssg/renderPages.d.ts +3 -2
  51. package/dist/node/ssg/renderPages.js +15 -10
  52. package/dist/node/ssg/rsbuildPluginCSR.d.ts +3 -1
  53. package/dist/node/ssg/rsbuildPluginCSR.js +2 -2
  54. package/dist/node/ssg/rsbuildPluginSSG.d.ts +3 -1
  55. package/dist/node/ssg/rsbuildPluginSSG.js +3 -3
  56. package/dist/node/ssg/ssgEnv.js +1 -1
  57. package/dist/node/ssg-md/llms/emitLlmsTxt.js +2 -2
  58. package/dist/node/ssg-md/llms/llmsTxt.d.ts +2 -2
  59. package/dist/node/ssg-md/llms/llmsTxt.js +49 -35
  60. package/dist/node/ssg-md/renderPage.js +1 -1
  61. package/dist/node/ssg-md/renderPages.js +2 -2
  62. package/dist/node/ssg-md/rsbuildPluginSSGMD.js +1 -1
  63. package/dist/node/utils/checkLanguageParity.js +1 -1
  64. package/dist/node/utils/createHash.d.ts +1 -1
  65. package/dist/node/utils/createHash.js +3 -3
  66. package/dist/node/utils/flattenMdxContent.js +1 -1
  67. package/dist/node/utils/getPageKey.js +1 -1
  68. package/dist/node/utils/reactAlias.js +1 -1
  69. package/dist/runtime/App.js +2 -0
  70. package/dist/runtime/index.d.ts +1 -1
  71. package/dist/runtime/index.js +1 -1
  72. package/dist/runtime/utils.d.ts +2 -1
  73. package/dist/runtime/utils.js +5 -2
  74. package/dist/theme/assets/anthropic.js +15 -0
  75. package/dist/theme/assets/open-in-chat.js +19 -0
  76. package/dist/theme/assets/openai.js +15 -0
  77. package/dist/theme/components/DocContent/docComponents/title.js +1 -1
  78. package/dist/theme/components/HomeFeature/index.css +1 -0
  79. package/dist/theme/components/HomeFeature/index.js +32 -34
  80. package/dist/theme/components/HoverGroup/index.css +7 -0
  81. package/dist/theme/components/Llms/LlmsHiddenHint.d.ts +1 -0
  82. package/dist/theme/components/Llms/LlmsHiddenHint.js +18 -0
  83. package/dist/theme/components/Llms/LlmsOpenRow.js +31 -57
  84. package/dist/theme/components/Llms/LlmsViewOptions.d.ts +6 -4
  85. package/dist/theme/components/Llms/LlmsViewOptions.js +28 -45
  86. package/dist/theme/components/Llms/index.d.ts +2 -1
  87. package/dist/theme/components/Llms/index.js +1 -0
  88. package/dist/theme/components/Outline/index.js +1 -1
  89. package/dist/theme/icons.d.ts +4 -1
  90. package/dist/theme/icons.js +8 -2
  91. package/dist/theme/index.d.ts +1 -1
  92. package/dist/theme/index.js +1 -1
  93. package/package.json +4 -4
  94. /package/dist/{8629.js.LICENSE.txt → 5871.js.LICENSE.txt} +0 -0
@@ -1,7 +1,7 @@
1
1
  import type React from 'react';
2
2
  import './index.scss';
3
3
  import './LlmsViewOptions.scss';
4
- type Option = {
4
+ export type LlmsViewOptionsItem = {
5
5
  title: string;
6
6
  icon?: React.ReactNode;
7
7
  onClick?: () => void;
@@ -16,8 +16,11 @@ export interface LlmsViewOptionsProps extends React.ButtonHTMLAttributes<HTMLBut
16
16
  * @default ['markdownLink', 'chatgpt', 'claude']
17
17
  * - 'chatgpt': Open in ChatGPT
18
18
  * - 'claude': Open in Claude
19
+ *
20
+ * Unlike `themeConfig.llmsUI.viewOptions`, component options can use
21
+ * ReactNode icons and onClick callbacks.
19
22
  */
20
- options?: Option[];
23
+ options?: LlmsViewOptionsItem[];
21
24
  /**
22
25
  * Button text by language, used with `useLang`.
23
26
  * @default en: 'Open', zh: '\u6253\u5f00'
@@ -30,5 +33,4 @@ export interface LlmsViewOptionsProps extends React.ButtonHTMLAttributes<HTMLBut
30
33
  */
31
34
  text?: string;
32
35
  }
33
- export declare function LlmsViewOptions({ options: propsOptions, }: LlmsViewOptionsProps): React.JSX.Element;
34
- export {};
36
+ export declare function LlmsViewOptions({ options: propsOptions, }: LlmsViewOptionsProps): React.JSX.Element | null;
@@ -1,7 +1,7 @@
1
1
  /*! LICENSE: LlmsViewOptions.js.LICENSE.txt */
2
2
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
3
3
  import { useI18n, useSite } from "@rspress/core/runtime";
4
- import { IconDown, IconExternalLink, IconLink, SvgWrapper, copyToClipboard } from "@rspress/core/theme";
4
+ import { IconAnthropic, IconDown, IconExternalLink, IconLink, IconOpenAI, SvgWrapper, copyToClipboard } from "@rspress/core/theme";
5
5
  import { useEffect, useMemo, useRef, useState } from "react";
6
6
  import "./index.css";
7
7
  import "./LlmsViewOptions.css";
@@ -18,7 +18,8 @@ import { useMdUrl } from "./useMdUrl.js";
18
18
  function LlmsViewOptions({ options: propsOptions }) {
19
19
  const { site } = useSite();
20
20
  const llmsUI = site?.themeConfig?.llmsUI;
21
- const options = ('object' == typeof llmsUI ? llmsUI?.viewOptions : propsOptions) ?? DEFAULT_OPTIONS;
21
+ const configuredOptions = 'object' == typeof llmsUI ? llmsUI?.viewOptions : propsOptions;
22
+ const options = false === configuredOptions ? [] : configuredOptions ?? DEFAULT_OPTIONS;
22
23
  const [isOpen, setIsOpen] = useState(false);
23
24
  const dropdownRef = useRef(null);
24
25
  useEffect(()=>{
@@ -56,22 +57,8 @@ function LlmsViewOptions({ options: propsOptions }) {
56
57
  hints: 'search',
57
58
  q
58
59
  })}`,
59
- icon: /*#__PURE__*/ jsxs("svg", {
60
- role: "img",
61
- viewBox: "0 0 24 24",
62
- fill: "currentColor",
63
- xmlns: "http://www.w3.org/2000/svg",
64
- children: [
65
- /*#__PURE__*/ jsx("title", {
66
- children: "OpenAI"
67
- }),
68
- /*#__PURE__*/ jsx("path", {
69
- d: "M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364 15.1192 7.2a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.407-.667zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z"
70
- }),
71
- /*#__PURE__*/ jsx("path", {
72
- d: "M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364 15.1192 7.2a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.407-.667zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z"
73
- })
74
- ]
60
+ icon: /*#__PURE__*/ jsx(SvgWrapper, {
61
+ icon: IconOpenAI
75
62
  })
76
63
  },
77
64
  claude: {
@@ -81,19 +68,8 @@ function LlmsViewOptions({ options: propsOptions }) {
81
68
  href: `https://claude.ai/new?${new URLSearchParams({
82
69
  q
83
70
  })}`,
84
- icon: /*#__PURE__*/ jsxs("svg", {
85
- fill: "currentColor",
86
- role: "img",
87
- viewBox: "0 0 24 24",
88
- xmlns: "http://www.w3.org/2000/svg",
89
- children: [
90
- /*#__PURE__*/ jsx("title", {
91
- children: "Anthropic"
92
- }),
93
- /*#__PURE__*/ jsx("path", {
94
- d: "M17.3041 3.541h-3.6718l6.696 16.918H24Zm-10.6082 0L0 20.459h3.7442l1.3693-3.5527h7.0052l1.3693 3.5528h3.7442L10.5363 3.5409Zm-.3712 10.2232 2.2914-5.9456 2.2914 5.9456Z"
95
- })
96
- ]
71
+ icon: /*#__PURE__*/ jsx(SvgWrapper, {
72
+ icon: IconAnthropic
97
73
  })
98
74
  }
99
75
  };
@@ -101,6 +77,17 @@ function LlmsViewOptions({ options: propsOptions }) {
101
77
  pathname,
102
78
  t
103
79
  ]);
80
+ const renderableItems = useMemo(()=>options.map((option)=>{
81
+ if ('markdownLink' === option) return items.markdownLink;
82
+ if ('chatgpt' === option) return items.chatgpt;
83
+ if ('claude' === option) return items.claude;
84
+ if ('object' == typeof option && 'title' in option && 'string' == typeof option.title && ('href' in option || 'onClick' in option)) return option;
85
+ return null;
86
+ }).filter((item)=>null !== item), [
87
+ items,
88
+ options
89
+ ]);
90
+ if (0 === renderableItems.length) return null;
104
91
  return /*#__PURE__*/ jsx(Fragment, {
105
92
  children: /*#__PURE__*/ jsxs("button", {
106
93
  ref: dropdownRef,
@@ -113,23 +100,19 @@ function LlmsViewOptions({ options: propsOptions }) {
113
100
  }),
114
101
  isOpen && /*#__PURE__*/ jsx("div", {
115
102
  className: "rp-llms-view-options__menu",
116
- children: options.map((item)=>{
117
- let displayItem = item;
118
- if ('markdownLink' === item) displayItem = items.markdownLink;
119
- else if ('chatgpt' === item) displayItem = items.chatgpt;
120
- else if ('claude' === item) displayItem = items.claude;
121
- if (displayItem.href) return /*#__PURE__*/ jsxs("a", {
103
+ children: renderableItems.map((item)=>{
104
+ if (item.href) return /*#__PURE__*/ jsxs("a", {
122
105
  className: "rp-llms-view-options__menu-item",
123
- href: displayItem.href,
106
+ href: item.href,
124
107
  target: "_blank",
125
108
  rel: "noopener noreferrer",
126
109
  children: [
127
110
  /*#__PURE__*/ jsx("span", {
128
111
  className: "rp-llms-view-options__item-icon",
129
- children: displayItem.icon
112
+ children: item.icon
130
113
  }),
131
114
  /*#__PURE__*/ jsx("span", {
132
- children: displayItem.title
115
+ children: item.title
133
116
  }),
134
117
  /*#__PURE__*/ jsx("span", {
135
118
  className: "rp-llms-view-options__external-icon",
@@ -138,20 +121,20 @@ function LlmsViewOptions({ options: propsOptions }) {
138
121
  })
139
122
  })
140
123
  ]
141
- }, displayItem.title);
124
+ }, item.title);
142
125
  return /*#__PURE__*/ jsxs("div", {
143
126
  className: "rp-llms-view-options__menu-item",
144
- onClick: displayItem.onClick,
127
+ onClick: item.onClick,
145
128
  children: [
146
129
  /*#__PURE__*/ jsx("span", {
147
130
  className: "rp-llms-view-options__item-icon",
148
- children: displayItem.icon
131
+ children: item.icon
149
132
  }),
150
133
  /*#__PURE__*/ jsx("span", {
151
- children: displayItem.title
134
+ children: item.title
152
135
  })
153
136
  ]
154
- }, displayItem.title);
137
+ }, item.title);
155
138
  })
156
139
  })
157
140
  ]
@@ -1,4 +1,5 @@
1
1
  export { LlmsContainer, type LlmsContainerProps } from './LlmsContainer.js';
2
2
  export { LlmsCopyButton, type LlmsCopyButtonProps } from './LlmsCopyButton.js';
3
- export { LlmsViewOptions, type LlmsViewOptionsProps } from './LlmsViewOptions.js';
3
+ export { LlmsHiddenHint } from './LlmsHiddenHint.js';
4
+ export { LlmsViewOptions, type LlmsViewOptionsItem, type LlmsViewOptionsProps, } from './LlmsViewOptions.js';
4
5
  export { useMdUrl } from './useMdUrl.js';
@@ -1,4 +1,5 @@
1
1
  export { LlmsContainer } from "./LlmsContainer.js";
2
2
  export { LlmsCopyButton } from "./LlmsCopyButton.js";
3
+ export { LlmsHiddenHint } from "./LlmsHiddenHint.js";
3
4
  export { LlmsViewOptions } from "./LlmsViewOptions.js";
4
5
  export { useMdUrl } from "./useMdUrl.js";
@@ -33,7 +33,7 @@ function Outline() {
33
33
  /*#__PURE__*/ jsx(EditLink, {
34
34
  isOutline: true
35
35
  }),
36
- process.env.ENABLE_LLMS_UI && 'outline' === placement && /*#__PURE__*/ jsxs(Fragment, {
36
+ import.meta.env.ENABLE_LLMS_UI && 'outline' === placement && /*#__PURE__*/ jsxs(Fragment, {
37
37
  children: [
38
38
  /*#__PURE__*/ jsx(LlmsCopyRow, {}),
39
39
  /*#__PURE__*/ jsx(LlmsOpenRow, {})
@@ -1,8 +1,11 @@
1
1
  type Icon = React.FC<React.SVGProps<SVGSVGElement>> | string;
2
2
  export declare const IconDeprecated: Icon;
3
3
  export declare const IconExperimental: Icon;
4
+ export declare const IconExternalLink: Icon;
5
+ export declare const IconOpenInChat: Icon;
4
6
  export declare const IconArrowDown: Icon;
5
7
  export declare const IconArrowRight: Icon;
8
+ export declare const IconAnthropic: Icon;
6
9
  export declare const IconClose: Icon;
7
10
  export declare const IconCopy: Icon;
8
11
  export declare const IconDown: Icon;
@@ -16,6 +19,7 @@ export declare const IconJump: Icon;
16
19
  export declare const IconLoading: Icon;
17
20
  export declare const IconMenu: Icon;
18
21
  export declare const IconMoon: Icon;
22
+ export declare const IconOpenAI: Icon;
19
23
  export declare const IconScrollToTop: Icon;
20
24
  export declare const IconSearch: Icon;
21
25
  export declare const IconSmallMenu: Icon;
@@ -24,6 +28,5 @@ export declare const IconSun: Icon;
24
28
  export declare const IconTitle: Icon;
25
29
  export declare const IconWrap: Icon;
26
30
  export declare const IconWrapped: Icon;
27
- export declare const IconExternalLink: Icon;
28
31
  export declare const IconLink: Icon;
29
32
  export {};
@@ -1,5 +1,6 @@
1
1
  import arrow_down from "./assets/arrow-down.js";
2
2
  import arrow_right from "./assets/arrow-right.js";
3
+ import anthropic from "./assets/anthropic.js";
3
4
  import assets_close from "./assets/close.js";
4
5
  import copy from "./assets/copy.js";
5
6
  import deprecated from "./assets/deprecated.js";
@@ -8,6 +9,7 @@ import edit from "./assets/edit.js";
8
9
  import empty from "./assets/empty.js";
9
10
  import experimental from "./assets/experimental.js";
10
11
  import external_link from "./assets/external-link.js";
12
+ import open_in_chat from "./assets/open-in-chat.js";
11
13
  import file from "./assets/file.js";
12
14
  import github from "./assets/github.js";
13
15
  import gitlab from "./assets/gitlab.js";
@@ -17,6 +19,7 @@ import assets_link from "./assets/link.js";
17
19
  import loading from "./assets/loading.js";
18
20
  import menu from "./assets/menu.js";
19
21
  import moon from "./assets/moon.js";
22
+ import openai from "./assets/openai.js";
20
23
  import scroll_to_top from "./assets/scroll-to-top.js";
21
24
  import search from "./assets/search.js";
22
25
  import small_menu from "./assets/small-menu.js";
@@ -27,8 +30,11 @@ import wrap from "./assets/wrap.js";
27
30
  import wrapped from "./assets/wrapped.js";
28
31
  const IconDeprecated = deprecated;
29
32
  const IconExperimental = experimental;
33
+ const IconExternalLink = external_link;
34
+ const IconOpenInChat = open_in_chat;
30
35
  const IconArrowDown = arrow_down;
31
36
  const IconArrowRight = arrow_right;
37
+ const IconAnthropic = anthropic;
32
38
  const IconClose = assets_close;
33
39
  const IconCopy = copy;
34
40
  const IconDown = down;
@@ -42,6 +48,7 @@ const IconJump = jump;
42
48
  const IconLoading = loading;
43
49
  const IconMenu = menu;
44
50
  const IconMoon = moon;
51
+ const IconOpenAI = openai;
45
52
  const IconScrollToTop = scroll_to_top;
46
53
  const IconSearch = search;
47
54
  const IconSmallMenu = small_menu;
@@ -50,6 +57,5 @@ const IconSun = sun;
50
57
  const IconTitle = title;
51
58
  const IconWrap = wrap;
52
59
  const IconWrapped = wrapped;
53
- const IconExternalLink = external_link;
54
60
  const IconLink = assets_link;
55
- export { IconArrowDown, IconArrowRight, IconClose, IconCopy, IconDeprecated, IconDown, IconEdit, IconEmpty, IconExperimental, IconExternalLink, IconFile, IconGithub, IconGitlab, IconHeader, IconJump, IconLink, IconLoading, IconMenu, IconMoon, IconScrollToTop, IconSearch, IconSmallMenu, IconSuccess, IconSun, IconTitle, IconWrap, IconWrapped };
61
+ export { IconAnthropic, IconArrowDown, IconArrowRight, IconClose, IconCopy, IconDeprecated, IconDown, IconEdit, IconEmpty, IconExperimental, IconExternalLink, IconFile, IconGithub, IconGitlab, IconHeader, IconJump, IconLink, IconLoading, IconMenu, IconMoon, IconOpenAI, IconOpenInChat, IconScrollToTop, IconSearch, IconSmallMenu, IconSuccess, IconSun, IconTitle, IconWrap, IconWrapped };
@@ -21,7 +21,7 @@ export { useHoverGroup } from './components/HoverGroup/useHoverGroup.js';
21
21
  export { LastUpdated } from './components/LastUpdated/index.js';
22
22
  export { Link, type LinkProps } from './components/Link/index.js';
23
23
  export { useLinkNavigate } from './components/Link/useLinkNavigate.js';
24
- export { LlmsContainer, type LlmsContainerProps, LlmsCopyButton, type LlmsCopyButtonProps, LlmsViewOptions, type LlmsViewOptionsProps, useMdUrl, } from './components/Llms/index.js';
24
+ export { LlmsContainer, type LlmsContainerProps, LlmsCopyButton, type LlmsCopyButtonProps, LlmsHiddenHint, LlmsViewOptions, type LlmsViewOptionsItem, type LlmsViewOptionsProps, useMdUrl, } from './components/Llms/index.js';
25
25
  export { LlmsCopyRow } from './components/Llms/LlmsCopyRow.js';
26
26
  export { LlmsOpenRow } from './components/Llms/LlmsOpenRow.js';
27
27
  export { Nav, type NavProps } from './components/Nav/index.js';
@@ -21,7 +21,7 @@ export { useHoverGroup } from "./components/HoverGroup/useHoverGroup.js";
21
21
  export { LastUpdated } from "./components/LastUpdated/index.js";
22
22
  export { Link } from "./components/Link/index.js";
23
23
  export { useLinkNavigate } from "./components/Link/useLinkNavigate.js";
24
- export { LlmsContainer, LlmsCopyButton, LlmsViewOptions, useMdUrl } from "./components/Llms/index.js";
24
+ export { LlmsContainer, LlmsCopyButton, LlmsHiddenHint, LlmsViewOptions, useMdUrl } from "./components/Llms/index.js";
25
25
  export { LlmsCopyRow } from "./components/Llms/LlmsCopyRow.js";
26
26
  export { LlmsOpenRow } from "./components/Llms/LlmsOpenRow.js";
27
27
  export { Nav } from "./components/Nav/index.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rspress/core",
3
- "version": "2.0.17",
3
+ "version": "2.0.18",
4
4
  "description": "The Rspress Documentation Framework",
5
5
  "bugs": "https://github.com/web-infra-dev/rspress/issues",
6
6
  "repository": {
@@ -95,7 +95,7 @@
95
95
  "unist-util-remove": "^4.0.0",
96
96
  "unist-util-visit": "^5.1.0",
97
97
  "unist-util-visit-children": "^3.0.0",
98
- "@rspress/shared": "2.0.17"
98
+ "@rspress/shared": "2.0.18"
99
99
  },
100
100
  "devDependencies": {
101
101
  "@microsoft/api-extractor": "^7.58.9",
@@ -103,7 +103,7 @@
103
103
  "@rsbuild/plugin-svgr": "^2.0.5",
104
104
  "@rslib/core": "0.23.2",
105
105
  "@types/body-scroll-lock": "^3.1.2",
106
- "@types/hast": "^3.0.4",
106
+ "@types/hast": "^3.0.5",
107
107
  "@types/mdast": "^4.0.4",
108
108
  "@types/node": "^22.8.1",
109
109
  "@types/nprogress": "^0.2.3",
@@ -119,7 +119,7 @@
119
119
  "memfs": "^4.57.8",
120
120
  "p-map": "^7.0.5",
121
121
  "picocolors": "^1.1.1",
122
- "postcss": "8.5.16",
122
+ "postcss": "8.5.17",
123
123
  "remark-directive": "^4.0.0",
124
124
  "rsbuild-plugin-publint": "^1.0.0",
125
125
  "rsbuild-plugin-virtual-module": "0.4.5",