@redocly/theme 0.56.0 → 0.57.0-next.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (60) hide show
  1. package/lib/components/Catalog/CatalogEntities.js +1 -1
  2. package/lib/components/Dropdown/Dropdown.d.ts +2 -1
  3. package/lib/components/Dropdown/Dropdown.js +3 -2
  4. package/lib/components/Dropdown/variables.js +1 -1
  5. package/lib/core/hooks/__mocks__/search/use-recent-searches.d.ts +2 -2
  6. package/lib/core/hooks/__mocks__/search/use-recent-searches.js +2 -1
  7. package/lib/core/hooks/__mocks__/search/use-search-filter.d.ts +2 -2
  8. package/lib/core/hooks/__mocks__/search/use-search-filter.js +2 -1
  9. package/lib/core/hooks/__mocks__/search/use-suggested-pages.d.ts +2 -2
  10. package/lib/core/hooks/__mocks__/search/use-suggested-pages.js +2 -1
  11. package/lib/core/hooks/__mocks__/use-controlled-state.d.ts +1 -1
  12. package/lib/core/hooks/__mocks__/use-controlled-state.js +2 -1
  13. package/lib/core/hooks/__mocks__/use-input-key-commands.d.ts +3 -3
  14. package/lib/core/hooks/__mocks__/use-input-key-commands.js +3 -2
  15. package/lib/core/hooks/__mocks__/use-mobile-menu.d.ts +1 -1
  16. package/lib/core/hooks/__mocks__/use-mobile-menu.js +2 -1
  17. package/lib/core/hooks/__mocks__/use-theme-config.d.ts +2 -2
  18. package/lib/core/hooks/__mocks__/use-theme-config.js +2 -1
  19. package/lib/core/hooks/__mocks__/use-theme-hooks.d.ts +47 -47
  20. package/lib/core/hooks/__mocks__/use-theme-hooks.js +38 -37
  21. package/lib/core/hooks/__mocks__/use-time-ago.d.ts +2 -2
  22. package/lib/core/hooks/__mocks__/use-time-ago.js +2 -1
  23. package/lib/core/hooks/catalog/useCatalogEntities.js +6 -4
  24. package/lib/core/hooks/code-walkthrough/__mocks__/MockIntersectionObserver.js +4 -3
  25. package/lib/core/hooks/menu/__mocks__/use-mobile-menu-items.d.ts +1 -1
  26. package/lib/core/hooks/menu/__mocks__/use-mobile-menu-items.js +2 -1
  27. package/lib/core/hooks/use-page-actions.js +5 -1
  28. package/lib/core/types/l10n.d.ts +1 -1
  29. package/lib/core/types/user-claims.d.ts +2 -0
  30. package/lib/core/utils/dynamic.d.ts +7 -0
  31. package/lib/core/utils/dynamic.js +59 -0
  32. package/lib/core/utils/index.d.ts +1 -0
  33. package/lib/core/utils/index.js +1 -0
  34. package/lib/icons/GenericIcon/GenericIcon.d.ts +2 -2
  35. package/lib/icons/GenericIcon/GenericIcon.js +8 -3
  36. package/lib/icons/__tests__/IconTestUtils.d.ts +0 -1
  37. package/lib/icons/__tests__/IconTestUtils.js +8 -7
  38. package/package.json +11 -15
  39. package/src/components/Catalog/CatalogEntities.tsx +1 -1
  40. package/src/components/Dropdown/Dropdown.tsx +4 -1
  41. package/src/components/Dropdown/variables.ts +1 -1
  42. package/src/core/hooks/__mocks__/search/use-recent-searches.ts +3 -1
  43. package/src/core/hooks/__mocks__/search/use-search-filter.ts +3 -1
  44. package/src/core/hooks/__mocks__/search/use-suggested-pages.ts +3 -1
  45. package/src/core/hooks/__mocks__/use-controlled-state.ts +3 -1
  46. package/src/core/hooks/__mocks__/use-input-key-commands.ts +4 -2
  47. package/src/core/hooks/__mocks__/use-mobile-menu.ts +3 -1
  48. package/src/core/hooks/__mocks__/use-theme-config.ts +3 -1
  49. package/src/core/hooks/__mocks__/use-theme-hooks.ts +39 -37
  50. package/src/core/hooks/__mocks__/use-time-ago.ts +3 -1
  51. package/src/core/hooks/catalog/useCatalogEntities.ts +7 -4
  52. package/src/core/hooks/code-walkthrough/__mocks__/MockIntersectionObserver.ts +5 -3
  53. package/src/core/hooks/menu/__mocks__/use-mobile-menu-items.ts +3 -1
  54. package/src/core/hooks/use-page-actions.ts +5 -1
  55. package/src/core/types/l10n.ts +2 -0
  56. package/src/core/types/user-claims.ts +2 -0
  57. package/src/core/utils/dynamic.tsx +83 -0
  58. package/src/core/utils/index.ts +1 -0
  59. package/src/icons/GenericIcon/GenericIcon.tsx +13 -4
  60. package/src/icons/__tests__/IconTestUtils.tsx +5 -4
