@diplodoc/client 3.0.4 → 3.1.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.
@@ -5,7 +5,6 @@ import type { RouterConfig } from '../Router';
5
5
  import { DocContentPageData as DocContentPageDataBase, DocLeadingPageData, DocPageData, Lang } from '@diplodoc/components';
6
6
  import '@diplodoc/transform/dist/js/yfm';
7
7
  import '../../interceptors/leading-page-links';
8
- import '../../interceptors/fast-class-applier';
9
8
  import './App.scss';
10
9
  export type DocAnalytics = {
11
10
  gtm?: {
@@ -1 +1,2 @@
1
- export {};
1
+ import type { DocInnerProps } from '../components/App';
2
+ export declare function setRootClasses(data: DocInnerProps): void;
@@ -1,7 +1,7 @@
1
1
  /******/ (() => { // webpackBootstrap
2
2
  /******/ var __webpack_modules__ = ({
3
3
 
4
- /***/ 60204:
4
+ /***/ 31890:
5
5
  /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
6
6
 
7
7
  "use strict";
@@ -54,6 +54,8 @@ const RouterProvider = RouterContext.Provider;
54
54
  function useRouter() {
55
55
  return (0,react.useContext)(RouterContext);
56
56
  }
57
+ // EXTERNAL MODULE: ./node_modules/@diplodoc/components/build/esm/utils/index.js + 59 modules
58
+ var utils = __webpack_require__(54878);
57
59
  // EXTERNAL MODULE: ./node_modules/@diplodoc/components/build/esm/models/index.js
58
60
  var models = __webpack_require__(78184);
59
61
  ;// CONCATENATED MODULE: ./src/constants.ts
@@ -78,6 +80,7 @@ const LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG = ['src', 'url', 'href', 'icon', 'image'
78
80
  const LINK_KEYS = [...new Set([...LINK_KEYS_LEADING_CONFIG, ...LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG])];
79
81
  ;// CONCATENATED MODULE: ./src/utils.ts
80
82
 
83
+
81
84
  function isBrowser() {
82
85
  return typeof document !== 'undefined';
83
86
  }
@@ -109,6 +112,10 @@ function updateRootClassName(states) {
109
112
  case 'fullScreen':
110
113
  toggle('dc-root_full-screen', states[state]);
111
114
  break;
115
+ case 'landingPage':
116
+ toggle('dc-root_document-page', !states[state]);
117
+ toggle('dc-root_landing-page', states[state]);
118
+ break;
112
119
  case 'mobileView':
113
120
  toggle('mobile', states[state]);
114
121
  toggle('desktop', !states[state]);
@@ -140,6 +147,9 @@ function getSettings() {
140
147
  fullScreen: toBoolean(fullScreen)
141
148
  };
142
149
  }
150
+ function getLandingPage(data) {
151
+ return (0,utils/* getPageType */.M5)(data) === 'PAGE_CONSTRUCTOR';
152
+ }
143
153
  function getMobileView() {
144
154
  if (!isBrowser()) {
145
155
  return false;
@@ -175,30 +185,10 @@ function useLang() {
175
185
  }
176
186
  // EXTERNAL MODULE: ./src/interceptors/leading-page-links.js
177
187
  var leading_page_links = __webpack_require__(44186);
178
- ;// CONCATENATED MODULE: ./src/interceptors/fast-class-applier.ts
179
-
180
- if (typeof document !== 'undefined') {
181
- const {
182
- theme,
183
- wideFormat,
184
- fullScreen
185
- } = getSettings();
186
- const mobileView = getMobileView();
187
- updateRootClassName({
188
- mobileView,
189
- wideFormat,
190
- fullScreen
191
- });
192
- updateThemeClassName({
193
- theme
194
- });
195
- }
196
188
  // EXTERNAL MODULE: ./node_modules/@gravity-ui/page-constructor/build/esm/containers/PageConstructor/Provider.js
197
189
  var Provider = __webpack_require__(47658);
198
190
  // EXTERNAL MODULE: ./node_modules/@gravity-ui/page-constructor/build/esm/containers/PageConstructor/PageConstructor.js + 10 modules
199
191
  var PageConstructor = __webpack_require__(95168);
200
- // EXTERNAL MODULE: ./node_modules/@diplodoc/components/build/esm/utils/index.js + 59 modules
201
- var utils = __webpack_require__(54878);
202
192
  // EXTERNAL MODULE: ./node_modules/bem-cn-lite/lib/index.js
203
193
  var lib = __webpack_require__(23614);
204
194
  ;// CONCATENATED MODULE: ./src/components/Layout/index.tsx
@@ -324,6 +314,10 @@ const useContent = (data, CustomPage) => {
324
314
  };
325
315
  // EXTERNAL MODULE: ./node_modules/@diplodoc/components/build/esm/components/SearchSuggest/index.js + 8 modules
326
316
  var SearchSuggest = __webpack_require__(9400);
317
+ // EXTERNAL MODULE: ./node_modules/@gravity-ui/uikit/build/esm/components/Icon/Icon.js + 3 modules
318
+ var Icon = __webpack_require__(29504);
319
+ // EXTERNAL MODULE: ./node_modules/@gravity-ui/icons/esm/Magnifier.js
320
+ var Magnifier = __webpack_require__(84941);
327
321
  ;// CONCATENATED MODULE: ./src/components/index.ts
328
322
 
329
323
 
@@ -447,6 +441,17 @@ function useProvider() {
447
441
 
448
442
 
449
443
 
444
+
445
+
446
+
447
+ const Suggest_b = (0,lib/* default */.A)('Suggest');
448
+ function SearchButton() {
449
+ return /*#__PURE__*/react.createElement(Icon/* Icon */.I, {
450
+ data: Magnifier/* default */.A,
451
+ className: Suggest_b('end'),
452
+ size: 24
453
+ });
454
+ }
450
455
  function Suggest() {
451
456
  const provider = useProvider();
452
457
  const suggest = (0,react.useRef)(null);
@@ -473,7 +478,10 @@ function Suggest() {
473
478
  provider: provider,
474
479
  onFocus: onFocus,
475
480
  onBlur: onBlur,
476
- classNameContainer: 'Suggest'
481
+ endContent: /*#__PURE__*/react.createElement(SearchButton, null),
482
+ className: Suggest_b('input'),
483
+ classNameContainer: Suggest_b(),
484
+ closeButton: true
477
485
  });
478
486
  }
479
487
  // EXTERNAL MODULE: ./node_modules/@diplodoc/components/build/esm/components/Controls/ControlsLayout.js
@@ -560,7 +568,10 @@ const useNavigation = (data, controls, CustomControls, CustomSuggest) => {
560
568
  const navigationData = (0,react.useMemo)(() => ({
561
569
  withBorder: true,
562
570
  leftItems: leftItems,
563
- rightItems: rightItems
571
+ rightItems: rightItems,
572
+ customMobileHeaderItems: [{
573
+ type: 'search'
574
+ }]
564
575
  }), [leftItems, rightItems]);
565
576
  const navigationTocData = (0,react.useMemo)(() => ({
566
577
  toc,
@@ -775,7 +786,6 @@ function useMobile() {
775
786
 
776
787
 
777
788
 
778
-
779
789
  function hasNavigation(data) {
780
790
  return Boolean(data.toc.navigation);
781
791
  }
@@ -814,16 +824,18 @@ function App(props) {
814
824
  mobileView
815
825
  }), [langs, settings, mobileView]);
816
826
  const direction = getDirection(lang);
827
+ const landingPage = getLandingPage(data);
817
828
  (0,react.useEffect)(() => {
818
829
  updateRootClassName({
819
830
  mobileView,
820
831
  wideFormat,
821
- fullScreen
832
+ fullScreen,
833
+ landingPage
822
834
  });
823
835
  updateThemeClassName({
824
836
  theme
825
837
  });
826
- }, [theme, mobileView, wideFormat, fullScreen]);
838
+ }, [theme, mobileView, wideFormat, fullScreen, landingPage]);
827
839
  return /*#__PURE__*/react.createElement("div", {
828
840
  className: "App"
829
841
  }, /*#__PURE__*/react.createElement(ThemeProvider/* ThemeProvider */.N, {
@@ -1276,7 +1288,7 @@ module.exports = require("util");
1276
1288
  /******/ __webpack_require__.x = () => {
1277
1289
  /******/ // Load entry module and return exports
1278
1290
  /******/ // This entry module depends on other loaded chunks and execution need to be delayed
1279
- /******/ var __webpack_exports__ = __webpack_require__.O(undefined, [644,121], () => (__webpack_require__(60204)))
1291
+ /******/ var __webpack_exports__ = __webpack_require__.O(undefined, [644,121], () => (__webpack_require__(31890)))
1280
1292
  /******/ __webpack_exports__ = __webpack_require__.O(__webpack_exports__);
1281
1293
  /******/ return __webpack_exports__;
1282
1294
  /******/ };
@@ -1 +1 @@
1
- {"version":3,"file":"app.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAA0B;AAEnB,MAAMC,MAAM,GAAGA,CAAA,KAAM;EACxB,oBAAOD,KAAA,CAAAE,aAAA,cAAK,SAAY,CAAC;AAC7B,CAAC;;ACF+C;AAIzC,MAAMG,aAAa,gBAAGF,uBAAa,CAAkC,IAAI,CAAC;AAEjFE,aAAa,CAACC,WAAW,GAAG,eAAe;AAEpC,MAAMC,cAAc,GAAGF,aAAa,CAACG,QAAQ;AAEpB;AAEzB,SAASC,SAASA,CAAA,EAAG;EACxB,OAAOL,oBAAU,CAACC,aAAa,CAAC;AACp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WCrCA;;;;;WCAA;WACA;WACA;WACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA;;;;;WCPA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,EAAE;WACF;;;;;WCRA;WACA;WACA;WACA,eAAe,6BAA6B;WAC5C;;;;;WCJA;WACA;WACA;WACA;WACA;;;;;WCJA;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D;;;;;WCNA;WACA;WACA;WACA;WACA;;;;;WCJA;;;;;WCAA;;WAEA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,gBAAgB,qBAAqB;WACrC;WACA;WACA;;WAEA;WACA;WACA;WACA;WACA,aAAa;WACb;WACA,IAAI;WACJ;WACA;;WAEA;;WAEA;;WAEA;;;;;WCrCA;WACA;WACA;WACA;WACA;WACA;;;;;UELA;UACA","sources":["webpack://@diplodoc/client/./src/components/Search/Search.tsx","webpack://@diplodoc/client/./src/components/Search/index.ts","webpack://@diplodoc/client/./src/components/Router/index.ts","webpack://@diplodoc/client/./src/constants.ts","webpack://@diplodoc/client/./src/utils.ts","webpack://@diplodoc/client/./src/hooks/useLang.ts","webpack://@diplodoc/client/./src/interceptors/fast-class-applier.ts","webpack://@diplodoc/client/./src/components/Layout/index.tsx","webpack://@diplodoc/client/./src/components/ConstructorPage/index.tsx","webpack://@diplodoc/client/./src/components/ConstructorPage/useContent.tsx","webpack://@diplodoc/client/./src/components/index.ts","webpack://@diplodoc/client/./src/components/Search/provider/index.ts","webpack://@diplodoc/client/./src/components/Search/useProvider.ts","webpack://@diplodoc/client/./src/components/Search/Suggest.tsx","webpack://@diplodoc/client/./src/components/HeaderControls/index.tsx","webpack://@diplodoc/client/./src/components/ConstructorPage/useNavigation.tsx","webpack://@diplodoc/client/./src/components/App/Page.tsx","webpack://@diplodoc/client/./src/components/App/Runtime.tsx","webpack://@diplodoc/client/./src/components/App/useLangs.ts","webpack://@diplodoc/client/./src/components/App/useSettings.ts","webpack://@diplodoc/client/./src/components/App/useMobile.ts","webpack://@diplodoc/client/./src/components/App/index.tsx","webpack://@diplodoc/client/./src/preprocess.ts","webpack://@diplodoc/client/./src/index.server.tsx","webpack://@diplodoc/client/./src/interceptors/leading-page-links.js","webpack://@diplodoc/client/./src/stub/empty-module.js","webpack://@diplodoc/client/./node_modules/picocolors/ sync","webpack://@diplodoc/client/external node-commonjs \"buffer\"","webpack://@diplodoc/client/external node-commonjs \"crypto\"","webpack://@diplodoc/client/external node-commonjs \"fs\"","webpack://@diplodoc/client/external node-commonjs \"node:assert\"","webpack://@diplodoc/client/external node-commonjs \"node:async_hooks\"","webpack://@diplodoc/client/external node-commonjs \"node:buffer\"","webpack://@diplodoc/client/external node-commonjs \"node:console\"","webpack://@diplodoc/client/external node-commonjs \"node:crypto\"","webpack://@diplodoc/client/external node-commonjs \"node:diagnostics_channel\"","webpack://@diplodoc/client/external node-commonjs \"node:events\"","webpack://@diplodoc/client/external node-commonjs \"node:http\"","webpack://@diplodoc/client/external node-commonjs \"node:http2\"","webpack://@diplodoc/client/external node-commonjs \"node:net\"","webpack://@diplodoc/client/external node-commonjs \"node:perf_hooks\"","webpack://@diplodoc/client/external node-commonjs \"node:querystring\"","webpack://@diplodoc/client/external node-commonjs \"node:stream\"","webpack://@diplodoc/client/external node-commonjs \"node:tls\"","webpack://@diplodoc/client/external node-commonjs \"node:url\"","webpack://@diplodoc/client/external node-commonjs \"node:util\"","webpack://@diplodoc/client/external node-commonjs \"node:util/types\"","webpack://@diplodoc/client/external node-commonjs \"node:worker_threads\"","webpack://@diplodoc/client/external node-commonjs \"node:zlib\"","webpack://@diplodoc/client/external node-commonjs \"os\"","webpack://@diplodoc/client/external node-commonjs \"path\"","webpack://@diplodoc/client/external node-commonjs \"process\"","webpack://@diplodoc/client/external node-commonjs \"punycode\"","webpack://@diplodoc/client/external node-commonjs \"stream\"","webpack://@diplodoc/client/external node-commonjs \"string_decoder\"","webpack://@diplodoc/client/external node-commonjs \"tty\"","webpack://@diplodoc/client/external node-commonjs \"url\"","webpack://@diplodoc/client/external node-commonjs \"util\"","webpack://@diplodoc/client/webpack/bootstrap","webpack://@diplodoc/client/webpack/runtime/amd options","webpack://@diplodoc/client/webpack/runtime/chunk loaded","webpack://@diplodoc/client/webpack/runtime/compat get default export","webpack://@diplodoc/client/webpack/runtime/define property getters","webpack://@diplodoc/client/webpack/runtime/ensure chunk","webpack://@diplodoc/client/webpack/runtime/get javascript chunk filename","webpack://@diplodoc/client/webpack/runtime/get mini-css chunk filename","webpack://@diplodoc/client/webpack/runtime/hasOwnProperty shorthand","webpack://@diplodoc/client/webpack/runtime/make namespace object","webpack://@diplodoc/client/webpack/runtime/node module decorator","webpack://@diplodoc/client/webpack/runtime/publicPath","webpack://@diplodoc/client/webpack/runtime/require chunk loading","webpack://@diplodoc/client/webpack/runtime/startup chunk dependencies","webpack://@diplodoc/client/webpack/before-startup","webpack://@diplodoc/client/webpack/startup","webpack://@diplodoc/client/webpack/after-startup"],"sourcesContent":["import React from 'react';\n\nexport const Search = () => {\n return <div>Initial</div>;\n};\n","import type {SearchConfig, WorkerApi, WorkerConfig} from './types';\n\nimport {createContext, useContext} from 'react';\n\nexport type {SearchConfig, WorkerConfig, WorkerApi};\n\nexport const SearchContext = createContext<SearchConfig | null | undefined>(null);\n\nSearchContext.displayName = 'SearchContext';\n\nexport const SearchProvider = SearchContext.Provider;\n\nexport {Search} from './Search';\n\nexport function useSearch() {\n return useContext(SearchContext);\n}\n","import type {Router} from '@diplodoc/components';\n\nimport {createContext, useContext} from 'react';\n\nexport interface RouterConfig extends Router {\n depth: number;\n}\n\nexport const RouterContext = createContext<RouterConfig>({\n pathname: '/',\n depth: 0,\n});\n\nRouterContext.displayName = 'RouterContext';\n\nexport const RouterProvider = RouterContext.Provider;\n\nexport function useRouter() {\n return useContext(RouterContext);\n}\n","import {TextSizes, Theme} from '@diplodoc/components';\n\nexport const HEADER_HEIGHT = 64;\n\nexport const MOBILE_VIEW_WIDTH_BREAKPOINT = 769;\n\nexport const DEFAULT_USER_SETTINGS = {\n theme: Theme.Light,\n textSize: TextSizes.M,\n showMiniToc: true,\n wideFormat: true,\n fullScreen: false,\n};\n\nexport const RTL_LANGS = [\n 'ar',\n 'arc',\n 'ckb',\n 'dv',\n 'fa',\n 'ha',\n 'he',\n 'khw',\n 'ks',\n 'ps',\n 'sd',\n 'ur',\n 'uz_AF',\n 'yi',\n];\n\nexport enum TextDirection {\n RTL = 'rtl',\n LTR = 'ltr',\n}\n\nexport const LINK_KEYS_LEADING_CONFIG = ['href'];\nexport const LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG = [\n 'src',\n 'url',\n 'href',\n 'icon',\n 'image',\n 'desktop',\n 'mobile',\n 'tablet',\n 'previewImg',\n 'image',\n 'avatar',\n 'logo',\n 'light',\n 'dark',\n];\n\nexport const LINK_KEYS = [\n ...new Set([...LINK_KEYS_LEADING_CONFIG, ...LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG]),\n];\n","import {Lang, Theme} from '@diplodoc/components';\n\nimport {\n DEFAULT_USER_SETTINGS,\n MOBILE_VIEW_WIDTH_BREAKPOINT,\n RTL_LANGS,\n TextDirection,\n} from './constants';\n\nexport function isBrowser() {\n return typeof document !== 'undefined';\n}\n\nexport function updateThemeClassName({theme}: {theme: Theme}) {\n if (typeof document === 'undefined') {\n return;\n }\n\n document.querySelectorAll('.g-root').forEach((el) => {\n el.classList.toggle('g-root_theme_light', theme === 'light');\n el.classList.toggle('g-root_theme_dark', theme === 'dark');\n });\n}\n\nexport function updateRootClassName(states: {\n mobileView?: boolean;\n wideFormat?: boolean;\n fullScreen?: boolean;\n focusSearch?: boolean;\n}) {\n if (!isBrowser()) {\n return;\n }\n\n document.body.classList.add('g-root');\n\n const toggle = (name: string, state: unknown) =>\n document.body.classList.toggle(name, Boolean(state));\n\n Object.keys(states).forEach((state) => {\n switch (state) {\n case 'wideFormat':\n toggle('dc-root_wide-format', states[state]);\n break;\n case 'focusSearch':\n toggle('dc-root_focused-search', states[state]);\n break;\n case 'fullScreen':\n toggle('dc-root_full-screen', states[state]);\n break;\n case 'mobileView':\n toggle('mobile', states[state]);\n toggle('desktop', !states[state]);\n break;\n }\n });\n}\n\nexport function getDirection(lang: Lang): TextDirection {\n const isRTL = RTL_LANGS.includes(lang);\n\n return isRTL ? TextDirection.RTL : TextDirection.LTR;\n}\n\nconst toBoolean = (str: string | boolean) => {\n if (typeof str === 'boolean') {\n return str;\n }\n\n return str ? str === 'true' : false;\n};\n\nexport type Settings = typeof DEFAULT_USER_SETTINGS;\n\nexport function getSettings() {\n const theme = getSetting('theme');\n const textSize = getSetting('textSize');\n const showMiniToc = getSetting('showMiniToc');\n const wideFormat = getSetting('wideFormat');\n const fullScreen = getSetting('fullScreen');\n\n return {\n theme,\n textSize,\n showMiniToc: toBoolean(showMiniToc),\n wideFormat: toBoolean(wideFormat),\n fullScreen: toBoolean(fullScreen),\n };\n}\n\nexport function getMobileView() {\n if (!isBrowser()) {\n return false;\n }\n\n return document.body.clientWidth < MOBILE_VIEW_WIDTH_BREAKPOINT;\n}\n\nfunction getSetting<T extends keyof Settings>(name: T): Settings[T] {\n if (!isBrowser()) {\n return DEFAULT_USER_SETTINGS[name];\n }\n\n try {\n return (sessionStorage.getItem(name) as Settings[T]) || DEFAULT_USER_SETTINGS[name];\n } catch {\n return DEFAULT_USER_SETTINGS[name];\n }\n}\n\nexport function setSetting<T>(name: string, value: T) {\n if (!isBrowser()) {\n return;\n }\n\n try {\n sessionStorage.setItem(name, String(value));\n } catch {}\n}\n","import {createContext, useContext} from 'react';\nimport {Lang} from '@diplodoc/components';\n\nconst LangContext = createContext<Lang>(Lang.En);\n\nLangContext.displayName = 'Lang';\n\nexport const LangProvider = LangContext.Provider;\n\nexport function useLang() {\n return useContext(LangContext);\n}\n","import {getMobileView, getSettings, updateRootClassName, updateThemeClassName} from '../utils';\n\nif (typeof document !== 'undefined') {\n const {theme, wideFormat, fullScreen} = getSettings();\n const mobileView = getMobileView();\n\n updateRootClassName({mobileView, wideFormat, fullScreen});\n updateThemeClassName({theme});\n}\n","import React, {FC, PropsWithChildren, ReactElement} from 'react';\nimport block from 'bem-cn-lite';\n\nimport './Layout.scss';\n\nconst b = block('Layout');\n\nfunction Header() {\n return null;\n}\n\nfunction Content() {\n return null;\n}\n\nfunction Footer() {\n return null;\n}\n\ntype LayoutStatics = {\n Header: FC<PropsWithChildren>;\n Content: FC<PropsWithChildren>;\n Footer: FC<PropsWithChildren>;\n};\n\ntype LayoutProps = {\n doc?: boolean;\n headerHeight?: number;\n};\n\nconst defaults = {\n doc: false,\n};\n\nexport const Layout: LayoutStatics & FC<PropsWithChildren<LayoutProps>> = (props) => {\n const {children, doc, headerHeight = 0} = {...defaults, ...props};\n let header, content, footer;\n\n React.Children.forEach(children as ReactElement[], (child: ReactElement) => {\n switch (child.type) {\n case Header:\n header = child.props.children;\n break;\n case Content:\n content = child.props.children;\n break;\n case Footer:\n footer = child.props.children;\n break;\n }\n });\n\n return (\n <div className={b({'full-header': headerHeight > 0})}>\n {header && <div className={b('header')}>{header}</div>}\n <div className={b('body')}>\n {content && <div className={b('content')}>{content}</div>}\n {footer && <div className={b('footer', {doc})}>{footer}</div>}\n </div>\n </div>\n );\n};\n\nLayout.displayName = 'Layout';\n\nLayout.Header = Header;\nLayout.Content = Content;\nLayout.Footer = Footer;\n","import type {PropsWithChildren} from 'react';\nimport type {PageContent} from '@gravity-ui/page-constructor';\n\nimport React from 'react';\nimport block from 'bem-cn-lite';\nimport {\n BackgroundMedia,\n Col,\n ConstructorBlocks,\n Grid,\n Row,\n getThemedValue,\n useTheme,\n} from '@gravity-ui/page-constructor';\n\nconst bPC = block('pc-page-constructor');\nconst bPCRow = block('pc-constructor-row');\n\nexport const ConstructorRow = ({children}: PropsWithChildren) =>\n children ? (\n <Row className={bPCRow()}>\n <Col>{children}</Col>\n </Row>\n ) : null;\n\nexport function ConstructorPage({background, blocks}: PageContent) {\n const theme = useTheme();\n const themedBackground = getThemedValue(background, theme);\n\n return (\n <div className={bPC('docs')}>\n <div className={bPC('wrapper')}>\n {blocks && themedBackground && (\n <BackgroundMedia {...themedBackground} className={bPC('background')} />\n )}\n <Grid>\n <ConstructorRow>\n <ConstructorBlocks items={blocks} />\n </ConstructorRow>\n </Grid>\n </div>\n </div>\n );\n}\n","import type {ReactNode} from 'react';\nimport type {PageContent} from '@gravity-ui/page-constructor';\nimport type {DocContentPageData} from '@diplodoc/components';\n\nimport {DocumentType, getPageType} from '@diplodoc/components';\nimport {useMemo} from 'react';\n\nexport const useContent = (data: DocContentPageData, CustomPage: () => ReactNode) => {\n const type = getPageType(data);\n const fullScreen =\n type === DocumentType.PageConstructor &&\n 'data' in data &&\n 'fullScreen' in data.data &&\n data.data.fullScreen;\n\n const layout = useMemo(\n () =>\n fullScreen\n ? (data.data as PageContent)\n : {\n blocks: [\n {\n type: 'page',\n resetPaddings: true,\n },\n ],\n },\n [fullScreen, data],\n );\n\n const config = useMemo(\n () => ({\n custom: {\n page: CustomPage,\n },\n layout,\n }),\n [CustomPage, layout],\n );\n\n return config;\n};\n","export {SearchContext, SearchProvider, useSearch} from './Search';\nexport {RouterContext, RouterProvider, useRouter} from './Router';\n\nexport {App} from './App';\n","import type {ISearchProvider, ISearchResult} from '@diplodoc/components';\nimport type {SearchConfig, WorkerConfig} from '../types';\n\nexport class SearchProvider implements ISearchProvider {\n private worker!: Promise<Worker>;\n\n private config: SearchConfig;\n\n constructor(config: SearchConfig) {\n this.config = config;\n }\n\n init = () => {\n this.worker = initWorker({\n ...this.config,\n base: this.base,\n mark: 'Suggest__Item__Marker',\n });\n };\n\n async suggest(query: string) {\n return this.request({\n type: 'suggest',\n query,\n }) as Promise<ISearchResult[]>;\n }\n\n async search(query: string) {\n return this.request({\n type: 'search',\n query,\n }) as Promise<ISearchResult[]>;\n }\n\n // Temporary disable link to search page\n // TODO: Implement search page\n link = () => null;\n\n // link = (query: string) => {\n // const params = query ? `?query=${encodeURIComponent(query)}` : '';\n //\n // return `${this.base}/${this.config.link}${params}`;\n // };\n\n private get base() {\n return window.location.href.split('/').slice(0, -this.config.depth).join('/');\n }\n\n private async request(message: object) {\n return request(await this.worker, message);\n }\n}\n\nconst BAD_ORIGIN_ERROR = /Script at '(.*?)' cannot be accessed from origin/;\n\nasync function loadWorker() {\n try {\n return new Worker(new URL('../worker/index.ts', import.meta.url));\n } catch (error) {\n // @see https://stackoverflow.com/questions/21408510/chrome-cant-load-web-worker\n if (error instanceof DOMException) {\n const match = BAD_ORIGIN_ERROR.exec(error.message);\n if (match) {\n const url = match[1];\n const blob = new Blob([`importScripts('${url}');`], {type: 'text/javascript'});\n\n return new Worker(URL.createObjectURL(blob));\n }\n }\n\n throw error;\n }\n}\n\nasync function initWorker(config: WorkerConfig) {\n const worker = await loadWorker();\n\n await request(worker, {...config, type: 'init'});\n\n return worker;\n}\n\nfunction request(worker: Worker, message: object) {\n const channel = new MessageChannel();\n\n return new Promise((resolve, reject) => {\n channel.port1.onmessage = (message) => {\n if (message.data.error) {\n // eslint-disable-next-line no-console\n console.error(message.data.error);\n\n reject(message.data.error);\n } else {\n resolve(message.data.result);\n }\n };\n\n channel.port1.onmessageerror = (message) => {\n reject(message.data.error);\n };\n\n worker.postMessage(message, [channel.port2]);\n });\n}\n","import {useContext, useMemo} from 'react';\n\nimport {RouterContext, SearchContext} from '../index';\nimport {useLang} from '../../hooks/useLang';\n\nimport {SearchProvider} from './provider';\n\nexport function useProvider() {\n const lang = useLang();\n const {depth = 0} = useContext(RouterContext);\n const search = useContext(SearchContext);\n\n return useMemo(() => {\n if (!search) {\n return null;\n }\n\n return new SearchProvider({\n ...search,\n depth,\n lang,\n });\n }, [lang, depth, search]);\n}\n","import type {ISearchProvider, SearchSuggestApi} from '@diplodoc/components';\n\nimport React, {useCallback, useRef} from 'react';\nimport {SearchSuggest} from '@diplodoc/components';\n\nimport {updateRootClassName} from '../../utils';\n\nimport {useProvider} from './useProvider';\nimport './Suggest.scss';\n\nexport function Suggest() {\n const provider: ISearchProvider | null = useProvider();\n const suggest = useRef<SearchSuggestApi>(null);\n\n const onFocus = useCallback(() => {\n updateRootClassName({focusSearch: true});\n }, []);\n\n const onBlur = useCallback(() => {\n updateRootClassName({focusSearch: false});\n setTimeout(() => {\n if (suggest.current) {\n suggest.current.close();\n }\n }, 100);\n }, []);\n\n if (!provider) {\n return null;\n }\n\n return (\n <SearchSuggest\n ref={suggest}\n provider={provider}\n onFocus={onFocus}\n onBlur={onBlur}\n classNameContainer={'Suggest'}\n />\n );\n}\n","import React, {memo} from 'react';\nimport {ControlSizes, Controls, ControlsLayout, Lang, TextSizes, Theme} from '@diplodoc/components';\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\ntype OnChangeCallback = (value: any) => void;\n\nexport type Props = {\n mobileView: boolean;\n\n theme: Theme;\n onChangeTheme: OnChangeCallback;\n textSize: TextSizes;\n onChangeTextSize: OnChangeCallback;\n wideFormat: boolean;\n onChangeWideFormat: OnChangeCallback;\n showMiniToc: boolean;\n onChangeShowMiniToc: OnChangeCallback;\n lang: Lang;\n langs: Lang[];\n onChangeLang?: (lang: Lang) => void;\n};\n\nexport const HeaderControls = memo<Props>(\n ({\n mobileView,\n\n theme,\n onChangeTheme,\n\n textSize,\n onChangeTextSize,\n\n wideFormat,\n onChangeWideFormat,\n\n showMiniToc,\n onChangeShowMiniToc,\n\n lang,\n langs,\n onChangeLang,\n }) => {\n return (\n <ControlsLayout\n controlClassName={'Control'}\n controlSize={ControlSizes.L}\n isWideView={mobileView}\n isMobileView={mobileView}\n >\n <Controls\n className={'Controls'}\n theme={theme}\n onChangeTheme={onChangeTheme}\n wideFormat={wideFormat}\n onChangeWideFormat={onChangeWideFormat}\n showMiniToc={showMiniToc}\n onChangeShowMiniToc={onChangeShowMiniToc}\n textSize={textSize}\n onChangeTextSize={onChangeTextSize}\n lang={lang}\n langs={langs}\n onChangeLang={onChangeLang}\n />\n </ControlsLayout>\n );\n },\n);\n\nHeaderControls.displayName = 'HeaderControls';\n","import type {ReactNode} from 'react';\nimport type {NavigationData, NavigationItemModel} from '@gravity-ui/page-constructor';\nimport type {DocBasePageData} from '@diplodoc/components';\nimport type {WithNavigation} from '../App';\nimport type {Props as HeaderControlsProps} from '../HeaderControls';\n\nimport React, {useMemo} from 'react';\nimport {ControlSizes, CustomNavigation, MobileDropdown} from '@diplodoc/components';\n\nimport {HEADER_HEIGHT} from '../../constants';\nimport {useRouter, useSearch} from '../';\n\nfunction findItem(right: NavigationItemModel[], left: NavigationItemModel[], type: string) {\n return right.some((item) => item.type === type) || left.some((item) => item.type === type);\n}\n\nexport const useNavigation = (\n data: DocBasePageData<WithNavigation>,\n controls: HeaderControlsProps,\n CustomControls: () => ReactNode,\n CustomSuggest: () => ReactNode,\n) => {\n const {toc} = data;\n const {navigation} = toc;\n const {header = {}, logo} = navigation;\n const {leftItems = [], rightItems = []} = header as NavigationData['header'];\n\n const withControls = findItem(rightItems, leftItems, 'controls');\n const withSearch = findItem(rightItems, leftItems, 'search');\n\n const search = useSearch();\n const router = useRouter();\n\n if (search && !withSearch) {\n rightItems.unshift({type: 'search'} as unknown as NavigationItemModel);\n }\n\n const navigationData = useMemo(\n () => ({\n withBorder: true,\n leftItems: leftItems,\n rightItems: rightItems,\n }),\n [leftItems, rightItems],\n );\n const navigationTocData = useMemo(\n () => ({\n toc,\n router,\n headerHeight: HEADER_HEIGHT,\n }),\n [toc, router],\n );\n const mobileControlsData = useMemo(\n () => ({\n controlSize: ControlSizes.L,\n userSettings: controls,\n }),\n [controls],\n );\n\n const layout = useMemo(\n () => ({\n header: {\n leftItems: [],\n },\n renderNavigation: () => (\n <CustomNavigation\n logo={logo}\n data={navigationData}\n navigationTocData={navigationTocData}\n mobileControlsData={mobileControlsData}\n />\n ),\n logo,\n }),\n [navigationData, navigationTocData, mobileControlsData, logo],\n );\n\n const config = useMemo(\n () => ({\n custom: {\n search: CustomSuggest,\n controls: CustomControls,\n MobileDropdown: MobileDropdown,\n },\n layout,\n withControls,\n }),\n [CustomSuggest, CustomControls, layout, withControls],\n );\n\n return config;\n};\n","import type {PropsWithChildren} from 'react';\nimport type {AppProps, PageData} from './index';\nimport type {Settings} from '../../utils';\n\nimport React, {useCallback, useMemo} from 'react';\nimport {PageConstructor, PageConstructorProvider} from '@gravity-ui/page-constructor';\nimport {DocBasePageData, getPageByType, getPageType} from '@diplodoc/components';\n\nimport {Layout} from '../Layout';\nimport {ConstructorPage} from '../ConstructorPage';\nimport {useContent} from '../ConstructorPage/useContent';\nimport {Suggest} from '../Search/Suggest';\nimport {HeaderControls, Props as HeaderControlsProps} from '../HeaderControls';\nimport {useNavigation} from '../ConstructorPage/useNavigation';\n\nimport {DocContentPageData, WithNavigation} from './index';\n\ntype Props = PropsWithChildren<Partial<AppProps> & {data: PageData; headerHeight: number}>;\n\nexport function Page({data, ...pageProps}: Props) {\n const type = getPageType(data);\n const Page = getPageByType(type);\n\n return (\n <Layout headerHeight={pageProps.headerHeight}>\n <Layout.Content>\n {/*@ts-ignore*/}\n <Page {...data} {...pageProps} />\n </Layout.Content>\n </Layout>\n );\n}\n\ntype PageProps<T extends {} = {}> = {\n data: DocBasePageData<T> & PageData;\n props: {\n router: AppProps['router'];\n } & Settings;\n controls: HeaderControlsProps;\n};\n\nconst EMPTY = {};\n\nexport function LegacyNavPage({data, props, controls}: PageProps) {\n const {theme} = props;\n\n const CustomPage = useCallback(\n () => <ConstructorPage {...(data as DocContentPageData).data} />,\n [data],\n );\n const content = useContent(data as DocContentPageData, CustomPage);\n\n const custom = useMemo(\n () => ({\n blocks: content.custom,\n }),\n [content],\n );\n\n return (\n <Page data={data} headerHeight={0} {...props} {...controls}>\n <PageConstructorProvider theme={theme}>\n <PageConstructor custom={custom} content={content.layout} />\n </PageConstructorProvider>\n </Page>\n );\n}\n\nexport function RichNavPage({data, props, controls}: PageProps<WithNavigation>) {\n const {theme, fullScreen} = props;\n\n const CustomSuggest = useCallback(() => <Suggest />, []);\n const CustomControls = useCallback(() => <HeaderControls {...controls} />, [controls]);\n const navigation = useNavigation(data, controls, CustomControls, CustomSuggest);\n\n const CustomPage = useCallback(\n () => (\n <Page\n data={data}\n headerHeight={fullScreen ? 0 : 64}\n {...props}\n {...(navigation.withControls ? EMPTY : controls)}\n >\n <ConstructorPage {...(data as DocContentPageData).data} />\n </Page>\n ),\n [data, navigation, props, controls, fullScreen],\n );\n const content = useContent(data as DocContentPageData, CustomPage);\n\n const custom = useMemo(\n () => ({\n navigation: navigation.custom,\n blocks: content.custom,\n }),\n [navigation, content],\n );\n\n return (\n <PageConstructorProvider theme={theme}>\n <PageConstructor\n custom={custom}\n content={content.layout}\n navigation={fullScreen ? undefined : navigation.layout}\n />\n </PageConstructorProvider>\n );\n}\n","import React from 'react';\nimport {MermaidRuntime} from '@diplodoc/mermaid-extension/react';\nimport {LatexRuntime} from '@diplodoc/latex-extension/react';\nimport {Runtime as OpenapiSandbox} from '@diplodoc/openapi-extension/runtime';\nimport {Theme} from '@diplodoc/components';\nimport {useTheme} from '@gravity-ui/uikit';\n\nexport function Runtime() {\n const theme = useTheme();\n\n return (\n <>\n <OpenapiSandbox />\n <LatexRuntime />\n <MermaidRuntime\n theme={theme === Theme.Dark ? 'dark' : 'neutral'}\n zoom={{\n showMenu: true,\n bindKeys: true,\n }}\n />\n </>\n );\n}\n","import type {AppProps} from './index';\n\nimport {Lang, getLangPath} from '@diplodoc/components';\nimport {useCallback, useMemo} from 'react';\n\nexport function useLangs({router, lang, langs}: AppProps) {\n const onChangeLang = useCallback(\n (lang: Lang) => {\n const path = getLangPath(router, lang);\n window.location.replace(path);\n },\n [router],\n );\n\n return useMemo(() => ({lang, langs, onChangeLang}), [lang, langs, onChangeLang]);\n}\n","import type {Settings} from '../../utils';\n\nimport {useMemo, useState} from 'react';\n\nimport {getSettings, setSetting} from '../../utils';\n\nconst capitalize = <T extends string>(string: T): Capitalize<T> =>\n string.replace(/^./, (ch) => ch.toUpperCase()) as Capitalize<T>;\n\nexport function useSettings() {\n const settings = getSettings();\n\n const theme = useSetting('theme', settings);\n const textSize = useSetting('textSize', settings);\n const wideFormat = useSetting('wideFormat', settings);\n const fullScreen = useSetting('fullScreen', settings);\n const showMiniToc = useSetting('showMiniToc', settings);\n\n const controls = useMemo(\n () => ({\n ...theme,\n ...textSize,\n ...wideFormat,\n ...showMiniToc,\n ...fullScreen,\n }),\n [theme, textSize, wideFormat, showMiniToc, fullScreen],\n );\n\n return controls;\n}\n\ntype State<P extends keyof Settings> = {\n [prop in P]: Settings[P];\n} & {\n [prop in `onChange${Capitalize<P>}`]: (value: Settings[P]) => void;\n};\n\nfunction useSetting<P extends keyof Settings>(name: P, settings: Settings): State<P> {\n const [setting, setSetting] = useState<Settings[P]>(settings[name]);\n const onChangeSetting = useMemo(() => withSavingSetting(name, setSetting), [name, setSetting]);\n\n return useMemo(\n () =>\n ({\n [name]: setting,\n ['onChange' + capitalize(name)]: onChangeSetting,\n }) as State<P>,\n [name, setting, onChangeSetting],\n );\n}\n\nfunction withSavingSetting<T>(settingName: string, onChange: (value: T) => void) {\n return (value: T) => {\n setSetting<T>(settingName, value);\n\n onChange(value);\n };\n}\n","import {useCallback, useEffect, useState} from 'react';\n\nimport {getMobileView} from '../../utils';\n\nexport function useMobile() {\n const [mobileView, setMobileView] = useState<boolean>(getMobileView());\n\n const onResizeHandler = useCallback(() => {\n setMobileView(getMobileView());\n }, []);\n\n useEffect(onResizeHandler, [onResizeHandler]);\n\n useEffect(() => {\n window.addEventListener('resize', onResizeHandler);\n\n return () => window.removeEventListener('resize', onResizeHandler);\n }, [onResizeHandler]);\n\n return mobileView;\n}\n","import type {NavigationData, PageContent} from '@gravity-ui/page-constructor';\nimport type {ReactElement} from 'react';\nimport type {Props as HeaderControlsProps} from '../HeaderControls';\nimport type {SearchConfig} from '../Search';\nimport type {RouterConfig} from '../Router';\n\nimport React, {useEffect, useMemo} from 'react';\nimport {ThemeProvider} from '@gravity-ui/uikit';\nimport {\n ConsentPopup,\n DocBasePageData,\n DocContentPageData as DocContentPageDataBase,\n DocLeadingPageData,\n DocPageData,\n Lang,\n configure,\n} from '@diplodoc/components';\nimport '@diplodoc/transform/dist/js/yfm';\n\nimport {SearchProvider} from '../Search';\nimport {RouterProvider} from '../Router';\nimport {getDirection, updateRootClassName, updateThemeClassName} from '../../utils';\nimport {LangProvider} from '../../hooks/useLang';\nimport '../../interceptors/leading-page-links';\nimport '../../interceptors/fast-class-applier';\n\nimport {LegacyNavPage, RichNavPage} from './Page';\nimport {Runtime} from './Runtime';\nimport {useLangs} from './useLangs';\nimport {useSettings} from './useSettings';\nimport {useMobile} from './useMobile';\nimport './App.scss';\n\nexport type DocAnalytics = {\n gtm?: {\n id?: string;\n mode?: 'base' | 'notification';\n };\n};\n\nexport interface AppProps {\n lang: Lang;\n langs: Lang[];\n router: RouterConfig;\n search?: SearchConfig;\n analytics?: DocAnalytics;\n}\n\nexport type WithNavigation = {\n navigation: NavigationData;\n};\n\nexport type DocContentPageData = DocContentPageDataBase<PageContent>;\n\nexport type PageData = DocPageData | DocLeadingPageData | DocContentPageData;\n\nexport type DocInnerProps<Data extends PageData = PageData> = {\n data: Data;\n} & AppProps;\n\nexport type {DocLeadingPageData, DocPageData};\n\nfunction hasNavigation(\n data: DocBasePageData<Partial<WithNavigation>>,\n): data is DocBasePageData<WithNavigation> {\n return Boolean(data.toc.navigation);\n}\n\nexport function App(props: DocInnerProps): ReactElement {\n const {data, router, lang, search, analytics} = props;\n\n configure({\n lang,\n });\n\n const settings = useSettings();\n const langs = useLangs(props);\n const mobileView = useMobile();\n\n const {theme, textSize, wideFormat, fullScreen, showMiniToc} = settings;\n\n const page = useMemo(\n () => ({\n router,\n\n theme,\n textSize,\n wideFormat,\n fullScreen,\n showMiniToc,\n }),\n [router, theme, textSize, wideFormat, fullScreen, showMiniToc],\n );\n const controls: HeaderControlsProps = useMemo(\n () => ({\n ...settings,\n ...langs,\n mobileView,\n }),\n [langs, settings, mobileView],\n );\n const direction = getDirection(lang);\n\n useEffect(() => {\n updateRootClassName({mobileView, wideFormat, fullScreen});\n updateThemeClassName({theme});\n }, [theme, mobileView, wideFormat, fullScreen]);\n\n return (\n <div className=\"App\">\n <ThemeProvider theme={theme} direction={direction}>\n <LangProvider value={lang}>\n <RouterProvider value={router}>\n <SearchProvider value={search}>\n {hasNavigation(data) ? (\n <RichNavPage data={data} props={page} controls={controls} />\n ) : (\n <LegacyNavPage data={data} props={page} controls={controls} />\n )}\n {analytics && (\n <ConsentPopup\n router={router}\n gtmId={analytics?.gtm?.id || ''}\n consentMode={analytics?.gtm?.mode}\n />\n )}\n <Runtime />\n </SearchProvider>\n </RouterProvider>\n </LangProvider>\n </ThemeProvider>\n </div>\n );\n}\n","import {\n Block,\n ConstructorBlock,\n NavigationData as ConstructorNavigaitonData,\n PageContent as ConstructorPageContentBase,\n} from '@gravity-ui/page-constructor';\nimport {\n BlocksConfig,\n Parser,\n TransformerRaw,\n config,\n contentTransformer,\n} from '@gravity-ui/page-constructor/server';\n\nexport interface MetaData {\n title: string;\n description?: string;\n}\n\nexport interface PageContentBase {\n meta?: MetaData;\n}\n\nexport enum Lang {\n RU = 'ru',\n EN = 'en',\n}\n\nexport type PageContent<T> = T & PageContentBase;\nexport type ConstructorPageContent = PageContent<ConstructorPageContentBase>;\nexport type NavigationData = PageContent<ConstructorNavigaitonData>;\nexport type ConfigData = ConstructorPageContent | NavigationData;\n\nexport interface PreloadParams {\n lang: Lang;\n pageName: string;\n pageReferer?: string;\n}\n\ninterface BlockConfig {\n transformer: TransformerRaw;\n fields?: string[];\n parser?: Parser;\n}\n\nexport function isPageConfig(config: ConfigData): config is ConstructorPageContent {\n return 'blocks' in config;\n}\n\nexport function preprocess(\n content: ConfigData,\n params: PreloadParams,\n customYfmTransformer: TransformerRaw,\n) {\n const {lang} = params;\n\n if (isPageConfig(content) && content.blocks) {\n return {\n ...content,\n blocks: transformBlocks(content.blocks, lang, customYfmTransformer),\n };\n }\n\n return content;\n}\n\nfunction replaceTransformer(config: BlocksConfig, newTransformer: TransformerRaw): BlocksConfig {\n return Object.keys(config).reduce((newConfig, subBlockType) => {\n const subBlock = config[subBlockType];\n\n if (Array.isArray(subBlock)) {\n newConfig[subBlockType] = subBlock.map((block: {transformer: {name: string}}) => {\n return block.transformer.name === 'yfmTransformer'\n ? {...block, transformer: newTransformer}\n : block;\n }) as BlockConfig[];\n } else {\n newConfig[subBlockType] =\n subBlock.transformer.name === 'yfmTransformer'\n ? {...subBlock, transformer: newTransformer}\n : subBlock;\n }\n\n return newConfig;\n }, {} as BlocksConfig);\n}\n\nfunction transformBlocks(\n blocks: ConstructorBlock[],\n lang: Lang,\n customYfmTransformer: TransformerRaw,\n) {\n const customConfig = replaceTransformer(config, customYfmTransformer);\n\n return contentTransformer({\n content: {blocks},\n options: {\n lang,\n customConfig,\n },\n }).blocks as Block[];\n}\n","import React from 'react';\nimport {renderToString} from 'react-dom/server';\n\nimport {App, DocAnalytics, DocInnerProps, DocLeadingPageData, DocPageData} from './components/App';\nimport {LINK_KEYS, LINK_KEYS_LEADING_CONFIG, LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG} from './constants';\nimport {preprocess} from './preprocess';\n\nexport type {DocInnerProps, DocPageData, DocLeadingPageData, DocAnalytics};\nexport type {\n SearchConfig as ISearchProviderConfig,\n WorkerConfig as ISearchWorkerConfig,\n WorkerApi as ISearchWorkerApi,\n} from './components/Search';\nexport {LINK_KEYS, LINK_KEYS_LEADING_CONFIG, LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG, preprocess};\n\nexport const render = (props: DocInnerProps) => renderToString(<App {...props} />);\n","(function () {\n /**\n * Element.matches() polyfill.\n * @link https://developer.mozilla.org/ru/docs/Web/API/Element/matches\n */\n if (typeof Element !== 'undefined') {\n (function (e) {\n const matches =\n e.matches ||\n e.matchesSelector ||\n e.webkitMatchesSelector ||\n e.mozMatchesSelector ||\n e.msMatchesSelector ||\n e.oMatchesSelector;\n\n if (matches) {\n e.matches = e.matchesSelector = matches;\n } else {\n e.matches = e.matchesSelector = function (selector) {\n const th = this;\n return Array.prototype.some.call(document.querySelectorAll(selector), (el) => {\n return el === th;\n });\n };\n }\n })(Element.prototype);\n }\n\n if (typeof document !== 'undefined') {\n document.addEventListener('click', (event) => {\n const href = event.target.href;\n const locationOrigin = window.location.origin;\n\n if (\n event.target.matches('.dc-doc-layout__center a') &&\n href.startsWith(locationOrigin)\n ) {\n event.preventDefault();\n\n const mainFileName = 'index';\n const extention = '.html';\n\n if (href.endsWith('/')) {\n window.location.href = `${href}${mainFileName}${extention}`;\n return;\n }\n\n // https://../file-name, https://../file-name#fragment\n const splitedHref = href.split('#');\n if (splitedHref.length > 0 && !splitedHref[0].endsWith(extention)) {\n splitedHref[0] += extention;\n window.location.href = splitedHref.join('#');\n return;\n }\n\n window.location.href = href;\n }\n });\n }\n})();\n","export default function () {}\n","function webpackEmptyContext(req) {\n\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\te.code = 'MODULE_NOT_FOUND';\n\tthrow e;\n}\nwebpackEmptyContext.keys = () => ([]);\nwebpackEmptyContext.resolve = webpackEmptyContext;\nwebpackEmptyContext.id = 29249;\nmodule.exports = webpackEmptyContext;","module.exports = require(\"buffer\");","module.exports = require(\"crypto\");","module.exports = require(\"fs\");","module.exports = require(\"node:assert\");","module.exports = require(\"node:async_hooks\");","module.exports = require(\"node:buffer\");","module.exports = require(\"node:console\");","module.exports = require(\"node:crypto\");","module.exports = require(\"node:diagnostics_channel\");","module.exports = require(\"node:events\");","module.exports = require(\"node:http\");","module.exports = require(\"node:http2\");","module.exports = require(\"node:net\");","module.exports = require(\"node:perf_hooks\");","module.exports = require(\"node:querystring\");","module.exports = require(\"node:stream\");","module.exports = require(\"node:tls\");","module.exports = require(\"node:url\");","module.exports = require(\"node:util\");","module.exports = require(\"node:util/types\");","module.exports = require(\"node:worker_threads\");","module.exports = require(\"node:zlib\");","module.exports = require(\"os\");","module.exports = require(\"path\");","module.exports = require(\"process\");","module.exports = require(\"punycode\");","module.exports = require(\"stream\");","module.exports = require(\"string_decoder\");","module.exports = require(\"tty\");","module.exports = require(\"url\");","module.exports = require(\"util\");","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [644,121], () => (__webpack_require__(60204)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","__webpack_require__.amdO = {};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + ({\"121\":\"vendor\",\"644\":\"react\"}[chunkId] || chunkId) + \".js\";\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.miniCssF = (chunkId) => {\n\t// return url for filenames based on template\n\treturn undefined;\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.p = \"\";","__webpack_require__.b = require(\"url\").pathToFileURL(__filename);\n\n// object to store loaded chunks\n// \"1\" means \"loaded\", otherwise not loaded yet\nvar installedChunks = {\n\t524: 1\n};\n\n__webpack_require__.O.require = (chunkId) => (installedChunks[chunkId]);\n\nvar installChunk = (chunk) => {\n\tvar moreModules = chunk.modules, chunkIds = chunk.ids, runtime = chunk.runtime;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\tfor(var i = 0; i < chunkIds.length; i++)\n\t\tinstalledChunks[chunkIds[i]] = 1;\n\t__webpack_require__.O();\n};\n\n// require() chunk loading for javascript\n__webpack_require__.f.require = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\tinstallChunk(require(\"./\" + __webpack_require__.u(chunkId)));\n\t\t} else installedChunks[chunkId] = 1;\n\t}\n};\n\n// no external install chunk\n\n// no HMR\n\n// no HMR manifest","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\t__webpack_require__.e(644);\n\t__webpack_require__.e(121);\n\treturn next();\n};","","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n",""],"names":["React","Search","createElement","createContext","useContext","SearchContext","displayName","SearchProvider","Provider","useSearch","RouterContext","pathname","depth","RouterProvider","useRouter","TextSizes","Theme","HEADER_HEIGHT","MOBILE_VIEW_WIDTH_BREAKPOINT","DEFAULT_USER_SETTINGS","theme","Light","textSize","M","showMiniToc","wideFormat","fullScreen","RTL_LANGS","TextDirection","LINK_KEYS_LEADING_CONFIG","LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG","LINK_KEYS","Set","isBrowser","document","updateThemeClassName","querySelectorAll","forEach","el","classList","toggle","updateRootClassName","states","body","add","name","state","Boolean","Object","keys","getDirection","lang","isRTL","includes","RTL","LTR","toBoolean","str","getSettings","getSetting","getMobileView","clientWidth","sessionStorage","getItem","setSetting","value","setItem","String","Lang","LangContext","En","LangProvider","useLang","mobileView","block","b","Header","Content","Footer","defaults","doc","Layout","props","children","headerHeight","header","content","footer","Children","child","type","className","BackgroundMedia","Col","ConstructorBlocks","Grid","Row","getThemedValue","useTheme","bPC","bPCRow","ConstructorRow","ConstructorPage","background","blocks","themedBackground","assign","items","DocumentType","getPageType","useMemo","useContent","data","CustomPage","PageConstructor","layout","resetPaddings","config","custom","page","App","constructor","_defineProperty","worker","initWorker","base","mark","suggest","query","request","search","window","location","href","split","slice","join","message","BAD_ORIGIN_ERROR","loadWorker","Worker","URL","import","meta","url","error","DOMException","match","exec","blob","Blob","createObjectURL","channel","MessageChannel","Promise","resolve","reject","port1","onmessage","console","result","onmessageerror","postMessage","port2","useProvider","useCallback","useRef","SearchSuggest","Suggest","provider","onFocus","focusSearch","onBlur","setTimeout","current","close","ref","classNameContainer","memo","ControlSizes","Controls","ControlsLayout","HeaderControls","onChangeTheme","onChangeTextSize","onChangeWideFormat","onChangeShowMiniToc","langs","onChangeLang","controlClassName","controlSize","L","isWideView","isMobileView","CustomNavigation","MobileDropdown","findItem","right","left","some","item","useNavigation","controls","CustomControls","CustomSuggest","toc","navigation","logo","leftItems","rightItems","withControls","withSearch","router","unshift","navigationData","withBorder","navigationTocData","mobileControlsData","userSettings","renderNavigation","PageConstructorProvider","getPageByType","Page","pageProps","EMPTY","LegacyNavPage","RichNavPage","undefined","MermaidRuntime","LatexRuntime","Runtime","OpenapiSandbox","Fragment","Dark","zoom","showMenu","bindKeys","getLangPath","useLangs","path","replace","useState","capitalize","string","ch","toUpperCase","useSettings","settings","useSetting","setting","onChangeSetting","withSavingSetting","settingName","onChange","useEffect","useMobile","setMobileView","onResizeHandler","addEventListener","removeEventListener","ThemeProvider","ConsentPopup","configure","hasNavigation","analytics","direction","gtmId","gtm","id","consentMode","mode","contentTransformer","isPageConfig","preprocess","params","customYfmTransformer","transformBlocks","replaceTransformer","newTransformer","reduce","newConfig","subBlockType","subBlock","Array","isArray","map","transformer","customConfig","options","renderToString","render","Element","e","matches","matchesSelector","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","oMatchesSelector","selector","th","prototype","call","event","target","locationOrigin","origin","startsWith","preventDefault","mainFileName","extention","endsWith","splitedHref","length"],"sourceRoot":""}
1
+ {"version":3,"file":"app.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAA0B;AAEnB,MAAMC,MAAM,GAAGA,CAAA,KAAM;EACxB,oBAAOD,KAAA,CAAAE,aAAA,cAAK,SAAY,CAAC;AAC7B,CAAC;;ACF+C;AAIzC,MAAMG,aAAa,gBAAGF,uBAAa,CAAkC,IAAI,CAAC;AAEjFE,aAAa,CAACC,WAAW,GAAG,eAAe;AAEpC,MAAMC,cAAc,GAAGF,aAAa,CAACG,QAAQ;AAEpB;AAEzB,SAASC,SAASA,CAAA,EAAG;EACxB,OAAOL,oBAAU,CAACC,aAAa,CAAC;AACpC;;ACdgD;AAMzC,MAAMK,aAAa,gBAAGP,uBAAa,CAAe;EACrDQ,QAAQ,EAAE,GAAG;EACbC,KAAK,EAAE;AACX,CAAC,CAAC;AAEFF,aAAa,CAACJ,WAAW,GAAG,eAAe;AAEpC,MAAMO,cAAc,GAAGH,aAAa,CAACF,QAAQ;AAE7C,SAASM,SAASA,CAAA,EAAG;EACxB,OAAOV,oBAAU,CAACM,aAAa,CAAC;AACpC;;;;;;ACnBsD;AAE/C,MAAMO,aAAa,GAAG,EAAE;AAExB,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;;;ACAA;;;;;;;;ACAA;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;;;;WCrCA;;;;;WCAA;WACA;WACA;WACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA;;;;;WCPA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,EAAE;WACF;;;;;WCRA;WACA;WACA;WACA,eAAe,6BAA6B;WAC5C;;;;;WCJA;WACA;WACA;WACA;WACA;;;;;WCJA;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D;;;;;WCNA;WACA;WACA;WACA;WACA;;;;;WCJA;;;;;WCAA;;WAEA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,gBAAgB,qBAAqB;WACrC;WACA;WACA;;WAEA;WACA;WACA;WACA;WACA,aAAa;WACb;WACA,IAAI;WACJ;WACA;;WAEA;;WAEA;;WAEA;;;;;WCrCA;WACA;WACA;WACA;WACA;WACA;;;;;UELA;UACA","sources":["webpack://@diplodoc/client/./src/components/Search/Search.tsx","webpack://@diplodoc/client/./src/components/Search/index.ts","webpack://@diplodoc/client/./src/components/Router/index.ts","webpack://@diplodoc/client/./src/constants.ts","webpack://@diplodoc/client/./src/utils.ts","webpack://@diplodoc/client/./src/hooks/useLang.ts","webpack://@diplodoc/client/./src/components/Layout/index.tsx","webpack://@diplodoc/client/./src/components/ConstructorPage/index.tsx","webpack://@diplodoc/client/./src/components/ConstructorPage/useContent.tsx","webpack://@diplodoc/client/./src/components/index.ts","webpack://@diplodoc/client/./src/components/Search/provider/index.ts","webpack://@diplodoc/client/./src/components/Search/useProvider.ts","webpack://@diplodoc/client/./src/components/Search/Suggest.tsx","webpack://@diplodoc/client/./src/components/HeaderControls/index.tsx","webpack://@diplodoc/client/./src/components/ConstructorPage/useNavigation.tsx","webpack://@diplodoc/client/./src/components/App/Page.tsx","webpack://@diplodoc/client/./src/components/App/Runtime.tsx","webpack://@diplodoc/client/./src/components/App/useLangs.ts","webpack://@diplodoc/client/./src/components/App/useSettings.ts","webpack://@diplodoc/client/./src/components/App/useMobile.ts","webpack://@diplodoc/client/./src/components/App/index.tsx","webpack://@diplodoc/client/./src/preprocess.ts","webpack://@diplodoc/client/./src/index.server.tsx","webpack://@diplodoc/client/./src/interceptors/leading-page-links.js","webpack://@diplodoc/client/./src/stub/empty-module.js","webpack://@diplodoc/client/./node_modules/picocolors/ sync","webpack://@diplodoc/client/external node-commonjs \"buffer\"","webpack://@diplodoc/client/external node-commonjs \"crypto\"","webpack://@diplodoc/client/external node-commonjs \"fs\"","webpack://@diplodoc/client/external node-commonjs \"node:assert\"","webpack://@diplodoc/client/external node-commonjs \"node:async_hooks\"","webpack://@diplodoc/client/external node-commonjs \"node:buffer\"","webpack://@diplodoc/client/external node-commonjs \"node:console\"","webpack://@diplodoc/client/external node-commonjs \"node:crypto\"","webpack://@diplodoc/client/external node-commonjs \"node:diagnostics_channel\"","webpack://@diplodoc/client/external node-commonjs \"node:events\"","webpack://@diplodoc/client/external node-commonjs \"node:http\"","webpack://@diplodoc/client/external node-commonjs \"node:http2\"","webpack://@diplodoc/client/external node-commonjs \"node:net\"","webpack://@diplodoc/client/external node-commonjs \"node:perf_hooks\"","webpack://@diplodoc/client/external node-commonjs \"node:querystring\"","webpack://@diplodoc/client/external node-commonjs \"node:stream\"","webpack://@diplodoc/client/external node-commonjs \"node:tls\"","webpack://@diplodoc/client/external node-commonjs \"node:url\"","webpack://@diplodoc/client/external node-commonjs \"node:util\"","webpack://@diplodoc/client/external node-commonjs \"node:util/types\"","webpack://@diplodoc/client/external node-commonjs \"node:worker_threads\"","webpack://@diplodoc/client/external node-commonjs \"node:zlib\"","webpack://@diplodoc/client/external node-commonjs \"os\"","webpack://@diplodoc/client/external node-commonjs \"path\"","webpack://@diplodoc/client/external node-commonjs \"process\"","webpack://@diplodoc/client/external node-commonjs \"punycode\"","webpack://@diplodoc/client/external node-commonjs \"stream\"","webpack://@diplodoc/client/external node-commonjs \"string_decoder\"","webpack://@diplodoc/client/external node-commonjs \"tty\"","webpack://@diplodoc/client/external node-commonjs \"url\"","webpack://@diplodoc/client/external node-commonjs \"util\"","webpack://@diplodoc/client/webpack/bootstrap","webpack://@diplodoc/client/webpack/runtime/amd options","webpack://@diplodoc/client/webpack/runtime/chunk loaded","webpack://@diplodoc/client/webpack/runtime/compat get default export","webpack://@diplodoc/client/webpack/runtime/define property getters","webpack://@diplodoc/client/webpack/runtime/ensure chunk","webpack://@diplodoc/client/webpack/runtime/get javascript chunk filename","webpack://@diplodoc/client/webpack/runtime/get mini-css chunk filename","webpack://@diplodoc/client/webpack/runtime/hasOwnProperty shorthand","webpack://@diplodoc/client/webpack/runtime/make namespace object","webpack://@diplodoc/client/webpack/runtime/node module decorator","webpack://@diplodoc/client/webpack/runtime/publicPath","webpack://@diplodoc/client/webpack/runtime/require chunk loading","webpack://@diplodoc/client/webpack/runtime/startup chunk dependencies","webpack://@diplodoc/client/webpack/before-startup","webpack://@diplodoc/client/webpack/startup","webpack://@diplodoc/client/webpack/after-startup"],"sourcesContent":["import React from 'react';\n\nexport const Search = () => {\n return <div>Initial</div>;\n};\n","import type {SearchConfig, WorkerApi, WorkerConfig} from './types';\n\nimport {createContext, useContext} from 'react';\n\nexport type {SearchConfig, WorkerConfig, WorkerApi};\n\nexport const SearchContext = createContext<SearchConfig | null | undefined>(null);\n\nSearchContext.displayName = 'SearchContext';\n\nexport const SearchProvider = SearchContext.Provider;\n\nexport {Search} from './Search';\n\nexport function useSearch() {\n return useContext(SearchContext);\n}\n","import type {Router} from '@diplodoc/components';\n\nimport {createContext, useContext} from 'react';\n\nexport interface RouterConfig extends Router {\n depth: number;\n}\n\nexport const RouterContext = createContext<RouterConfig>({\n pathname: '/',\n depth: 0,\n});\n\nRouterContext.displayName = 'RouterContext';\n\nexport const RouterProvider = RouterContext.Provider;\n\nexport function useRouter() {\n return useContext(RouterContext);\n}\n","import {TextSizes, Theme} from '@diplodoc/components';\n\nexport const HEADER_HEIGHT = 64;\n\nexport const MOBILE_VIEW_WIDTH_BREAKPOINT = 769;\n\nexport const DEFAULT_USER_SETTINGS = {\n theme: Theme.Light,\n textSize: TextSizes.M,\n showMiniToc: true,\n wideFormat: true,\n fullScreen: false,\n};\n\nexport const RTL_LANGS = [\n 'ar',\n 'arc',\n 'ckb',\n 'dv',\n 'fa',\n 'ha',\n 'he',\n 'khw',\n 'ks',\n 'ps',\n 'sd',\n 'ur',\n 'uz_AF',\n 'yi',\n];\n\nexport enum TextDirection {\n RTL = 'rtl',\n LTR = 'ltr',\n}\n\nexport const LINK_KEYS_LEADING_CONFIG = ['href'];\nexport const LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG = [\n 'src',\n 'url',\n 'href',\n 'icon',\n 'image',\n 'desktop',\n 'mobile',\n 'tablet',\n 'previewImg',\n 'image',\n 'avatar',\n 'logo',\n 'light',\n 'dark',\n];\n\nexport const LINK_KEYS = [\n ...new Set([...LINK_KEYS_LEADING_CONFIG, ...LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG]),\n];\n","import type {PageData} from './components/App';\n\nimport {Lang, Theme, getPageType} from '@diplodoc/components';\n\nimport {\n DEFAULT_USER_SETTINGS,\n MOBILE_VIEW_WIDTH_BREAKPOINT,\n RTL_LANGS,\n TextDirection,\n} from './constants';\n\nexport function isBrowser() {\n return typeof document !== 'undefined';\n}\n\nexport function updateThemeClassName({theme}: {theme: Theme}) {\n if (typeof document === 'undefined') {\n return;\n }\n\n document.querySelectorAll('.g-root').forEach((el) => {\n el.classList.toggle('g-root_theme_light', theme === 'light');\n el.classList.toggle('g-root_theme_dark', theme === 'dark');\n });\n}\n\nexport function updateRootClassName(states: {\n mobileView?: boolean;\n wideFormat?: boolean;\n fullScreen?: boolean;\n focusSearch?: boolean;\n landingPage?: boolean;\n}) {\n if (!isBrowser()) {\n return;\n }\n\n document.body.classList.add('g-root');\n\n const toggle = (name: string, state: unknown) =>\n document.body.classList.toggle(name, Boolean(state));\n\n Object.keys(states).forEach((state) => {\n switch (state) {\n case 'wideFormat':\n toggle('dc-root_wide-format', states[state]);\n break;\n case 'focusSearch':\n toggle('dc-root_focused-search', states[state]);\n break;\n case 'fullScreen':\n toggle('dc-root_full-screen', states[state]);\n break;\n case 'landingPage':\n toggle('dc-root_document-page', !states[state]);\n toggle('dc-root_landing-page', states[state]);\n break;\n case 'mobileView':\n toggle('mobile', states[state]);\n toggle('desktop', !states[state]);\n break;\n }\n });\n}\n\nexport function getDirection(lang: Lang): TextDirection {\n const isRTL = RTL_LANGS.includes(lang);\n\n return isRTL ? TextDirection.RTL : TextDirection.LTR;\n}\n\nconst toBoolean = (str: string | boolean) => {\n if (typeof str === 'boolean') {\n return str;\n }\n\n return str ? str === 'true' : false;\n};\n\nexport type Settings = typeof DEFAULT_USER_SETTINGS;\n\nexport function getSettings() {\n const theme = getSetting('theme');\n const textSize = getSetting('textSize');\n const showMiniToc = getSetting('showMiniToc');\n const wideFormat = getSetting('wideFormat');\n const fullScreen = getSetting('fullScreen');\n\n return {\n theme,\n textSize,\n showMiniToc: toBoolean(showMiniToc),\n wideFormat: toBoolean(wideFormat),\n fullScreen: toBoolean(fullScreen),\n };\n}\n\nexport function getLandingPage(data: PageData) {\n return getPageType(data) === 'PAGE_CONSTRUCTOR';\n}\n\nexport function getMobileView() {\n if (!isBrowser()) {\n return false;\n }\n\n return document.body.clientWidth < MOBILE_VIEW_WIDTH_BREAKPOINT;\n}\n\nfunction getSetting<T extends keyof Settings>(name: T): Settings[T] {\n if (!isBrowser()) {\n return DEFAULT_USER_SETTINGS[name];\n }\n\n try {\n return (sessionStorage.getItem(name) as Settings[T]) || DEFAULT_USER_SETTINGS[name];\n } catch {\n return DEFAULT_USER_SETTINGS[name];\n }\n}\n\nexport function setSetting<T>(name: string, value: T) {\n if (!isBrowser()) {\n return;\n }\n\n try {\n sessionStorage.setItem(name, String(value));\n } catch {}\n}\n","import {createContext, useContext} from 'react';\nimport {Lang} from '@diplodoc/components';\n\nconst LangContext = createContext<Lang>(Lang.En);\n\nLangContext.displayName = 'Lang';\n\nexport const LangProvider = LangContext.Provider;\n\nexport function useLang() {\n return useContext(LangContext);\n}\n","import React, {FC, PropsWithChildren, ReactElement} from 'react';\nimport block from 'bem-cn-lite';\n\nimport './Layout.scss';\n\nconst b = block('Layout');\n\nfunction Header() {\n return null;\n}\n\nfunction Content() {\n return null;\n}\n\nfunction Footer() {\n return null;\n}\n\ntype LayoutStatics = {\n Header: FC<PropsWithChildren>;\n Content: FC<PropsWithChildren>;\n Footer: FC<PropsWithChildren>;\n};\n\ntype LayoutProps = {\n doc?: boolean;\n headerHeight?: number;\n};\n\nconst defaults = {\n doc: false,\n};\n\nexport const Layout: LayoutStatics & FC<PropsWithChildren<LayoutProps>> = (props) => {\n const {children, doc, headerHeight = 0} = {...defaults, ...props};\n let header, content, footer;\n\n React.Children.forEach(children as ReactElement[], (child: ReactElement) => {\n switch (child.type) {\n case Header:\n header = child.props.children;\n break;\n case Content:\n content = child.props.children;\n break;\n case Footer:\n footer = child.props.children;\n break;\n }\n });\n\n return (\n <div className={b({'full-header': headerHeight > 0})}>\n {header && <div className={b('header')}>{header}</div>}\n <div className={b('body')}>\n {content && <div className={b('content')}>{content}</div>}\n {footer && <div className={b('footer', {doc})}>{footer}</div>}\n </div>\n </div>\n );\n};\n\nLayout.displayName = 'Layout';\n\nLayout.Header = Header;\nLayout.Content = Content;\nLayout.Footer = Footer;\n","import type {PropsWithChildren} from 'react';\nimport type {PageContent} from '@gravity-ui/page-constructor';\n\nimport React from 'react';\nimport block from 'bem-cn-lite';\nimport {\n BackgroundMedia,\n Col,\n ConstructorBlocks,\n Grid,\n Row,\n getThemedValue,\n useTheme,\n} from '@gravity-ui/page-constructor';\n\nconst bPC = block('pc-page-constructor');\nconst bPCRow = block('pc-constructor-row');\n\nexport const ConstructorRow = ({children}: PropsWithChildren) =>\n children ? (\n <Row className={bPCRow()}>\n <Col>{children}</Col>\n </Row>\n ) : null;\n\nexport function ConstructorPage({background, blocks}: PageContent) {\n const theme = useTheme();\n const themedBackground = getThemedValue(background, theme);\n\n return (\n <div className={bPC('docs')}>\n <div className={bPC('wrapper')}>\n {blocks && themedBackground && (\n <BackgroundMedia {...themedBackground} className={bPC('background')} />\n )}\n <Grid>\n <ConstructorRow>\n <ConstructorBlocks items={blocks} />\n </ConstructorRow>\n </Grid>\n </div>\n </div>\n );\n}\n","import type {ReactNode} from 'react';\nimport type {PageContent} from '@gravity-ui/page-constructor';\nimport type {DocContentPageData} from '@diplodoc/components';\n\nimport {DocumentType, getPageType} from '@diplodoc/components';\nimport {useMemo} from 'react';\n\nexport const useContent = (data: DocContentPageData, CustomPage: () => ReactNode) => {\n const type = getPageType(data);\n const fullScreen =\n type === DocumentType.PageConstructor &&\n 'data' in data &&\n 'fullScreen' in data.data &&\n data.data.fullScreen;\n\n const layout = useMemo(\n () =>\n fullScreen\n ? (data.data as PageContent)\n : {\n blocks: [\n {\n type: 'page',\n resetPaddings: true,\n },\n ],\n },\n [fullScreen, data],\n );\n\n const config = useMemo(\n () => ({\n custom: {\n page: CustomPage,\n },\n layout,\n }),\n [CustomPage, layout],\n );\n\n return config;\n};\n","export {SearchContext, SearchProvider, useSearch} from './Search';\nexport {RouterContext, RouterProvider, useRouter} from './Router';\n\nexport {App} from './App';\n","import type {ISearchProvider, ISearchResult} from '@diplodoc/components';\nimport type {SearchConfig, WorkerConfig} from '../types';\n\nexport class SearchProvider implements ISearchProvider {\n private worker!: Promise<Worker>;\n\n private config: SearchConfig;\n\n constructor(config: SearchConfig) {\n this.config = config;\n }\n\n init = () => {\n this.worker = initWorker({\n ...this.config,\n base: this.base,\n mark: 'Suggest__Item__Marker',\n });\n };\n\n async suggest(query: string) {\n return this.request({\n type: 'suggest',\n query,\n }) as Promise<ISearchResult[]>;\n }\n\n async search(query: string) {\n return this.request({\n type: 'search',\n query,\n }) as Promise<ISearchResult[]>;\n }\n\n // Temporary disable link to search page\n // TODO: Implement search page\n link = () => null;\n\n // link = (query: string) => {\n // const params = query ? `?query=${encodeURIComponent(query)}` : '';\n //\n // return `${this.base}/${this.config.link}${params}`;\n // };\n\n private get base() {\n return window.location.href.split('/').slice(0, -this.config.depth).join('/');\n }\n\n private async request(message: object) {\n return request(await this.worker, message);\n }\n}\n\nconst BAD_ORIGIN_ERROR = /Script at '(.*?)' cannot be accessed from origin/;\n\nasync function loadWorker() {\n try {\n return new Worker(new URL('../worker/index.ts', import.meta.url));\n } catch (error) {\n // @see https://stackoverflow.com/questions/21408510/chrome-cant-load-web-worker\n if (error instanceof DOMException) {\n const match = BAD_ORIGIN_ERROR.exec(error.message);\n if (match) {\n const url = match[1];\n const blob = new Blob([`importScripts('${url}');`], {type: 'text/javascript'});\n\n return new Worker(URL.createObjectURL(blob));\n }\n }\n\n throw error;\n }\n}\n\nasync function initWorker(config: WorkerConfig) {\n const worker = await loadWorker();\n\n await request(worker, {...config, type: 'init'});\n\n return worker;\n}\n\nfunction request(worker: Worker, message: object) {\n const channel = new MessageChannel();\n\n return new Promise((resolve, reject) => {\n channel.port1.onmessage = (message) => {\n if (message.data.error) {\n // eslint-disable-next-line no-console\n console.error(message.data.error);\n\n reject(message.data.error);\n } else {\n resolve(message.data.result);\n }\n };\n\n channel.port1.onmessageerror = (message) => {\n reject(message.data.error);\n };\n\n worker.postMessage(message, [channel.port2]);\n });\n}\n","import {useContext, useMemo} from 'react';\n\nimport {RouterContext, SearchContext} from '../index';\nimport {useLang} from '../../hooks/useLang';\n\nimport {SearchProvider} from './provider';\n\nexport function useProvider() {\n const lang = useLang();\n const {depth = 0} = useContext(RouterContext);\n const search = useContext(SearchContext);\n\n return useMemo(() => {\n if (!search) {\n return null;\n }\n\n return new SearchProvider({\n ...search,\n depth,\n lang,\n });\n }, [lang, depth, search]);\n}\n","import type {ISearchProvider, SearchSuggestApi} from '@diplodoc/components';\n\nimport React, {useCallback, useRef} from 'react';\nimport {SearchSuggest} from '@diplodoc/components';\nimport {Icon} from '@gravity-ui/uikit';\nimport {Magnifier} from '@gravity-ui/icons';\nimport block from 'bem-cn-lite';\n\nimport {updateRootClassName} from '../../utils';\n\nimport {useProvider} from './useProvider';\nimport './Suggest.scss';\n\nconst b = block('Suggest');\n\nfunction SearchButton() {\n return <Icon data={Magnifier} className={b('end')} size={24} />;\n}\n\nexport function Suggest() {\n const provider: ISearchProvider | null = useProvider();\n const suggest = useRef<SearchSuggestApi>(null);\n\n const onFocus = useCallback(() => {\n updateRootClassName({focusSearch: true});\n }, []);\n\n const onBlur = useCallback(() => {\n updateRootClassName({focusSearch: false});\n setTimeout(() => {\n if (suggest.current) {\n suggest.current.close();\n }\n }, 100);\n }, []);\n\n if (!provider) {\n return null;\n }\n\n return (\n <SearchSuggest\n ref={suggest}\n provider={provider}\n onFocus={onFocus}\n onBlur={onBlur}\n endContent={<SearchButton />}\n className={b('input')}\n classNameContainer={b()}\n closeButton={true}\n />\n );\n}\n","import React, {memo} from 'react';\nimport {ControlSizes, Controls, ControlsLayout, Lang, TextSizes, Theme} from '@diplodoc/components';\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\ntype OnChangeCallback = (value: any) => void;\n\nexport type Props = {\n mobileView: boolean;\n\n theme: Theme;\n onChangeTheme: OnChangeCallback;\n textSize: TextSizes;\n onChangeTextSize: OnChangeCallback;\n wideFormat: boolean;\n onChangeWideFormat: OnChangeCallback;\n showMiniToc: boolean;\n onChangeShowMiniToc: OnChangeCallback;\n lang: Lang;\n langs: Lang[];\n onChangeLang?: (lang: Lang) => void;\n};\n\nexport const HeaderControls = memo<Props>(\n ({\n mobileView,\n\n theme,\n onChangeTheme,\n\n textSize,\n onChangeTextSize,\n\n wideFormat,\n onChangeWideFormat,\n\n showMiniToc,\n onChangeShowMiniToc,\n\n lang,\n langs,\n onChangeLang,\n }) => {\n return (\n <ControlsLayout\n controlClassName={'Control'}\n controlSize={ControlSizes.L}\n isWideView={mobileView}\n isMobileView={mobileView}\n >\n <Controls\n className={'Controls'}\n theme={theme}\n onChangeTheme={onChangeTheme}\n wideFormat={wideFormat}\n onChangeWideFormat={onChangeWideFormat}\n showMiniToc={showMiniToc}\n onChangeShowMiniToc={onChangeShowMiniToc}\n textSize={textSize}\n onChangeTextSize={onChangeTextSize}\n lang={lang}\n langs={langs}\n onChangeLang={onChangeLang}\n />\n </ControlsLayout>\n );\n },\n);\n\nHeaderControls.displayName = 'HeaderControls';\n","import type {ReactNode} from 'react';\nimport type {NavigationData, NavigationItemModel} from '@gravity-ui/page-constructor';\nimport type {DocBasePageData} from '@diplodoc/components';\nimport type {WithNavigation} from '../App';\nimport type {Props as HeaderControlsProps} from '../HeaderControls';\n\nimport React, {useMemo} from 'react';\nimport {ControlSizes, CustomNavigation, MobileDropdown} from '@diplodoc/components';\n\nimport {HEADER_HEIGHT} from '../../constants';\nimport {useRouter, useSearch} from '../';\n\nfunction findItem(right: NavigationItemModel[], left: NavigationItemModel[], type: string) {\n return right.some((item) => item.type === type) || left.some((item) => item.type === type);\n}\n\nexport const useNavigation = (\n data: DocBasePageData<WithNavigation>,\n controls: HeaderControlsProps,\n CustomControls: () => ReactNode,\n CustomSuggest: () => ReactNode,\n) => {\n const {toc} = data;\n const {navigation} = toc;\n const {header = {}, logo} = navigation;\n const {leftItems = [], rightItems = []} = header as NavigationData['header'];\n\n const withControls = findItem(rightItems, leftItems, 'controls');\n const withSearch = findItem(rightItems, leftItems, 'search');\n\n const search = useSearch();\n const router = useRouter();\n\n if (search && !withSearch) {\n rightItems.unshift({type: 'search'} as unknown as NavigationItemModel);\n }\n\n const navigationData = useMemo(\n () => ({\n withBorder: true,\n leftItems: leftItems,\n rightItems: rightItems,\n customMobileHeaderItems: [{type: 'search'} as unknown as NavigationItemModel],\n }),\n [leftItems, rightItems],\n );\n const navigationTocData = useMemo(\n () => ({\n toc,\n router,\n headerHeight: HEADER_HEIGHT,\n }),\n [toc, router],\n );\n const mobileControlsData = useMemo(\n () => ({\n controlSize: ControlSizes.L,\n userSettings: controls,\n }),\n [controls],\n );\n\n const layout = useMemo(\n () => ({\n header: {\n leftItems: [],\n },\n renderNavigation: () => (\n <CustomNavigation\n logo={logo}\n data={navigationData}\n navigationTocData={navigationTocData}\n mobileControlsData={mobileControlsData}\n />\n ),\n logo,\n }),\n [navigationData, navigationTocData, mobileControlsData, logo],\n );\n\n const config = useMemo(\n () => ({\n custom: {\n search: CustomSuggest,\n controls: CustomControls,\n MobileDropdown: MobileDropdown,\n },\n layout,\n withControls,\n }),\n [CustomSuggest, CustomControls, layout, withControls],\n );\n\n return config;\n};\n","import type {PropsWithChildren} from 'react';\nimport type {AppProps, PageData} from './index';\nimport type {Settings} from '../../utils';\n\nimport React, {useCallback, useMemo} from 'react';\nimport {PageConstructor, PageConstructorProvider} from '@gravity-ui/page-constructor';\nimport {DocBasePageData, getPageByType, getPageType} from '@diplodoc/components';\n\nimport {Layout} from '../Layout';\nimport {ConstructorPage} from '../ConstructorPage';\nimport {useContent} from '../ConstructorPage/useContent';\nimport {Suggest} from '../Search/Suggest';\nimport {HeaderControls, Props as HeaderControlsProps} from '../HeaderControls';\nimport {useNavigation} from '../ConstructorPage/useNavigation';\n\nimport {DocContentPageData, WithNavigation} from './index';\n\ntype Props = PropsWithChildren<Partial<AppProps> & {data: PageData; headerHeight: number}>;\n\nexport function Page({data, ...pageProps}: Props) {\n const type = getPageType(data);\n const Page = getPageByType(type);\n\n return (\n <Layout headerHeight={pageProps.headerHeight}>\n <Layout.Content>\n {/*@ts-ignore*/}\n <Page {...data} {...pageProps} />\n </Layout.Content>\n </Layout>\n );\n}\n\ntype PageProps<T extends {} = {}> = {\n data: DocBasePageData<T> & PageData;\n props: {\n router: AppProps['router'];\n } & Settings;\n controls: HeaderControlsProps;\n};\n\nconst EMPTY = {};\n\nexport function LegacyNavPage({data, props, controls}: PageProps) {\n const {theme} = props;\n\n const CustomPage = useCallback(\n () => <ConstructorPage {...(data as DocContentPageData).data} />,\n [data],\n );\n const content = useContent(data as DocContentPageData, CustomPage);\n\n const custom = useMemo(\n () => ({\n blocks: content.custom,\n }),\n [content],\n );\n\n return (\n <Page data={data} headerHeight={0} {...props} {...controls}>\n <PageConstructorProvider theme={theme}>\n <PageConstructor custom={custom} content={content.layout} />\n </PageConstructorProvider>\n </Page>\n );\n}\n\nexport function RichNavPage({data, props, controls}: PageProps<WithNavigation>) {\n const {theme, fullScreen} = props;\n\n const CustomSuggest = useCallback(() => <Suggest />, []);\n const CustomControls = useCallback(() => <HeaderControls {...controls} />, [controls]);\n const navigation = useNavigation(data, controls, CustomControls, CustomSuggest);\n\n const CustomPage = useCallback(\n () => (\n <Page\n data={data}\n headerHeight={fullScreen ? 0 : 64}\n {...props}\n {...(navigation.withControls ? EMPTY : controls)}\n >\n <ConstructorPage {...(data as DocContentPageData).data} />\n </Page>\n ),\n [data, navigation, props, controls, fullScreen],\n );\n const content = useContent(data as DocContentPageData, CustomPage);\n\n const custom = useMemo(\n () => ({\n navigation: navigation.custom,\n blocks: content.custom,\n }),\n [navigation, content],\n );\n\n return (\n <PageConstructorProvider theme={theme}>\n <PageConstructor\n custom={custom}\n content={content.layout}\n navigation={fullScreen ? undefined : navigation.layout}\n />\n </PageConstructorProvider>\n );\n}\n","import React from 'react';\nimport {MermaidRuntime} from '@diplodoc/mermaid-extension/react';\nimport {LatexRuntime} from '@diplodoc/latex-extension/react';\nimport {Runtime as OpenapiSandbox} from '@diplodoc/openapi-extension/runtime';\nimport {Theme} from '@diplodoc/components';\nimport {useTheme} from '@gravity-ui/uikit';\n\nexport function Runtime() {\n const theme = useTheme();\n\n return (\n <>\n <OpenapiSandbox />\n <LatexRuntime />\n <MermaidRuntime\n theme={theme === Theme.Dark ? 'dark' : 'neutral'}\n zoom={{\n showMenu: true,\n bindKeys: true,\n }}\n />\n </>\n );\n}\n","import type {AppProps} from './index';\n\nimport {Lang, getLangPath} from '@diplodoc/components';\nimport {useCallback, useMemo} from 'react';\n\nexport function useLangs({router, lang, langs}: AppProps) {\n const onChangeLang = useCallback(\n (lang: Lang) => {\n const path = getLangPath(router, lang);\n window.location.replace(path);\n },\n [router],\n );\n\n return useMemo(() => ({lang, langs, onChangeLang}), [lang, langs, onChangeLang]);\n}\n","import type {Settings} from '../../utils';\n\nimport {useMemo, useState} from 'react';\n\nimport {getSettings, setSetting} from '../../utils';\n\nconst capitalize = <T extends string>(string: T): Capitalize<T> =>\n string.replace(/^./, (ch) => ch.toUpperCase()) as Capitalize<T>;\n\nexport function useSettings() {\n const settings = getSettings();\n\n const theme = useSetting('theme', settings);\n const textSize = useSetting('textSize', settings);\n const wideFormat = useSetting('wideFormat', settings);\n const fullScreen = useSetting('fullScreen', settings);\n const showMiniToc = useSetting('showMiniToc', settings);\n\n const controls = useMemo(\n () => ({\n ...theme,\n ...textSize,\n ...wideFormat,\n ...showMiniToc,\n ...fullScreen,\n }),\n [theme, textSize, wideFormat, showMiniToc, fullScreen],\n );\n\n return controls;\n}\n\ntype State<P extends keyof Settings> = {\n [prop in P]: Settings[P];\n} & {\n [prop in `onChange${Capitalize<P>}`]: (value: Settings[P]) => void;\n};\n\nfunction useSetting<P extends keyof Settings>(name: P, settings: Settings): State<P> {\n const [setting, setSetting] = useState<Settings[P]>(settings[name]);\n const onChangeSetting = useMemo(() => withSavingSetting(name, setSetting), [name, setSetting]);\n\n return useMemo(\n () =>\n ({\n [name]: setting,\n ['onChange' + capitalize(name)]: onChangeSetting,\n }) as State<P>,\n [name, setting, onChangeSetting],\n );\n}\n\nfunction withSavingSetting<T>(settingName: string, onChange: (value: T) => void) {\n return (value: T) => {\n setSetting<T>(settingName, value);\n\n onChange(value);\n };\n}\n","import {useCallback, useEffect, useState} from 'react';\n\nimport {getMobileView} from '../../utils';\n\nexport function useMobile() {\n const [mobileView, setMobileView] = useState<boolean>(getMobileView());\n\n const onResizeHandler = useCallback(() => {\n setMobileView(getMobileView());\n }, []);\n\n useEffect(onResizeHandler, [onResizeHandler]);\n\n useEffect(() => {\n window.addEventListener('resize', onResizeHandler);\n\n return () => window.removeEventListener('resize', onResizeHandler);\n }, [onResizeHandler]);\n\n return mobileView;\n}\n","import type {NavigationData, PageContent} from '@gravity-ui/page-constructor';\nimport type {ReactElement} from 'react';\nimport type {Props as HeaderControlsProps} from '../HeaderControls';\nimport type {SearchConfig} from '../Search';\nimport type {RouterConfig} from '../Router';\n\nimport React, {useEffect, useMemo} from 'react';\nimport {ThemeProvider} from '@gravity-ui/uikit';\nimport {\n ConsentPopup,\n DocBasePageData,\n DocContentPageData as DocContentPageDataBase,\n DocLeadingPageData,\n DocPageData,\n Lang,\n configure,\n} from '@diplodoc/components';\nimport '@diplodoc/transform/dist/js/yfm';\n\nimport {SearchProvider} from '../Search';\nimport {RouterProvider} from '../Router';\nimport {getDirection, getLandingPage, updateRootClassName, updateThemeClassName} from '../../utils';\nimport {LangProvider} from '../../hooks/useLang';\nimport '../../interceptors/leading-page-links';\n\nimport {LegacyNavPage, RichNavPage} from './Page';\nimport {Runtime} from './Runtime';\nimport {useLangs} from './useLangs';\nimport {useSettings} from './useSettings';\nimport {useMobile} from './useMobile';\nimport './App.scss';\n\nexport type DocAnalytics = {\n gtm?: {\n id?: string;\n mode?: 'base' | 'notification';\n };\n};\n\nexport interface AppProps {\n lang: Lang;\n langs: Lang[];\n router: RouterConfig;\n search?: SearchConfig;\n analytics?: DocAnalytics;\n}\n\nexport type WithNavigation = {\n navigation: NavigationData;\n};\n\nexport type DocContentPageData = DocContentPageDataBase<PageContent>;\n\nexport type PageData = DocPageData | DocLeadingPageData | DocContentPageData;\n\nexport type DocInnerProps<Data extends PageData = PageData> = {\n data: Data;\n} & AppProps;\n\nexport type {DocLeadingPageData, DocPageData};\n\nfunction hasNavigation(\n data: DocBasePageData<Partial<WithNavigation>>,\n): data is DocBasePageData<WithNavigation> {\n return Boolean(data.toc.navigation);\n}\n\nexport function App(props: DocInnerProps): ReactElement {\n const {data, router, lang, search, analytics} = props;\n\n configure({\n lang,\n });\n\n const settings = useSettings();\n const langs = useLangs(props);\n const mobileView = useMobile();\n\n const {theme, textSize, wideFormat, fullScreen, showMiniToc} = settings;\n\n const page = useMemo(\n () => ({\n router,\n\n theme,\n textSize,\n wideFormat,\n fullScreen,\n showMiniToc,\n }),\n [router, theme, textSize, wideFormat, fullScreen, showMiniToc],\n );\n const controls: HeaderControlsProps = useMemo(\n () => ({\n ...settings,\n ...langs,\n mobileView,\n }),\n [langs, settings, mobileView],\n );\n const direction = getDirection(lang);\n const landingPage = getLandingPage(data);\n\n useEffect(() => {\n updateRootClassName({mobileView, wideFormat, fullScreen, landingPage});\n updateThemeClassName({theme});\n }, [theme, mobileView, wideFormat, fullScreen, landingPage]);\n\n return (\n <div className=\"App\">\n <ThemeProvider theme={theme} direction={direction}>\n <LangProvider value={lang}>\n <RouterProvider value={router}>\n <SearchProvider value={search}>\n {hasNavigation(data) ? (\n <RichNavPage data={data} props={page} controls={controls} />\n ) : (\n <LegacyNavPage data={data} props={page} controls={controls} />\n )}\n {analytics && (\n <ConsentPopup\n router={router}\n gtmId={analytics?.gtm?.id || ''}\n consentMode={analytics?.gtm?.mode}\n />\n )}\n <Runtime />\n </SearchProvider>\n </RouterProvider>\n </LangProvider>\n </ThemeProvider>\n </div>\n );\n}\n","import {\n Block,\n ConstructorBlock,\n NavigationData as ConstructorNavigaitonData,\n PageContent as ConstructorPageContentBase,\n} from '@gravity-ui/page-constructor';\nimport {\n BlocksConfig,\n Parser,\n TransformerRaw,\n config,\n contentTransformer,\n} from '@gravity-ui/page-constructor/server';\n\nexport interface MetaData {\n title: string;\n description?: string;\n}\n\nexport interface PageContentBase {\n meta?: MetaData;\n}\n\nexport enum Lang {\n RU = 'ru',\n EN = 'en',\n}\n\nexport type PageContent<T> = T & PageContentBase;\nexport type ConstructorPageContent = PageContent<ConstructorPageContentBase>;\nexport type NavigationData = PageContent<ConstructorNavigaitonData>;\nexport type ConfigData = ConstructorPageContent | NavigationData;\n\nexport interface PreloadParams {\n lang: Lang;\n pageName: string;\n pageReferer?: string;\n}\n\ninterface BlockConfig {\n transformer: TransformerRaw;\n fields?: string[];\n parser?: Parser;\n}\n\nexport function isPageConfig(config: ConfigData): config is ConstructorPageContent {\n return 'blocks' in config;\n}\n\nexport function preprocess(\n content: ConfigData,\n params: PreloadParams,\n customYfmTransformer: TransformerRaw,\n) {\n const {lang} = params;\n\n if (isPageConfig(content) && content.blocks) {\n return {\n ...content,\n blocks: transformBlocks(content.blocks, lang, customYfmTransformer),\n };\n }\n\n return content;\n}\n\nfunction replaceTransformer(config: BlocksConfig, newTransformer: TransformerRaw): BlocksConfig {\n return Object.keys(config).reduce((newConfig, subBlockType) => {\n const subBlock = config[subBlockType];\n\n if (Array.isArray(subBlock)) {\n newConfig[subBlockType] = subBlock.map((block: {transformer: {name: string}}) => {\n return block.transformer.name === 'yfmTransformer'\n ? {...block, transformer: newTransformer}\n : block;\n }) as BlockConfig[];\n } else {\n newConfig[subBlockType] =\n subBlock.transformer.name === 'yfmTransformer'\n ? {...subBlock, transformer: newTransformer}\n : subBlock;\n }\n\n return newConfig;\n }, {} as BlocksConfig);\n}\n\nfunction transformBlocks(\n blocks: ConstructorBlock[],\n lang: Lang,\n customYfmTransformer: TransformerRaw,\n) {\n const customConfig = replaceTransformer(config, customYfmTransformer);\n\n return contentTransformer({\n content: {blocks},\n options: {\n lang,\n customConfig,\n },\n }).blocks as Block[];\n}\n","import React from 'react';\nimport {renderToString} from 'react-dom/server';\n\nimport {App, DocAnalytics, DocInnerProps, DocLeadingPageData, DocPageData} from './components/App';\nimport {LINK_KEYS, LINK_KEYS_LEADING_CONFIG, LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG} from './constants';\nimport {preprocess} from './preprocess';\n\nexport type {DocInnerProps, DocPageData, DocLeadingPageData, DocAnalytics};\nexport type {\n SearchConfig as ISearchProviderConfig,\n WorkerConfig as ISearchWorkerConfig,\n WorkerApi as ISearchWorkerApi,\n} from './components/Search';\nexport {LINK_KEYS, LINK_KEYS_LEADING_CONFIG, LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG, preprocess};\n\nexport const render = (props: DocInnerProps) => renderToString(<App {...props} />);\n","(function () {\n /**\n * Element.matches() polyfill.\n * @link https://developer.mozilla.org/ru/docs/Web/API/Element/matches\n */\n if (typeof Element !== 'undefined') {\n (function (e) {\n const matches =\n e.matches ||\n e.matchesSelector ||\n e.webkitMatchesSelector ||\n e.mozMatchesSelector ||\n e.msMatchesSelector ||\n e.oMatchesSelector;\n\n if (matches) {\n e.matches = e.matchesSelector = matches;\n } else {\n e.matches = e.matchesSelector = function (selector) {\n const th = this;\n return Array.prototype.some.call(document.querySelectorAll(selector), (el) => {\n return el === th;\n });\n };\n }\n })(Element.prototype);\n }\n\n if (typeof document !== 'undefined') {\n document.addEventListener('click', (event) => {\n const href = event.target.href;\n const locationOrigin = window.location.origin;\n\n if (\n event.target.matches('.dc-doc-layout__center a') &&\n href.startsWith(locationOrigin)\n ) {\n event.preventDefault();\n\n const mainFileName = 'index';\n const extention = '.html';\n\n if (href.endsWith('/')) {\n window.location.href = `${href}${mainFileName}${extention}`;\n return;\n }\n\n // https://../file-name, https://../file-name#fragment\n const splitedHref = href.split('#');\n if (splitedHref.length > 0 && !splitedHref[0].endsWith(extention)) {\n splitedHref[0] += extention;\n window.location.href = splitedHref.join('#');\n return;\n }\n\n window.location.href = href;\n }\n });\n }\n})();\n","export default function () {}\n","function webpackEmptyContext(req) {\n\tvar e = new Error(\"Cannot find module '\" + req + \"'\");\n\te.code = 'MODULE_NOT_FOUND';\n\tthrow e;\n}\nwebpackEmptyContext.keys = () => ([]);\nwebpackEmptyContext.resolve = webpackEmptyContext;\nwebpackEmptyContext.id = 29249;\nmodule.exports = webpackEmptyContext;","module.exports = require(\"buffer\");","module.exports = require(\"crypto\");","module.exports = require(\"fs\");","module.exports = require(\"node:assert\");","module.exports = require(\"node:async_hooks\");","module.exports = require(\"node:buffer\");","module.exports = require(\"node:console\");","module.exports = require(\"node:crypto\");","module.exports = require(\"node:diagnostics_channel\");","module.exports = require(\"node:events\");","module.exports = require(\"node:http\");","module.exports = require(\"node:http2\");","module.exports = require(\"node:net\");","module.exports = require(\"node:perf_hooks\");","module.exports = require(\"node:querystring\");","module.exports = require(\"node:stream\");","module.exports = require(\"node:tls\");","module.exports = require(\"node:url\");","module.exports = require(\"node:util\");","module.exports = require(\"node:util/types\");","module.exports = require(\"node:worker_threads\");","module.exports = require(\"node:zlib\");","module.exports = require(\"os\");","module.exports = require(\"path\");","module.exports = require(\"process\");","module.exports = require(\"punycode\");","module.exports = require(\"stream\");","module.exports = require(\"string_decoder\");","module.exports = require(\"tty\");","module.exports = require(\"url\");","module.exports = require(\"util\");","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [644,121], () => (__webpack_require__(31890)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","__webpack_require__.amdO = {};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + ({\"121\":\"vendor\",\"644\":\"react\"}[chunkId] || chunkId) + \".js\";\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.miniCssF = (chunkId) => {\n\t// return url for filenames based on template\n\treturn undefined;\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = (module) => {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.p = \"\";","__webpack_require__.b = require(\"url\").pathToFileURL(__filename);\n\n// object to store loaded chunks\n// \"1\" means \"loaded\", otherwise not loaded yet\nvar installedChunks = {\n\t524: 1\n};\n\n__webpack_require__.O.require = (chunkId) => (installedChunks[chunkId]);\n\nvar installChunk = (chunk) => {\n\tvar moreModules = chunk.modules, chunkIds = chunk.ids, runtime = chunk.runtime;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\tfor(var i = 0; i < chunkIds.length; i++)\n\t\tinstalledChunks[chunkIds[i]] = 1;\n\t__webpack_require__.O();\n};\n\n// require() chunk loading for javascript\n__webpack_require__.f.require = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\tinstallChunk(require(\"./\" + __webpack_require__.u(chunkId)));\n\t\t} else installedChunks[chunkId] = 1;\n\t}\n};\n\n// no external install chunk\n\n// no HMR\n\n// no HMR manifest","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\t__webpack_require__.e(644);\n\t__webpack_require__.e(121);\n\treturn next();\n};","","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n",""],"names":["React","Search","createElement","createContext","useContext","SearchContext","displayName","SearchProvider","Provider","useSearch","RouterContext","pathname","depth","RouterProvider","useRouter","TextSizes","Theme","HEADER_HEIGHT","MOBILE_VIEW_WIDTH_BREAKPOINT","DEFAULT_USER_SETTINGS","theme","Light","textSize","M","showMiniToc","wideFormat","fullScreen","RTL_LANGS","TextDirection","LINK_KEYS_LEADING_CONFIG","LINK_KEYS_PAGE_CONSTRUCTOR_CONFIG","LINK_KEYS","Set","getPageType","isBrowser","document","updateThemeClassName","querySelectorAll","forEach","el","classList","toggle","updateRootClassName","states","body","add","name","state","Boolean","Object","keys","getDirection","lang","isRTL","includes","RTL","LTR","toBoolean","str","getSettings","getSetting","getLandingPage","data","getMobileView","clientWidth","sessionStorage","getItem","setSetting","value","setItem","String","Lang","LangContext","En","LangProvider","useLang","block","b","Header","Content","Footer","defaults","doc","Layout","props","children","headerHeight","header","content","footer","Children","child","type","className","BackgroundMedia","Col","ConstructorBlocks","Grid","Row","getThemedValue","useTheme","bPC","bPCRow","ConstructorRow","ConstructorPage","background","blocks","themedBackground","assign","items","DocumentType","useMemo","useContent","CustomPage","PageConstructor","layout","resetPaddings","config","custom","page","App","constructor","_defineProperty","worker","initWorker","base","mark","suggest","query","request","search","window","location","href","split","slice","join","message","BAD_ORIGIN_ERROR","loadWorker","Worker","URL","import","meta","url","error","DOMException","match","exec","blob","Blob","createObjectURL","channel","MessageChannel","Promise","resolve","reject","port1","onmessage","console","result","onmessageerror","postMessage","port2","useProvider","useCallback","useRef","SearchSuggest","Icon","Magnifier","SearchButton","size","Suggest","provider","onFocus","focusSearch","onBlur","setTimeout","current","close","ref","endContent","classNameContainer","closeButton","memo","ControlSizes","Controls","ControlsLayout","HeaderControls","mobileView","onChangeTheme","onChangeTextSize","onChangeWideFormat","onChangeShowMiniToc","langs","onChangeLang","controlClassName","controlSize","L","isWideView","isMobileView","CustomNavigation","MobileDropdown","findItem","right","left","some","item","useNavigation","controls","CustomControls","CustomSuggest","toc","navigation","logo","leftItems","rightItems","withControls","withSearch","router","unshift","navigationData","withBorder","customMobileHeaderItems","navigationTocData","mobileControlsData","userSettings","renderNavigation","PageConstructorProvider","getPageByType","Page","pageProps","EMPTY","LegacyNavPage","RichNavPage","undefined","MermaidRuntime","LatexRuntime","Runtime","OpenapiSandbox","Fragment","Dark","zoom","showMenu","bindKeys","getLangPath","useLangs","path","replace","useState","capitalize","string","ch","toUpperCase","useSettings","settings","useSetting","setting","onChangeSetting","withSavingSetting","settingName","onChange","useEffect","useMobile","setMobileView","onResizeHandler","addEventListener","removeEventListener","ThemeProvider","ConsentPopup","configure","hasNavigation","analytics","direction","landingPage","gtmId","gtm","id","consentMode","mode","contentTransformer","isPageConfig","preprocess","params","customYfmTransformer","transformBlocks","replaceTransformer","newTransformer","reduce","newConfig","subBlockType","subBlock","Array","isArray","map","transformer","customConfig","options","renderToString","render","Element","e","matches","matchesSelector","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","oMatchesSelector","selector","th","prototype","call","event","target","locationOrigin","origin","startsWith","preventDefault","mainFileName","extention","endsWith","splitedHref","length"],"sourceRoot":""}