@redocly/theme 0.1.9 → 0.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Button/index.d.ts +1 -1
- package/Button/index.js +1 -1
- package/CodeBlock/index.d.ts +1 -1
- package/CodeBlock/index.js +1 -1
- package/CopyButton/index.d.ts +2 -2
- package/CopyButton/index.js +2 -2
- package/Footer/Footer.d.ts +2 -2
- package/Footer/Footer.js +1 -1
- package/Footer/FooterColumn.js +6 -6
- package/Footer/FooterColumns.d.ts +3 -3
- package/Footer/FooterCopyright.d.ts +3 -3
- package/Footer/FooterCopyright.js +1 -1
- package/Footer/index.d.ts +4 -4
- package/Footer/index.js +4 -4
- package/Headings/index.d.ts +1 -1
- package/Headings/index.js +1 -1
- package/JsonViewer/index.d.ts +2 -2
- package/JsonViewer/index.js +2 -2
- package/Layout/index.d.ts +2 -2
- package/Layout/index.js +2 -2
- package/Markdown/Admonition.js +4 -4
- package/Markdown/CodeSample/index.d.ts +3 -3
- package/Markdown/CodeSample/index.js +3 -3
- package/Markdown/Heading.js +1 -1
- package/Markdown/MarkdownLayout.d.ts +2 -2
- package/Markdown/StyledMarkdown.js +2 -2
- package/Markdown/Tabs/index.d.ts +2 -2
- package/Markdown/Tabs/index.js +2 -2
- package/Markdown/index.d.ts +9 -9
- package/Markdown/index.js +9 -9
- package/Navbar/Navbar.d.ts +0 -1
- package/Navbar/Navbar.js +1 -1
- package/Navbar/NavbarItem.js +1 -1
- package/Navbar/index.d.ts +3 -0
- package/Navbar/index.js +19 -0
- package/NavbarLogo/NavbarLogo.d.ts +6 -0
- package/{Logo/Logo.js → NavbarLogo/NavbarLogo.js} +8 -5
- package/NavbarLogo/index.d.ts +1 -0
- package/{Logo → NavbarLogo}/index.js +1 -1
- package/OperationBadge/index.d.ts +1 -1
- package/OperationBadge/index.js +1 -1
- package/PageNavigation/index.d.ts +3 -0
- package/PageNavigation/index.js +19 -0
- package/Panel/index.d.ts +8 -8
- package/Panel/index.js +8 -8
- package/REAMDE.md +1 -0
- package/SamplesPanelControls/index.d.ts +1 -1
- package/SamplesPanelControls/index.js +1 -1
- package/Search/Autocomplete.js +1 -1
- package/Search/Parameters.js +2 -2
- package/Search/SearchItem.js +2 -2
- package/Search/index.d.ts +9 -9
- package/Search/index.js +9 -9
- package/Search/utils.js +1 -1
- package/Sidebar/BackButton.js +1 -1
- package/Sidebar/DrilldownMenuItem.js +3 -3
- package/Sidebar/Menu.js +1 -1
- package/Sidebar/MenuItemLabel.js +2 -2
- package/Sidebar/MenuLink.js +1 -1
- package/Sidebar/MobileSidebarButton.js +1 -1
- package/Sidebar/Sidebar.js +1 -1
- package/Sidebar/index.d.ts +19 -19
- package/Sidebar/index.js +19 -19
- package/Sidebar/types/index.d.ts +5 -5
- package/Sidebar/types/index.js +5 -5
- package/SidebarLogo/index.d.ts +1 -1
- package/SidebarLogo/index.js +1 -1
- package/SourceCode/index.d.ts +1 -1
- package/SourceCode/index.js +1 -1
- package/TableOfContent/TableOfContent.js +3 -3
- package/TableOfContent/index.d.ts +1 -1
- package/TableOfContent/index.js +1 -1
- package/Tooltip/index.d.ts +1 -1
- package/Tooltip/index.js +1 -1
- package/globalStyle.js +1 -1
- package/hooks/index.d.ts +7 -7
- package/hooks/index.js +7 -7
- package/hooks/useActiveSectionId.d.ts +2 -2
- package/hooks/useActiveSectionId.js +1 -0
- package/icons/ShelfIcon/index.d.ts +2 -2
- package/icons/ShelfIcon/index.js +1 -1
- package/icons/index.d.ts +1 -1
- package/icons/index.js +1 -1
- package/package.json +1 -1
- package/src/Button/Button.stories.tsx +1 -1
- package/src/Button/index.ts +1 -1
- package/src/CodeBlock/index.ts +1 -1
- package/src/CopyButton/CopyButton.stories.tsx +1 -1
- package/src/CopyButton/index.ts +2 -2
- package/src/Footer/Footer.stories.tsx +57 -0
- package/src/Footer/Footer.tsx +5 -8
- package/src/Footer/FooterColumn.tsx +7 -7
- package/src/Footer/FooterColumns.tsx +3 -1
- package/src/Footer/FooterCopyright.tsx +5 -3
- package/src/Footer/__tests__/Footer.test.tsx +55 -0
- package/src/Footer/__tests__/__snapshots__/Footer.test.tsx.snap +253 -0
- package/src/Footer/index.ts +4 -4
- package/src/Headings/index.ts +1 -1
- package/src/JsonViewer/JsonViewer.stories.tsx +1 -1
- package/src/JsonViewer/index.ts +2 -2
- package/src/Layout/__tests__/PageLayout.test.tsx +17 -0
- package/src/Layout/__tests__/RootLayout.test.tsx +17 -0
- package/src/Layout/__tests__/__snapshots__/PageLayout.test.tsx.snap +38 -0
- package/src/Layout/__tests__/__snapshots__/RootLayout.test.tsx.snap +18 -0
- package/src/Layout/index.ts +2 -2
- package/src/Markdown/Admonition.tsx +15 -15
- package/src/Markdown/CodeSample/index.ts +3 -3
- package/src/Markdown/Heading.tsx +4 -1
- package/src/Markdown/MarkdownLayout.tsx +2 -2
- package/src/Markdown/StyledMarkdown.tsx +27 -27
- package/src/Markdown/Tabs/index.ts +2 -2
- package/src/Markdown/index.ts +9 -9
- package/src/Navbar/Navbar.stories.tsx +7 -3
- package/src/Navbar/Navbar.tsx +2 -3
- package/src/Navbar/NavbarItem.tsx +1 -1
- package/src/Navbar/index.ts +3 -0
- package/src/NavbarLogo/NavbarLogo.stories.tsx +20 -0
- package/src/NavbarLogo/NavbarLogo.tsx +24 -0
- package/src/NavbarLogo/__tests__/NavbarLogo.test.tsx +47 -0
- package/src/NavbarLogo/__tests__/__snapshots__/NavbarLogo.test.tsx.snap +38 -0
- package/src/NavbarLogo/index.ts +1 -0
- package/src/OperationBadge/OperationBadge.stories.tsx +1 -1
- package/src/OperationBadge/index.ts +1 -1
- package/src/PageNavigation/index.ts +3 -0
- package/src/Panel/index.ts +8 -8
- package/src/SamplesPanelControls/SamplesControlButton.stories.tsx +1 -1
- package/src/SamplesPanelControls/index.ts +1 -1
- package/src/Search/Autocomplete.tsx +1 -1
- package/src/Search/Parameters.tsx +2 -2
- package/src/Search/SearchItem.tsx +2 -2
- package/src/Search/index.ts +9 -9
- package/src/Search/utils.tsx +1 -1
- package/src/Sidebar/BackButton.tsx +2 -2
- package/src/Sidebar/DrilldownMenuItem.tsx +4 -4
- package/src/Sidebar/Menu.tsx +1 -1
- package/src/Sidebar/MenuItemLabel.tsx +4 -4
- package/src/Sidebar/MenuLink.tsx +1 -1
- package/src/Sidebar/MobileSidebarButton.tsx +2 -2
- package/src/Sidebar/Sidebar.tsx +1 -1
- package/src/Sidebar/index.ts +19 -19
- package/src/Sidebar/types/index.ts +5 -5
- package/src/SidebarLogo/SidebarLogo.stories.tsx +1 -1
- package/src/SidebarLogo/index.ts +1 -1
- package/src/SourceCode/SourceCode.stories.tsx +1 -1
- package/src/SourceCode/index.ts +1 -1
- package/src/TableOfContent/TableOfContent.tsx +6 -6
- package/src/TableOfContent/index.ts +1 -1
- package/src/Tooltip/Tooltip.stories.tsx +1 -1
- package/src/Tooltip/index.ts +1 -1
- package/src/Welcome.stories.mdx +7 -0
- package/src/globalStyle.ts +102 -7
- package/src/hooks/index.ts +7 -7
- package/src/hooks/useActiveSectionId.ts +3 -3
- package/src/icons/ShelfIcon/index.ts +2 -2
- package/src/icons/index.ts +1 -1
- package/src/types/portal/index.d.ts +0 -1
- package/src/types/portal/src/client/app/Sidebar/types.d.ts +32 -41
- package/src/types/portal/src/client/app/media-css.d.ts +4 -4
- package/src/types/portal/src/client/styling/default.d.ts +585 -391
- package/src/types/portal/src/client/styling/index.d.ts +2 -6
- package/src/types/portal/src/server/constants.d.ts +5 -9
- package/src/types/portal/src/server/plugins/markdown/types.d.ts +14 -19
- package/src/types/portal/src/server/plugins/portal-config/types.d.ts +12 -12
- package/src/types/portal/src/server/plugins/types.d.ts +55 -0
- package/src/types/portal/src/server/store.d.ts +49 -97
- package/src/types/portal/src/server/utils/async.d.ts +1 -5
- package/src/types/portal/src/server/utils/content-provider.d.ts +51 -0
- package/src/types/portal/src/server/utils/index.d.ts +1 -1
- package/src/types/portal/src/server/utils/paths.d.ts +10 -13
- package/src/types/portal/src/server/utils/reporter/formatter.d.ts +8 -8
- package/src/types/portal/src/server/utils/reporter/reporter.d.ts +15 -15
- package/src/types/portal/src/server/version-store.d.ts +35 -0
- package/src/types/portal/src/shared/constants.d.ts +6 -6
- package/src/types/portal/src/shared/types.d.ts +97 -58
- package/src/types/portal/src/shared/urls.d.ts +2 -1
- package/src/ui/AlertIcon.tsx +8 -7
- package/src/ui/Background.tsx +3 -3
- package/src/ui/Dropdown.tsx +4 -4
- package/src/ui/Jumbotron.tsx +3 -3
- package/src/ui/Tiles/TileHeader.ts +1 -1
- package/src/ui/Tiles/TileText.tsx +2 -2
- package/src/ui/Tiles/index.ts +4 -4
- package/src/ui/Typography.tsx +22 -22
- package/ui/AlertIcon.d.ts +3 -2
- package/ui/AlertIcon.js +2 -2
- package/ui/Background.js +1 -1
- package/ui/Dropdown.js +3 -3
- package/ui/Jumbotron.js +3 -3
- package/ui/Tiles/TileHeader.js +1 -1
- package/ui/Tiles/TileText.js +1 -1
- package/ui/Tiles/index.d.ts +4 -4
- package/ui/Tiles/index.js +4 -4
- package/ui/Typography.js +20 -20
- package/Logo/Logo.d.ts +0 -5
- package/Logo/index.d.ts +0 -1
- package/src/Introduction.stories.mdx +0 -7
- package/src/Logo/Logo.tsx +0 -17
- package/src/Logo/index.ts +0 -1
- package/src/types/portal/src/server/plugins/nav-utils.d.ts +0 -19
- package/src/types/portal/src/server/plugins/sidebars/index.d.ts +0 -16
- package/src/types/portal/src/server/plugins/versions/index.d.ts +0 -15
- package/src/types/portal/src/server/plugins/versions/types.d.ts +0 -23
- package/src/types/portal/src/server/plugins/versions/utils.d.ts +0 -10
- package/src/types/portal/src/server/utils/watcher.d.ts +0 -16
package/Logo/Logo.d.ts
DELETED
package/Logo/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './Logo';
|
package/src/Logo/Logo.tsx
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import styled from 'styled-components';
|
|
3
|
-
|
|
4
|
-
import { Link } from '@portal/Link';
|
|
5
|
-
import { LogoConfig } from '@theme/types/portal';
|
|
6
|
-
|
|
7
|
-
export function Logo({ logo }: { logo: LogoConfig }): JSX.Element | null {
|
|
8
|
-
const img = <NavLogo src={logo.image} alt={logo.altText} data-component-name="Logo/Logo" />;
|
|
9
|
-
return logo?.image ? logo.link ? <Link to={logo.link}>{img}</Link> : img : null;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
const NavLogo = styled.img`
|
|
13
|
-
max-width: var(--logo-max-width);
|
|
14
|
-
max-height: var(--logo-max-height);
|
|
15
|
-
height: var(--logo-height);
|
|
16
|
-
margin: var(--logo-margin);
|
|
17
|
-
`;
|
package/src/Logo/index.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './Logo';
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { Page, Store } from '../store.js';
|
|
2
|
-
import type { ResolvedNavItem, NavItem, RawNavItem } from '../../shared/types.js';
|
|
3
|
-
export declare function normalizeItems(items: RawNavItem[]): NavItem[];
|
|
4
|
-
export declare function resolveVersionItems(
|
|
5
|
-
items: RawNavItem[],
|
|
6
|
-
store: Store,
|
|
7
|
-
versions?: any,
|
|
8
|
-
): RawNavItem[];
|
|
9
|
-
export declare function resolvePage(pagePath: string, fromFile: string, store: Store): Page;
|
|
10
|
-
export declare function resolveItems(
|
|
11
|
-
items: NavItem[],
|
|
12
|
-
fromFile: string,
|
|
13
|
-
store: Store,
|
|
14
|
-
): Promise<ResolvedNavItem[]>;
|
|
15
|
-
export declare function resolveItem(
|
|
16
|
-
item: NavItem,
|
|
17
|
-
fromFile: string,
|
|
18
|
-
store: Store,
|
|
19
|
-
): Promise<ResolvedNavItem | ResolvedNavItem[]>;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import type { NavItem, RawNavItem, ResolvedNavItem } from '../../../shared/types.js';
|
|
2
|
-
import { Page, Store } from '../../store.js';
|
|
3
|
-
import { Watcher } from '../../utils/index.js';
|
|
4
|
-
export declare function sidebarsPlugin(watcher: Watcher, store: Store): void;
|
|
5
|
-
export declare class Sidebar {
|
|
6
|
-
absolutePath: string;
|
|
7
|
-
id: string;
|
|
8
|
-
store: Store;
|
|
9
|
-
hash: string;
|
|
10
|
-
dirname: string;
|
|
11
|
-
items: NavItem[];
|
|
12
|
-
constructor(absolutePath: string, items: RawNavItem[], id: string, store: Store);
|
|
13
|
-
resolve(): Promise<ResolvedNavItem[]>;
|
|
14
|
-
getDependentPages(): Set<Page>;
|
|
15
|
-
private collectDependentPages;
|
|
16
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import type { AllFilesType } from './types.js';
|
|
2
|
-
import { Watcher } from '../../utils/index.js';
|
|
3
|
-
import type { Store } from '../../store.js';
|
|
4
|
-
export declare function allFilesPaths(): AllFilesType;
|
|
5
|
-
export declare const existingVersionPages: Set<string>;
|
|
6
|
-
export declare function initVersionPlugin(
|
|
7
|
-
contentDir: string,
|
|
8
|
-
store: Store,
|
|
9
|
-
allFiles: AllFilesType,
|
|
10
|
-
): void;
|
|
11
|
-
export declare function versionsPlugin(
|
|
12
|
-
watcher: Watcher,
|
|
13
|
-
store: Store,
|
|
14
|
-
allFiles: AllFilesType,
|
|
15
|
-
): void;
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
export declare type Version = {
|
|
2
|
-
version: string;
|
|
3
|
-
label: string;
|
|
4
|
-
link: string;
|
|
5
|
-
default: boolean;
|
|
6
|
-
active: boolean;
|
|
7
|
-
};
|
|
8
|
-
export declare type VersionConfigItem = {
|
|
9
|
-
version: string;
|
|
10
|
-
name?: string;
|
|
11
|
-
};
|
|
12
|
-
export declare type VersionsConfigType = {
|
|
13
|
-
versions: VersionConfigItem[];
|
|
14
|
-
default?: string;
|
|
15
|
-
missingBehavior?: string;
|
|
16
|
-
};
|
|
17
|
-
export declare type AllFilesType = {
|
|
18
|
-
addPath: (path: string) => string[];
|
|
19
|
-
addPaths: (paths: string[]) => void;
|
|
20
|
-
removePath: (path: string) => void;
|
|
21
|
-
getAll: () => string[];
|
|
22
|
-
hasPath: (path: string) => void;
|
|
23
|
-
};
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { Version, VersionsConfigType } from './types.js';
|
|
2
|
-
export declare function getVersionConfigByBasePath(
|
|
3
|
-
versionsConfigMap: Map<string, VersionsConfigType>,
|
|
4
|
-
basePath: string,
|
|
5
|
-
): VersionsConfigType | null;
|
|
6
|
-
export declare function getPageVersions(
|
|
7
|
-
pathname: string,
|
|
8
|
-
currentVersion: string,
|
|
9
|
-
versionsConfig: VersionsConfigType,
|
|
10
|
-
): Version[];
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
import * as chokidar from 'chokidar';
|
|
3
|
-
import * as fs from 'fs';
|
|
4
|
-
declare type WatchCb = (event: 'add' | 'change' | 'unlink', path: string, stats?: fs.Stats) => void;
|
|
5
|
-
export declare class Watcher {
|
|
6
|
-
cwd: string;
|
|
7
|
-
private _readyPromise;
|
|
8
|
-
private listeners;
|
|
9
|
-
constructor(cwd: string);
|
|
10
|
-
watch(test: RegExp, cb: WatchCb): void;
|
|
11
|
-
emit(event: 'add' | 'change' | 'unlink', path: string, stats?: fs.Stats): void;
|
|
12
|
-
stop(): Promise<void>;
|
|
13
|
-
start(): void;
|
|
14
|
-
ready(): Promise<chokidar.FSWatcher>;
|
|
15
|
-
}
|
|
16
|
-
export {};
|