@@ -43,7 +43,7 @@ function CatalogEntities(props) {
43
43
  const { items: entities, query, total, } = useFetchCatalogEntities({
44
44
  limit: LOAD_MORE_THRESHOLD,
45
45
  filter: initialFilter && filterQuery
46
- ? `${initialFilter} AND ${filterQuery}`
46
+ ? `(${initialFilter}) AND (${filterQuery})`
47
47
  : initialFilter || filterQuery,
48
48
  sort: sortOption || undefined,
49
49
  search: searchQuery,
@@ -11,5 +11,6 @@ export type DropdownProps = PropsWithChildren<{
11
11
  className?: string;
12
12
  withArrow?: boolean;
13
13
  onClick?: (event: React.UIEvent) => void;
14
+ onClose?: () => void;
14
15
  }>;
15
- export declare function Dropdown({ children, className, active, trigger, triggerEvent, closeOnClick, withArrow, dataAttributes, placement, alignment, onClick, }: DropdownProps): JSX.Element;
16
+ export declare function Dropdown({ children, className, active, trigger, triggerEvent, closeOnClick, withArrow, dataAttributes, placement, alignment, onClick, onClose, }: DropdownProps): JSX.Element;
@@ -32,7 +32,7 @@ const styled_components_1 = __importDefault(require("styled-components"));
32
32
  const hooks_1 = require("../../core/hooks");
33
33
  const ChevronDownIcon_1 = require("../../icons/ChevronDownIcon/ChevronDownIcon");
34
34
  const ChevronUpIcon_1 = require("../../icons/ChevronUpIcon/ChevronUpIcon");
35
- function Dropdown({ children, className, active, trigger, triggerEvent = 'click', closeOnClick = true, withArrow, dataAttributes, placement, alignment, onClick, }) {
35
+ function Dropdown({ children, className, active, trigger, triggerEvent = 'click', closeOnClick = true, withArrow, dataAttributes, placement, alignment, onClick, onClose, }) {
36
36
  const dropdownRef = (0, react_1.useRef)(null);
37
37
  const [isOpen, setIsOpen] = (0, hooks_1.useControlledState)(false, active);
38
38
  const handleOpen = () => {
@@ -40,6 +40,7 @@ function Dropdown({ children, className, active, trigger, triggerEvent = 'click'
40
40
  };
41
41
  const handleClose = () => {
42
42
  setIsOpen(false);
43
+ onClose === null || onClose === void 0 ? void 0 : onClose();
43
44
  };
44
45
  const handleChildClick = () => {
45
46
  handleClose();
@@ -78,7 +79,7 @@ const DropdownWrapper = styled_components_1.default.div `
78
79
  text-decoration: none;
79
80
  `;
80
81
  const ChildrenWrapper = styled_components_1.default.div `
81
- padding-top: var(--dropdown-menu-margin-top);
82
+ padding-top: var(--dropdown-menu-padding-top);
82
83
  position: absolute;
83
84
  top: ${({ placement }) => (placement === 'top' ? 'auto' : '100%')};
84
85
  bottom: ${({ placement }) => (placement === 'top' ? '100%' : 'auto')};
@@ -11,7 +11,7 @@ exports.dropdown = (0, styled_components_1.css) `
11
11
  --dropdown-menu-line-height: var(--line-height-base); // @presenter LineHeight
12
12
  --dropdown-menu-text-color: var(--text-color-secondary); // @presenter Color
13
13
 
14
- --dropdown-menu-margin-top: var(--spacing-xxs);
14
+ --dropdown-menu-padding-top: var(--spacing-xxs);
15
15
  --dropdown-menu-min-width: 100px;
16
16
  --dropdown-menu-max-width: 424px;
17
17
  --dropdown-menu-max-height: 300px;
@@ -1,5 +1,5 @@
1
- export declare const useRecentSearches: jest.Mock<{
1
+ export declare const useRecentSearches: import("vitest").Mock<() => {
2
2
  items: string[];
3
3
  addSearchHistoryItem: (value: string) => string;
4
4
  removeSearchHistoryItem: (value: string) => string;
5
- }, [], any>;
5
+ }>;
@@ -1,7 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useRecentSearches = void 0;
4
- exports.useRecentSearches = jest.fn(() => {
4
+ const vitest_1 = require("vitest");
5
+ exports.useRecentSearches = vitest_1.vi.fn(() => {
5
6
  const items = ['test'];
6
7
  return {
7
8
  items,
@@ -1,8 +1,8 @@
1
- export declare const useSearchFilter: jest.Mock<{
1
+ export declare const useSearchFilter: import("vitest").Mock<() => {
2
2
  isFilterOpen: boolean;
3
3
  onFacetReset: () => void;
4
4
  onFilterChange: () => void;
5
5
  onFilterToggle: () => void;
6
6
  onFilterReset: () => void;
7
7
  onQuickFilterReset: () => void;
8
- }, [], any>;
8
+ }>;
@@ -1,7 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useSearchFilter = void 0;
4
- exports.useSearchFilter = jest.fn(() => {
4
+ const vitest_1 = require("vitest");
5
+ exports.useSearchFilter = vitest_1.vi.fn(() => {
5
6
  return {
6
7
  isFilterOpen: false,
7
8
  onFacetReset: () => { },
@@ -1,4 +1,4 @@
1
- export declare const useSuggestedPages: jest.Mock<{
1
+ export declare const useSuggestedPages: import("vitest").Mock<() => {
2
2
  link: string;
3
3
  label: string;
4
- }[], [], any>;
4
+ }[]>;
@@ -1,7 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useSuggestedPages = void 0;
4
- exports.useSuggestedPages = jest.fn(() => {
4
+ const vitest_1 = require("vitest");
5
+ exports.useSuggestedPages = vitest_1.vi.fn(() => {
5
6
  return [
6
7
  {
7
8
  link: '/',
@@ -1 +1 @@
1
- export declare const useControlledState: () => (boolean | jest.Mock<any, any, any>)[];
1
+ export declare const useControlledState: () => (boolean | import("vitest").Mock<(...args: any[]) => any>)[];
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useControlledState = void 0;
4
- const useControlledState = () => [false, jest.fn()];
4
+ const vitest_1 = require("vitest");
5
+ const useControlledState = () => [false, vitest_1.vi.fn()];
5
6
  exports.useControlledState = useControlledState;
6
7
  //# sourceMappingURL=use-controlled-state.js.map
@@ -1,3 +1,3 @@
1
- export declare const useInputKeyCommands: jest.Mock<{
2
- onKeyDown: jest.Mock<any, any, any>;
3
- }, [], any>;
1
+ export declare const useInputKeyCommands: import("vitest").Mock<() => {
2
+ onKeyDown: import("vitest").Mock<(...args: any[]) => any>;
3
+ }>;
@@ -1,7 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useInputKeyCommands = void 0;
4
- exports.useInputKeyCommands = jest.fn(() => ({
5
- onKeyDown: jest.fn(),
4
+ const vitest_1 = require("vitest");
5
+ exports.useInputKeyCommands = vitest_1.vi.fn(() => ({
6
+ onKeyDown: vitest_1.vi.fn(),
6
7
  }));
7
8
  //# sourceMappingURL=use-input-key-commands.js.map
@@ -1 +1 @@
1
- export declare const useMobileMenu: () => (boolean | typeof jest.fn)[];
1
+ export declare const useMobileMenu: () => (boolean | import("vitest").Mock<(...args: any[]) => any>)[];
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useMobileMenu = void 0;
4
- const useMobileMenu = () => [false, jest.fn];
4
+ const vitest_1 = require("vitest");
5
+ const useMobileMenu = () => [false, vitest_1.vi.fn()];
5
6
  exports.useMobileMenu = useMobileMenu;
6
7
  //# sourceMappingURL=use-mobile-menu.js.map
@@ -1,8 +1,8 @@
1
- export declare const useThemeConfig: jest.Mock<{
1
+ export declare const useThemeConfig: import("vitest").Mock<() => {
2
2
  userMenu: {
3
3
  items: never[];
4
4
  };
5
5
  codeSnippet: {
6
6
  elementFormat: string;
7
7
  };
8
- }, [], any>;
8
+ }>;
@@ -1,7 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useThemeConfig = void 0;
4
- exports.useThemeConfig = jest.fn(() => ({
4
+ const vitest_1 = require("vitest");
5
+ exports.useThemeConfig = vitest_1.vi.fn(() => ({
5
6
  userMenu: {
6
7
  items: [],
7
8
  },
@@ -1,68 +1,68 @@
1
- export declare const useThemeHooks: jest.Mock<{
2
- useTranslate: jest.Mock<{
3
- translate: jest.Mock<any, [key: string, defaultValue: string], any>;
4
- }, [], any>;
5
- useTelemetry: jest.Mock<{
6
- send: jest.Mock<any, any, any>;
7
- }, [], any>;
8
- useBreadcrumbs: jest.Mock<any, any, any>;
9
- usePageSharedData: jest.Mock<any, any, any>;
10
- useCatalogClassic: jest.Mock<{
1
+ export declare const useThemeHooks: import("vitest").Mock<() => {
2
+ useTranslate: import("vitest").Mock<() => {
3
+ translate: import("vitest").Mock<(key: string, defaultValue: string) => any>;
4
+ }>;
5
+ useTelemetry: import("vitest").Mock<() => {
6
+ send: import("vitest").Mock<(...args: any[]) => any>;
7
+ }>;
8
+ useBreadcrumbs: import("vitest").Mock<(...args: any[]) => any>;
9
+ usePageSharedData: import("vitest").Mock<(...args: any[]) => any>;
10
+ useCatalogClassic: import("vitest").Mock<() => {
11
11
  groups: never[];
12
12
  filters: never[];
13
13
  filterTerm: string;
14
- setFilterTerm: jest.Mock<any, any, any>;
15
- }, [], any>;
16
- useL10n: jest.Mock<{
17
- changeLanguage: jest.Mock<any, any, any>;
18
- }, [], any>;
19
- useL10nConfig: jest.Mock<{
14
+ setFilterTerm: import("vitest").Mock<(...args: any[]) => any>;
15
+ }>;
16
+ useL10n: import("vitest").Mock<() => {
17
+ changeLanguage: import("vitest").Mock<(...args: any[]) => any>;
18
+ }>;
19
+ useL10nConfig: import("vitest").Mock<() => {
20
20
  currentLocale: string;
21
21
  defaultLocale: string;
22
22
  locales: {
23
23
  code: string;
24
24
  name: string;
25
25
  }[];
26
- }, [], any>;
27
- usePreloadHistory: jest.Mock<{
28
- push: jest.Mock<any, any, any>;
29
- }, [], any>;
30
- useCurrentProduct: jest.Mock<any, any, any>;
31
- useProducts: jest.Mock<never[], [], any>;
32
- useSearch: jest.Mock<{
33
- query: jest.Mock<any, any, any>;
34
- setQuery: jest.Mock<any, any, any>;
26
+ }>;
27
+ usePreloadHistory: import("vitest").Mock<() => {
28
+ push: import("vitest").Mock<(...args: any[]) => any>;
29
+ }>;
30
+ useCurrentProduct: import("vitest").Mock<(...args: any[]) => any>;
31
+ useProducts: import("vitest").Mock<() => never[]>;
32
+ useSearch: import("vitest").Mock<() => {
33
+ query: import("vitest").Mock<(...args: any[]) => any>;
34
+ setQuery: import("vitest").Mock<(...args: any[]) => any>;
35
35
  items: never[];
36
36
  isLoading: boolean;
37
- }, [], any>;
38
- useAiSearch: jest.Mock<{
39
- askQuestion: jest.Mock<any, any, any>;
37
+ }>;
38
+ useAiSearch: import("vitest").Mock<() => {
39
+ askQuestion: import("vitest").Mock<(...args: any[]) => any>;
40
40
  references: never[];
41
- }, [], any>;
42
- useFacetQuery: jest.Mock<{
41
+ }>;
42
+ useFacetQuery: import("vitest").Mock<() => {
43
43
  searchFacet: null;
44
- setSearchFacet: jest.Mock<any, any, any>;
45
- setSearchFacetQuery: jest.Mock<any, any, any>;
46
- }, [], any>;
47
- useMarkdownText: jest.Mock<null, [], any>;
48
- useUserMenu: jest.Mock<{
44
+ setSearchFacet: import("vitest").Mock<(...args: any[]) => any>;
45
+ setSearchFacetQuery: import("vitest").Mock<(...args: any[]) => any>;
46
+ }>;
47
+ useMarkdownText: import("vitest").Mock<() => null>;
48
+ useUserMenu: import("vitest").Mock<() => {
49
49
  userData: {
50
50
  isAuthenticated: boolean;
51
51
  name: string;
52
52
  email: string;
53
53
  picture: string;
54
54
  };
55
- handleLogout: jest.Mock<any, any, any>;
55
+ handleLogout: import("vitest").Mock<(...args: any[]) => any>;
56
56
  loginUrl: string;
57
57
  hasDeveloperOnboarding: boolean;
58
- }, [], any>;
59
- usePageVersions: jest.Mock<any, any, any>;
60
- useSidebarItems: jest.Mock<any, any, any>;
61
- useSidebarSiblingsData: jest.Mock<any, any, any>;
62
- useSubmitFeedback: jest.Mock<{
63
- submitFeedback: jest.Mock<any, any, any>;
64
- }, [], any>;
65
- useLoadAndNavigate: jest.Mock<any, any, any>;
66
- usePageProps: jest.Mock<any, any, any>;
67
- usePageData: jest.Mock<any, any, any>;
68
- }, [], any>;
58
+ }>;
59
+ usePageVersions: import("vitest").Mock<(...args: any[]) => any>;
60
+ useSidebarItems: import("vitest").Mock<(...args: any[]) => any>;
61
+ useSidebarSiblingsData: import("vitest").Mock<(...args: any[]) => any>;
62
+ useSubmitFeedback: import("vitest").Mock<() => {
63
+ submitFeedback: import("vitest").Mock<(...args: any[]) => any>;
64
+ }>;
65
+ useLoadAndNavigate: import("vitest").Mock<(...args: any[]) => any>;
66
+ usePageProps: import("vitest").Mock<(...args: any[]) => any>;
67
+ usePageData: import("vitest").Mock<(...args: any[]) => any>;
68
+ }>;
@@ -1,29 +1,30 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useThemeHooks = void 0;
4
- exports.useThemeHooks = jest.fn(() => ({
5
- useTranslate: jest.fn(() => ({
6
- translate: jest.fn((key, defaultValue) => defaultValue
4
+ const vitest_1 = require("vitest");
5
+ exports.useThemeHooks = vitest_1.vi.fn(() => ({
6
+ useTranslate: vitest_1.vi.fn(() => ({
7
+ translate: vitest_1.vi.fn((key, defaultValue) => defaultValue
7
8
  ? typeof defaultValue !== 'string'
8
9
  ? defaultValue.defaultValue
9
10
  : defaultValue
10
11
  : key),
11
12
  })),
12
- useTelemetry: jest.fn(() => ({
13
- send: jest.fn(),
13
+ useTelemetry: vitest_1.vi.fn(() => ({
14
+ send: vitest_1.vi.fn(),
14
15
  })),
15
- useBreadcrumbs: jest.fn().mockReturnValue([]),
16
- usePageSharedData: jest.fn().mockReturnValue({}),
17
- useCatalogClassic: jest.fn(() => ({
16
+ useBreadcrumbs: vitest_1.vi.fn().mockReturnValue([]),
17
+ usePageSharedData: vitest_1.vi.fn().mockReturnValue({}),
18
+ useCatalogClassic: vitest_1.vi.fn(() => ({
18
19
  groups: [],
19
20
  filters: [],
20
21
  filterTerm: '',
21
- setFilterTerm: jest.fn(),
22
+ setFilterTerm: vitest_1.vi.fn(),
22
23
  })),
23
- useL10n: jest.fn(() => ({
24
- changeLanguage: jest.fn(),
24
+ useL10n: vitest_1.vi.fn(() => ({
25
+ changeLanguage: vitest_1.vi.fn(),
25
26
  })),
26
- useL10nConfig: jest.fn(() => ({
27
+ useL10nConfig: vitest_1.vi.fn(() => ({
27
28
  currentLocale: 'en',
28
29
  defaultLocale: 'en',
29
30
  locales: [
@@ -32,42 +33,42 @@ exports.useThemeHooks = jest.fn(() => ({
32
33
  { code: 'uk', name: 'Ukraine' },
33
34
  ],
34
35
  })),
35
- usePreloadHistory: jest.fn(() => ({
36
- push: jest.fn(),
36
+ usePreloadHistory: vitest_1.vi.fn(() => ({
37
+ push: vitest_1.vi.fn(),
37
38
  })),
38
- useCurrentProduct: jest.fn(),
39
- useProducts: jest.fn(() => []),
40
- useSearch: jest.fn(() => ({
41
- query: jest.fn().mockReturnValue(''),
42
- setQuery: jest.fn(),
39
+ useCurrentProduct: vitest_1.vi.fn(),
40
+ useProducts: vitest_1.vi.fn(() => []),
41
+ useSearch: vitest_1.vi.fn(() => ({
42
+ query: vitest_1.vi.fn().mockReturnValue(''),
43
+ setQuery: vitest_1.vi.fn(),
43
44
  items: [],
44
45
  isLoading: false,
45
46
  })),
46
- useAiSearch: jest.fn(() => ({
47
- askQuestion: jest.fn(),
47
+ useAiSearch: vitest_1.vi.fn(() => ({
48
+ askQuestion: vitest_1.vi.fn(),
48
49
  references: [],
49
50
  })),
50
- useFacetQuery: jest.fn(() => ({
51
+ useFacetQuery: vitest_1.vi.fn(() => ({
51
52
  searchFacet: null,
52
- setSearchFacet: jest.fn(),
53
- setSearchFacetQuery: jest.fn(),
53
+ setSearchFacet: vitest_1.vi.fn(),
54
+ setSearchFacetQuery: vitest_1.vi.fn(),
54
55
  })),
55
- useMarkdownText: jest.fn(() => {
56
+ useMarkdownText: vitest_1.vi.fn(() => {
56
57
  return null;
57
58
  }),
58
- useUserMenu: jest.fn(() => ({
59
+ useUserMenu: vitest_1.vi.fn(() => ({
59
60
  userData: {
60
61
  isAuthenticated: true,
61
62
  name: 'test-name',
62
63
  email: 'test-email@test.xyz',
63
64
  picture: 'picture',
64
65
  },
65
- handleLogout: jest.fn(),
66
+ handleLogout: vitest_1.vi.fn(),
66
67
  loginUrl: 'https://login.redoc.ly',
67
68
  hasDeveloperOnboarding: true,
68
69
  })),
69
- usePageVersions: jest.fn(),
70
- useSidebarItems: jest.fn().mockReturnValue({
70
+ usePageVersions: vitest_1.vi.fn(),
71
+ useSidebarItems: vitest_1.vi.fn().mockReturnValue({
71
72
  currentItems: [
72
73
  {
73
74
  label: 'Item',
@@ -78,15 +79,15 @@ exports.useThemeHooks = jest.fn(() => ({
78
79
  label: 'Item',
79
80
  },
80
81
  ],
81
- popDrilldownState: jest.fn(),
82
- pushDrilldownState: jest.fn(),
82
+ popDrilldownState: vitest_1.vi.fn(),
83
+ pushDrilldownState: vitest_1.vi.fn(),
83
84
  }),
84
- useSidebarSiblingsData: jest.fn(),
85
- useSubmitFeedback: jest.fn(() => ({
86
- submitFeedback: jest.fn(),
85
+ useSidebarSiblingsData: vitest_1.vi.fn(),
86
+ useSubmitFeedback: vitest_1.vi.fn(() => ({
87
+ submitFeedback: vitest_1.vi.fn(),
87
88
  })),
88
- useLoadAndNavigate: jest.fn(),
89
- usePageProps: jest.fn().mockReturnValue({}),
90
- usePageData: jest.fn().mockReturnValue(null),
89
+ useLoadAndNavigate: vitest_1.vi.fn(),
90
+ usePageProps: vitest_1.vi.fn().mockReturnValue({}),
91
+ usePageData: vitest_1.vi.fn().mockReturnValue(null),
91
92
  }));
92
93
  //# sourceMappingURL=use-theme-hooks.js.map
@@ -1,3 +1,3 @@
1
- export declare const useTimeAgo: jest.Mock<{
1
+ export declare const useTimeAgo: import("vitest").Mock<() => {
2
2
  format: () => "5 days ago";
3
- }, [], any>;
3
+ }>;
@@ -1,7 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useTimeAgo = void 0;
4
- exports.useTimeAgo = jest.fn(() => ({
4
+ const vitest_1 = require("vitest");
5
+ exports.useTimeAgo = vitest_1.vi.fn(() => ({
5
6
  format: () => '5 days ago',
6
7
  }));
7
8
  //# sourceMappingURL=use-time-ago.js.map
@@ -7,11 +7,13 @@ function useCatalogEntities({ entitiesTypes, excludedEntities }) {
7
7
  const initialExcludedEntitiesFilter = (excludedEntities === null || excludedEntities === void 0 ? void 0 : excludedEntities.length)
8
8
  ? `-key:${excludedEntities.map((entity) => entity.key).join(',')}`
9
9
  : '';
10
- const initialFilter = initialTypesFilter
11
- ? `${initialTypesFilter} AND ${initialExcludedEntitiesFilter}`
12
- : initialExcludedEntitiesFilter;
10
+ if (initialTypesFilter && initialExcludedEntitiesFilter) {
11
+ return {
12
+ initialFilter: `(${initialTypesFilter}) AND (${initialExcludedEntitiesFilter})`,
13
+ };
14
+ }
13
15
  return {
14
- initialFilter,
16
+ initialFilter: initialTypesFilter || initialExcludedEntitiesFilter,
15
17
  };
16
18
  }
17
19
  //# sourceMappingURL=useCatalogEntities.js.map
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.MockIntersectionObserver = void 0;
4
+ const vitest_1 = require("vitest");
4
5
  class MockIntersectionObserver {
5
6
  // @ts-ignore
6
7
  constructor(callback, options) {
@@ -43,9 +44,9 @@ class MockIntersectionObserver {
43
44
  this.root = null;
44
45
  this.rootMargin = '0px';
45
46
  this.thresholds = [1];
46
- this.observe = jest.fn;
47
- this.unobserve = jest.fn;
48
- this.disconnect = jest.fn;
47
+ this.observe = vitest_1.vi.fn();
48
+ this.unobserve = vitest_1.vi.fn();
49
+ this.disconnect = vitest_1.vi.fn();
49
50
  }
50
51
  takeRecords() {
51
52
  return [];
@@ -1 +1 @@
1
- export declare const useMobileMenuItems: jest.Mock<any, any, any>;
1
+ export declare const useMobileMenuItems: import("vitest").Mock<(...args: any[]) => any>;
@@ -1,7 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useMobileMenuItems = void 0;
4
- exports.useMobileMenuItems = jest.fn().mockReturnValue({
4
+ const vitest_1 = require("vitest");
5
+ exports.useMobileMenuItems = vitest_1.vi.fn().mockReturnValue({
5
6
  items: [
6
7
  {
7
8
  type: 'group',
@@ -26,7 +26,8 @@ function usePageActions(pageSlug) {
26
26
  const { translate } = useTranslate();
27
27
  const { navigation } = (0, use_theme_config_1.useThemeConfig)();
28
28
  // Can't use any actions if no markdown files are generated for LLMs
29
- const isLlmsDisabled = ((_c = (_b = (_a = usePageProps()) === null || _a === void 0 ? void 0 : _a.seo) === null || _b === void 0 ? void 0 : _b.llmstxt) === null || _c === void 0 ? void 0 : _c.hide) === true;
29
+ const pageProps = usePageProps();
30
+ const isLlmsDisabled = ((_b = (_a = pageProps === null || pageProps === void 0 ? void 0 : pageProps.seo) === null || _a === void 0 ? void 0 : _a.llmstxt) === null || _b === void 0 ? void 0 : _b.hide) || ((_c = pageProps === null || pageProps === void 0 ? void 0 : pageProps.frontmatter) === null || _c === void 0 ? void 0 : _c.excludeFromSearch);
30
31
  const { isPublic } = usePageData() || {};
31
32
  const actions = (0, react_1.useMemo)(() => {
32
33
  var _a, _b;
@@ -54,6 +55,9 @@ function usePageActions(pageSlug) {
54
55
  onClick: () => __awaiter(this, void 0, void 0, function* () {
55
56
  try {
56
57
  const result = yield fetch(mdPageUrl);
58
+ if (result.status !== 200) {
59
+ throw new Error('Failed to fetch markdown content');
60
+ }
57
61
  const text = yield result.text();
58
62
  clipboard_service_1.ClipboardService.copyCustom(text);
59
63
  }
@@ -1,5 +1,5 @@
1
1
  import type { TOptions } from 'i18next';
2
- export type TranslationKey = 'dev.newApp' | 'dev.newApp.text' | 'dev.sidebar.header' | 'dev.sidebar.footer.text' | 'dev.create.app.dialog.appName.placeholder' | 'dev.create.app.dialog.appName.error' | 'dev.create.app.dialog.selectAPIs' | 'dev.create.app.dialog.description' | 'dev.create.app.dialog.description.placeholder' | 'dev.create.app.dialog.create' | 'dev.create.app.dialog.cancel' | 'dev.main.tab.appKeys' | 'dev.main.tab.logs' | 'dev.app.description.title' | 'dev.edit.description.dialog.title' | 'dev.edit.description.dialog.save' | 'dev.edit.description.dialog.cancel' | 'dev.edit.apis.dialog.selectedAPIs' | 'dev.app.key.create' | 'dev.create.key.dialog.title' | 'dev.create.key.dialog.create' | 'dev.create.key.dialog.cancel' | 'dev.app.edit' | 'dev.app.delete' | 'dev.edit.app.dialog.title' | 'dev.edit.app.dialog.save' | 'dev.edit.app.dialog.cancel' | 'dev.delete.app.dialog.title' | 'dev.delete.app.dialog.confirmation' | 'dev.delete.app.dialog.delete' | 'dev.delete.app.dialog.cancel' | 'dev.app.key.roll' | 'dev.roll.key.dialog.title' | 'dev.roll.key.dialog.apiKey' | 'dev.roll.key.dialog.expires' | 'dev.roll.key.dialog.confirmation' | 'dev.roll.key.dialog.cancel' | 'dev.roll.key.dialog.roll' | 'dev.update.key.dialog.title' | 'dev.update.key.dialog.update' | 'dev.update.key.dialog.cancel' | 'dev.app.key.api.name' | 'dev.app.key.api.status' | 'dev.app.key.api.edit' | 'dev.edit.apis.dialog.title' | 'dev.edit.apis.dialog.apiKey' | 'dev.edit.apis.dialog.save' | 'dev.edit.apis.dialog.cancel' | 'dev.select.placeholder' | 'dev.app.overview.status.pending' | 'dev.app.overview.status.approved' | 'dev.app.overview.status.revoked' | 'dev.app.overview.status' | 'dev.app.overview.non-production' | 'dev.app.overview.production' | 'dev.app.overview.clientId' | 'dev.app.overview.apiKey' | 'dev.app.key.revoke' | 'dev.revoke.key.dialog.title' | 'dev.revoke.key.dialog.apiKey' | 'dev.revoke.key.dialog.expires' | 'dev.revoke.key.dialog.confirmation' | 'dev.revoke.key.dialog.revoke' | 'dev.revoke.key.dialog.cancel' | 'dev.app.overview.expires' | 'dev.app.overview.created' | 'dev.app.overview.visibilityToggle.hide' | 'dev.app.overview.visibilityToggle.show' | 'search.loading' | 'search.noResults.title' | 'search.keys.navigate' | 'search.keys.select' | 'search.keys.exit' | 'search.label' | 'search.cancel' | 'search.recent' | 'search.navbar.label' | 'search.suggested' | 'search.showMore' | 'search.filter.title' | 'search.filter.reset' | 'search.filter.field.reset' | 'search.ai.welcomeText' | 'search.ai.newConversation' | 'search.ai.backToSearch' | 'search.ai.placeholder' | 'search.ai.generatingResponse' | 'search.ai.followUpQuestion' | 'search.ai.suggestionsTitle' | 'search.ai.thinkingText' | 'search.ai.resourcesFound' | 'search.ai.resourcesFound.basedOn' | 'search.ai.resourcesFound.resources' | 'search.ai.button' | 'search.ai.label' | 'search.ai.disclaimer' | 'search.ai.error.description' | 'search.ai.error.description.forbidden' | 'search.ai.error.description.unauthorized' | 'search.ai.error.header' | 'search.ai.error.header.forbidden' | 'search.ai.error.header.unauthorized' | 'toc.header' | 'footer.copyrightText' | 'page.homeButton' | 'page.forbidden.title' | 'page.notFound.title' | 'page.notFound.description' | 'page.lastUpdated.timeago' | 'page.lastUpdated.on' | 'catalog.filters.placeholder' | 'catalog.filters.title' | 'catalog.filters.add' | 'catalog.filters.clearAll' | 'catalog.filters.select.addFilter' | 'catalog.filters.select.all' | 'catalog.filters.done' | 'catalog.catalogs.all.title' | 'catalog.catalogs.all.description' | 'catalog.catalogs.all.switcherLabel' | 'catalog.catalogs.service.title' | 'catalog.catalogs.service.description' | 'catalog.catalogs.service.switcherLabel' | 'catalog.catalogs.user.title' | 'catalog.catalogs.user.description' | 'catalog.catalogs.user.switcherLabel' | 'catalog.catalogs.team.title' | 'catalog.catalogs.team.description' | 'catalog.catalogs.team.switcherLabel' | 'catalog.catalogs.domain.title' | 'catalog.catalogs.domain.description' | 'catalog.catalogs.domain.switcherLabel' | 'catalog.catalogs.apiDescription.title' | 'catalog.catalogs.apiDescription.description' | 'catalog.catalogs.apiDescription.switcherLabel' | 'catalog.catalogs.dataSchema.title' | 'catalog.catalogs.dataSchema.description' | 'catalog.catalogs.dataSchema.switcherLabel' | 'catalog.catalogs.apiOperation.title' | 'catalog.catalogs.apiOperation.description' | 'catalog.catalogs.apiOperation.switcherLabel' | 'catalog.entity.metadata.title' | 'catalog.entity.schema.title' | 'catalog.entity.properties.apiDescription.title' | 'sidebar.menu.backLabel' | 'sidebar.menu.backToLabel' | 'sidebar.actions.show' | 'sidebar.actions.hide' | 'sidebar.actions.changeLayout' | 'versionPicker.label' | 'versionPicker.unversioned' | 'codeSnippet.copy.buttonText' | 'codeSnippet.copy.tooltipText' | 'codeSnippet.copy.toasterText' | 'markdown.editPage.text' | 'feedback.settings.comment.submitText' | 'feedback.settings.comment.label' | 'feedback.settings.comment.send' | 'feedback.settings.comment.cancel' | 'feedback.settings.comment.satisfiedLabel' | 'feedback.settings.comment.neutralLabel' | 'feedback.settings.comment.dissatisfiedLabel' | 'feedback.settings.submitText' | 'feedback.settings.label' | 'feedback.settings.reasons.label' | 'feedback.submit' | 'feedback.cancel' | 'feedback.settings.comment.likeLabel' | 'feedback.settings.comment.dislikeLabel' | 'feedback.sentiment.thumbUp' | 'feedback.sentiment.thumbDown' | 'feedback.settings.leftScaleLabel' | 'feedback.settings.rightScaleLabel' | 'feedback.settings.optionalEmail.placeholder' | 'feedback.settings.optionalEmail.label' | 'codeSnippet.report.buttonText' | 'codeSnippet.report.tooltipText' | 'codeSnippet.report.label' | 'codeSnippet.expand.tooltipText' | 'codeSnippet.collapse.tooltipText' | 'userMenu.login' | 'userMenu.logout' | 'userMenu.devOnboardingLabel' | 'mobileMenu.mainMenu' | 'mobileMenu.previous' | 'mobileMenu.products' | 'mobileMenu.version' | 'navbar.products' | 'page.nextButton' | 'page.previousButton' | 'page.actions.copyButtonText' | 'page.actions.copyTitle' | 'page.actions.copyDescription' | 'page.actions.viewAsMdTitle' | 'page.actions.viewAsMdButtonText' | 'page.actions.viewAsMdDescription' | 'page.actions.chatGptTitle' | 'page.actions.chatGptButtonText' | 'page.actions.chatGptDescription' | 'page.actions.claudeTitle' | 'page.actions.claudeButtonText' | 'page.actions.claudeDescription' | 'openapi.download.description.title' | 'openapi.info.title' | 'openapi.info.contact.url' | 'openapi.info.contact.name' | 'openapi.info.license' | 'openapi.info.termsOfService' | 'openapi.info.metadata.title' | 'openapi.key' | 'openapi.value' | 'openapi.enum' | 'openapi.items' | 'openapi.default' | 'openapi.variable' | 'openapi.variables' | 'openapi.actions.show' | 'openapi.actions.hide' | 'openapi.actions.more' | 'openapi.languages.title' | 'openapi.servers.title' | 'openapi.operations' | 'openapi.webhooks' | 'openapi.description' | 'openapi.badges.deprecated' | 'openapi.badges.required' | 'openapi.badges.webhook' | 'openapi.request' | 'openapi.path' | 'openapi.query' | 'openapi.cookie' | 'openapi.header' | 'openapi.body' | 'openapi.responses' | 'openapi.response' | 'openapi.callbacks' | 'openapi.callbackRequest' | 'openapi.callbackResponse' | 'openapi.payload' | 'openapi.discriminator' | 'openapi.contentType' | 'openapi.tryIt' | 'openapi.loading' | 'openapi.example' | 'openapi.examples' | 'openapi.additionalProperties' | 'openapi.patternProperties' | 'openapi.required' | 'openapi.recursive' | 'openapi.complex' | 'openapi.hideExample' | 'openapi.showExample' | 'openapi.expandAll' | 'openapi.collapseAll' | 'openapi.viewSecurityDetails' | 'openapi.noResponseExample' | 'openapi.noResponseContent' | 'openapi.noRequestPayload' | 'openapi.hidePattern' | 'openapi.showPattern' | 'openapi.authorizationUrl' | 'openapi.tokenUrl' | 'openapi.refreshUrl' | 'openapi.showOptionalScopes' | 'openapi.hideOptionalScopes' | 'openapi.security' | 'openapi.httpAuthorizationScheme' | 'openapi.bearerFormat' | 'openapi.parameterName' | 'openapi.flowType' | 'openapi.connectUrl' | 'openapi.requiredScopes' | 'openapi.unsupportedLanguage' | 'openapi.failedToGenerateCodeSample' | 'asyncapi.download.description.title' | 'asyncapi.info.title' | 'graphql.queries' | 'graphql.mutations' | 'graphql.subscriptions' | 'graphql.directives' | 'graphql.objects' | 'graphql.interfaces' | 'graphql.unions' | 'graphql.enums' | 'graphql.inputs' | 'graphql.scalars' | 'graphql.arguments.label' | 'graphql.arguments.show' | 'graphql.arguments.hide' | 'graphql.arguments.here' | 'graphql.returnTypes.label' | 'graphql.returnTypes.show' | 'graphql.returnTypes.hide' | 'graphql.possibleTypes' | 'graphql.defaultValue' | 'graphql.deprecationReason' | 'graphql.implementedInterfaces' | 'graphql.nonNull' | 'graphql.required' | 'graphql.deprecated' | 'graphql.variables' | 'graphql.querySample' | 'graphql.mutationSample' | 'graphql.subscriptionSample' | 'graphql.responseSample' | 'graphql.locations' | 'graphql.sample' | 'graphql.referenced' | 'graphql.content.fragment' | 'codeWalkthrough.download' | 'codeWalkthrough.preview' | 'time.justNow' | 'time.past.second' | 'time.past.seconds' | 'time.past.minute' | 'time.past.minutes' | 'time.past.hour' | 'time.past.hours' | 'time.past.day' | 'time.past.days' | 'time.past.week' | 'time.past.weeks' | 'time.past.month' | 'time.past.months' | 'time.past.year' | 'time.past.years' | 'page.internalServerError.title' | 'page.internalServerError.description' | 'page.skipToContent.label';
2
+ export type TranslationKey = 'dev.newApp' | 'dev.newApp.text' | 'dev.sidebar.header' | 'dev.sidebar.footer.text' | 'dev.create.app.dialog.appName.placeholder' | 'dev.create.app.dialog.appName.error' | 'dev.create.app.dialog.selectAPIs' | 'dev.create.app.dialog.description' | 'dev.create.app.dialog.description.placeholder' | 'dev.create.app.dialog.create' | 'dev.create.app.dialog.cancel' | 'dev.main.tab.appKeys' | 'dev.main.tab.logs' | 'dev.app.description.title' | 'dev.edit.description.dialog.title' | 'dev.edit.description.dialog.save' | 'dev.edit.description.dialog.cancel' | 'dev.edit.apis.dialog.selectedAPIs' | 'dev.app.key.create' | 'dev.create.key.dialog.title' | 'dev.create.key.dialog.create' | 'dev.create.key.dialog.cancel' | 'dev.app.edit' | 'dev.app.delete' | 'dev.edit.app.dialog.title' | 'dev.edit.app.dialog.save' | 'dev.edit.app.dialog.cancel' | 'dev.delete.app.dialog.title' | 'dev.delete.app.dialog.confirmation' | 'dev.delete.app.dialog.delete' | 'dev.delete.app.dialog.cancel' | 'dev.app.key.roll' | 'dev.roll.key.dialog.title' | 'dev.roll.key.dialog.apiKey' | 'dev.roll.key.dialog.expires' | 'dev.roll.key.dialog.confirmation' | 'dev.roll.key.dialog.cancel' | 'dev.roll.key.dialog.roll' | 'dev.update.key.dialog.title' | 'dev.update.key.dialog.update' | 'dev.update.key.dialog.cancel' | 'dev.app.key.api.name' | 'dev.app.key.api.status' | 'dev.app.key.api.edit' | 'dev.edit.apis.dialog.title' | 'dev.edit.apis.dialog.apiKey' | 'dev.edit.apis.dialog.save' | 'dev.edit.apis.dialog.cancel' | 'dev.select.placeholder' | 'dev.app.overview.status.pending' | 'dev.app.overview.status.approved' | 'dev.app.overview.status.revoked' | 'dev.app.overview.status' | 'dev.app.overview.non-production' | 'dev.app.overview.production' | 'dev.app.overview.clientId' | 'dev.app.overview.apiKey' | 'dev.app.key.revoke' | 'dev.revoke.key.dialog.title' | 'dev.revoke.key.dialog.apiKey' | 'dev.revoke.key.dialog.expires' | 'dev.revoke.key.dialog.confirmation' | 'dev.revoke.key.dialog.revoke' | 'dev.revoke.key.dialog.cancel' | 'dev.app.overview.expires' | 'dev.app.overview.created' | 'dev.app.overview.visibilityToggle.hide' | 'dev.app.overview.visibilityToggle.show' | 'search.loading' | 'search.noResults.title' | 'search.keys.navigate' | 'search.keys.select' | 'search.keys.exit' | 'search.label' | 'search.cancel' | 'search.recent' | 'search.navbar.label' | 'search.suggested' | 'search.showMore' | 'search.filter.title' | 'search.filter.reset' | 'search.filter.field.reset' | 'search.ai.welcomeText' | 'search.ai.newConversation' | 'search.ai.backToSearch' | 'search.ai.placeholder' | 'search.ai.generatingResponse' | 'search.ai.followUpQuestion' | 'search.ai.suggestionsTitle' | 'search.ai.thinkingText' | 'search.ai.resourcesFound' | 'search.ai.resourcesFound.basedOn' | 'search.ai.resourcesFound.resources' | 'search.ai.button' | 'search.ai.label' | 'search.ai.disclaimer' | 'search.ai.error.description' | 'search.ai.error.description.forbidden' | 'search.ai.error.description.unauthorized' | 'search.ai.error.header' | 'search.ai.error.header.forbidden' | 'search.ai.error.header.unauthorized' | 'toc.header' | 'footer.copyrightText' | 'page.homeButton' | 'page.forbidden.title' | 'page.notFound.title' | 'page.notFound.description' | 'page.lastUpdated.timeago' | 'page.lastUpdated.on' | 'catalog.filters.placeholder' | 'catalog.filters.title' | 'catalog.filters.add' | 'catalog.filters.clearAll' | 'catalog.filters.select.addFilter' | 'catalog.filters.select.all' | 'catalog.filters.done' | 'catalog.catalogs.all.title' | 'catalog.catalogs.all.description' | 'catalog.catalogs.all.switcherLabel' | 'catalog.catalogs.service.title' | 'catalog.catalogs.service.description' | 'catalog.catalogs.service.switcherLabel' | 'catalog.catalogs.user.title' | 'catalog.catalogs.user.description' | 'catalog.catalogs.user.switcherLabel' | 'catalog.catalogs.team.title' | 'catalog.catalogs.team.description' | 'catalog.catalogs.team.switcherLabel' | 'catalog.catalogs.domain.title' | 'catalog.catalogs.domain.description' | 'catalog.catalogs.domain.switcherLabel' | 'catalog.catalogs.apiDescription.title' | 'catalog.catalogs.apiDescription.description' | 'catalog.catalogs.apiDescription.switcherLabel' | 'catalog.catalogs.dataSchema.title' | 'catalog.catalogs.dataSchema.description' | 'catalog.catalogs.dataSchema.switcherLabel' | 'catalog.catalogs.apiOperation.title' | 'catalog.catalogs.apiOperation.description' | 'catalog.catalogs.apiOperation.switcherLabel' | 'catalog.entity.metadata.title' | 'catalog.entity.schema.title' | 'catalog.entity.properties.apiDescription.title' | 'sidebar.menu.backLabel' | 'sidebar.menu.backToLabel' | 'sidebar.actions.show' | 'sidebar.actions.hide' | 'sidebar.actions.changeLayout' | 'versionPicker.label' | 'versionPicker.unversioned' | 'codeSnippet.copy.buttonText' | 'codeSnippet.copy.tooltipText' | 'codeSnippet.copy.toasterText' | 'markdown.editPage.text' | 'feedback.settings.comment.submitText' | 'feedback.settings.comment.label' | 'feedback.settings.comment.send' | 'feedback.settings.comment.cancel' | 'feedback.settings.comment.satisfiedLabel' | 'feedback.settings.comment.neutralLabel' | 'feedback.settings.comment.dissatisfiedLabel' | 'feedback.settings.submitText' | 'feedback.settings.label' | 'feedback.settings.reasons.label' | 'feedback.submit' | 'feedback.cancel' | 'feedback.settings.comment.likeLabel' | 'feedback.settings.comment.dislikeLabel' | 'feedback.sentiment.thumbUp' | 'feedback.sentiment.thumbDown' | 'feedback.settings.leftScaleLabel' | 'feedback.settings.rightScaleLabel' | 'feedback.settings.optionalEmail.placeholder' | 'feedback.settings.optionalEmail.label' | 'codeSnippet.report.buttonText' | 'codeSnippet.report.tooltipText' | 'codeSnippet.report.label' | 'codeSnippet.expand.tooltipText' | 'codeSnippet.collapse.tooltipText' | 'userMenu.login' | 'userMenu.logout' | 'userMenu.devOnboardingLabel' | 'mobileMenu.mainMenu' | 'mobileMenu.previous' | 'mobileMenu.products' | 'mobileMenu.version' | 'navbar.products' | 'page.nextButton' | 'page.previousButton' | 'page.actions.copyButtonText' | 'page.actions.copyTitle' | 'page.actions.copyDescription' | 'page.actions.viewAsMdTitle' | 'page.actions.viewAsMdButtonText' | 'page.actions.viewAsMdDescription' | 'page.actions.chatGptTitle' | 'page.actions.chatGptButtonText' | 'page.actions.chatGptDescription' | 'page.actions.claudeTitle' | 'page.actions.claudeButtonText' | 'page.actions.claudeDescription' | 'openapi.download.description.title' | 'openapi.info.title' | 'openapi.info.contact.url' | 'openapi.info.contact.name' | 'openapi.info.license' | 'openapi.info.termsOfService' | 'openapi.info.metadata.title' | 'openapi.key' | 'openapi.value' | 'openapi.enum' | 'openapi.items' | 'openapi.default' | 'openapi.variable' | 'openapi.variables' | 'openapi.actions.show' | 'openapi.actions.hide' | 'openapi.actions.more' | 'openapi.languages.title' | 'openapi.servers.title' | 'openapi.operations' | 'openapi.webhooks' | 'openapi.description' | 'openapi.badges.deprecated' | 'openapi.badges.required' | 'openapi.badges.webhook' | 'openapi.request' | 'openapi.path' | 'openapi.query' | 'openapi.cookie' | 'openapi.header' | 'openapi.body' | 'openapi.responses' | 'openapi.response' | 'openapi.callbacks' | 'openapi.callbackRequest' | 'openapi.callbackResponse' | 'openapi.payload' | 'openapi.discriminator' | 'openapi.contentType' | 'openapi.tryIt' | 'openapi.loading' | 'openapi.example' | 'openapi.examples' | 'openapi.additionalProperties' | 'openapi.patternProperties' | 'openapi.required' | 'openapi.recursive' | 'openapi.complex' | 'openapi.hideExample' | 'openapi.showExample' | 'openapi.expandAll' | 'openapi.collapseAll' | 'openapi.viewSecurityDetails' | 'openapi.noResponseExample' | 'openapi.discriminator.searchPlaceholder' | 'openapi.discriminator.searchNoResults' | 'openapi.noResponseContent' | 'openapi.noRequestPayload' | 'openapi.hidePattern' | 'openapi.showPattern' | 'openapi.authorizationUrl' | 'openapi.tokenUrl' | 'openapi.refreshUrl' | 'openapi.showOptionalScopes' | 'openapi.hideOptionalScopes' | 'openapi.security' | 'openapi.httpAuthorizationScheme' | 'openapi.bearerFormat' | 'openapi.parameterName' | 'openapi.flowType' | 'openapi.connectUrl' | 'openapi.requiredScopes' | 'openapi.unsupportedLanguage' | 'openapi.failedToGenerateCodeSample' | 'asyncapi.download.description.title' | 'asyncapi.info.title' | 'graphql.queries' | 'graphql.mutations' | 'graphql.subscriptions' | 'graphql.directives' | 'graphql.objects' | 'graphql.interfaces' | 'graphql.unions' | 'graphql.enums' | 'graphql.inputs' | 'graphql.scalars' | 'graphql.arguments.label' | 'graphql.arguments.show' | 'graphql.arguments.hide' | 'graphql.arguments.here' | 'graphql.returnTypes.label' | 'graphql.returnTypes.show' | 'graphql.returnTypes.hide' | 'graphql.possibleTypes' | 'graphql.defaultValue' | 'graphql.deprecationReason' | 'graphql.implementedInterfaces' | 'graphql.nonNull' | 'graphql.required' | 'graphql.deprecated' | 'graphql.variables' | 'graphql.querySample' | 'graphql.mutationSample' | 'graphql.subscriptionSample' | 'graphql.responseSample' | 'graphql.locations' | 'graphql.sample' | 'graphql.referenced' | 'graphql.content.fragment' | 'codeWalkthrough.download' | 'codeWalkthrough.preview' | 'time.justNow' | 'time.past.second' | 'time.past.seconds' | 'time.past.minute' | 'time.past.minutes' | 'time.past.hour' | 'time.past.hours' | 'time.past.day' | 'time.past.days' | 'time.past.week' | 'time.past.weeks' | 'time.past.month' | 'time.past.months' | 'time.past.year' | 'time.past.years' | 'page.internalServerError.title' | 'page.internalServerError.description' | 'page.skipToContent.label';
3
3
  export type Locale = {
4
4
  code: string;
5
5
  name: string;
@@ -1,4 +1,6 @@
1
1
  export type UserClaims = {
2
2
  email?: string;
3
3
  name?: string;
4
+ federatedAccessToken?: string;
5
+ federatedIdToken?: string;
4
6
  };
@@ -0,0 +1,7 @@
1
+ import React from 'react';
2
+ interface DynamicOptions {
3
+ ssr?: boolean;
4
+ loading?: React.ComponentType<Record<string, unknown>>;
5
+ }
6
+ export declare function dynamic<T extends React.ComponentType<Record<string, unknown>>>(factory: () => Promise<T | Record<string, unknown>>, { ssr, loading }?: DynamicOptions): React.ComponentType<Record<string, unknown>>;
7
+ export {};