zudoku 0.25.2 → 0.26.0
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/dist/app/demo.js +0 -1
- package/dist/app/demo.js.map +1 -1
- package/dist/app/standalone.js +0 -1
- package/dist/app/standalone.js.map +1 -1
- package/dist/cli/dev/handler.js +2 -2
- package/dist/cli/dev/handler.js.map +1 -1
- package/dist/config/validators/InputSidebarSchema.d.ts +2 -2
- package/dist/config/validators/common.d.ts +28 -28
- package/dist/config/validators/icon-types.d.ts +1 -1
- package/dist/config/validators/validate.d.ts +16 -16
- package/dist/lib/components/navigation/SidebarCategory.js +1 -1
- package/dist/lib/components/navigation/SidebarCategory.js.map +1 -1
- package/dist/lib/oas/graphql/index.d.ts +3 -0
- package/dist/lib/oas/graphql/index.js +12 -13
- package/dist/lib/oas/graphql/index.js.map +1 -1
- package/dist/lib/plugins/openapi/ColorizedParam.d.ts +10 -2
- package/dist/lib/plugins/openapi/ColorizedParam.js +16 -7
- package/dist/lib/plugins/openapi/ColorizedParam.js.map +1 -1
- package/dist/lib/plugins/openapi/OperationList.js +3 -0
- package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
- package/dist/lib/plugins/openapi/ParameterListItem.js +3 -2
- package/dist/lib/plugins/openapi/ParameterListItem.js.map +1 -1
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js +2 -0
- package/dist/lib/plugins/openapi/PlaygroundDialogWrapper.js.map +1 -1
- package/dist/lib/plugins/openapi/RequestBodySidecarBox.d.ts +3 -2
- package/dist/lib/plugins/openapi/RequestBodySidecarBox.js +3 -6
- package/dist/lib/plugins/openapi/RequestBodySidecarBox.js.map +1 -1
- package/dist/lib/plugins/openapi/ResponsesSidecarBox.js +2 -6
- package/dist/lib/plugins/openapi/ResponsesSidecarBox.js.map +1 -1
- package/dist/lib/plugins/openapi/Sidecar.js +9 -6
- package/dist/lib/plugins/openapi/Sidecar.js.map +1 -1
- package/dist/lib/plugins/openapi/SidecarBox.js +1 -1
- package/dist/lib/plugins/openapi/SidecarBox.js.map +1 -1
- package/dist/lib/plugins/openapi/{ExampleDisplay.d.ts → SidecarExamples.d.ts} +3 -6
- package/dist/lib/plugins/openapi/SidecarExamples.js +65 -0
- package/dist/lib/plugins/openapi/SidecarExamples.js.map +1 -0
- package/dist/lib/plugins/openapi/client/GraphQLClient.d.ts +1 -1
- package/dist/lib/plugins/openapi/client/GraphQLClient.js +22 -93
- package/dist/lib/plugins/openapi/client/GraphQLClient.js.map +1 -1
- package/dist/lib/plugins/openapi/client/createServer.d.ts +2 -1
- package/dist/lib/plugins/openapi/client/createServer.js +5 -2
- package/dist/lib/plugins/openapi/client/createServer.js.map +1 -1
- package/dist/lib/plugins/openapi/client/useCreateQuery.d.ts +1 -1
- package/dist/lib/plugins/openapi/client/useCreateQuery.js +2 -13
- package/dist/lib/plugins/openapi/client/useCreateQuery.js.map +1 -1
- package/dist/lib/plugins/openapi/index.d.ts +2 -1
- package/dist/lib/plugins/openapi/index.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/EnumSelector.d.ts +8 -0
- package/dist/lib/plugins/openapi/playground/EnumSelector.js +21 -0
- package/dist/lib/plugins/openapi/playground/EnumSelector.js.map +1 -0
- package/dist/lib/plugins/openapi/playground/PathParams.js +9 -4
- package/dist/lib/plugins/openapi/playground/PathParams.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/Playground.d.ts +3 -0
- package/dist/lib/plugins/openapi/playground/Playground.js +5 -2
- package/dist/lib/plugins/openapi/playground/Playground.js.map +1 -1
- package/dist/lib/plugins/openapi/playground/QueryParams.js +23 -8
- package/dist/lib/plugins/openapi/playground/QueryParams.js.map +1 -1
- package/dist/lib/plugins/openapi/schema/SchemaComponents.js +2 -1
- package/dist/lib/plugins/openapi/schema/SchemaComponents.js.map +1 -1
- package/dist/lib/plugins/openapi/util/generateSchemaExample.js +19 -11
- package/dist/lib/plugins/openapi/util/generateSchemaExample.js.map +1 -1
- package/dist/lib/ui/Badge.d.ts +1 -1
- package/dist/lib/ui/Badge.js +2 -1
- package/dist/lib/ui/Badge.js.map +1 -1
- package/dist/lib/ui/Button.d.ts +1 -1
- package/dist/lib/ui/Checkbox.d.ts +8 -2
- package/dist/lib/ui/Checkbox.js +13 -1
- package/dist/lib/ui/Checkbox.js.map +1 -1
- package/dist/lib/util/traverse.d.ts +8 -1
- package/dist/lib/util/traverse.js +7 -3
- package/dist/lib/util/traverse.js.map +1 -1
- package/dist/vite/api/schema-codegen.d.ts +12 -0
- package/dist/vite/api/schema-codegen.js +62 -0
- package/dist/vite/api/schema-codegen.js.map +1 -0
- package/dist/vite/api/schema-codegen.test.d.ts +1 -0
- package/dist/vite/api/schema-codegen.test.js +247 -0
- package/dist/vite/api/schema-codegen.test.js.map +1 -0
- package/dist/vite/config.js +0 -7
- package/dist/vite/config.js.map +1 -1
- package/dist/vite/config.test.js +5 -1
- package/dist/vite/config.test.js.map +1 -1
- package/dist/vite/plugin-api.js +110 -82
- package/dist/vite/plugin-api.js.map +1 -1
- package/dist/vite/plugin-component.js +0 -1
- package/dist/vite/plugin-component.js.map +1 -1
- package/lib/{AnchorLink-DFZZbmvr.js → AnchorLink-_Vu02ceN.js} +3 -3
- package/lib/{AnchorLink-DFZZbmvr.js.map → AnchorLink-_Vu02ceN.js.map} +1 -1
- package/lib/{AuthenticationPlugin-D7G3me8L.js → AuthenticationPlugin-DNXBcsVN.js} +4 -4
- package/lib/{AuthenticationPlugin-D7G3me8L.js.map → AuthenticationPlugin-DNXBcsVN.js.map} +1 -1
- package/lib/{Button-DeAoTouo.js → Button-oroWHXAy.js} +3 -3
- package/lib/{Button-DeAoTouo.js.map → Button-oroWHXAy.js.map} +1 -1
- package/lib/{CategoryHeading-CBconmtI.js → CategoryHeading-MYL1u_6K.js} +3 -3
- package/lib/{CategoryHeading-CBconmtI.js.map → CategoryHeading-MYL1u_6K.js.map} +1 -1
- package/lib/Command-D5DE0DD7.js +611 -0
- package/lib/Command-D5DE0DD7.js.map +1 -0
- package/lib/{Markdown-CZDLNOFc.js → Markdown-BrfrjEk_.js} +1041 -1041
- package/lib/{Markdown-CZDLNOFc.js.map → Markdown-BrfrjEk_.js.map} +1 -1
- package/lib/{MdxPage-DKMbBROv.js → MdxPage-LNZLj_A5.js} +24 -24
- package/lib/{MdxPage-DKMbBROv.js.map → MdxPage-LNZLj_A5.js.map} +1 -1
- package/lib/{OperationList-BLdHAQ39.js → OperationList-PCwzTp1r.js} +1899 -1877
- package/lib/OperationList-PCwzTp1r.js.map +1 -0
- package/lib/{Route-DYwKZ_c_.js → Route-Pzk6qwIk.js} +5 -5
- package/lib/{Route-DYwKZ_c_.js.map → Route-Pzk6qwIk.js.map} +1 -1
- package/lib/{Select-B_IxRUUC.js → Select-DkOpAG0c.js} +36 -36
- package/lib/{Select-B_IxRUUC.js.map → Select-DkOpAG0c.js.map} +1 -1
- package/lib/{SlotletProvider-pfc9oejW.js → SlotletProvider-DPbx9KdU.js} +53 -53
- package/lib/{SlotletProvider-pfc9oejW.js.map → SlotletProvider-DPbx9KdU.js.map} +1 -1
- package/lib/{Spinner-DuxJLLNE.js → Spinner-C5gHXrVz.js} +2 -2
- package/lib/{Spinner-DuxJLLNE.js.map → Spinner-C5gHXrVz.js.map} +1 -1
- package/lib/{SyntaxHighlight-Bz-lOJtH.js → SyntaxHighlight-CJCSPG1F.js} +297 -301
- package/lib/{SyntaxHighlight-Bz-lOJtH.js.map → SyntaxHighlight-CJCSPG1F.js.map} +1 -1
- package/lib/{ZudokuContext-hmLMUdf2.js → ZudokuContext-D3ayHjP-.js} +357 -356
- package/lib/ZudokuContext-D3ayHjP-.js.map +1 -0
- package/lib/{chunk-D52XG6IA-Dl7HLe6j.js → chunk-SYFQ2XB5-KWlHsT7t.js} +407 -410
- package/lib/chunk-SYFQ2XB5-KWlHsT7t.js.map +1 -0
- package/lib/context-rwLGh-6_.js +22 -0
- package/lib/{context-h_UkBLvr.js.map → context-rwLGh-6_.js.map} +1 -1
- package/lib/{createServer-Bf5_6o6G.js → createServer-BcaswoFO.js} +4363 -5302
- package/lib/createServer-BcaswoFO.js.map +1 -0
- package/lib/{hook-CHq7pFyz.js → hook-DUyACbIK.js} +17 -17
- package/lib/{hook-CHq7pFyz.js.map → hook-DUyACbIK.js.map} +1 -1
- package/lib/index-CaILD1AV.js +1292 -0
- package/lib/index-CaILD1AV.js.map +1 -0
- package/lib/index-Djenk2Hj.js +36 -0
- package/lib/{index-CPNSgwSb.js.map → index-Djenk2Hj.js.map} +1 -1
- package/lib/{index-CBXSgjaE.js → index-Dl3Yl0yb.js} +65 -69
- package/lib/index-Dl3Yl0yb.js.map +1 -0
- package/lib/index-TaRXY2w1.js +43 -0
- package/lib/index-TaRXY2w1.js.map +1 -0
- package/lib/{index.esm-BSV1C092.js → index.esm-9-TF9KQB.js} +52 -52
- package/lib/{index.esm-BSV1C092.js.map → index.esm-9-TF9KQB.js.map} +1 -1
- package/lib/index.esm-CrSoEshU.js +1207 -0
- package/lib/index.esm-CrSoEshU.js.map +1 -0
- package/lib/{jsx-runtime-Dx-03ztt.js → jsx-runtime-Bdg6XQ1m.js} +135 -135
- package/lib/{jsx-runtime-Dx-03ztt.js.map → jsx-runtime-Bdg6XQ1m.js.map} +1 -1
- package/lib/post-processors/removeExtensions.js +3 -3
- package/lib/post-processors/traverse.js +11 -8
- package/lib/post-processors/traverse.js.map +1 -1
- package/lib/{prism-bash.min-DadFsM4Z.js → prism-bash.min-HHIMdNJ_.js} +4 -4
- package/lib/{prism-bash.min-DadFsM4Z.js.map → prism-bash.min-HHIMdNJ_.js.map} +1 -1
- package/lib/{prism-csharp.min-DUwvItt4.js → prism-csharp.min-bQAo2pmx.js} +33 -33
- package/lib/{prism-csharp.min-DUwvItt4.js.map → prism-csharp.min-bQAo2pmx.js.map} +1 -1
- package/lib/{prism-java.min-BtgBR4yd.js → prism-java.min-BpvsOuIa.js} +12 -12
- package/lib/{prism-java.min-BtgBR4yd.js.map → prism-java.min-BpvsOuIa.js.map} +1 -1
- package/lib/{prism-markdown.min-F3U-vPBi.js → prism-markdown.min-C0Qn0m-5.js} +30 -30
- package/lib/{prism-markdown.min-F3U-vPBi.js.map → prism-markdown.min-C0Qn0m-5.js.map} +1 -1
- package/lib/{prism-ruby.min-DeDXCp1r.js → prism-ruby.min-Dx9KO9ds.js} +16 -16
- package/lib/{prism-ruby.min-DeDXCp1r.js.map → prism-ruby.min-Dx9KO9ds.js.map} +1 -1
- package/lib/prism-typescript.min-CD7H2IYQ.js.map +1 -1
- package/lib/state-mM7uaXTW.js +202 -0
- package/lib/state-mM7uaXTW.js.map +1 -0
- package/lib/ui/Accordion.js +1 -1
- package/lib/ui/ActionButton.js +3 -3
- package/lib/ui/Alert.js +2 -2
- package/lib/ui/AlertDialog.js +1 -1
- package/lib/ui/Badge.js +4 -3
- package/lib/ui/Badge.js.map +1 -1
- package/lib/ui/Breadcrumb.js +1 -1
- package/lib/ui/Button.js +2 -2
- package/lib/ui/Callout.js +1 -1
- package/lib/ui/Card.js +1 -1
- package/lib/ui/Carousel.js +3 -3
- package/lib/ui/Carousel.js.map +1 -1
- package/lib/ui/Checkbox.js +26 -15
- package/lib/ui/Checkbox.js.map +1 -1
- package/lib/ui/Command.js +14 -550
- package/lib/ui/Command.js.map +1 -1
- package/lib/ui/Dialog.js +1 -1
- package/lib/ui/Drawer.js +520 -519
- package/lib/ui/Drawer.js.map +1 -1
- package/lib/ui/DropdownMenu.js +1 -1
- package/lib/ui/Form.js +2 -2
- package/lib/ui/HoverCard.js +1 -1
- package/lib/ui/Input.js +1 -1
- package/lib/ui/Label.js +2 -2
- package/lib/ui/Pagination.js +7 -7
- package/lib/ui/Popover.js +1 -1
- package/lib/ui/Progress.js +1 -1
- package/lib/ui/RadioGroup.js +1 -1
- package/lib/ui/ScrollArea.js +1 -1
- package/lib/ui/Select.js +1 -1
- package/lib/ui/Skeleton.js +1 -1
- package/lib/ui/Slider.js +1 -1
- package/lib/ui/Switch.js +1 -1
- package/lib/ui/Tabs.js +1 -1
- package/lib/ui/Textarea.js +1 -1
- package/lib/ui/Toggle.js +2 -2
- package/lib/ui/ToggleGroup.js +1 -1
- package/lib/ui/Tooltip.js +1 -1
- package/lib/{useExposedProps-DE9lR6MF.js → useExposedProps-BBHR7aLM.js} +2 -2
- package/lib/{useExposedProps-DE9lR6MF.js.map → useExposedProps-BBHR7aLM.js.map} +1 -1
- package/lib/zudoku.auth-auth0.js +1 -1
- package/lib/zudoku.auth-clerk.js +18 -18
- package/lib/zudoku.auth-openid.js +5 -5
- package/lib/zudoku.components.js +492 -477
- package/lib/zudoku.components.js.map +1 -1
- package/lib/zudoku.plugin-api-catalog.js +5 -5
- package/lib/zudoku.plugin-api-keys.js +7 -7
- package/lib/zudoku.plugin-custom-pages.js +3 -3
- package/lib/zudoku.plugin-markdown.js +2 -2
- package/lib/zudoku.plugin-openapi.js +5 -5
- package/lib/zudoku.plugin-redirect.js +1 -1
- package/lib/zudoku.plugin-search-inkeep.js +9 -9
- package/package.json +48 -53
- package/src/app/demo.tsx +0 -1
- package/src/app/standalone.tsx +0 -1
- package/src/lib/components/navigation/SidebarCategory.tsx +2 -2
- package/src/lib/oas/graphql/index.ts +19 -15
- package/src/lib/plugins/openapi/ColorizedParam.tsx +29 -12
- package/src/lib/plugins/openapi/OperationList.tsx +4 -0
- package/src/lib/plugins/openapi/ParameterListItem.tsx +5 -7
- package/src/lib/plugins/openapi/PlaygroundDialogWrapper.tsx +2 -0
- package/src/lib/plugins/openapi/RequestBodySidecarBox.tsx +9 -8
- package/src/lib/plugins/openapi/ResponsesSidecarBox.tsx +5 -8
- package/src/lib/plugins/openapi/Sidecar.tsx +14 -7
- package/src/lib/plugins/openapi/SidecarBox.tsx +1 -1
- package/src/lib/plugins/openapi/SidecarExamples.tsx +163 -0
- package/src/lib/plugins/openapi/client/GraphQLClient.tsx +28 -120
- package/src/lib/plugins/openapi/client/createServer.ts +6 -2
- package/src/lib/plugins/openapi/client/useCreateQuery.ts +2 -17
- package/src/lib/plugins/openapi/index.tsx +2 -1
- package/src/lib/plugins/openapi/playground/EnumSelector.tsx +86 -0
- package/src/lib/plugins/openapi/playground/PathParams.tsx +72 -64
- package/src/lib/plugins/openapi/playground/Playground.tsx +26 -13
- package/src/lib/plugins/openapi/playground/QueryParams.tsx +102 -73
- package/src/lib/plugins/openapi/schema/SchemaComponents.tsx +4 -7
- package/src/lib/plugins/openapi/util/generateSchemaExample.ts +26 -11
- package/src/lib/ui/Badge.tsx +2 -1
- package/src/lib/ui/Checkbox.tsx +24 -7
- package/src/lib/util/traverse.ts +15 -5
- package/dist/lib/plugins/openapi/ExampleDisplay.js +0 -78
- package/dist/lib/plugins/openapi/ExampleDisplay.js.map +0 -1
- package/dist/lib/plugins/openapi/client/worker.d.ts +0 -4
- package/dist/lib/plugins/openapi/client/worker.js +0 -29
- package/dist/lib/plugins/openapi/client/worker.js.map +0 -1
- package/dist/lib/plugins/openapi-worker.d.ts +0 -1
- package/dist/lib/plugins/openapi-worker.js +0 -8
- package/dist/lib/plugins/openapi-worker.js.map +0 -1
- package/lib/Dialog-Bxv1yEIg.js +0 -67
- package/lib/Dialog-Bxv1yEIg.js.map +0 -1
- package/lib/OperationList-BLdHAQ39.js.map +0 -1
- package/lib/ZudokuContext-hmLMUdf2.js.map +0 -1
- package/lib/assets/index-C7jnHK4b.js +0 -4841
- package/lib/assets/index-C7jnHK4b.js.map +0 -1
- package/lib/assets/worker-Cbp2r2BQ.js +0 -18592
- package/lib/assets/worker-Cbp2r2BQ.js.map +0 -1
- package/lib/chunk-D52XG6IA-Dl7HLe6j.js.map +0 -1
- package/lib/context-h_UkBLvr.js +0 -22
- package/lib/createServer-Bf5_6o6G.js.map +0 -1
- package/lib/index-BNx95gkf.js +0 -1284
- package/lib/index-BNx95gkf.js.map +0 -1
- package/lib/index-CBXSgjaE.js.map +0 -1
- package/lib/index-CPNSgwSb.js +0 -36
- package/lib/index-DyBL--Kz.js +0 -826
- package/lib/index-DyBL--Kz.js.map +0 -1
- package/lib/index.esm-BnnBRKJX.js +0 -1214
- package/lib/index.esm-BnnBRKJX.js.map +0 -1
- package/lib/state-CFQsUZUP.js +0 -202
- package/lib/state-CFQsUZUP.js.map +0 -1
- package/lib/zudoku.openapi-worker.js +0 -15
- package/lib/zudoku.openapi-worker.js.map +0 -1
- package/src/lib/plugins/openapi/ExampleDisplay.tsx +0 -163
- package/src/lib/plugins/openapi/client/worker.ts +0 -44
- package/src/lib/plugins/openapi-worker.ts +0 -11
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
import { j as I } from "./jsx-runtime-
|
|
1
|
+
import { j as I } from "./jsx-runtime-Bdg6XQ1m.js";
|
|
2
2
|
import * as _ from "react";
|
|
3
|
-
import { createElement as
|
|
4
|
-
import { a as
|
|
5
|
-
import { CheckIcon as
|
|
6
|
-
import { C as
|
|
7
|
-
var
|
|
3
|
+
import { createElement as he, useCallback as V, useMemo as ve, useState as ke } from "react";
|
|
4
|
+
import { a as ce, c as ae } from "./cn-qaFjX9_3.js";
|
|
5
|
+
import { CheckIcon as we, CopyIcon as Ee } from "lucide-react";
|
|
6
|
+
import { C as xe } from "./ClientOnly-E7hGysn1.js";
|
|
7
|
+
var Se = Object.create, W = Object.defineProperty, Ae = Object.defineProperties, _e = Object.getOwnPropertyDescriptor, Fe = Object.getOwnPropertyDescriptors, pe = Object.getOwnPropertyNames, Z = Object.getOwnPropertySymbols, Te = Object.getPrototypeOf, Q = Object.prototype.hasOwnProperty, de = Object.prototype.propertyIsEnumerable, ne = (e, t, a) => t in e ? W(e, t, { enumerable: !0, configurable: !0, writable: !0, value: a }) : e[t] = a, B = (e, t) => {
|
|
8
8
|
for (var a in t || (t = {}))
|
|
9
|
-
|
|
9
|
+
Q.call(t, a) && ne(e, a, t[a]);
|
|
10
10
|
if (Z)
|
|
11
11
|
for (var a of Z(t))
|
|
12
|
-
|
|
12
|
+
de.call(t, a) && ne(e, a, t[a]);
|
|
13
13
|
return e;
|
|
14
|
-
}, q = (e, t) =>
|
|
14
|
+
}, q = (e, t) => Ae(e, Fe(t)), ge = (e, t) => {
|
|
15
15
|
var a = {};
|
|
16
|
-
for (var
|
|
17
|
-
|
|
16
|
+
for (var i in e)
|
|
17
|
+
Q.call(e, i) && t.indexOf(i) < 0 && (a[i] = e[i]);
|
|
18
18
|
if (e != null && Z)
|
|
19
|
-
for (var
|
|
20
|
-
t.indexOf(
|
|
19
|
+
for (var i of Z(e))
|
|
20
|
+
t.indexOf(i) < 0 && de.call(e, i) && (a[i] = e[i]);
|
|
21
21
|
return a;
|
|
22
|
-
},
|
|
23
|
-
return t || (0, e[
|
|
24
|
-
},
|
|
22
|
+
}, Re = (e, t) => function() {
|
|
23
|
+
return t || (0, e[pe(e)[0]])((t = { exports: {} }).exports, t), t.exports;
|
|
24
|
+
}, Ie = (e, t) => {
|
|
25
25
|
for (var a in t)
|
|
26
26
|
W(e, a, { get: t[a], enumerable: !0 });
|
|
27
|
-
},
|
|
27
|
+
}, Le = (e, t, a, i) => {
|
|
28
28
|
if (t && typeof t == "object" || typeof t == "function")
|
|
29
|
-
for (let p of
|
|
30
|
-
!
|
|
29
|
+
for (let p of pe(t))
|
|
30
|
+
!Q.call(e, p) && p !== a && W(e, p, { get: () => t[p], enumerable: !(i = _e(t, p)) || i.enumerable });
|
|
31
31
|
return e;
|
|
32
|
-
},
|
|
32
|
+
}, Oe = (e, t, a) => (a = e != null ? Se(Te(e)) : {}, Le(
|
|
33
33
|
// If the importer is in node compatibility mode or this is not an ESM
|
|
34
34
|
// file that has been converted to a CommonJS file using a Babel-
|
|
35
35
|
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
36
36
|
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
37
37
|
!e || !e.__esModule ? W(a, "default", { value: e, enumerable: !0 }) : a,
|
|
38
38
|
e
|
|
39
|
-
)),
|
|
39
|
+
)), Ce = Re({
|
|
40
40
|
"../../node_modules/.pnpm/prismjs@1.29.0_patch_hash=vrxx3pzkik6jpmgpayxfjunetu/node_modules/prismjs/prism.js"(e, t) {
|
|
41
41
|
var a = function() {
|
|
42
|
-
var
|
|
42
|
+
var i = /(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i, p = 0, h = {}, c = {
|
|
43
43
|
/**
|
|
44
44
|
* A namespace for utility methods.
|
|
45
45
|
*
|
|
@@ -51,7 +51,7 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
51
51
|
*/
|
|
52
52
|
util: {
|
|
53
53
|
encode: function n(r) {
|
|
54
|
-
return r instanceof
|
|
54
|
+
return r instanceof m ? new m(r.type, n(r.content), r.alias) : Array.isArray(r) ? r.map(n) : r.replace(/&/g, "&").replace(/</g, "<").replace(/\u00a0/g, " ");
|
|
55
55
|
},
|
|
56
56
|
/**
|
|
57
57
|
* Returns the name of the type of the given value.
|
|
@@ -93,13 +93,13 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
93
93
|
*/
|
|
94
94
|
clone: function n(r, s) {
|
|
95
95
|
s = s || {};
|
|
96
|
-
var d,
|
|
96
|
+
var d, l;
|
|
97
97
|
switch (c.util.type(r)) {
|
|
98
98
|
case "Object":
|
|
99
|
-
if (
|
|
100
|
-
return s[
|
|
99
|
+
if (l = c.util.objId(r), s[l])
|
|
100
|
+
return s[l];
|
|
101
101
|
d = /** @type {Record<string, any>} */
|
|
102
|
-
{}, s[
|
|
102
|
+
{}, s[l] = d;
|
|
103
103
|
for (var f in r)
|
|
104
104
|
r.hasOwnProperty(f) && (d[f] = n(r[f], s));
|
|
105
105
|
return (
|
|
@@ -107,7 +107,7 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
107
107
|
d
|
|
108
108
|
);
|
|
109
109
|
case "Array":
|
|
110
|
-
return
|
|
110
|
+
return l = c.util.objId(r), s[l] ? s[l] : (d = [], s[l] = d, r.forEach(function(E, w) {
|
|
111
111
|
d[w] = n(E, s);
|
|
112
112
|
}), /** @type {any} */
|
|
113
113
|
d);
|
|
@@ -125,7 +125,7 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
125
125
|
*/
|
|
126
126
|
getLanguage: function(n) {
|
|
127
127
|
for (; n; ) {
|
|
128
|
-
var r =
|
|
128
|
+
var r = i.exec(n.className);
|
|
129
129
|
if (r)
|
|
130
130
|
return r[1].toLowerCase();
|
|
131
131
|
n = n.parentElement;
|
|
@@ -140,7 +140,7 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
140
140
|
* @returns {void}
|
|
141
141
|
*/
|
|
142
142
|
setLanguage: function(n, r) {
|
|
143
|
-
n.className = n.className.replace(RegExp(
|
|
143
|
+
n.className = n.className.replace(RegExp(i, "gi"), ""), n.classList.add("language-" + r);
|
|
144
144
|
},
|
|
145
145
|
/**
|
|
146
146
|
* Returns whether a given class is active for `element`.
|
|
@@ -163,10 +163,10 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
163
163
|
*/
|
|
164
164
|
isActive: function(n, r, s) {
|
|
165
165
|
for (var d = "no-" + r; n; ) {
|
|
166
|
-
var
|
|
167
|
-
if (
|
|
166
|
+
var l = n.classList;
|
|
167
|
+
if (l.contains(r))
|
|
168
168
|
return !0;
|
|
169
|
-
if (
|
|
169
|
+
if (l.contains(d))
|
|
170
170
|
return !1;
|
|
171
171
|
n = n.parentElement;
|
|
172
172
|
}
|
|
@@ -184,10 +184,10 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
184
184
|
/**
|
|
185
185
|
* The grammar for plain, unformatted text.
|
|
186
186
|
*/
|
|
187
|
-
plain:
|
|
188
|
-
plaintext:
|
|
189
|
-
text:
|
|
190
|
-
txt:
|
|
187
|
+
plain: h,
|
|
188
|
+
plaintext: h,
|
|
189
|
+
text: h,
|
|
190
|
+
txt: h,
|
|
191
191
|
/**
|
|
192
192
|
* Creates a deep copy of the language with the given id and appends the given tokens.
|
|
193
193
|
*
|
|
@@ -300,13 +300,13 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
300
300
|
insertBefore: function(n, r, s, d) {
|
|
301
301
|
d = d || /** @type {any} */
|
|
302
302
|
c.languages;
|
|
303
|
-
var
|
|
304
|
-
for (var E in
|
|
305
|
-
if (
|
|
303
|
+
var l = d[n], f = {};
|
|
304
|
+
for (var E in l)
|
|
305
|
+
if (l.hasOwnProperty(E)) {
|
|
306
306
|
if (E == r)
|
|
307
307
|
for (var w in s)
|
|
308
308
|
s.hasOwnProperty(w) && (f[w] = s[w]);
|
|
309
|
-
s.hasOwnProperty(E) || (f[E] =
|
|
309
|
+
s.hasOwnProperty(E) || (f[E] = l[E]);
|
|
310
310
|
}
|
|
311
311
|
var x = d[n];
|
|
312
312
|
return d[n] = f, c.languages.DFS(c.languages, function(S, F) {
|
|
@@ -314,14 +314,14 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
314
314
|
}), f;
|
|
315
315
|
},
|
|
316
316
|
// Traverse a language definition with Depth First Search
|
|
317
|
-
DFS: function n(r, s, d,
|
|
318
|
-
|
|
317
|
+
DFS: function n(r, s, d, l) {
|
|
318
|
+
l = l || {};
|
|
319
319
|
var f = c.util.objId;
|
|
320
320
|
for (var E in r)
|
|
321
321
|
if (r.hasOwnProperty(E)) {
|
|
322
322
|
s.call(r, E, r[E], d || E);
|
|
323
323
|
var w = r[E], x = c.util.type(w);
|
|
324
|
-
x === "Object" && !
|
|
324
|
+
x === "Object" && !l[f(w)] ? (l[f(w)] = !0, n(w, s, null, l)) : x === "Array" && !l[f(w)] && (l[f(w)] = !0, n(w, s, E, l));
|
|
325
325
|
}
|
|
326
326
|
}
|
|
327
327
|
},
|
|
@@ -354,7 +354,7 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
354
354
|
};
|
|
355
355
|
if (c.hooks.run("before-tokenize", d), !d.grammar)
|
|
356
356
|
throw new Error('The language "' + d.language + '" has no grammar.');
|
|
357
|
-
return d.tokens = c.tokenize(d.code, d.grammar), c.hooks.run("after-tokenize", d),
|
|
357
|
+
return d.tokens = c.tokenize(d.code, d.grammar), c.hooks.run("after-tokenize", d), m.stringify(c.util.encode(d.tokens), d.language);
|
|
358
358
|
},
|
|
359
359
|
/**
|
|
360
360
|
* This is the heart of Prism, and the most low-level function you can use. It accepts a string of text as input
|
|
@@ -387,8 +387,8 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
387
387
|
r[d] = s[d];
|
|
388
388
|
delete r.rest;
|
|
389
389
|
}
|
|
390
|
-
var
|
|
391
|
-
return y(
|
|
390
|
+
var l = new b();
|
|
391
|
+
return y(l, l.head, n), g(n, l, r, l.head, 0), k(l);
|
|
392
392
|
},
|
|
393
393
|
/**
|
|
394
394
|
* @namespace
|
|
@@ -425,16 +425,16 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
425
425
|
run: function(n, r) {
|
|
426
426
|
var s = c.hooks.all[n];
|
|
427
427
|
if (!(!s || !s.length))
|
|
428
|
-
for (var d = 0,
|
|
429
|
-
|
|
428
|
+
for (var d = 0, l; l = s[d++]; )
|
|
429
|
+
l(r);
|
|
430
430
|
}
|
|
431
431
|
},
|
|
432
|
-
Token:
|
|
432
|
+
Token: m
|
|
433
433
|
};
|
|
434
|
-
function
|
|
434
|
+
function m(n, r, s, d) {
|
|
435
435
|
this.type = n, this.content = r, this.alias = s, this.length = (d || "").length | 0;
|
|
436
436
|
}
|
|
437
|
-
|
|
437
|
+
m.stringify = function n(r, s) {
|
|
438
438
|
if (typeof r == "string")
|
|
439
439
|
return r;
|
|
440
440
|
if (Array.isArray(r)) {
|
|
@@ -443,7 +443,7 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
443
443
|
d += n(x, s);
|
|
444
444
|
}), d;
|
|
445
445
|
}
|
|
446
|
-
var
|
|
446
|
+
var l = {
|
|
447
447
|
type: r.type,
|
|
448
448
|
content: n(r.content, s),
|
|
449
449
|
tag: "span",
|
|
@@ -451,22 +451,22 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
451
451
|
attributes: {},
|
|
452
452
|
language: s
|
|
453
453
|
}, f = r.alias;
|
|
454
|
-
f && (Array.isArray(f) ? Array.prototype.push.apply(
|
|
454
|
+
f && (Array.isArray(f) ? Array.prototype.push.apply(l.classes, f) : l.classes.push(f)), c.hooks.run("wrap", l);
|
|
455
455
|
var E = "";
|
|
456
|
-
for (var w in
|
|
457
|
-
E += " " + w + '="' + (
|
|
458
|
-
return "<" +
|
|
456
|
+
for (var w in l.attributes)
|
|
457
|
+
E += " " + w + '="' + (l.attributes[w] || "").replace(/"/g, """) + '"';
|
|
458
|
+
return "<" + l.tag + ' class="' + l.classes.join(" ") + '"' + E + ">" + l.content + "</" + l.tag + ">";
|
|
459
459
|
};
|
|
460
460
|
function u(n, r, s, d) {
|
|
461
461
|
n.lastIndex = r;
|
|
462
|
-
var
|
|
463
|
-
if (
|
|
464
|
-
var f =
|
|
465
|
-
|
|
462
|
+
var l = n.exec(s);
|
|
463
|
+
if (l && d && l[1]) {
|
|
464
|
+
var f = l[1].length;
|
|
465
|
+
l.index += f, l[0] = l[0].slice(f);
|
|
466
466
|
}
|
|
467
|
-
return
|
|
467
|
+
return l;
|
|
468
468
|
}
|
|
469
|
-
function g(n, r, s, d,
|
|
469
|
+
function g(n, r, s, d, l, f) {
|
|
470
470
|
for (var E in s)
|
|
471
471
|
if (!(!s.hasOwnProperty(E) || !s[E])) {
|
|
472
472
|
var w = s[E];
|
|
@@ -479,31 +479,31 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
479
479
|
var O = S.pattern.toString().match(/[imsuy]*$/)[0];
|
|
480
480
|
S.pattern = RegExp(S.pattern.source, O + "g");
|
|
481
481
|
}
|
|
482
|
-
for (var
|
|
482
|
+
for (var ee = S.pattern || S, R = d.next, D = l; R !== r.tail && !(f && D >= f.reach); D += R.value.length, R = R.next) {
|
|
483
483
|
var P = R.value;
|
|
484
484
|
if (r.length > n.length)
|
|
485
485
|
return;
|
|
486
|
-
if (!(P instanceof
|
|
486
|
+
if (!(P instanceof m)) {
|
|
487
487
|
var z = 1, N;
|
|
488
488
|
if (C) {
|
|
489
|
-
if (N = u(
|
|
489
|
+
if (N = u(ee, D, n, A), !N || N.index >= n.length)
|
|
490
490
|
break;
|
|
491
|
-
var M = N.index,
|
|
491
|
+
var M = N.index, be = N.index + N[0].length, $ = D;
|
|
492
492
|
for ($ += R.value.length; M >= $; )
|
|
493
493
|
R = R.next, $ += R.value.length;
|
|
494
|
-
if ($ -= R.value.length, D = $, R.value instanceof
|
|
494
|
+
if ($ -= R.value.length, D = $, R.value instanceof m)
|
|
495
495
|
continue;
|
|
496
|
-
for (var j = R; j !== r.tail && ($ <
|
|
496
|
+
for (var j = R; j !== r.tail && ($ < be || typeof j.value == "string"); j = j.next)
|
|
497
497
|
z++, $ += j.value.length;
|
|
498
498
|
z--, P = n.slice(D, $), N.index -= D;
|
|
499
|
-
} else if (N = u(
|
|
499
|
+
} else if (N = u(ee, 0, P, A), !N)
|
|
500
500
|
continue;
|
|
501
|
-
var M = N.index, U = N[0], H = P.slice(0, M),
|
|
501
|
+
var M = N.index, U = N[0], H = P.slice(0, M), te = P.slice(M + U.length), Y = D + P.length;
|
|
502
502
|
f && Y > f.reach && (f.reach = Y);
|
|
503
503
|
var G = R.prev;
|
|
504
504
|
H && (G = y(r, G, H), D += H.length), v(r, G, z);
|
|
505
|
-
var
|
|
506
|
-
if (R = y(r, G,
|
|
505
|
+
var me = new m(E, F ? c.tokenize(U, F) : U, T, U);
|
|
506
|
+
if (R = y(r, G, me), te && y(r, R, te), z > 1) {
|
|
507
507
|
var K = {
|
|
508
508
|
cause: E + "," + x,
|
|
509
509
|
reach: Y
|
|
@@ -520,13 +520,13 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
520
520
|
n.next = r, this.head = n, this.tail = r, this.length = 0;
|
|
521
521
|
}
|
|
522
522
|
function y(n, r, s) {
|
|
523
|
-
var d = r.next,
|
|
524
|
-
return r.next =
|
|
523
|
+
var d = r.next, l = { value: s, prev: r, next: d };
|
|
524
|
+
return r.next = l, d.prev = l, n.length++, l;
|
|
525
525
|
}
|
|
526
526
|
function v(n, r, s) {
|
|
527
|
-
for (var d = r.next,
|
|
527
|
+
for (var d = r.next, l = 0; l < s && d !== n.tail; l++)
|
|
528
528
|
d = d.next;
|
|
529
|
-
r.next = d, d.prev = r, n.length -=
|
|
529
|
+
r.next = d, d.prev = r, n.length -= l;
|
|
530
530
|
}
|
|
531
531
|
function k(n) {
|
|
532
532
|
for (var r = [], s = n.head.next; s !== n.tail; )
|
|
@@ -537,36 +537,36 @@ var Fe = Object.create, W = Object.defineProperty, Te = Object.defineProperties,
|
|
|
537
537
|
}();
|
|
538
538
|
t.exports = a, a.default = a;
|
|
539
539
|
}
|
|
540
|
-
}), o =
|
|
540
|
+
}), o = Oe(Ce());
|
|
541
541
|
o.languages.markup = { comment: { pattern: /<!--(?:(?!<!--)[\s\S])*?-->/, greedy: !0 }, prolog: { pattern: /<\?[\s\S]+?\?>/, greedy: !0 }, doctype: { pattern: /<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i, greedy: !0, inside: { "internal-subset": { pattern: /(^[^\[]*\[)[\s\S]+(?=\]>$)/, lookbehind: !0, greedy: !0, inside: null }, string: { pattern: /"[^"]*"|'[^']*'/, greedy: !0 }, punctuation: /^<!|>$|[[\]]/, "doctype-tag": /^DOCTYPE/i, name: /[^\s<>'"]+/ } }, cdata: { pattern: /<!\[CDATA\[[\s\S]*?\]\]>/i, greedy: !0 }, tag: { pattern: /<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/, greedy: !0, inside: { tag: { pattern: /^<\/?[^\s>\/]+/, inside: { punctuation: /^<\/?/, namespace: /^[^\s>\/:]+:/ } }, "special-attr": [], "attr-value": { pattern: /=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/, inside: { punctuation: [{ pattern: /^=/, alias: "attr-equals" }, { pattern: /^(\s*)["']|["']$/, lookbehind: !0 }] } }, punctuation: /\/?>/, "attr-name": { pattern: /[^\s>\/]+/, inside: { namespace: /^[^\s>\/:]+:/ } } } }, entity: [{ pattern: /&[\da-z]{1,8};/i, alias: "named-entity" }, /&#x?[\da-f]{1,8};/i] }, o.languages.markup.tag.inside["attr-value"].inside.entity = o.languages.markup.entity, o.languages.markup.doctype.inside["internal-subset"].inside = o.languages.markup, o.hooks.add("wrap", function(e) {
|
|
542
542
|
e.type === "entity" && (e.attributes.title = e.content.replace(/&/, "&"));
|
|
543
|
-
}), Object.defineProperty(o.languages.markup.tag, "addInlined", { value: function(e,
|
|
544
|
-
var a = {}, a = (a["language-" +
|
|
545
|
-
|
|
543
|
+
}), Object.defineProperty(o.languages.markup.tag, "addInlined", { value: function(e, i) {
|
|
544
|
+
var a = {}, a = (a["language-" + i] = { pattern: /(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i, lookbehind: !0, inside: o.languages[i] }, a.cdata = /^<!\[CDATA\[|\]\]>$/i, { "included-cdata": { pattern: /<!\[CDATA\[[\s\S]*?\]\]>/i, inside: a } }), i = (a["language-" + i] = { pattern: /[\s\S]+/, inside: o.languages[i] }, {});
|
|
545
|
+
i[e] = { pattern: RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g, function() {
|
|
546
546
|
return e;
|
|
547
|
-
}), "i"), lookbehind: !0, greedy: !0, inside: a }, o.languages.insertBefore("markup", "cdata",
|
|
547
|
+
}), "i"), lookbehind: !0, greedy: !0, inside: a }, o.languages.insertBefore("markup", "cdata", i);
|
|
548
548
|
} }), Object.defineProperty(o.languages.markup.tag, "addAttribute", { value: function(e, t) {
|
|
549
549
|
o.languages.markup.tag.inside["special-attr"].push({ pattern: RegExp(/(^|["'\s])/.source + "(?:" + e + ")" + /\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source, "i"), lookbehind: !0, inside: { "attr-name": /^[^\s=]+/, "attr-value": { pattern: /=[\s\S]+/, inside: { value: { pattern: /(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/, lookbehind: !0, alias: [t, "language-" + t], inside: o.languages[t] }, punctuation: [{ pattern: /^=/, alias: "attr-equals" }, /"|'/] } } } });
|
|
550
550
|
} }), o.languages.html = o.languages.markup, o.languages.mathml = o.languages.markup, o.languages.svg = o.languages.markup, o.languages.xml = o.languages.extend("markup", {}), o.languages.ssml = o.languages.xml, o.languages.atom = o.languages.xml, o.languages.rss = o.languages.xml, function(e) {
|
|
551
|
-
var t = { pattern: /\\[\\(){}[\]^$+*?|.]/, alias: "escape" }, a = /\\(?:x[\da-fA-F]{2}|u[\da-fA-F]{4}|u\{[\da-fA-F]+\}|0[0-7]{0,2}|[123][0-7]{2}|c[a-zA-Z]|.)/,
|
|
552
|
-
e.languages.regex = { "char-class": { pattern: /((?:^|[^\\])(?:\\\\)*)\[(?:[^\\\]]|\\[\s\S])*\]/, lookbehind: !0, inside: { "char-class-negation": { pattern: /(^\[)\^/, lookbehind: !0, alias: "operator" }, "char-class-punctuation": { pattern: /^\[|\]$/, alias: "punctuation" }, range: { pattern:
|
|
551
|
+
var t = { pattern: /\\[\\(){}[\]^$+*?|.]/, alias: "escape" }, a = /\\(?:x[\da-fA-F]{2}|u[\da-fA-F]{4}|u\{[\da-fA-F]+\}|0[0-7]{0,2}|[123][0-7]{2}|c[a-zA-Z]|.)/, i = "(?:[^\\\\-]|" + a.source + ")", i = RegExp(i + "-" + i), p = { pattern: /(<|')[^<>']+(?=[>']$)/, lookbehind: !0, alias: "variable" };
|
|
552
|
+
e.languages.regex = { "char-class": { pattern: /((?:^|[^\\])(?:\\\\)*)\[(?:[^\\\]]|\\[\s\S])*\]/, lookbehind: !0, inside: { "char-class-negation": { pattern: /(^\[)\^/, lookbehind: !0, alias: "operator" }, "char-class-punctuation": { pattern: /^\[|\]$/, alias: "punctuation" }, range: { pattern: i, inside: { escape: a, "range-punctuation": { pattern: /-/, alias: "operator" } } }, "special-escape": t, "char-set": { pattern: /\\[wsd]|\\p\{[^{}]+\}/i, alias: "class-name" }, escape: a } }, "special-escape": t, "char-set": { pattern: /\.|\\[wsd]|\\p\{[^{}]+\}/i, alias: "class-name" }, backreference: [{ pattern: /\\(?![123][0-7]{2})[1-9]/, alias: "keyword" }, { pattern: /\\k<[^<>']+>/, alias: "keyword", inside: { "group-name": p } }], anchor: { pattern: /[$^]|\\[ABbGZz]/, alias: "function" }, escape: a, group: [{ pattern: /\((?:\?(?:<[^<>']+>|'[^<>']+'|[>:]|<?[=!]|[idmnsuxU]+(?:-[idmnsuxU]+)?:?))?/, alias: "punctuation", inside: { "group-name": p } }, { pattern: /\)/, alias: "punctuation" }], quantifier: { pattern: /(?:[+*?]|\{\d+(?:,\d*)?\})[?+]?/, alias: "number" }, alternation: { pattern: /\|/, alias: "keyword" } };
|
|
553
553
|
}(o), o.languages.clike = { comment: [{ pattern: /(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/, lookbehind: !0, greedy: !0 }, { pattern: /(^|[^\\:])\/\/.*/, lookbehind: !0, greedy: !0 }], string: { pattern: /(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/, greedy: !0 }, "class-name": { pattern: /(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i, lookbehind: !0, inside: { punctuation: /[.\\]/ } }, keyword: /\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/, boolean: /\b(?:false|true)\b/, function: /\b\w+(?=\()/, number: /\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i, operator: /[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/, punctuation: /[{}[\];(),.:]/ }, o.languages.javascript = o.languages.extend("clike", { "class-name": [o.languages.clike["class-name"], { pattern: /(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/, lookbehind: !0 }], keyword: [{ pattern: /((?:^|\})\s*)catch\b/, lookbehind: !0 }, { pattern: /(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/, lookbehind: !0 }], function: /#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/, number: { pattern: RegExp(/(^|[^\w$])/.source + "(?:" + /NaN|Infinity/.source + "|" + /0[bB][01]+(?:_[01]+)*n?/.source + "|" + /0[oO][0-7]+(?:_[0-7]+)*n?/.source + "|" + /0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source + "|" + /\d+(?:_\d+)*n/.source + "|" + /(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source + ")" + /(?![\w$])/.source), lookbehind: !0 }, operator: /--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/ }), o.languages.javascript["class-name"][0].pattern = /(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/, o.languages.insertBefore("javascript", "keyword", { regex: { pattern: RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source + /\//.source + "(?:" + /(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source + "|" + /(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source + ")" + /(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source), lookbehind: !0, greedy: !0, inside: { "regex-source": { pattern: /^(\/)[\s\S]+(?=\/[a-z]*$)/, lookbehind: !0, alias: "language-regex", inside: o.languages.regex }, "regex-delimiter": /^\/|\/$/, "regex-flags": /^[a-z]+$/ } }, "function-variable": { pattern: /#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/, alias: "function" }, parameter: [{ pattern: /(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/, lookbehind: !0, inside: o.languages.javascript }, { pattern: /(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i, lookbehind: !0, inside: o.languages.javascript }, { pattern: /(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/, lookbehind: !0, inside: o.languages.javascript }, { pattern: /((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/, lookbehind: !0, inside: o.languages.javascript }], constant: /\b[A-Z](?:[A-Z_]|\dx?)*\b/ }), o.languages.insertBefore("javascript", "string", { hashbang: { pattern: /^#!.*/, greedy: !0, alias: "comment" }, "template-string": { pattern: /`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/, greedy: !0, inside: { "template-punctuation": { pattern: /^`|`$/, alias: "string" }, interpolation: { pattern: /((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/, lookbehind: !0, inside: { "interpolation-punctuation": { pattern: /^\$\{|\}$/, alias: "punctuation" }, rest: o.languages.javascript } }, string: /[\s\S]+/ } }, "string-property": { pattern: /((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m, lookbehind: !0, greedy: !0, alias: "property" } }), o.languages.insertBefore("javascript", "operator", { "literal-property": { pattern: /((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m, lookbehind: !0, alias: "property" } }), o.languages.markup && (o.languages.markup.tag.addInlined("script", "javascript"), o.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source, "javascript")), o.languages.js = o.languages.javascript, o.languages.actionscript = o.languages.extend("javascript", { keyword: /\b(?:as|break|case|catch|class|const|default|delete|do|dynamic|each|else|extends|final|finally|for|function|get|if|implements|import|in|include|instanceof|interface|internal|is|namespace|native|new|null|override|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|use|var|void|while|with)\b/, operator: /\+\+|--|(?:[+\-*\/%^]|&&?|\|\|?|<<?|>>?>?|[!=]=?)=?|[~?@]/ }), o.languages.actionscript["class-name"].alias = "function", delete o.languages.actionscript.parameter, delete o.languages.actionscript["literal-property"], o.languages.markup && o.languages.insertBefore("actionscript", "string", { xml: { pattern: /(^|[^.])<\/?\w+(?:\s+[^\s>\/=]+=("|')(?:\\[\s\S]|(?!\2)[^\\])*\2)*\s*\/?>/, lookbehind: !0, inside: o.languages.markup } }), function(e) {
|
|
554
554
|
var t = /#(?!\{).+/, a = { pattern: /#\{[^}]+\}/, alias: "variable" };
|
|
555
555
|
e.languages.coffeescript = e.languages.extend("javascript", { comment: t, string: [{ pattern: /'(?:\\[\s\S]|[^\\'])*'/, greedy: !0 }, { pattern: /"(?:\\[\s\S]|[^\\"])*"/, greedy: !0, inside: { interpolation: a } }], keyword: /\b(?:and|break|by|catch|class|continue|debugger|delete|do|each|else|extend|extends|false|finally|for|if|in|instanceof|is|isnt|let|loop|namespace|new|no|not|null|of|off|on|or|own|return|super|switch|then|this|throw|true|try|typeof|undefined|unless|until|when|while|window|with|yes|yield)\b/, "class-member": { pattern: /@(?!\d)\w+/, alias: "variable" } }), e.languages.insertBefore("coffeescript", "comment", { "multiline-comment": { pattern: /###[\s\S]+?###/, alias: "comment" }, "block-regex": { pattern: /\/{3}[\s\S]*?\/{3}/, alias: "regex", inside: { comment: t, interpolation: a } } }), e.languages.insertBefore("coffeescript", "string", { "inline-javascript": { pattern: /`(?:\\[\s\S]|[^\\`])*`/, inside: { delimiter: { pattern: /^`|`$/, alias: "punctuation" }, script: { pattern: /[\s\S]+/, alias: "language-javascript", inside: e.languages.javascript } } }, "multiline-string": [{ pattern: /'''[\s\S]*?'''/, greedy: !0, alias: "string" }, { pattern: /"""[\s\S]*?"""/, greedy: !0, alias: "string", inside: { interpolation: a } }] }), e.languages.insertBefore("coffeescript", "keyword", { property: /(?!\d)\w+(?=\s*:(?!:))/ }), delete e.languages.coffeescript["template-string"], e.languages.coffee = e.languages.coffeescript;
|
|
556
556
|
}(o), function(e) {
|
|
557
557
|
var t = e.languages.javadoclike = { parameter: { pattern: /(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*@(?:arg|arguments|param)\s+)\w+/m, lookbehind: !0 }, keyword: { pattern: /(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*|\{)@[a-z][a-zA-Z-]+\b/m, lookbehind: !0 }, punctuation: /[{}]/ };
|
|
558
|
-
Object.defineProperty(t, "addSupport", { value: function(a,
|
|
558
|
+
Object.defineProperty(t, "addSupport", { value: function(a, i) {
|
|
559
559
|
(a = typeof a == "string" ? [a] : a).forEach(function(p) {
|
|
560
|
-
var
|
|
561
|
-
y.inside || (y.inside = {}), y.inside.rest =
|
|
560
|
+
var h = function(y) {
|
|
561
|
+
y.inside || (y.inside = {}), y.inside.rest = i;
|
|
562
562
|
}, c = "doc-comment";
|
|
563
|
-
if (
|
|
564
|
-
var
|
|
565
|
-
if ((u = u || (
|
|
563
|
+
if (m = e.languages[p]) {
|
|
564
|
+
var m, u = m[c];
|
|
565
|
+
if ((u = u || (m = e.languages.insertBefore(p, "comment", { "doc-comment": { pattern: /(^|[^\\])\/\*\*[^/][\s\S]*?(?:\*\/|$)/, lookbehind: !0, alias: "comment" } }))[c]) instanceof RegExp && (u = m[c] = { pattern: u }), Array.isArray(u))
|
|
566
566
|
for (var g = 0, b = u.length; g < b; g++)
|
|
567
|
-
u[g] instanceof RegExp && (u[g] = { pattern: u[g] }),
|
|
567
|
+
u[g] instanceof RegExp && (u[g] = { pattern: u[g] }), h(u[g]);
|
|
568
568
|
else
|
|
569
|
-
|
|
569
|
+
h(u);
|
|
570
570
|
}
|
|
571
571
|
});
|
|
572
572
|
} }), t.addSupport(["java", "javascript", "php"], t);
|
|
@@ -577,25 +577,25 @@ o.languages.markup = { comment: { pattern: /<!--(?:(?!<!--)[\s\S])*?-->/, greedy
|
|
|
577
577
|
var t = /("|')(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/, t = (e.languages.css.selector = { pattern: e.languages.css.selector.pattern, lookbehind: !0, inside: t = { "pseudo-element": /:(?:after|before|first-letter|first-line|selection)|::[-\w]+/, "pseudo-class": /:[-\w]+/, class: /\.[-\w]+/, id: /#[-\w]+/, attribute: { pattern: RegExp(`\\[(?:[^[\\]"']|` + t.source + ")*\\]"), greedy: !0, inside: { punctuation: /^\[|\]$/, "case-sensitivity": { pattern: /(\s)[si]$/i, lookbehind: !0, alias: "keyword" }, namespace: { pattern: /^(\s*)(?:(?!\s)[-*\w\xA0-\uFFFF])*\|(?!=)/, lookbehind: !0, inside: { punctuation: /\|$/ } }, "attr-name": { pattern: /^(\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+/, lookbehind: !0 }, "attr-value": [t, { pattern: /(=\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+(?=\s*$)/, lookbehind: !0 }], operator: /[|~*^$]?=/ } }, "n-th": [{ pattern: /(\(\s*)[+-]?\d*[\dn](?:\s*[+-]\s*\d+)?(?=\s*\))/, lookbehind: !0, inside: { number: /[\dn]+/, operator: /[+-]/ } }, { pattern: /(\(\s*)(?:even|odd)(?=\s*\))/i, lookbehind: !0 }], combinator: />|\+|~|\|\|/, punctuation: /[(),]/ } }, e.languages.css.atrule.inside["selector-function-argument"].inside = t, e.languages.insertBefore("css", "property", { variable: { pattern: /(^|[^-\w\xA0-\uFFFF])--(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*/i, lookbehind: !0 } }), { pattern: /(\b\d+)(?:%|[a-z]+(?![\w-]))/, lookbehind: !0 }), a = { pattern: /(^|[^\w.-])-?(?:\d+(?:\.\d+)?|\.\d+)/, lookbehind: !0 };
|
|
578
578
|
e.languages.insertBefore("css", "function", { operator: { pattern: /(\s)[+\-*\/](?=\s)/, lookbehind: !0 }, hexcode: { pattern: /\B#[\da-f]{3,8}\b/i, alias: "color" }, color: [{ pattern: /(^|[^\w-])(?:AliceBlue|AntiqueWhite|Aqua|Aquamarine|Azure|Beige|Bisque|Black|BlanchedAlmond|Blue|BlueViolet|Brown|BurlyWood|CadetBlue|Chartreuse|Chocolate|Coral|CornflowerBlue|Cornsilk|Crimson|Cyan|DarkBlue|DarkCyan|DarkGoldenRod|DarkGr[ae]y|DarkGreen|DarkKhaki|DarkMagenta|DarkOliveGreen|DarkOrange|DarkOrchid|DarkRed|DarkSalmon|DarkSeaGreen|DarkSlateBlue|DarkSlateGr[ae]y|DarkTurquoise|DarkViolet|DeepPink|DeepSkyBlue|DimGr[ae]y|DodgerBlue|FireBrick|FloralWhite|ForestGreen|Fuchsia|Gainsboro|GhostWhite|Gold|GoldenRod|Gr[ae]y|Green|GreenYellow|HoneyDew|HotPink|IndianRed|Indigo|Ivory|Khaki|Lavender|LavenderBlush|LawnGreen|LemonChiffon|LightBlue|LightCoral|LightCyan|LightGoldenRodYellow|LightGr[ae]y|LightGreen|LightPink|LightSalmon|LightSeaGreen|LightSkyBlue|LightSlateGr[ae]y|LightSteelBlue|LightYellow|Lime|LimeGreen|Linen|Magenta|Maroon|MediumAquaMarine|MediumBlue|MediumOrchid|MediumPurple|MediumSeaGreen|MediumSlateBlue|MediumSpringGreen|MediumTurquoise|MediumVioletRed|MidnightBlue|MintCream|MistyRose|Moccasin|NavajoWhite|Navy|OldLace|Olive|OliveDrab|Orange|OrangeRed|Orchid|PaleGoldenRod|PaleGreen|PaleTurquoise|PaleVioletRed|PapayaWhip|PeachPuff|Peru|Pink|Plum|PowderBlue|Purple|RebeccaPurple|Red|RosyBrown|RoyalBlue|SaddleBrown|Salmon|SandyBrown|SeaGreen|SeaShell|Sienna|Silver|SkyBlue|SlateBlue|SlateGr[ae]y|Snow|SpringGreen|SteelBlue|Tan|Teal|Thistle|Tomato|Transparent|Turquoise|Violet|Wheat|White|WhiteSmoke|Yellow|YellowGreen)(?![\w-])/i, lookbehind: !0 }, { pattern: /\b(?:hsl|rgb)\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*\)\B|\b(?:hsl|rgb)a\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*,\s*(?:0|0?\.\d+|1)\s*\)\B/i, inside: { unit: t, number: a, function: /[\w-]+(?=\()/, punctuation: /[(),]/ } }], entity: /\\[\da-f]{1,8}/i, unit: t, number: a });
|
|
579
579
|
}(o), function(e) {
|
|
580
|
-
var t = /[*&][^\s[\]{},]+/, a = /!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,
|
|
580
|
+
var t = /[*&][^\s[\]{},]+/, a = /!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/, i = "(?:" + a.source + "(?:[ ]+" + t.source + ")?|" + t.source + "(?:[ ]+" + a.source + ")?)", p = /(?:[^\s\x00-\x08\x0e-\x1f!"#%&'*,\-:>?@[\]`{|}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]|[?:-]<PLAIN>)(?:[ \t]*(?:(?![#:])<PLAIN>|:<PLAIN>))*/.source.replace(/<PLAIN>/g, function() {
|
|
581
581
|
return /[^\s\x00-\x08\x0e-\x1f,[\]{}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]/.source;
|
|
582
|
-
}),
|
|
583
|
-
function c(
|
|
582
|
+
}), h = /"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/.source;
|
|
583
|
+
function c(m, u) {
|
|
584
584
|
u = (u || "").replace(/m/g, "") + "m";
|
|
585
585
|
var g = /([:\-,[{]\s*(?:\s<<prop>>[ \t]+)?)(?:<<value>>)(?=[ \t]*(?:$|,|\]|\}|(?:[\r\n]\s*)?#))/.source.replace(/<<prop>>/g, function() {
|
|
586
|
-
return
|
|
586
|
+
return i;
|
|
587
587
|
}).replace(/<<value>>/g, function() {
|
|
588
|
-
return
|
|
588
|
+
return m;
|
|
589
589
|
});
|
|
590
590
|
return RegExp(g, u);
|
|
591
591
|
}
|
|
592
592
|
e.languages.yaml = { scalar: { pattern: RegExp(/([\-:]\s*(?:\s<<prop>>[ \t]+)?[|>])[ \t]*(?:((?:\r?\n|\r)[ \t]+)\S[^\r\n]*(?:\2[^\r\n]+)*)/.source.replace(/<<prop>>/g, function() {
|
|
593
|
-
return
|
|
593
|
+
return i;
|
|
594
594
|
})), lookbehind: !0, alias: "string" }, comment: /#.*/, key: { pattern: RegExp(/((?:^|[:\-,[{\r\n?])[ \t]*(?:<<prop>>[ \t]+)?)<<key>>(?=\s*:\s)/.source.replace(/<<prop>>/g, function() {
|
|
595
|
-
return
|
|
595
|
+
return i;
|
|
596
596
|
}).replace(/<<key>>/g, function() {
|
|
597
|
-
return "(?:" + p + "|" +
|
|
598
|
-
})), lookbehind: !0, greedy: !0, alias: "atrule" }, directive: { pattern: /(^[ \t]*)%.+/m, lookbehind: !0, alias: "important" }, datetime: { pattern: c(/\d{4}-\d\d?-\d\d?(?:[tT]|[ \t]+)\d\d?:\d{2}:\d{2}(?:\.\d*)?(?:[ \t]*(?:Z|[-+]\d\d?(?::\d{2})?))?|\d{4}-\d{2}-\d{2}|\d\d?:\d{2}(?::\d{2}(?:\.\d*)?)?/.source), lookbehind: !0, alias: "number" }, boolean: { pattern: c(/false|true/.source, "i"), lookbehind: !0, alias: "important" }, null: { pattern: c(/null|~/.source, "i"), lookbehind: !0, alias: "important" }, string: { pattern: c(
|
|
597
|
+
return "(?:" + p + "|" + h + ")";
|
|
598
|
+
})), lookbehind: !0, greedy: !0, alias: "atrule" }, directive: { pattern: /(^[ \t]*)%.+/m, lookbehind: !0, alias: "important" }, datetime: { pattern: c(/\d{4}-\d\d?-\d\d?(?:[tT]|[ \t]+)\d\d?:\d{2}:\d{2}(?:\.\d*)?(?:[ \t]*(?:Z|[-+]\d\d?(?::\d{2})?))?|\d{4}-\d{2}-\d{2}|\d\d?:\d{2}(?::\d{2}(?:\.\d*)?)?/.source), lookbehind: !0, alias: "number" }, boolean: { pattern: c(/false|true/.source, "i"), lookbehind: !0, alias: "important" }, null: { pattern: c(/null|~/.source, "i"), lookbehind: !0, alias: "important" }, string: { pattern: c(h), lookbehind: !0, greedy: !0 }, number: { pattern: c(/[+-]?(?:0x[\da-f]+|0o[0-7]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|\.inf|\.nan)/.source, "i"), lookbehind: !0 }, tag: a, important: t, punctuation: /---|[:[\]{}\-,|>?]|\.\.\./ }, e.languages.yml = e.languages.yaml;
|
|
599
599
|
}(o), function(e) {
|
|
600
600
|
var t = /(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;
|
|
601
601
|
function a(g) {
|
|
@@ -603,9 +603,9 @@ o.languages.markup = { comment: { pattern: /<!--(?:(?!<!--)[\s\S])*?-->/, greedy
|
|
|
603
603
|
return t;
|
|
604
604
|
}), RegExp(/((?:^|[^\\])(?:\\{2})*)/.source + "(?:" + g + ")");
|
|
605
605
|
}
|
|
606
|
-
var
|
|
607
|
-
return
|
|
608
|
-
}),
|
|
606
|
+
var i = /(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source, p = /\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g, function() {
|
|
607
|
+
return i;
|
|
608
|
+
}), h = /\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source, c = (e.languages.markdown = e.languages.extend("markup", {}), e.languages.insertBefore("markdown", "prolog", { "front-matter-block": { pattern: /(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/, lookbehind: !0, greedy: !0, inside: { punctuation: /^---|---$/, "front-matter": { pattern: /\S+(?:\s+\S+)*/, alias: ["yaml", "language-yaml"], inside: e.languages.yaml } } }, blockquote: { pattern: /^>(?:[\t ]*>)*/m, alias: "punctuation" }, table: { pattern: RegExp("^" + p + h + "(?:" + p + ")*", "m"), inside: { "table-data-rows": { pattern: RegExp("^(" + p + h + ")(?:" + p + ")*$"), lookbehind: !0, inside: { "table-data": { pattern: RegExp(i), inside: e.languages.markdown }, punctuation: /\|/ } }, "table-line": { pattern: RegExp("^(" + p + ")" + h + "$"), lookbehind: !0, inside: { punctuation: /\||:?-{3,}:?/ } }, "table-header-row": { pattern: RegExp("^" + p + "$"), inside: { "table-header": { pattern: RegExp(i), alias: "important", inside: e.languages.markdown }, punctuation: /\|/ } } } }, code: [{ pattern: /((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/, lookbehind: !0, alias: "keyword" }, { pattern: /^```[\s\S]*?^```$/m, greedy: !0, inside: { "code-block": { pattern: /^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m, lookbehind: !0 }, "code-language": { pattern: /^(```).+/, lookbehind: !0 }, punctuation: /```/ } }], title: [{ pattern: /\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m, alias: "important", inside: { punctuation: /==+$|--+$/ } }, { pattern: /(^\s*)#.+/m, lookbehind: !0, alias: "important", inside: { punctuation: /^#+|#+$/ } }], hr: { pattern: /(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m, lookbehind: !0, alias: "punctuation" }, list: { pattern: /(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m, lookbehind: !0, alias: "punctuation" }, "url-reference": { pattern: /!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/, inside: { variable: { pattern: /^(!?\[)[^\]]+/, lookbehind: !0 }, string: /(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/, punctuation: /^[\[\]!:]|[<>]/ }, alias: "url" }, bold: { pattern: a(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source), lookbehind: !0, greedy: !0, inside: { content: { pattern: /(^..)[\s\S]+(?=..$)/, lookbehind: !0, inside: {} }, punctuation: /\*\*|__/ } }, italic: { pattern: a(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source), lookbehind: !0, greedy: !0, inside: { content: { pattern: /(^.)[\s\S]+(?=.$)/, lookbehind: !0, inside: {} }, punctuation: /[*_]/ } }, strike: { pattern: a(/(~~?)(?:(?!~)<inner>)+\2/.source), lookbehind: !0, greedy: !0, inside: { content: { pattern: /(^~~?)[\s\S]+(?=\1$)/, lookbehind: !0, inside: {} }, punctuation: /~~?/ } }, "code-snippet": { pattern: /(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/, lookbehind: !0, greedy: !0, alias: ["code", "keyword"] }, url: { pattern: a(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source), lookbehind: !0, greedy: !0, inside: { operator: /^!/, content: { pattern: /(^\[)[^\]]+(?=\])/, lookbehind: !0, inside: {} }, variable: { pattern: /(^\][ \t]?\[)[^\]]+(?=\]$)/, lookbehind: !0 }, url: { pattern: /(^\]\()[^\s)]+/, lookbehind: !0 }, string: { pattern: /(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/, lookbehind: !0 } } } }), ["url", "bold", "italic", "strike"].forEach(function(g) {
|
|
609
609
|
["url", "bold", "italic", "strike", "code-snippet"].forEach(function(b) {
|
|
610
610
|
g !== b && (e.languages.markdown[g].inside.content.inside[b] = e.languages.markdown[b]);
|
|
611
611
|
});
|
|
@@ -628,40 +628,40 @@ o.languages.markup = { comment: { pattern: /<!--(?:(?!<!--)[\s\S])*?-->/, greedy
|
|
|
628
628
|
}
|
|
629
629
|
var n, r = e.languages[b];
|
|
630
630
|
r ? g.content = e.highlight(function(s) {
|
|
631
|
-
return s = s.replace(c, ""), s = s.replace(/&(\w{1,8}|#x?[\da-f]{1,8});/gi, function(d,
|
|
631
|
+
return s = s.replace(c, ""), s = s.replace(/&(\w{1,8}|#x?[\da-f]{1,8});/gi, function(d, l) {
|
|
632
632
|
var f;
|
|
633
|
-
return (
|
|
633
|
+
return (l = l.toLowerCase())[0] === "#" ? (f = l[1] === "x" ? parseInt(l.slice(2), 16) : Number(l.slice(1)), u(f)) : m[l] || d;
|
|
634
634
|
});
|
|
635
635
|
}(g.content), r, b) : b && b !== "none" && e.plugins.autoloader && (n = "md-" + (/* @__PURE__ */ new Date()).valueOf() + "-" + Math.floor(1e16 * Math.random()), g.attributes.id = n, e.plugins.autoloader.loadLanguages(b, function() {
|
|
636
636
|
var s = document.getElementById(n);
|
|
637
637
|
s && (s.innerHTML = e.highlight(s.textContent, e.languages[b], b));
|
|
638
638
|
}));
|
|
639
639
|
}
|
|
640
|
-
}), RegExp(e.languages.markup.tag.pattern.source, "gi")),
|
|
640
|
+
}), RegExp(e.languages.markup.tag.pattern.source, "gi")), m = { amp: "&", lt: "<", gt: ">", quot: '"' }, u = String.fromCodePoint || String.fromCharCode;
|
|
641
641
|
e.languages.md = e.languages.markdown;
|
|
642
642
|
}(o), o.languages.graphql = { comment: /#.*/, description: { pattern: /(?:"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*")(?=\s*[a-z_])/i, greedy: !0, alias: "string", inside: { "language-markdown": { pattern: /(^"(?:"")?)(?!\1)[\s\S]+(?=\1$)/, lookbehind: !0, inside: o.languages.markdown } } }, string: { pattern: /"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*"/, greedy: !0 }, number: /(?:\B-|\b)\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i, boolean: /\b(?:false|true)\b/, variable: /\$[a-z_]\w*/i, directive: { pattern: /@[a-z_]\w*/i, alias: "function" }, "attr-name": { pattern: /\b[a-z_]\w*(?=\s*(?:\((?:[^()"]|"(?:\\.|[^\\"\r\n])*")*\))?:)/i, greedy: !0 }, "atom-input": { pattern: /\b[A-Z]\w*Input\b/, alias: "class-name" }, scalar: /\b(?:Boolean|Float|ID|Int|String)\b/, constant: /\b[A-Z][A-Z_\d]*\b/, "class-name": { pattern: /(\b(?:enum|implements|interface|on|scalar|type|union)\s+|&\s*|:\s*|\[)[A-Z_]\w*/, lookbehind: !0 }, fragment: { pattern: /(\bfragment\s+|\.{3}\s*(?!on\b))[a-zA-Z_]\w*/, lookbehind: !0, alias: "function" }, "definition-mutation": { pattern: /(\bmutation\s+)[a-zA-Z_]\w*/, lookbehind: !0, alias: "function" }, "definition-query": { pattern: /(\bquery\s+)[a-zA-Z_]\w*/, lookbehind: !0, alias: "function" }, keyword: /\b(?:directive|enum|extend|fragment|implements|input|interface|mutation|on|query|repeatable|scalar|schema|subscription|type|union)\b/, operator: /[!=|&]|\.{3}/, "property-query": /\w+(?=\s*\()/, object: /\w+(?=\s*\{)/, punctuation: /[!(){}\[\]:=,]/, property: /\w+/ }, o.hooks.add("after-tokenize", function(e) {
|
|
643
643
|
if (e.language === "graphql")
|
|
644
644
|
for (var t = e.tokens.filter(function(n) {
|
|
645
645
|
return typeof n != "string" && n.type !== "comment" && n.type !== "scalar";
|
|
646
646
|
}), a = 0; a < t.length; ) {
|
|
647
|
-
var
|
|
648
|
-
if (
|
|
647
|
+
var i = t[a++];
|
|
648
|
+
if (i.type === "keyword" && i.content === "mutation") {
|
|
649
649
|
var p = [];
|
|
650
650
|
if (y(["definition-mutation", "punctuation"]) && b(1).content === "(") {
|
|
651
651
|
a += 2;
|
|
652
|
-
var
|
|
653
|
-
if (
|
|
652
|
+
var h = v(/^\($/, /^\)$/);
|
|
653
|
+
if (h === -1)
|
|
654
654
|
continue;
|
|
655
|
-
for (; a <
|
|
655
|
+
for (; a < h; a++) {
|
|
656
656
|
var c = b(0);
|
|
657
657
|
c.type === "variable" && (k(c, "variable-input"), p.push(c.content));
|
|
658
658
|
}
|
|
659
|
-
a =
|
|
659
|
+
a = h + 1;
|
|
660
660
|
}
|
|
661
661
|
if (y(["punctuation", "property-query"]) && b(0).content === "{" && (a++, k(b(0), "property-mutation"), 0 < p.length)) {
|
|
662
|
-
var
|
|
663
|
-
if (
|
|
664
|
-
for (var u = a; u <
|
|
662
|
+
var m = v(/^\{$/, /^\}$/);
|
|
663
|
+
if (m !== -1)
|
|
664
|
+
for (var u = a; u < m; u++) {
|
|
665
665
|
var g = t[u];
|
|
666
666
|
g.type === "variable" && 0 <= p.indexOf(g.content) && k(g, "variable-input");
|
|
667
667
|
}
|
|
@@ -682,8 +682,8 @@ o.languages.markup = { comment: { pattern: /<!--(?:(?!<!--)[\s\S])*?-->/, greedy
|
|
|
682
682
|
}
|
|
683
683
|
function v(n, r) {
|
|
684
684
|
for (var s = 1, d = a; d < t.length; d++) {
|
|
685
|
-
var
|
|
686
|
-
if (
|
|
685
|
+
var l = t[d], f = l.content;
|
|
686
|
+
if (l.type === "punctuation" && typeof f == "string") {
|
|
687
687
|
if (n.test(f))
|
|
688
688
|
s++;
|
|
689
689
|
else if (r.test(f) && --s === 0)
|
|
@@ -697,28 +697,28 @@ o.languages.markup = { comment: { pattern: /<!--(?:(?!<!--)[\s\S])*?-->/, greedy
|
|
|
697
697
|
s ? Array.isArray(s) || (n.alias = s = [s]) : n.alias = s = [], s.push(r);
|
|
698
698
|
}
|
|
699
699
|
}), o.languages.sql = { comment: { pattern: /(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/, lookbehind: !0 }, variable: [{ pattern: /@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/, greedy: !0 }, /@[\w.$]+/], string: { pattern: /(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/, greedy: !0, lookbehind: !0 }, identifier: { pattern: /(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/, greedy: !0, lookbehind: !0, inside: { punctuation: /^`|`$/ } }, function: /\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i, keyword: /\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i, boolean: /\b(?:FALSE|NULL|TRUE)\b/i, number: /\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i, operator: /[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i, punctuation: /[;[\]()`,.]/ }, function(e) {
|
|
700
|
-
var t = e.languages.javascript["template-string"], a = t.pattern.source,
|
|
700
|
+
var t = e.languages.javascript["template-string"], a = t.pattern.source, i = t.inside.interpolation, p = i.inside["interpolation-punctuation"], h = i.pattern.source;
|
|
701
701
|
function c(y, v) {
|
|
702
702
|
if (e.languages[y])
|
|
703
703
|
return { pattern: RegExp("((?:" + v + ")\\s*)" + a), lookbehind: !0, greedy: !0, inside: { "template-punctuation": { pattern: /^`|`$/, alias: "string" }, "embedded-code": { pattern: /[\s\S]+/, alias: y } } };
|
|
704
704
|
}
|
|
705
|
-
function
|
|
705
|
+
function m(y, v, k) {
|
|
706
706
|
return y = { code: y, grammar: v, language: k }, e.hooks.run("before-tokenize", y), y.tokens = e.tokenize(y.code, y.grammar), e.hooks.run("after-tokenize", y), y.tokens;
|
|
707
707
|
}
|
|
708
708
|
function u(y, v, k) {
|
|
709
|
-
var s = e.tokenize(y, { interpolation: { pattern: RegExp(
|
|
710
|
-
if (typeof
|
|
711
|
-
return
|
|
712
|
-
for (var f, E,
|
|
709
|
+
var s = e.tokenize(y, { interpolation: { pattern: RegExp(h), lookbehind: !0 } }), n = 0, r = {}, s = m(s.map(function(l) {
|
|
710
|
+
if (typeof l == "string")
|
|
711
|
+
return l;
|
|
712
|
+
for (var f, E, l = l.content; y.indexOf((E = n++, f = "___" + k.toUpperCase() + "_" + E + "___")) !== -1; )
|
|
713
713
|
;
|
|
714
|
-
return r[f] =
|
|
714
|
+
return r[f] = l, f;
|
|
715
715
|
}).join(""), v, k), d = Object.keys(r);
|
|
716
|
-
return n = 0, function
|
|
716
|
+
return n = 0, function l(f) {
|
|
717
717
|
for (var E = 0; E < f.length; E++) {
|
|
718
718
|
if (n >= d.length)
|
|
719
719
|
return;
|
|
720
720
|
var w, x, S, F, A, C, T, O = f[E];
|
|
721
|
-
typeof O == "string" || typeof O.content == "string" ? (w = d[n], (T = (C = typeof O == "string" ? O : O.content).indexOf(w)) !== -1 && (++n, x = C.substring(0, T), A = r[w], S = void 0, (F = {})["interpolation-punctuation"] = p, (F = e.tokenize(A, F)).length === 3 && ((S = [1, 1]).push.apply(S,
|
|
721
|
+
typeof O == "string" || typeof O.content == "string" ? (w = d[n], (T = (C = typeof O == "string" ? O : O.content).indexOf(w)) !== -1 && (++n, x = C.substring(0, T), A = r[w], S = void 0, (F = {})["interpolation-punctuation"] = p, (F = e.tokenize(A, F)).length === 3 && ((S = [1, 1]).push.apply(S, m(F[1], e.languages.javascript, "javascript")), F.splice.apply(F, S)), S = new e.Token("interpolation", F, i.alias, A), F = C.substring(T + w.length), A = [], x && A.push(x), A.push(S), F && (l(C = [F]), A.push.apply(A, C)), typeof O == "string" ? (f.splice.apply(f, [E, 1].concat(A)), E += A.length - 1) : O.content = A)) : (T = O.content, Array.isArray(T) ? l(T) : l([T]));
|
|
722
722
|
}
|
|
723
723
|
}(s), new e.Token(k, s, "language-" + k, y);
|
|
724
724
|
}
|
|
@@ -730,8 +730,8 @@ o.languages.markup = { comment: { pattern: /<!--(?:(?!<!--)[\s\S])*?-->/, greedy
|
|
|
730
730
|
e.hooks.add("after-tokenize", function(y) {
|
|
731
731
|
y.language in g && function v(k) {
|
|
732
732
|
for (var n = 0, r = k.length; n < r; n++) {
|
|
733
|
-
var s, d,
|
|
734
|
-
typeof f != "string" && (s = f.content, Array.isArray(s) ? f.type === "template-string" ? (f = s[1], s.length === 3 && typeof f != "string" && f.type === "embedded-code" && (d = b(f), f = f.alias, f = Array.isArray(f) ? f[0] : f,
|
|
733
|
+
var s, d, l, f = k[n];
|
|
734
|
+
typeof f != "string" && (s = f.content, Array.isArray(s) ? f.type === "template-string" ? (f = s[1], s.length === 3 && typeof f != "string" && f.type === "embedded-code" && (d = b(f), f = f.alias, f = Array.isArray(f) ? f[0] : f, l = e.languages[f]) && (s[1] = u(d, l, f))) : v(s) : typeof s != "string" && v([s]));
|
|
735
735
|
}
|
|
736
736
|
}(y.tokens);
|
|
737
737
|
});
|
|
@@ -740,43 +740,43 @@ o.languages.markup = { comment: { pattern: /<!--(?:(?!<!--)[\s\S])*?-->/, greedy
|
|
|
740
740
|
var t = e.languages.extend("typescript", {});
|
|
741
741
|
delete t["class-name"], e.languages.typescript["class-name"].inside = t, e.languages.insertBefore("typescript", "function", { decorator: { pattern: /@[$\w\xA0-\uFFFF]+/, inside: { at: { pattern: /^@/, alias: "operator" }, function: /^[\s\S]+/ } }, "generic-function": { pattern: /#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/, greedy: !0, inside: { function: /^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/, generic: { pattern: /<[\s\S]+/, alias: "class-name", inside: t } } } }), e.languages.ts = e.languages.typescript;
|
|
742
742
|
}(o), function(e) {
|
|
743
|
-
var t = e.languages.javascript, a = /\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})+\}/.source,
|
|
744
|
-
e.languages.jsdoc = e.languages.extend("javadoclike", { parameter: { pattern: RegExp(
|
|
743
|
+
var t = e.languages.javascript, a = /\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})+\}/.source, i = "(@(?:arg|argument|param|property)\\s+(?:" + a + "\\s+)?)";
|
|
744
|
+
e.languages.jsdoc = e.languages.extend("javadoclike", { parameter: { pattern: RegExp(i + /(?:(?!\s)[$\w\xA0-\uFFFF.])+(?=\s|$)/.source), lookbehind: !0, inside: { punctuation: /\./ } } }), e.languages.insertBefore("jsdoc", "keyword", { "optional-parameter": { pattern: RegExp(i + /\[(?:(?!\s)[$\w\xA0-\uFFFF.])+(?:=[^[\]]+)?\](?=\s|$)/.source), lookbehind: !0, inside: { parameter: { pattern: /(^\[)[$\w\xA0-\uFFFF\.]+/, lookbehind: !0, inside: { punctuation: /\./ } }, code: { pattern: /(=)[\s\S]*(?=\]$)/, lookbehind: !0, inside: t, alias: "language-javascript" }, punctuation: /[=[\]]/ } }, "class-name": [{ pattern: RegExp(/(@(?:augments|class|extends|interface|memberof!?|template|this|typedef)\s+(?:<TYPE>\s+)?)[A-Z]\w*(?:\.[A-Z]\w*)*/.source.replace(/<TYPE>/g, function() {
|
|
745
745
|
return a;
|
|
746
746
|
})), lookbehind: !0, inside: { punctuation: /\./ } }, { pattern: RegExp("(@[a-z]+\\s+)" + a), lookbehind: !0, inside: { string: t.string, number: t.number, boolean: t.boolean, keyword: e.languages.typescript.keyword, operator: /=>|\.\.\.|[&|?:*]/, punctuation: /[.,;=<>{}()[\]]/ } }], example: { pattern: /(@example\s+(?!\s))(?:[^@\s]|\s+(?!\s))+?(?=\s*(?:\*\s*)?(?:@\w|\*\/))/, lookbehind: !0, inside: { code: { pattern: /^([\t ]*(?:\*\s*)?)\S.*$/m, lookbehind: !0, inside: t, alias: "language-javascript" } } } }), e.languages.javadoclike.addSupport("javascript", e.languages.jsdoc);
|
|
747
747
|
}(o), function(e) {
|
|
748
748
|
e.languages.flow = e.languages.extend("javascript", {}), e.languages.insertBefore("flow", "keyword", { type: [{ pattern: /\b(?:[Bb]oolean|Function|[Nn]umber|[Ss]tring|[Ss]ymbol|any|mixed|null|void)\b/, alias: "class-name" }] }), e.languages.flow["function-variable"].pattern = /(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=\s*(?:function\b|(?:\([^()]*\)(?:\s*:\s*\w+)?|(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/i, delete e.languages.flow.parameter, e.languages.insertBefore("flow", "operator", { "flow-punctuation": { pattern: /\{\||\|\}/, alias: "punctuation" } }), Array.isArray(e.languages.flow.keyword) || (e.languages.flow.keyword = [e.languages.flow.keyword]), e.languages.flow.keyword.unshift({ pattern: /(^|[^$]\b)(?:Class|declare|opaque|type)\b(?!\$)/, lookbehind: !0 }, { pattern: /(^|[^$]\B)\$(?:Diff|Enum|Exact|Keys|ObjMap|PropertyType|Record|Shape|Subtype|Supertype|await)\b(?!\$)/, lookbehind: !0 });
|
|
749
749
|
}(o), o.languages.n4js = o.languages.extend("javascript", { keyword: /\b(?:Array|any|boolean|break|case|catch|class|const|constructor|continue|debugger|declare|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|module|new|null|number|package|private|protected|public|return|set|static|string|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/ }), o.languages.insertBefore("n4js", "constant", { annotation: { pattern: /@+\w+/, alias: "operator" } }), o.languages.n4jsd = o.languages.n4js, function(e) {
|
|
750
|
-
function t(c,
|
|
750
|
+
function t(c, m) {
|
|
751
751
|
return RegExp(c.replace(/<ID>/g, function() {
|
|
752
752
|
return /(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/.source;
|
|
753
|
-
}),
|
|
753
|
+
}), m);
|
|
754
754
|
}
|
|
755
755
|
e.languages.insertBefore("javascript", "function-variable", { "method-variable": { pattern: RegExp("(\\.\\s*)" + e.languages.javascript["function-variable"].pattern.source), lookbehind: !0, alias: ["function-variable", "method", "function", "property-access"] } }), e.languages.insertBefore("javascript", "function", { method: { pattern: RegExp("(\\.\\s*)" + e.languages.javascript.function.source), lookbehind: !0, alias: ["function", "property-access"] } }), e.languages.insertBefore("javascript", "constant", { "known-class-name": [{ pattern: /\b(?:(?:Float(?:32|64)|(?:Int|Uint)(?:8|16|32)|Uint8Clamped)?Array|ArrayBuffer|BigInt|Boolean|DataView|Date|Error|Function|Intl|JSON|(?:Weak)?(?:Map|Set)|Math|Number|Object|Promise|Proxy|Reflect|RegExp|String|Symbol|WebAssembly)\b/, alias: "class-name" }, { pattern: /\b(?:[A-Z]\w*)Error\b/, alias: "class-name" }] }), e.languages.insertBefore("javascript", "keyword", { imports: { pattern: t(/(\bimport\b\s*)(?:<ID>(?:\s*,\s*(?:\*\s*as\s+<ID>|\{[^{}]*\}))?|\*\s*as\s+<ID>|\{[^{}]*\})(?=\s*\bfrom\b)/.source), lookbehind: !0, inside: e.languages.javascript }, exports: { pattern: t(/(\bexport\b\s*)(?:\*(?:\s*as\s+<ID>)?(?=\s*\bfrom\b)|\{[^{}]*\})/.source), lookbehind: !0, inside: e.languages.javascript } }), e.languages.javascript.keyword.unshift({ pattern: /\b(?:as|default|export|from|import)\b/, alias: "module" }, { pattern: /\b(?:await|break|catch|continue|do|else|finally|for|if|return|switch|throw|try|while|yield)\b/, alias: "control-flow" }, { pattern: /\bnull\b/, alias: ["null", "nil"] }, { pattern: /\bundefined\b/, alias: "nil" }), e.languages.insertBefore("javascript", "operator", { spread: { pattern: /\.{3}/, alias: "operator" }, arrow: { pattern: /=>/, alias: "operator" } }), e.languages.insertBefore("javascript", "punctuation", { "property-access": { pattern: t(/(\.\s*)#?<ID>/.source), lookbehind: !0 }, "maybe-class-name": { pattern: /(^|[^$\w\xA0-\uFFFF])[A-Z][$\w\xA0-\uFFFF]+/, lookbehind: !0 }, dom: { pattern: /\b(?:document|(?:local|session)Storage|location|navigator|performance|window)\b/, alias: "variable" }, console: { pattern: /\bconsole(?=\s*\.)/, alias: "class-name" } });
|
|
756
|
-
for (var a = ["function", "function-variable", "method", "method-variable", "property-access"],
|
|
757
|
-
var
|
|
758
|
-
(p.inside =
|
|
756
|
+
for (var a = ["function", "function-variable", "method", "method-variable", "property-access"], i = 0; i < a.length; i++) {
|
|
757
|
+
var h = a[i], p = e.languages.javascript[h], h = (p = e.util.type(p) === "RegExp" ? e.languages.javascript[h] = { pattern: p } : p).inside || {};
|
|
758
|
+
(p.inside = h)["maybe-class-name"] = /^[A-Z][\s\S]*/;
|
|
759
759
|
}
|
|
760
760
|
}(o), function(e) {
|
|
761
|
-
var t = e.util.clone(e.languages.javascript), a = /(?:\s|\/\/.*(?!.)|\/\*(?:[^*]|\*(?!\/))\*\/)/.source,
|
|
762
|
-
function
|
|
761
|
+
var t = e.util.clone(e.languages.javascript), a = /(?:\s|\/\/.*(?!.)|\/\*(?:[^*]|\*(?!\/))\*\/)/.source, i = /(?:\{(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])*\})/.source, p = /(?:\{<S>*\.{3}(?:[^{}]|<BRACES>)*\})/.source;
|
|
762
|
+
function h(u, g) {
|
|
763
763
|
return u = u.replace(/<S>/g, function() {
|
|
764
764
|
return a;
|
|
765
765
|
}).replace(/<BRACES>/g, function() {
|
|
766
|
-
return
|
|
766
|
+
return i;
|
|
767
767
|
}).replace(/<SPREAD>/g, function() {
|
|
768
768
|
return p;
|
|
769
769
|
}), RegExp(u, g);
|
|
770
770
|
}
|
|
771
|
-
p =
|
|
771
|
+
p = h(p).source, e.languages.jsx = e.languages.extend("markup", t), e.languages.jsx.tag.pattern = h(/<\/?(?:[\w.:-]+(?:<S>+(?:[\w.:$-]+(?:=(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s{'"/>=]+|<BRACES>))?|<SPREAD>))*<S>*\/?)?>/.source), e.languages.jsx.tag.inside.tag.pattern = /^<\/?[^\s>\/]*/, e.languages.jsx.tag.inside["attr-value"].pattern = /=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/, e.languages.jsx.tag.inside.tag.inside["class-name"] = /^[A-Z]\w*(?:\.[A-Z]\w*)*$/, e.languages.jsx.tag.inside.comment = t.comment, e.languages.insertBefore("inside", "attr-name", { spread: { pattern: h(/<SPREAD>/.source), inside: e.languages.jsx } }, e.languages.jsx.tag), e.languages.insertBefore("inside", "special-attr", { script: { pattern: h(/=<BRACES>/.source), alias: "language-javascript", inside: { "script-punctuation": { pattern: /^=(?=\{)/, alias: "punctuation" }, rest: e.languages.jsx } } }, e.languages.jsx.tag);
|
|
772
772
|
function c(u) {
|
|
773
773
|
for (var g = [], b = 0; b < u.length; b++) {
|
|
774
774
|
var y = u[b], v = !1;
|
|
775
|
-
typeof y != "string" && (y.type === "tag" && y.content[0] && y.content[0].type === "tag" ? y.content[0].content[0].content === "</" ? 0 < g.length && g[g.length - 1].tagName ===
|
|
775
|
+
typeof y != "string" && (y.type === "tag" && y.content[0] && y.content[0].type === "tag" ? y.content[0].content[0].content === "</" ? 0 < g.length && g[g.length - 1].tagName === m(y.content[0].content[1]) && g.pop() : y.content[y.content.length - 1].content !== "/>" && g.push({ tagName: m(y.content[0].content[1]), openedBraces: 0 }) : 0 < g.length && y.type === "punctuation" && y.content === "{" ? g[g.length - 1].openedBraces++ : 0 < g.length && 0 < g[g.length - 1].openedBraces && y.type === "punctuation" && y.content === "}" ? g[g.length - 1].openedBraces-- : v = !0), (v || typeof y == "string") && 0 < g.length && g[g.length - 1].openedBraces === 0 && (v = m(y), b < u.length - 1 && (typeof u[b + 1] == "string" || u[b + 1].type === "plain-text") && (v += m(u[b + 1]), u.splice(b + 1, 1)), 0 < b && (typeof u[b - 1] == "string" || u[b - 1].type === "plain-text") && (v = m(u[b - 1]) + v, u.splice(b - 1, 1), b--), u[b] = new e.Token("plain-text", v, null, v)), y.content && typeof y.content != "string" && c(y.content);
|
|
776
776
|
}
|
|
777
777
|
}
|
|
778
|
-
var
|
|
779
|
-
return u ? typeof u == "string" ? u : typeof u.content == "string" ? u.content : u.content.map(
|
|
778
|
+
var m = function(u) {
|
|
779
|
+
return u ? typeof u == "string" ? u : typeof u.content == "string" ? u.content : u.content.map(m).join("") : "";
|
|
780
780
|
};
|
|
781
781
|
e.hooks.add("after-tokenize", function(u) {
|
|
782
782
|
u.language !== "jsx" && u.language !== "tsx" || c(u.tokens);
|
|
@@ -808,30 +808,30 @@ o.languages.markup = { comment: { pattern: /<!--(?:(?!<!--)[\s\S])*?-->/, greedy
|
|
|
808
808
|
return a;
|
|
809
809
|
}) + ")"), lookbehind: !0, greedy: !0, inside: { string: /^[<"][\s\S]+/, operator: /:/, punctuation: /\./ } }, "raw-string": { pattern: /R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/, alias: "string", greedy: !0 } }), e.languages.insertBefore("cpp", "keyword", { "generic-function": { pattern: /\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i, inside: { function: /^\w+/, generic: { pattern: /<[\s\S]+/, alias: "class-name", inside: e.languages.cpp } } } }), e.languages.insertBefore("cpp", "operator", { "double-colon": { pattern: /::/, alias: "punctuation" } }), e.languages.insertBefore("cpp", "class-name", { "base-clause": { pattern: /(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/, lookbehind: !0, greedy: !0, inside: e.languages.extend("cpp", {}) } }), e.languages.insertBefore("inside", "double-colon", { "class-name": /\b[a-z_]\w*\b(?!\s*::)/i }, e.languages.cpp["base-clause"]);
|
|
810
810
|
}(o), o.languages.python = { comment: { pattern: /(^|[^\\])#.*/, lookbehind: !0, greedy: !0 }, "string-interpolation": { pattern: /(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i, greedy: !0, inside: { interpolation: { pattern: /((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/, lookbehind: !0, inside: { "format-spec": { pattern: /(:)[^:(){}]+(?=\}$)/, lookbehind: !0 }, "conversion-option": { pattern: //, alias: "punctuation" }, rest: null } }, string: /[\s\S]+/ } }, "triple-quoted-string": { pattern: /(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i, greedy: !0, alias: "string" }, string: { pattern: /(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i, greedy: !0 }, function: { pattern: /((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g, lookbehind: !0 }, "class-name": { pattern: /(\bclass\s+)\w+/i, lookbehind: !0 }, decorator: { pattern: /(^[\t ]*)@\w+(?:\.\w+)*/m, lookbehind: !0, alias: ["annotation", "punctuation"], inside: { punctuation: /\./ } }, keyword: /\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/, builtin: /\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/, boolean: /\b(?:False|None|True)\b/, number: /\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i, operator: /[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/, punctuation: /[{}[\];(),.:]/ }, o.languages.python["string-interpolation"].inside.interpolation.inside.rest = o.languages.python, o.languages.py = o.languages.python, o.languages.json = { property: { pattern: /(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/, lookbehind: !0, greedy: !0 }, string: { pattern: /(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/, lookbehind: !0, greedy: !0 }, comment: { pattern: /\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/, greedy: !0 }, number: /-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i, punctuation: /[{}[\],]/, operator: /:/, boolean: /\b(?:false|true)\b/, null: { pattern: /\bnull\b/, alias: "keyword" } }, o.languages.webmanifest = o.languages.json;
|
|
811
|
-
var
|
|
812
|
-
|
|
813
|
-
dracula: () =>
|
|
814
|
-
duotoneDark: () =>
|
|
815
|
-
duotoneLight: () =>
|
|
816
|
-
github: () =>
|
|
817
|
-
gruvboxMaterialDark: () =>
|
|
818
|
-
gruvboxMaterialLight: () =>
|
|
819
|
-
jettwaveDark: () =>
|
|
820
|
-
jettwaveLight: () =>
|
|
821
|
-
nightOwl: () =>
|
|
822
|
-
nightOwlLight: () =>
|
|
823
|
-
oceanicNext: () =>
|
|
824
|
-
okaidia: () =>
|
|
825
|
-
oneDark: () =>
|
|
826
|
-
oneLight: () =>
|
|
827
|
-
palenight: () =>
|
|
828
|
-
shadesOfPurple: () =>
|
|
829
|
-
synthwave84: () =>
|
|
830
|
-
ultramin: () =>
|
|
831
|
-
vsDark: () =>
|
|
832
|
-
vsLight: () =>
|
|
811
|
+
var X = {};
|
|
812
|
+
Ie(X, {
|
|
813
|
+
dracula: () => De,
|
|
814
|
+
duotoneDark: () => $e,
|
|
815
|
+
duotoneLight: () => je,
|
|
816
|
+
github: () => Me,
|
|
817
|
+
gruvboxMaterialDark: () => bt,
|
|
818
|
+
gruvboxMaterialLight: () => ht,
|
|
819
|
+
jettwaveDark: () => it,
|
|
820
|
+
jettwaveLight: () => ct,
|
|
821
|
+
nightOwl: () => Ge,
|
|
822
|
+
nightOwlLight: () => We,
|
|
823
|
+
oceanicNext: () => He,
|
|
824
|
+
okaidia: () => Ke,
|
|
825
|
+
oneDark: () => dt,
|
|
826
|
+
oneLight: () => yt,
|
|
827
|
+
palenight: () => Xe,
|
|
828
|
+
shadesOfPurple: () => Je,
|
|
829
|
+
synthwave84: () => tt,
|
|
830
|
+
ultramin: () => nt,
|
|
831
|
+
vsDark: () => ye,
|
|
832
|
+
vsLight: () => st
|
|
833
833
|
});
|
|
834
|
-
var
|
|
834
|
+
var Ne = {
|
|
835
835
|
plain: {
|
|
836
836
|
color: "#F8F8F2",
|
|
837
837
|
backgroundColor: "#282A36"
|
|
@@ -893,7 +893,7 @@ var $e = {
|
|
|
893
893
|
}
|
|
894
894
|
}
|
|
895
895
|
]
|
|
896
|
-
},
|
|
896
|
+
}, De = Ne, Be = {
|
|
897
897
|
plain: {
|
|
898
898
|
backgroundColor: "#2a2734",
|
|
899
899
|
color: "#9a86fd"
|
|
@@ -987,7 +987,7 @@ var $e = {
|
|
|
987
987
|
}
|
|
988
988
|
}
|
|
989
989
|
]
|
|
990
|
-
},
|
|
990
|
+
}, $e = Be, Pe = {
|
|
991
991
|
plain: {
|
|
992
992
|
backgroundColor: "#faf8f5",
|
|
993
993
|
color: "#728fcb"
|
|
@@ -1085,7 +1085,7 @@ var $e = {
|
|
|
1085
1085
|
}
|
|
1086
1086
|
}
|
|
1087
1087
|
]
|
|
1088
|
-
},
|
|
1088
|
+
}, je = Pe, ze = {
|
|
1089
1089
|
plain: {
|
|
1090
1090
|
color: "#393A34",
|
|
1091
1091
|
backgroundColor: "#f6f8fa"
|
|
@@ -1158,7 +1158,7 @@ var $e = {
|
|
|
1158
1158
|
}
|
|
1159
1159
|
}
|
|
1160
1160
|
]
|
|
1161
|
-
},
|
|
1161
|
+
}, Me = ze, Ue = {
|
|
1162
1162
|
plain: {
|
|
1163
1163
|
color: "#d6deeb",
|
|
1164
1164
|
backgroundColor: "#011627"
|
|
@@ -1262,7 +1262,7 @@ var $e = {
|
|
|
1262
1262
|
}
|
|
1263
1263
|
}
|
|
1264
1264
|
]
|
|
1265
|
-
},
|
|
1265
|
+
}, Ge = Ue, Ze = {
|
|
1266
1266
|
plain: {
|
|
1267
1267
|
color: "#403f53",
|
|
1268
1268
|
backgroundColor: "#FBFBFB"
|
|
@@ -1354,7 +1354,7 @@ var $e = {
|
|
|
1354
1354
|
}
|
|
1355
1355
|
}
|
|
1356
1356
|
]
|
|
1357
|
-
},
|
|
1357
|
+
}, We = Ze, L = {
|
|
1358
1358
|
char: "#D8DEE9",
|
|
1359
1359
|
comment: "#999999",
|
|
1360
1360
|
keyword: "#c5a5c5",
|
|
@@ -1368,7 +1368,7 @@ var $e = {
|
|
|
1368
1368
|
className: "#FAC863",
|
|
1369
1369
|
method: "#6699CC",
|
|
1370
1370
|
operator: "#fc929e"
|
|
1371
|
-
},
|
|
1371
|
+
}, qe = {
|
|
1372
1372
|
plain: {
|
|
1373
1373
|
backgroundColor: "#282c34",
|
|
1374
1374
|
color: "#ffffff"
|
|
@@ -1491,7 +1491,7 @@ var $e = {
|
|
|
1491
1491
|
}
|
|
1492
1492
|
}
|
|
1493
1493
|
]
|
|
1494
|
-
},
|
|
1494
|
+
}, He = qe, Ye = {
|
|
1495
1495
|
plain: {
|
|
1496
1496
|
color: "#f8f8f2",
|
|
1497
1497
|
backgroundColor: "#272822"
|
|
@@ -1606,7 +1606,7 @@ var $e = {
|
|
|
1606
1606
|
}
|
|
1607
1607
|
}
|
|
1608
1608
|
]
|
|
1609
|
-
},
|
|
1609
|
+
}, Ke = Ye, Ve = {
|
|
1610
1610
|
plain: {
|
|
1611
1611
|
color: "#bfc7d5",
|
|
1612
1612
|
backgroundColor: "#292d3e"
|
|
@@ -1699,7 +1699,7 @@ var $e = {
|
|
|
1699
1699
|
}
|
|
1700
1700
|
}
|
|
1701
1701
|
]
|
|
1702
|
-
},
|
|
1702
|
+
}, Xe = Ve, Qe = {
|
|
1703
1703
|
plain: {
|
|
1704
1704
|
color: "#9EFEFF",
|
|
1705
1705
|
backgroundColor: "#2D2A55"
|
|
@@ -1787,7 +1787,7 @@ var $e = {
|
|
|
1787
1787
|
}
|
|
1788
1788
|
}
|
|
1789
1789
|
]
|
|
1790
|
-
},
|
|
1790
|
+
}, Je = Qe, et = {
|
|
1791
1791
|
plain: {
|
|
1792
1792
|
backgroundColor: "linear-gradient(to bottom, #2a2139 75%, #34294f)",
|
|
1793
1793
|
backgroundImage: "#34294f",
|
|
@@ -1912,7 +1912,7 @@ var $e = {
|
|
|
1912
1912
|
}
|
|
1913
1913
|
}
|
|
1914
1914
|
]
|
|
1915
|
-
},
|
|
1915
|
+
}, tt = et, at = {
|
|
1916
1916
|
plain: {
|
|
1917
1917
|
color: "#282a2e",
|
|
1918
1918
|
backgroundColor: "#ffffff"
|
|
@@ -1937,7 +1937,7 @@ var $e = {
|
|
|
1937
1937
|
}
|
|
1938
1938
|
}
|
|
1939
1939
|
]
|
|
1940
|
-
},
|
|
1940
|
+
}, nt = at, rt = {
|
|
1941
1941
|
plain: {
|
|
1942
1942
|
color: "#9CDCFE",
|
|
1943
1943
|
backgroundColor: "#1E1E1E"
|
|
@@ -2039,7 +2039,7 @@ var $e = {
|
|
|
2039
2039
|
}
|
|
2040
2040
|
}
|
|
2041
2041
|
]
|
|
2042
|
-
},
|
|
2042
|
+
}, ye = rt, ot = {
|
|
2043
2043
|
plain: {
|
|
2044
2044
|
color: "#000000",
|
|
2045
2045
|
backgroundColor: "#ffffff"
|
|
@@ -2112,7 +2112,7 @@ var $e = {
|
|
|
2112
2112
|
}
|
|
2113
2113
|
}
|
|
2114
2114
|
]
|
|
2115
|
-
},
|
|
2115
|
+
}, st = ot, lt = {
|
|
2116
2116
|
plain: {
|
|
2117
2117
|
color: "#f8fafc",
|
|
2118
2118
|
backgroundColor: "#011627"
|
|
@@ -2211,7 +2211,7 @@ var $e = {
|
|
|
2211
2211
|
}
|
|
2212
2212
|
}
|
|
2213
2213
|
]
|
|
2214
|
-
},
|
|
2214
|
+
}, it = lt, ut = {
|
|
2215
2215
|
plain: {
|
|
2216
2216
|
color: "#0f172a",
|
|
2217
2217
|
backgroundColor: "#f1f5f9"
|
|
@@ -2310,7 +2310,7 @@ var $e = {
|
|
|
2310
2310
|
}
|
|
2311
2311
|
}
|
|
2312
2312
|
]
|
|
2313
|
-
},
|
|
2313
|
+
}, ct = ut, pt = {
|
|
2314
2314
|
plain: {
|
|
2315
2315
|
backgroundColor: "hsl(220, 13%, 18%)",
|
|
2316
2316
|
color: "hsl(220, 14%, 71%)",
|
|
@@ -2408,7 +2408,7 @@ var $e = {
|
|
|
2408
2408
|
}
|
|
2409
2409
|
}
|
|
2410
2410
|
]
|
|
2411
|
-
},
|
|
2411
|
+
}, dt = pt, gt = {
|
|
2412
2412
|
plain: {
|
|
2413
2413
|
backgroundColor: "hsl(230, 1%, 98%)",
|
|
2414
2414
|
color: "hsl(230, 8%, 24%)"
|
|
@@ -2509,7 +2509,7 @@ var $e = {
|
|
|
2509
2509
|
}
|
|
2510
2510
|
}
|
|
2511
2511
|
]
|
|
2512
|
-
},
|
|
2512
|
+
}, yt = gt, ft = {
|
|
2513
2513
|
plain: {
|
|
2514
2514
|
color: "#ebdbb2",
|
|
2515
2515
|
backgroundColor: "#292828"
|
|
@@ -2582,7 +2582,7 @@ var $e = {
|
|
|
2582
2582
|
}
|
|
2583
2583
|
}
|
|
2584
2584
|
]
|
|
2585
|
-
},
|
|
2585
|
+
}, bt = ft, mt = {
|
|
2586
2586
|
plain: {
|
|
2587
2587
|
color: "#654735",
|
|
2588
2588
|
backgroundColor: "#f9f5d7"
|
|
@@ -2654,54 +2654,38 @@ var $e = {
|
|
|
2654
2654
|
}
|
|
2655
2655
|
}
|
|
2656
2656
|
]
|
|
2657
|
-
},
|
|
2658
|
-
const { plain: a } = e, l = e.styles.reduce((p, m) => {
|
|
2659
|
-
const { languages: c, style: h } = m;
|
|
2660
|
-
return c && !c.includes(t) || m.types.forEach((u) => {
|
|
2661
|
-
const g = B(B({}, p[u]), h);
|
|
2662
|
-
p[u] = g;
|
|
2663
|
-
}), p;
|
|
2664
|
-
}, {});
|
|
2665
|
-
return l.root = a, l.plain = q(B({}, a), { backgroundColor: void 0 }), l;
|
|
2666
|
-
}, oe = Et, xt = (e, t) => {
|
|
2667
|
-
const [a, l] = de(
|
|
2668
|
-
oe(t, e)
|
|
2669
|
-
), p = V(), m = V();
|
|
2670
|
-
return Ee(() => {
|
|
2671
|
-
(t !== p.current || e !== m.current) && (p.current = t, m.current = e, l(oe(t, e)));
|
|
2672
|
-
}, [e, t]), a;
|
|
2673
|
-
}, St = (e) => X(
|
|
2657
|
+
}, ht = mt, vt = (e) => V(
|
|
2674
2658
|
(t) => {
|
|
2675
|
-
var a = t, { className:
|
|
2676
|
-
const
|
|
2677
|
-
className:
|
|
2659
|
+
var a = t, { className: i, style: p, line: h } = a, c = ge(a, ["className", "style", "line"]);
|
|
2660
|
+
const m = q(B({}, c), {
|
|
2661
|
+
className: ce("token-line", i)
|
|
2678
2662
|
});
|
|
2679
|
-
return typeof e == "object" && "plain" in e && (
|
|
2663
|
+
return typeof e == "object" && "plain" in e && (m.style = e.plain), typeof p == "object" && (m.style = B(B({}, m.style || {}), p)), m;
|
|
2680
2664
|
},
|
|
2681
2665
|
[e]
|
|
2682
|
-
),
|
|
2683
|
-
const t =
|
|
2684
|
-
({ types: a, empty:
|
|
2666
|
+
), kt = (e) => {
|
|
2667
|
+
const t = V(
|
|
2668
|
+
({ types: a, empty: i }) => {
|
|
2685
2669
|
if (e != null) {
|
|
2686
2670
|
{
|
|
2687
2671
|
if (a.length === 1 && a[0] === "plain")
|
|
2688
|
-
return
|
|
2689
|
-
if (a.length === 1 &&
|
|
2672
|
+
return i != null ? { display: "inline-block" } : void 0;
|
|
2673
|
+
if (a.length === 1 && i != null)
|
|
2690
2674
|
return e[a[0]];
|
|
2691
2675
|
}
|
|
2692
2676
|
return Object.assign(
|
|
2693
|
-
|
|
2677
|
+
i != null ? { display: "inline-block" } : {},
|
|
2694
2678
|
...a.map((p) => e[p])
|
|
2695
2679
|
);
|
|
2696
2680
|
}
|
|
2697
2681
|
},
|
|
2698
2682
|
[e]
|
|
2699
2683
|
);
|
|
2700
|
-
return
|
|
2684
|
+
return V(
|
|
2701
2685
|
(a) => {
|
|
2702
|
-
var
|
|
2703
|
-
const u = q(B({},
|
|
2704
|
-
className:
|
|
2686
|
+
var i = a, { token: p, className: h, style: c } = i, m = ge(i, ["token", "className", "style"]);
|
|
2687
|
+
const u = q(B({}, m), {
|
|
2688
|
+
className: ce("token", ...p.types, h),
|
|
2705
2689
|
children: p.content,
|
|
2706
2690
|
style: t(p)
|
|
2707
2691
|
});
|
|
@@ -2709,7 +2693,7 @@ var $e = {
|
|
|
2709
2693
|
},
|
|
2710
2694
|
[t]
|
|
2711
2695
|
);
|
|
2712
|
-
},
|
|
2696
|
+
}, wt = /\r\n|\r|\n/, re = (e) => {
|
|
2713
2697
|
e.length === 0 ? e.push({
|
|
2714
2698
|
types: ["plain"],
|
|
2715
2699
|
content: `
|
|
@@ -2717,66 +2701,78 @@ var $e = {
|
|
|
2717
2701
|
empty: !0
|
|
2718
2702
|
}) : e.length === 1 && e[0].content === "" && (e[0].content = `
|
|
2719
2703
|
`, e[0].empty = !0);
|
|
2720
|
-
},
|
|
2704
|
+
}, oe = (e, t) => {
|
|
2721
2705
|
const a = e.length;
|
|
2722
2706
|
return a > 0 && e[a - 1] === t ? e : e.concat(t);
|
|
2723
|
-
},
|
|
2724
|
-
const t = [[]], a = [e],
|
|
2725
|
-
let
|
|
2726
|
-
const u = [
|
|
2707
|
+
}, Et = (e) => {
|
|
2708
|
+
const t = [[]], a = [e], i = [0], p = [e.length];
|
|
2709
|
+
let h = 0, c = 0, m = [];
|
|
2710
|
+
const u = [m];
|
|
2727
2711
|
for (; c > -1; ) {
|
|
2728
|
-
for (; (
|
|
2712
|
+
for (; (h = i[c]++) < p[c]; ) {
|
|
2729
2713
|
let g, b = t[c];
|
|
2730
|
-
const v = a[c][
|
|
2731
|
-
if (typeof v == "string" ? (b = c > 0 ? b : ["plain"], g = v) : (b =
|
|
2732
|
-
c++, t.push(b), a.push(g),
|
|
2714
|
+
const v = a[c][h];
|
|
2715
|
+
if (typeof v == "string" ? (b = c > 0 ? b : ["plain"], g = v) : (b = oe(b, v.type), v.alias && (b = oe(b, v.alias)), g = v.content), typeof g != "string") {
|
|
2716
|
+
c++, t.push(b), a.push(g), i.push(0), p.push(g.length);
|
|
2733
2717
|
continue;
|
|
2734
2718
|
}
|
|
2735
|
-
const k = g.split(
|
|
2736
|
-
|
|
2719
|
+
const k = g.split(wt), n = k.length;
|
|
2720
|
+
m.push({
|
|
2737
2721
|
types: b,
|
|
2738
2722
|
content: k[0]
|
|
2739
2723
|
});
|
|
2740
2724
|
for (let r = 1; r < n; r++)
|
|
2741
|
-
|
|
2725
|
+
re(m), u.push(m = []), m.push({
|
|
2742
2726
|
types: b,
|
|
2743
2727
|
content: k[r]
|
|
2744
2728
|
});
|
|
2745
2729
|
}
|
|
2746
|
-
c--, t.pop(), a.pop(),
|
|
2730
|
+
c--, t.pop(), a.pop(), i.pop(), p.pop();
|
|
2747
2731
|
}
|
|
2748
|
-
return
|
|
2749
|
-
},
|
|
2750
|
-
|
|
2751
|
-
|
|
2752
|
-
|
|
2753
|
-
|
|
2754
|
-
|
|
2755
|
-
|
|
2756
|
-
|
|
2757
|
-
|
|
2758
|
-
|
|
2759
|
-
|
|
2760
|
-
|
|
2761
|
-
|
|
2762
|
-
|
|
2732
|
+
return re(m), u;
|
|
2733
|
+
}, se = Et, xt = ({ prism: e, code: t, grammar: a, language: i }) => ve(() => {
|
|
2734
|
+
if (a == null)
|
|
2735
|
+
return se([t]);
|
|
2736
|
+
const p = {
|
|
2737
|
+
code: t,
|
|
2738
|
+
grammar: a,
|
|
2739
|
+
language: i,
|
|
2740
|
+
tokens: []
|
|
2741
|
+
};
|
|
2742
|
+
return e.hooks.run("before-tokenize", p), p.tokens = e.tokenize(t, a), e.hooks.run("after-tokenize", p), se(p.tokens);
|
|
2743
|
+
}, [
|
|
2744
|
+
t,
|
|
2745
|
+
a,
|
|
2746
|
+
i,
|
|
2747
|
+
// prism is a stable import
|
|
2748
|
+
e
|
|
2749
|
+
]), St = (e, t) => {
|
|
2750
|
+
const { plain: a } = e, i = e.styles.reduce((p, h) => {
|
|
2751
|
+
const { languages: c, style: m } = h;
|
|
2752
|
+
return c && !c.includes(t) || h.types.forEach((u) => {
|
|
2753
|
+
const g = B(B({}, p[u]), m);
|
|
2754
|
+
p[u] = g;
|
|
2755
|
+
}), p;
|
|
2756
|
+
}, {});
|
|
2757
|
+
return i.root = a, i.plain = q(B({}, a), { backgroundColor: void 0 }), i;
|
|
2758
|
+
}, At = St, _t = ({
|
|
2763
2759
|
children: e,
|
|
2764
2760
|
language: t,
|
|
2765
2761
|
code: a,
|
|
2766
|
-
theme:
|
|
2762
|
+
theme: i,
|
|
2767
2763
|
prism: p
|
|
2768
2764
|
}) => {
|
|
2769
|
-
const
|
|
2765
|
+
const h = t.toLowerCase(), c = At(i, h), m = vt(c), u = kt(c), g = p.languages[h], b = xt({ prism: p, language: h, code: a, grammar: g });
|
|
2770
2766
|
return e({
|
|
2771
2767
|
tokens: b,
|
|
2772
|
-
className: `prism-code language-${
|
|
2768
|
+
className: `prism-code language-${h}`,
|
|
2773
2769
|
style: c != null ? c.root : {},
|
|
2774
|
-
getLineProps:
|
|
2770
|
+
getLineProps: m,
|
|
2775
2771
|
getTokenProps: u
|
|
2776
2772
|
});
|
|
2777
|
-
},
|
|
2773
|
+
}, Ft = (e) => he(_t, q(B({}, e), {
|
|
2778
2774
|
prism: e.prism || o,
|
|
2779
|
-
theme: e.theme ||
|
|
2775
|
+
theme: e.theme || ye,
|
|
2780
2776
|
code: e.code,
|
|
2781
2777
|
language: e.language
|
|
2782
2778
|
}));
|
|
@@ -2792,44 +2788,44 @@ prismjs/prism.js:
|
|
|
2792
2788
|
* @public
|
|
2793
2789
|
*)
|
|
2794
2790
|
*/
|
|
2795
|
-
var
|
|
2791
|
+
var Tt = (e, t, a, i, p, h, c, m) => {
|
|
2796
2792
|
let u = document.documentElement, g = ["light", "dark"];
|
|
2797
2793
|
function b(k) {
|
|
2798
2794
|
(Array.isArray(e) ? e : [e]).forEach((n) => {
|
|
2799
|
-
let r = n === "class", s = r &&
|
|
2795
|
+
let r = n === "class", s = r && h ? p.map((d) => h[d] || d) : p;
|
|
2800
2796
|
r ? (u.classList.remove(...s), u.classList.add(k)) : u.setAttribute(n, k);
|
|
2801
2797
|
}), y(k);
|
|
2802
2798
|
}
|
|
2803
2799
|
function y(k) {
|
|
2804
|
-
|
|
2800
|
+
m && g.includes(k) && (u.style.colorScheme = k);
|
|
2805
2801
|
}
|
|
2806
2802
|
function v() {
|
|
2807
2803
|
return window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
|
|
2808
2804
|
}
|
|
2809
|
-
if (
|
|
2805
|
+
if (i) b(i);
|
|
2810
2806
|
else try {
|
|
2811
2807
|
let k = localStorage.getItem(t) || a, n = c && k === "system" ? v() : k;
|
|
2812
2808
|
b(n);
|
|
2813
2809
|
} catch {
|
|
2814
2810
|
}
|
|
2815
|
-
},
|
|
2816
|
-
}, themes: [] },
|
|
2811
|
+
}, le = ["light", "dark"], fe = "(prefers-color-scheme: dark)", Rt = typeof window > "u", J = _.createContext(void 0), It = { setTheme: (e) => {
|
|
2812
|
+
}, themes: [] }, Lt = () => {
|
|
2817
2813
|
var e;
|
|
2818
|
-
return (e = _.useContext(
|
|
2819
|
-
},
|
|
2820
|
-
let [v, k] = _.useState(() =>
|
|
2814
|
+
return (e = _.useContext(J)) != null ? e : It;
|
|
2815
|
+
}, Ut = (e) => _.useContext(J) ? _.createElement(_.Fragment, null, e.children) : _.createElement(Ct, { ...e }), Ot = ["light", "dark"], Ct = ({ forcedTheme: e, disableTransitionOnChange: t = !1, enableSystem: a = !0, enableColorScheme: i = !0, storageKey: p = "theme", themes: h = Ot, defaultTheme: c = a ? "system" : "light", attribute: m = "data-theme", value: u, children: g, nonce: b, scriptProps: y }) => {
|
|
2816
|
+
let [v, k] = _.useState(() => ie(p, c)), [n, r] = _.useState(() => ie(p)), s = u ? Object.values(u) : h, d = _.useCallback((w) => {
|
|
2821
2817
|
let x = w;
|
|
2822
2818
|
if (!x) return;
|
|
2823
|
-
w === "system" && a && (x =
|
|
2824
|
-
let S = u ? u[x] : x, F = t ?
|
|
2819
|
+
w === "system" && a && (x = ue());
|
|
2820
|
+
let S = u ? u[x] : x, F = t ? Dt(b) : null, A = document.documentElement, C = (T) => {
|
|
2825
2821
|
T === "class" ? (A.classList.remove(...s), S && A.classList.add(S)) : T.startsWith("data-") && (S ? A.setAttribute(T, S) : A.removeAttribute(T));
|
|
2826
2822
|
};
|
|
2827
|
-
if (Array.isArray(
|
|
2828
|
-
let T =
|
|
2823
|
+
if (Array.isArray(m) ? m.forEach(C) : C(m), i) {
|
|
2824
|
+
let T = le.includes(c) ? c : null, O = le.includes(x) ? x : T;
|
|
2829
2825
|
A.style.colorScheme = O;
|
|
2830
2826
|
}
|
|
2831
2827
|
F == null || F();
|
|
2832
|
-
}, [b]),
|
|
2828
|
+
}, [b]), l = _.useCallback((w) => {
|
|
2833
2829
|
let x = typeof w == "function" ? w(v) : w;
|
|
2834
2830
|
k(x);
|
|
2835
2831
|
try {
|
|
@@ -2837,71 +2833,71 @@ var Lt = (e, t, a, l, p, m, c, h) => {
|
|
|
2837
2833
|
} catch {
|
|
2838
2834
|
}
|
|
2839
2835
|
}, [v]), f = _.useCallback((w) => {
|
|
2840
|
-
let x =
|
|
2836
|
+
let x = ue(w);
|
|
2841
2837
|
r(x), v === "system" && a && !e && d("system");
|
|
2842
2838
|
}, [v, e]);
|
|
2843
2839
|
_.useEffect(() => {
|
|
2844
|
-
let w = window.matchMedia(
|
|
2840
|
+
let w = window.matchMedia(fe);
|
|
2845
2841
|
return w.addListener(f), f(w), () => w.removeListener(f);
|
|
2846
2842
|
}, [f]), _.useEffect(() => {
|
|
2847
2843
|
let w = (x) => {
|
|
2848
|
-
x.key === p && (x.newValue ? k(x.newValue) :
|
|
2844
|
+
x.key === p && (x.newValue ? k(x.newValue) : l(c));
|
|
2849
2845
|
};
|
|
2850
2846
|
return window.addEventListener("storage", w), () => window.removeEventListener("storage", w);
|
|
2851
|
-
}, [
|
|
2847
|
+
}, [l]), _.useEffect(() => {
|
|
2852
2848
|
d(e ?? v);
|
|
2853
2849
|
}, [e, v]);
|
|
2854
|
-
let E = _.useMemo(() => ({ theme: v, setTheme:
|
|
2855
|
-
return _.createElement(
|
|
2856
|
-
},
|
|
2857
|
-
let b = JSON.stringify([a, t,
|
|
2858
|
-
return _.createElement("script", { ...g, suppressHydrationWarning: !0, nonce: typeof window > "u" ? u : "", dangerouslySetInnerHTML: { __html: `(${
|
|
2859
|
-
}),
|
|
2860
|
-
if (
|
|
2850
|
+
let E = _.useMemo(() => ({ theme: v, setTheme: l, forcedTheme: e, resolvedTheme: v === "system" ? n : v, themes: a ? [...h, "system"] : h, systemTheme: a ? n : void 0 }), [v, l, e, n, a, h]);
|
|
2851
|
+
return _.createElement(J.Provider, { value: E }, _.createElement(Nt, { forcedTheme: e, storageKey: p, attribute: m, enableSystem: a, enableColorScheme: i, defaultTheme: c, value: u, themes: h, nonce: b, scriptProps: y }), g);
|
|
2852
|
+
}, Nt = _.memo(({ forcedTheme: e, storageKey: t, attribute: a, enableSystem: i, enableColorScheme: p, defaultTheme: h, value: c, themes: m, nonce: u, scriptProps: g }) => {
|
|
2853
|
+
let b = JSON.stringify([a, t, h, e, m, c, i, p]).slice(1, -1);
|
|
2854
|
+
return _.createElement("script", { ...g, suppressHydrationWarning: !0, nonce: typeof window > "u" ? u : "", dangerouslySetInnerHTML: { __html: `(${Tt.toString()})(${b})` } });
|
|
2855
|
+
}), ie = (e, t) => {
|
|
2856
|
+
if (Rt) return;
|
|
2861
2857
|
let a;
|
|
2862
2858
|
try {
|
|
2863
2859
|
a = localStorage.getItem(e) || void 0;
|
|
2864
2860
|
} catch {
|
|
2865
2861
|
}
|
|
2866
2862
|
return a || t;
|
|
2867
|
-
},
|
|
2863
|
+
}, Dt = (e) => {
|
|
2868
2864
|
let t = document.createElement("style");
|
|
2869
2865
|
return e && t.setAttribute("nonce", e), t.appendChild(document.createTextNode("*,*::before,*::after{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}")), document.head.appendChild(t), () => {
|
|
2870
2866
|
window.getComputedStyle(document.body), setTimeout(() => {
|
|
2871
2867
|
document.head.removeChild(t);
|
|
2872
2868
|
}, 1);
|
|
2873
2869
|
};
|
|
2874
|
-
},
|
|
2870
|
+
}, ue = (e) => (e || (e = window.matchMedia(fe)), e.matches ? "dark" : "light");
|
|
2875
2871
|
globalThis.Prism = o;
|
|
2876
|
-
import("./prism-bash.min-
|
|
2877
|
-
import("./prism-ruby.min-
|
|
2872
|
+
import("./prism-bash.min-HHIMdNJ_.js");
|
|
2873
|
+
import("./prism-ruby.min-Dx9KO9ds.js").then((e) => e.p);
|
|
2878
2874
|
import("./prism-markup-BNGj0Tvm.js");
|
|
2879
2875
|
import("./prism-json.min-B1GJqK1k.js");
|
|
2880
|
-
import("./prism-java.min-
|
|
2881
|
-
import("./prism-csharp.min-
|
|
2876
|
+
import("./prism-java.min-BpvsOuIa.js").then((e) => e.p);
|
|
2877
|
+
import("./prism-csharp.min-bQAo2pmx.js").then((e) => e.p);
|
|
2882
2878
|
import("./prism-objectivec.min-BXSWqpJJ.js");
|
|
2883
|
-
import("./prism-markdown.min-
|
|
2879
|
+
import("./prism-markdown.min-C0Qn0m-5.js");
|
|
2884
2880
|
import("./prism-javascript.min-CEqHqgbm.js");
|
|
2885
2881
|
import("./prism-typescript.min-CD7H2IYQ.js").then((e) => e.p);
|
|
2886
|
-
const
|
|
2882
|
+
const Bt = {
|
|
2887
2883
|
mdx: "md"
|
|
2888
|
-
},
|
|
2884
|
+
}, Gt = ({
|
|
2889
2885
|
copyable: e = !0,
|
|
2890
2886
|
language: t = "plain",
|
|
2891
2887
|
...a
|
|
2892
2888
|
}) => {
|
|
2893
|
-
const { resolvedTheme:
|
|
2889
|
+
const { resolvedTheme: i } = Lt(), [p, h] = ke(!1);
|
|
2894
2890
|
if (!a.code)
|
|
2895
2891
|
return null;
|
|
2896
|
-
const c =
|
|
2892
|
+
const c = i === "dark" ? X.vsDark : X.github;
|
|
2897
2893
|
return /* @__PURE__ */ I.jsx(
|
|
2898
|
-
|
|
2894
|
+
xe,
|
|
2899
2895
|
{
|
|
2900
2896
|
fallback: /* @__PURE__ */ I.jsxs("div", { className: "relative group", children: [
|
|
2901
2897
|
/* @__PURE__ */ I.jsx(
|
|
2902
2898
|
"pre",
|
|
2903
2899
|
{
|
|
2904
|
-
className:
|
|
2900
|
+
className: ae(
|
|
2905
2901
|
"relative scrollbar overflow-x-auto",
|
|
2906
2902
|
a.className,
|
|
2907
2903
|
a.noBackground ? "!bg-transparent" : "bg-[#f6f8fa] text-[#393a34] dark:bg-[#1e1e1e] dark:text-[#9cdcfe]",
|
|
@@ -2913,16 +2909,16 @@ const jt = {
|
|
|
2913
2909
|
a.showLanguageIndicator && /* @__PURE__ */ I.jsx("span", { className: "absolute top-1.5 right-3 text-[11px] font-mono text-muted-foreground transition group-hover:opacity-0", children: t })
|
|
2914
2910
|
] }),
|
|
2915
2911
|
children: /* @__PURE__ */ I.jsx(
|
|
2916
|
-
|
|
2912
|
+
Ft,
|
|
2917
2913
|
{
|
|
2918
2914
|
theme: c,
|
|
2919
|
-
language:
|
|
2915
|
+
language: Bt[t] ?? t,
|
|
2920
2916
|
...a,
|
|
2921
2917
|
children: ({ className: u, style: g, tokens: b, getLineProps: y, getTokenProps: v }) => /* @__PURE__ */ I.jsxs("div", { className: "relative group", children: [
|
|
2922
2918
|
/* @__PURE__ */ I.jsx(
|
|
2923
2919
|
"pre",
|
|
2924
2920
|
{
|
|
2925
|
-
className:
|
|
2921
|
+
className: ae(
|
|
2926
2922
|
"relative scrollbar overflow-x-auto",
|
|
2927
2923
|
u,
|
|
2928
2924
|
a.className,
|
|
@@ -2949,20 +2945,20 @@ const jt = {
|
|
|
2949
2945
|
className: "absolute top-2 right-2 p-2 opacity-0 group-hover:opacity-100 group-hover:bg-zinc-100 group-hover:dark:bg-zinc-700 hover:outline hover:outline-border/75 dark:hover:outline-border rounded-md text-sm text-gray-400 hover:text-gray-600 dark:text-gray-500 dark:hover:text-gray-400 transition",
|
|
2950
2946
|
disabled: p,
|
|
2951
2947
|
onClick: () => {
|
|
2952
|
-
|
|
2948
|
+
h(!0), navigator.clipboard.writeText(
|
|
2953
2949
|
b.map((k) => k.map(({ content: n }) => n).join("")).join(`
|
|
2954
2950
|
`)
|
|
2955
|
-
), setTimeout(() =>
|
|
2951
|
+
), setTimeout(() => h(!1), 2e3);
|
|
2956
2952
|
},
|
|
2957
2953
|
children: p ? /* @__PURE__ */ I.jsx(
|
|
2958
|
-
|
|
2954
|
+
we,
|
|
2959
2955
|
{
|
|
2960
2956
|
className: "text-emerald-600",
|
|
2961
2957
|
size: 16,
|
|
2962
2958
|
strokeWidth: 2.5,
|
|
2963
2959
|
absoluteStrokeWidth: !0
|
|
2964
2960
|
}
|
|
2965
|
-
) : /* @__PURE__ */ I.jsx(
|
|
2961
|
+
) : /* @__PURE__ */ I.jsx(Ee, { size: 16 })
|
|
2966
2962
|
}
|
|
2967
2963
|
)
|
|
2968
2964
|
] })
|
|
@@ -2972,8 +2968,8 @@ const jt = {
|
|
|
2972
2968
|
);
|
|
2973
2969
|
};
|
|
2974
2970
|
export {
|
|
2975
|
-
|
|
2976
|
-
|
|
2977
|
-
|
|
2971
|
+
Ut as J,
|
|
2972
|
+
Gt as S,
|
|
2973
|
+
Lt as z
|
|
2978
2974
|
};
|
|
2979
|
-
//# sourceMappingURL=SyntaxHighlight-
|
|
2975
|
+
//# sourceMappingURL=SyntaxHighlight-CJCSPG1F.js.map
|