@appkit/dek-lib 0.31.0 → 0.33.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Background/Background.d.ts +1 -1
- package/dist/components/Background/Background.styled.d.ts +9 -0
- package/dist/components/Board/Board.d.ts +4 -4
- package/dist/components/Board/Board.styled.d.ts +8 -0
- package/dist/components/BoardProvider/BoardProvider.d.ts +7 -3
- package/dist/components/BoardScreen/BoardScreen.d.ts +6 -0
- package/dist/components/BoardScreen/BoardScreen.styled.d.ts +7 -0
- package/dist/components/BoardStylesProvider/BoardStylesProvider.d.ts +8 -0
- package/dist/components/BoardStylesProvider/BoardStylesProvider.styled.d.ts +7 -0
- package/dist/components/BoardStylesProvider/components/BoardPreviewOverlay/BoardPreviewOverlay.d.ts +2 -0
- package/dist/components/BoardStylesProvider/components/BoardPreviewOverlay/BoardPreviewOverlay.styled.d.ts +7 -0
- package/dist/components/BoardStylesProvider/components/BoardStyles.d.ts +6 -0
- package/dist/components/BoardWrapper/BoardWrapper.d.ts +6 -0
- package/dist/components/Command/Command.d.ts +5 -0
- package/dist/components/CommandGroup/CommandGroup.d.ts +4 -1
- package/dist/components/CommandGroup/CommandGroup.styled.d.ts +8 -2
- package/dist/components/Component/Component.d.ts +8 -0
- package/dist/components/PreviewBoardLoader/PreviewBoardLoader.d.ts +2 -0
- package/dist/components/PreviewBoardLoader/PreviewBoardLoader.styled.d.ts +7 -0
- package/dist/data/fetchUserData.d.ts +1 -1
- package/dist/data/fetchUserPlugins.d.ts +1 -1
- package/dist/data/getClient.d.ts +1 -1
- package/dist/data/types/gql.d.ts +2 -2
- package/dist/data/types/graphql.d.ts +23 -3
- package/dist/data/watchUser.d.ts +1 -1
- package/dist/index.d.ts +9 -1
- package/dist/index.es.js +57341 -57094
- package/dist/index.umd.js +58192 -57945
- package/dist/lib/contexts/PreviewConfigContext.d.ts +12 -0
- package/dist/lib/contexts/UserConfigContext.d.ts +4 -0
- package/dist/lib/data.d.ts +3 -2
- package/dist/lib/globals.d.ts +2 -1
- package/dist/lib/hooks/useAuthorization.d.ts +2 -0
- package/dist/lib/hooks/usePreviewContext.d.ts +2 -0
- package/dist/lib/hooks/useUserConfig.d.ts +1 -3
- package/dist/lib/hooks/useUserConfigLoader.d.ts +4 -0
- package/dist/lib/plugins.d.ts +1 -1
- package/package.json +1 -1
- package/dist/components/BoardProvider/BoardStyles.d.ts +0 -5
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare const Background: () =>
|
|
1
|
+
declare const Background: () => import("react/jsx-runtime").JSX.Element;
|
|
2
2
|
export default Background;
|
|
@@ -1,10 +1,19 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
type ContainerImageProps = {
|
|
3
3
|
$imageUrl: string;
|
|
4
|
+
$width?: number;
|
|
5
|
+
$height?: number;
|
|
4
6
|
};
|
|
5
7
|
export declare const ContainerImage: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ContainerImageProps>>;
|
|
6
8
|
type ContainerOverlayProps = {
|
|
7
9
|
$opacity: number;
|
|
10
|
+
$width?: number;
|
|
11
|
+
$height?: number;
|
|
8
12
|
};
|
|
9
13
|
export declare const ContainerOverlay: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ContainerOverlayProps>>;
|
|
14
|
+
type ContainerProps = {
|
|
15
|
+
$width?: number;
|
|
16
|
+
$height?: number;
|
|
17
|
+
};
|
|
18
|
+
export declare const Container: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ContainerProps>>;
|
|
10
19
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
type Props =
|
|
3
|
-
|
|
1
|
+
import { PreviewConfig } from '../../lib/contexts/PreviewConfigContext';
|
|
2
|
+
type Props = {
|
|
3
|
+
previewConfig?: PreviewConfig;
|
|
4
4
|
};
|
|
5
|
-
declare const Board: ({
|
|
5
|
+
declare const Board: ({ previewConfig }: Props) => import("react/jsx-runtime").JSX.Element | null;
|
|
6
6
|
export default Board;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
type ContainerProps = {
|
|
3
|
+
$width?: number;
|
|
4
|
+
$height?: number;
|
|
5
|
+
$zoom?: number;
|
|
6
|
+
};
|
|
7
|
+
export declare const Container: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ContainerProps>>;
|
|
8
|
+
export {};
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import { DekPluginFactory } from '@appkit/dek-plugin';
|
|
2
|
+
import { ReactNode } from 'react';
|
|
3
|
+
import { PreviewConfig } from '../../lib/contexts/PreviewConfigContext';
|
|
2
4
|
type Props = {
|
|
3
|
-
|
|
4
|
-
password: string;
|
|
5
|
+
authToken: string;
|
|
5
6
|
plugin?: DekPluginFactory;
|
|
6
7
|
pluginConfig?: any;
|
|
8
|
+
previewConfig?: PreviewConfig;
|
|
9
|
+
zoom?: number;
|
|
10
|
+
children?: ReactNode;
|
|
7
11
|
};
|
|
8
|
-
declare const BoardProvider: ({
|
|
12
|
+
declare const BoardProvider: ({ authToken, plugin, pluginConfig, zoom, children, }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
9
13
|
export default BoardProvider;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
type ContainerProps = {
|
|
3
|
+
$width?: number;
|
|
4
|
+
$height?: number;
|
|
5
|
+
};
|
|
6
|
+
export declare const Container: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ContainerProps>>;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
type Props = {
|
|
3
|
+
transitionDelay?: number;
|
|
4
|
+
zoom?: number;
|
|
5
|
+
children?: ReactNode;
|
|
6
|
+
};
|
|
7
|
+
declare const BoardStylesProvider: ({ zoom, transitionDelay, children, }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export default BoardStylesProvider;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
type ContainerProps = {
|
|
3
|
+
$width?: number;
|
|
4
|
+
$height?: number;
|
|
5
|
+
};
|
|
6
|
+
export declare const Container: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ContainerProps>>;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
type ContainerProps = {
|
|
3
|
+
$width?: number;
|
|
4
|
+
$height?: number;
|
|
5
|
+
};
|
|
6
|
+
export declare const Container: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ContainerProps>>;
|
|
7
|
+
export {};
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
+
import { CommandGroupAlignment } from './CommandGroup.styled';
|
|
1
2
|
type Props = {
|
|
2
3
|
groupKey: string;
|
|
4
|
+
title?: string;
|
|
5
|
+
align?: CommandGroupAlignment;
|
|
3
6
|
};
|
|
4
|
-
declare const CommandGroup: ({ groupKey }: Props) => import("react/jsx-runtime").JSX.Element | null;
|
|
7
|
+
declare const CommandGroup: ({ groupKey, title, align }: Props) => import("react/jsx-runtime").JSX.Element | null;
|
|
5
8
|
export default CommandGroup;
|
|
@@ -1,3 +1,9 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
export
|
|
3
|
-
|
|
2
|
+
export type CommandGroupAlignment = 'left' | 'right';
|
|
3
|
+
type ContainerProps = {
|
|
4
|
+
$align: CommandGroupAlignment;
|
|
5
|
+
};
|
|
6
|
+
export declare const Container: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("../../../../ui/dist/components/View/View").ViewProps, ContainerProps>> & Omit<({ label, direction, collapse, valign, halign, vscroll, hscroll, padding, paddingVert, paddingHorz, paddingRight, paddingLeft, paddingTop, paddingBottom, width, height, fixed, backColor, backColorHover, borderRadius, wrap, gap, gapRow, gapCol, className, onClick, style, children, }: import("../../../../ui/dist/components/View/View").ViewProps) => import("react/jsx-runtime").JSX.Element, keyof import("react").Component<any, {}, any>>;
|
|
7
|
+
export declare const Group: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("../../../../ui/dist/components/View/View").ViewProps, ContainerProps>> & Omit<({ label, direction, collapse, valign, halign, vscroll, hscroll, padding, paddingVert, paddingHorz, paddingRight, paddingLeft, paddingTop, paddingBottom, width, height, fixed, backColor, backColorHover, borderRadius, wrap, gap, gapRow, gapCol, className, onClick, style, children, }: import("../../../../ui/dist/components/View/View").ViewProps) => import("react/jsx-runtime").JSX.Element, keyof import("react").Component<any, {}, any>>;
|
|
8
|
+
export declare const CommandItem: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ContainerProps>>;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ComponentProp } from '../../lib/utils/parsePropsForComponent';
|
|
2
|
+
type Props = {
|
|
3
|
+
integrationKey: string;
|
|
4
|
+
componentKey: string;
|
|
5
|
+
componentProps?: ComponentProp[];
|
|
6
|
+
};
|
|
7
|
+
declare const Component: ({ integrationKey, componentKey }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export default Component;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
type ContainerProps = {
|
|
3
|
+
$width?: number;
|
|
4
|
+
$height?: number;
|
|
5
|
+
};
|
|
6
|
+
export declare const Container: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ContainerProps>>;
|
|
7
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { UserDataQuery } from './types/graphql';
|
|
2
2
|
export type UserData = UserDataQuery['currentUser'];
|
|
3
|
-
declare function fetchUserData(
|
|
3
|
+
declare function fetchUserData(authToken: string): Promise<UserData>;
|
|
4
4
|
export default fetchUserData;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ApolloQueryResult } from '@apollo/client';
|
|
2
2
|
import { UserPluginsAndIntegrationsQuery } from './types/graphql';
|
|
3
3
|
export type FetchUserPluginsResult = ApolloQueryResult<UserPluginsAndIntegrationsQuery>['data']['currentUser'];
|
|
4
|
-
declare function fetchUserPlugins(
|
|
4
|
+
declare function fetchUserPlugins(authToken: string): Promise<FetchUserPluginsResult>;
|
|
5
5
|
export default fetchUserPlugins;
|
package/dist/data/getClient.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { ApolloClient, NormalizedCacheObject } from '@apollo/client';
|
|
2
|
-
declare function getClient(
|
|
2
|
+
declare function getClient(authToken: string): Promise<ApolloClient<NormalizedCacheObject>>;
|
|
3
3
|
export default getClient;
|
package/dist/data/types/gql.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/
|
|
|
11
11
|
* Therefore it is highly recommended to use the babel or swc plugin for production.
|
|
12
12
|
*/
|
|
13
13
|
declare const documents: {
|
|
14
|
-
"\n query userData {\n currentUser {\n id\n name\n email\n location\n avatar\n boards {\n id\n title\n key\n layout\n base {\n integration\n key\n }\n zones {\n key\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n commandGroups {\n title\n key\n commands {\n title\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n }\n }\n": DocumentNode<types.UserDataQuery, types.Exact<{
|
|
14
|
+
"\n query userData {\n currentUser {\n id\n name\n email\n location\n avatar\n boards {\n id\n title\n key\n layout\n base {\n integration\n key\n }\n zones {\n key\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n commandGroups {\n title\n key\n commands {\n title\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n commands {\n title\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n }\n": DocumentNode<types.UserDataQuery, types.Exact<{
|
|
15
15
|
[key: string]: never;
|
|
16
16
|
}>>;
|
|
17
17
|
"\n query userPluginsAndIntegrations {\n currentUser {\n plugins {\n name\n code\n version\n }\n integrations {\n key\n pluginName\n pluginVersion\n pluginConfig {\n key\n value\n }\n }\n }\n }\n": DocumentNode<types.UserPluginsAndIntegrationsQuery, types.Exact<{
|
|
@@ -37,7 +37,7 @@ export declare function gql(source: string): unknown;
|
|
|
37
37
|
/**
|
|
38
38
|
* The gql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
|
|
39
39
|
*/
|
|
40
|
-
export declare function gql(source: "\n query userData {\n currentUser {\n id\n name\n email\n location\n avatar\n boards {\n id\n title\n key\n layout\n base {\n integration\n key\n }\n zones {\n key\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n commandGroups {\n title\n key\n commands {\n title\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n }\n }\n"): (typeof documents)["\n query userData {\n currentUser {\n id\n name\n email\n location\n avatar\n boards {\n id\n title\n key\n layout\n base {\n integration\n key\n }\n zones {\n key\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n commandGroups {\n title\n key\n commands {\n title\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n }\n }\n"];
|
|
40
|
+
export declare function gql(source: "\n query userData {\n currentUser {\n id\n name\n email\n location\n avatar\n boards {\n id\n title\n key\n layout\n base {\n integration\n key\n }\n zones {\n key\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n commandGroups {\n title\n key\n commands {\n title\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n commands {\n title\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n }\n"): (typeof documents)["\n query userData {\n currentUser {\n id\n name\n email\n location\n avatar\n boards {\n id\n title\n key\n layout\n base {\n integration\n key\n }\n zones {\n key\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n commandGroups {\n title\n key\n commands {\n title\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n commands {\n title\n integrationKey\n componentKey\n props {\n key\n value\n }\n containerProps {\n key\n value\n }\n }\n }\n }\n"];
|
|
41
41
|
/**
|
|
42
42
|
* The gql function is used to parse GraphQL queries into a document that can be used by GraphQL clients.
|
|
43
43
|
*/
|
|
@@ -451,6 +451,7 @@ export type Integration = {
|
|
|
451
451
|
createdAt: Scalars['DateTime']['output'];
|
|
452
452
|
id: Scalars['ID']['output'];
|
|
453
453
|
key: Scalars['String']['output'];
|
|
454
|
+
plugin: Plugin;
|
|
454
455
|
pluginConfig: Array<PluginConfig>;
|
|
455
456
|
pluginName: Scalars['String']['output'];
|
|
456
457
|
pluginVersion?: Maybe<Scalars['String']['output']>;
|
|
@@ -722,14 +723,17 @@ export type PluginConfigInput = {
|
|
|
722
723
|
};
|
|
723
724
|
export type PluginsQueryInput = {
|
|
724
725
|
archived?: InputMaybe<YesNoAnyInput>;
|
|
725
|
-
author?: InputMaybe<
|
|
726
|
+
author?: InputMaybe<Scalars['String']['input']>;
|
|
727
|
+
authorMatch?: InputMaybe<RegexExpressionInput>;
|
|
726
728
|
createdAt?: InputMaybe<DateRangeInput>;
|
|
727
|
-
name?: InputMaybe<
|
|
729
|
+
name?: InputMaybe<Scalars['String']['input']>;
|
|
730
|
+
nameMatch?: InputMaybe<RegexExpressionInput>;
|
|
728
731
|
private?: InputMaybe<YesNoAnyInput>;
|
|
729
732
|
publishedAt?: InputMaybe<DateRangeInput>;
|
|
730
733
|
updatedAt?: InputMaybe<DateRangeInput>;
|
|
731
734
|
userIds?: InputMaybe<Array<InputMaybe<Scalars['ID']['input']>>>;
|
|
732
|
-
version?: InputMaybe<
|
|
735
|
+
version?: InputMaybe<Scalars['String']['input']>;
|
|
736
|
+
versionMatch?: InputMaybe<RegexExpressionInput>;
|
|
733
737
|
};
|
|
734
738
|
export type PluginsResult = {
|
|
735
739
|
__typename?: 'PluginsResult';
|
|
@@ -1251,6 +1255,22 @@ export type UserDataQuery = {
|
|
|
1251
1255
|
}>;
|
|
1252
1256
|
}>;
|
|
1253
1257
|
}>;
|
|
1258
|
+
commands: Array<{
|
|
1259
|
+
__typename?: 'Command';
|
|
1260
|
+
title: string;
|
|
1261
|
+
integrationKey: string;
|
|
1262
|
+
componentKey: string;
|
|
1263
|
+
props: Array<{
|
|
1264
|
+
__typename?: 'CommandProp';
|
|
1265
|
+
key: string;
|
|
1266
|
+
value: string;
|
|
1267
|
+
}>;
|
|
1268
|
+
containerProps: Array<{
|
|
1269
|
+
__typename?: 'CommandProp';
|
|
1270
|
+
key: string;
|
|
1271
|
+
value: string;
|
|
1272
|
+
}>;
|
|
1273
|
+
}>;
|
|
1254
1274
|
};
|
|
1255
1275
|
};
|
|
1256
1276
|
export type UserPluginsAndIntegrationsQueryVariables = Exact<{
|
package/dist/data/watchUser.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
declare function watchUser(
|
|
1
|
+
declare function watchUser(authToken: string, cb: () => void): Promise<void>;
|
|
2
2
|
export default watchUser;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,15 @@
|
|
|
1
1
|
export { default as Board } from './components/Board/Board';
|
|
2
2
|
export { default as BoardProvider } from './components/BoardProvider/BoardProvider';
|
|
3
|
+
export { default as Command } from './components/Command/Command';
|
|
3
4
|
export { default as CommandGroup } from './components/CommandGroup/CommandGroup';
|
|
4
|
-
export { default as
|
|
5
|
+
export { default as Component } from './components/Component/Component';
|
|
5
6
|
export { default as Router } from './components/Router/Router';
|
|
7
|
+
export { default as RouteResolver } from './components/RouteResolver/RouteResolver';
|
|
6
8
|
export { default as Zone } from './components/Zone/Zone';
|
|
9
|
+
export type { PreviewConfig } from './lib/contexts/PreviewConfigContext';
|
|
10
|
+
export { authorize } from './lib/data';
|
|
11
|
+
export { default as useAuthorization } from './lib/hooks/useAuthorization';
|
|
7
12
|
export { default as loadCustomDekPlugin } from './lib/utils/loadCustomPlugin';
|
|
13
|
+
export { default as useUserConfigLoader } from './lib/hooks/useUserConfigLoader';
|
|
14
|
+
export { default as getPluginApi } from './lib/utils/getPluginApi';
|
|
15
|
+
export { default as parsePropsForComponent } from './lib/utils/parsePropsForComponent';
|