rotion 0.0.4 → 0.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/exporter/blocks.js +4 -1
- package/dist/exporter/blocks.js.map +1 -1
- package/dist/exporter/breadcrumbs.d.ts +2 -7
- package/dist/exporter/breadcrumbs.js +91 -82
- package/dist/exporter/breadcrumbs.js.map +1 -1
- package/dist/exporter/types.d.ts +9 -1
- package/dist/ui/cjs/index.js +28 -12
- package/dist/ui/cjs/index.js.map +1 -1
- package/dist/ui/cjs/types/exporter/breadcrumbs.d.ts +2 -7
- package/dist/ui/cjs/types/exporter/types.d.ts +9 -1
- package/dist/ui/cjs/types/ui/components/Page/BreadcrumbBlock/BreadcrumbBlock.d.ts +1 -1
- package/dist/ui/cjs/types/ui/components/Page/BreadcrumbBlock/BreadcrumbBlock.types.d.ts +16 -2
- package/dist/ui/cjs/types/ui/components/Page/Page.d.ts +1 -1
- package/dist/ui/cjs/types/ui/components/Page/Page.types.d.ts +1 -0
- package/dist/ui/cjs/types/ui/components/Page/PageHandler.d.ts +1 -1
- package/dist/ui/cjs/types/ui/components/Page/PageHandler.types.d.ts +1 -0
- package/dist/ui/esm/index.js +28 -12
- package/dist/ui/esm/index.js.map +1 -1
- package/dist/ui/esm/types/exporter/breadcrumbs.d.ts +2 -7
- package/dist/ui/esm/types/exporter/types.d.ts +9 -1
- package/dist/ui/esm/types/ui/components/Page/BreadcrumbBlock/BreadcrumbBlock.d.ts +1 -1
- package/dist/ui/esm/types/ui/components/Page/BreadcrumbBlock/BreadcrumbBlock.types.d.ts +16 -2
- package/dist/ui/esm/types/ui/components/Page/Page.d.ts +1 -1
- package/dist/ui/esm/types/ui/components/Page/Page.types.d.ts +1 -0
- package/dist/ui/esm/types/ui/components/Page/PageHandler.d.ts +1 -1
- package/dist/ui/esm/types/ui/components/Page/PageHandler.types.d.ts +1 -0
- package/dist/ui/styles/page.css +26 -0
- package/dist/ui/types.d.ts +17 -5
- package/dist/ui/umd/index.js +28 -12
- package/dist/ui/umd/index.js.map +1 -1
- package/dist/ui/umd/types/exporter/breadcrumbs.d.ts +2 -7
- package/dist/ui/umd/types/exporter/types.d.ts +9 -1
- package/dist/ui/umd/types/ui/components/Page/BreadcrumbBlock/BreadcrumbBlock.d.ts +1 -1
- package/dist/ui/umd/types/ui/components/Page/BreadcrumbBlock/BreadcrumbBlock.types.d.ts +16 -2
- package/dist/ui/umd/types/ui/components/Page/Page.d.ts +1 -1
- package/dist/ui/umd/types/ui/components/Page/Page.types.d.ts +1 -0
- package/dist/ui/umd/types/ui/components/Page/PageHandler.d.ts +1 -1
- package/dist/ui/umd/types/ui/components/Page/PageHandler.types.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1,12 +1,7 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { Breadcrumb } from './types.js';
|
|
2
2
|
export interface FetchBreadcrumbsProps {
|
|
3
3
|
type: 'page_id' | 'database_id' | 'block_id' | 'workspace';
|
|
4
4
|
id: string;
|
|
5
5
|
limit?: number;
|
|
6
6
|
}
|
|
7
|
-
export type
|
|
8
|
-
export interface Breadcrumbs {
|
|
9
|
-
name: string;
|
|
10
|
-
icon: BreadcrumbsIcon;
|
|
11
|
-
}
|
|
12
|
-
export declare const FetchBreadcrumbs: ({ type, id, limit }: FetchBreadcrumbsProps) => Promise<Breadcrumbs[]>;
|
|
7
|
+
export declare const FetchBreadcrumbs: ({ type, id, limit }: FetchBreadcrumbsProps) => Promise<Breadcrumb[]>;
|
|
@@ -208,7 +208,15 @@ export type ParagraphBlockObjectResponseEx = ParagraphBlockObjectResponse & {
|
|
|
208
208
|
color: SelectColor;
|
|
209
209
|
};
|
|
210
210
|
};
|
|
211
|
-
export type
|
|
211
|
+
export type Breadcrumb = {
|
|
212
|
+
id: string;
|
|
213
|
+
name: string;
|
|
214
|
+
icon: MentionIcon;
|
|
215
|
+
};
|
|
216
|
+
export type BreadcrumbBlockObjectResponseEx = BreadcrumbBlockObjectResponse & {
|
|
217
|
+
list: Breadcrumb[];
|
|
218
|
+
};
|
|
219
|
+
export type BlockObjectResponse = ParagraphBlockObjectResponseEx | Heading1BlockObjectResponse | Heading2BlockObjectResponse | Heading3BlockObjectResponse | BulletedListItemBlockObjectResponseEx | NumberedListItemBlockObjectResponseEx | QuoteBlockObjectResponse | ToDoBlockObjectResponse | ToggleBlockObjectResponseEx | TemplateBlockObjectResponse | SyncedBlockBlockObjectResponse | ChildPageBlockObjectResponseEx | ChildDatabaseBlockObjectResponseEx | EquationBlockObjectResponse | CodeBlockObjectResponse | CalloutBlockObjectResponseEx | DividerBlockObjectResponse | BreadcrumbBlockObjectResponseEx | TableOfContentsBlockObjectResponse | ColumnListBlockObjectResponseEx | ColumnBlockObjectResponse | LinkToPageBlockObjectResponse | TableBlockObjectResponseEx | TableRowBlockObjectResponse | EmbedBlockObjectResponseEx | BookmarkBlockObjectResponseEx | ImageBlockObjectResponseEx | VideoBlockObjectResponseEx | PdfBlockObjectResponse | FileBlockObjectResponse | AudioBlockObjectResponse | LinkPreviewBlockObjectResponse | UnsupportedBlockObjectResponse;
|
|
212
220
|
export type ListBlockChildrenResponseEx = ListBlockChildrenResponse & {
|
|
213
221
|
results: Array<BlockObjectResponse>;
|
|
214
222
|
children?: ListBlockChildrenResponse;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { BreadcrumbBlockProps } from './BreadcrumbBlock.types';
|
|
3
|
-
declare const BreadcrumbBlock: ({ block }: BreadcrumbBlockProps) => React.JSX.Element;
|
|
3
|
+
declare const BreadcrumbBlock: ({ block, link, hrefs, query }: BreadcrumbBlockProps) => React.JSX.Element;
|
|
4
4
|
export default BreadcrumbBlock;
|
|
@@ -1,4 +1,18 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import type { ReactNode } from 'react';
|
|
3
|
+
import type { ParsedUrlQueryInput } from 'node:querystring';
|
|
4
|
+
import type { Link } from '../../types';
|
|
5
|
+
import type { Breadcrumb, BreadcrumbBlockObjectResponseEx } from '../../../../exporter';
|
|
6
|
+
export interface BreadcrumbLinkProps {
|
|
7
|
+
breadcrumb: Breadcrumb;
|
|
8
|
+
link?: Link;
|
|
9
|
+
href?: string;
|
|
10
|
+
query?: ParsedUrlQueryInput;
|
|
11
|
+
children?: ReactNode;
|
|
12
|
+
}
|
|
2
13
|
export interface BreadcrumbBlockProps {
|
|
3
|
-
block:
|
|
14
|
+
block: BreadcrumbBlockObjectResponseEx;
|
|
15
|
+
link?: Link;
|
|
16
|
+
hrefs?: string[];
|
|
17
|
+
query?: ParsedUrlQueryInput;
|
|
4
18
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { PageProps } from './Page.types';
|
|
3
|
-
export declare const Page: ({ blocks, href, link, query, modules }: PageProps) => React.JSX.Element;
|
|
3
|
+
export declare const Page: ({ blocks, href, link, query, modules, breadcrumb_hrefs }: PageProps) => React.JSX.Element;
|
|
4
4
|
export default Page;
|
|
@@ -11,5 +11,5 @@ export declare const blockType: {
|
|
|
11
11
|
code: string;
|
|
12
12
|
quote: string;
|
|
13
13
|
};
|
|
14
|
-
export declare const PageHandler: ({ block, href, link, query, modules }: HandlerProps) => React.JSX.Element;
|
|
14
|
+
export declare const PageHandler: ({ block, href, link, query, modules, breadcrumb_hrefs }: HandlerProps) => React.JSX.Element;
|
|
15
15
|
export default PageHandler;
|