@fewbox/den 0.0.86 → 0.0.88

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fewbox/den",
3
- "version": "0.0.86",
3
+ "version": "0.0.88",
4
4
  "main": "index.js",
5
5
  "types": "index-app.d.ts",
6
6
  "repository": "https://github.com/FewBox/fewbox-den.git",
@@ -0,0 +1,9 @@
1
+ import { IChildrenProps } from '../../Engine/Base';
2
+ export interface IGoogleProps extends IChildrenProps {
3
+ clientId: string;
4
+ callback: (accessToken: string) => void;
5
+ enableGoogle: () => void;
6
+ disableGoogle: () => void;
7
+ }
8
+ declare const Google: (props: IGoogleProps) => JSX.Element;
9
+ export default Google;
@@ -1,14 +1,16 @@
1
- import { IChildrenProps } from '../../Engine/Base';
2
- export interface IGoogleAccount {
3
- token: string;
4
- id: string;
5
- name: string;
6
- avatarUrl: string;
1
+ export declare enum GoogleSigninCategory {
2
+ Prompt = "prompt",
3
+ Popup = "popup",
4
+ Redirect = "redirect"
7
5
  }
8
- export interface IGoogleSigninProps extends IChildrenProps {
9
- showStopWorkingMessage: () => void;
10
- showErrorMessage: (error: any) => void;
11
- initGoogleAccount: (googleAccount: IGoogleAccount) => void;
6
+ export interface IGoogleSigninProps {
7
+ clientId: string;
8
+ category: GoogleSigninCategory;
9
+ redirectUrl?: string;
10
+ gsiButtonConfiguration?: google.accounts.id.GsiButtonConfiguration;
11
+ callback: (credential: string) => void;
12
+ enableGoogle: () => void;
13
+ disableGoogle: () => void;
12
14
  }
13
15
  declare const GoogleSignin: (props: IGoogleSigninProps) => JSX.Element;
14
16
  export default GoogleSignin;
@@ -5,7 +5,12 @@ export type TLength = (string & {}) | 0;
5
5
  export interface IChildrenProps {
6
6
  children?: React.ReactNode | undefined;
7
7
  }
8
+ export declare enum RootCategory {
9
+ Div = "div",
10
+ Span = "span"
11
+ }
8
12
  export interface IViewProps {
13
+ rootCategory?: RootCategory;
9
14
  className?: string;
10
15
  style?: React.CSSProperties;
11
16
  size?: FullSizeType;
@@ -1,3 +1,4 @@
1
+ export { RootCategory } from './Engine/Base';
1
2
  export { default as Debug } from './Debug';
2
3
  export { BreakpointType } from './Layout';
3
4
  export { default as VZone, ZoneCategory } from './View/VZone';
@@ -109,11 +110,6 @@ export { default as VUrl } from './View/VInput/VUrl';
109
110
  export { default as VWeek } from './View/VInput/VWeek';
110
111
  export { default as VHidden } from './View/VInput/VHidden';
111
112
  export { default as VGroup } from './View/VInput/VGroup';
112
- export { default as VDesigner } from './View/VDesigner';
113
- export { DesignerNodeType, DesignerConnectionPointType } from './View/VDesigner/VDesignerNode';
114
- export { IVDesignerElementProps } from './View/VDesigner/VDesignerElement';
115
- export { IVDesignerConnectionProps } from './View/VDesigner/VDesignerConnection';
116
- export { IVDesignerGroupProps } from './View/VDesigner/VDesignerGroup';
117
113
  export { default as VChromeExtensionValidator, ExtensionStatus } from './View/VChromeExtensionValidator';
118
114
  export { default as VBoundary } from './View/VBoundary';
119
115
  export { default as VTooltip, TooltipCategory } from './View/VTooltip';
@@ -127,9 +123,9 @@ export { default as VSwitch } from './View/VSwitch';
127
123
  export { default as VFrame } from './View/VFrame';
128
124
  export { default as VPaypal } from './View/VPaypal';
129
125
  export { default as GA4 } from './Analyze/GA4';
130
- export { default as GAPI } from './Api/GAPI';
126
+ export { default as Google } from './Api/Google';
131
127
  export { default as FigmaSignin } from './Auth/FigmaSignin';
132
- export { default as GoogleSignin, IGoogleAccount } from './Auth/GoogleSignin';
128
+ export { default as GoogleSignin, GoogleSigninCategory } from './Auth/GoogleSignin';
133
129
  export { default as WeComSignin } from './Auth/WeComSignin';
134
130
  export { IUserProfile, parseJWT } from './Auth/util';
135
131
  export { ga4Scope, ga4Event, ga4Init, ga4Pageview, ga4SetFieldsObject, IGAEvent, IGA4Options, ICustomGA4Options, IGAOptions, ICustomGAOptions, IGTagOptions, ICustomGTagOptions, IGFieldsObject, GAEventTransportType } from './Analyze/util';
@@ -1,7 +0,0 @@
1
- export interface IGAPIProps {
2
- clientId: string;
3
- enableGoogle: () => void;
4
- disableGoogle: () => void;
5
- }
6
- declare const GAPI: (props: IGAPIProps) => JSX.Element;
7
- export default GAPI;
@@ -1,10 +0,0 @@
1
- import VDesignerNode, { DesignerConnectionPointType, IVDesignerNodePorps } from "../VDesignerNode";
2
- export interface IVDesignerConnectionProps extends IVDesignerNodePorps {
3
- upstream: string;
4
- downstream: string;
5
- isAnimated?: boolean;
6
- upstreamPointType?: DesignerConnectionPointType;
7
- downstreamPointType?: DesignerConnectionPointType;
8
- }
9
- export default class VDesignerConnection extends VDesignerNode<IVDesignerConnectionProps> {
10
- }
@@ -1,11 +0,0 @@
1
- import VDesignerNode, { DesignerConnectionPointType, IVDesignerNodePorps } from "../VDesignerNode";
2
- export interface IVDesignerElementProps extends IVDesignerNodePorps {
3
- connectionPointType?: DesignerConnectionPointType;
4
- x: number;
5
- y: number;
6
- width: number;
7
- content: JSX.Element | string;
8
- isGlobalStyle?: boolean;
9
- }
10
- export default class VDesignerElement extends VDesignerNode<IVDesignerElementProps> {
11
- }
@@ -1,10 +0,0 @@
1
- import VDesignerNode, { DesignerConnectionPointType, IVDesignerNodePorps } from "../VDesignerNode";
2
- import { IVDesignerElementProps } from "../VDesignerElement";
3
- export interface IVDesignerGroupProps extends IVDesignerNodePorps {
4
- connectionPointType?: DesignerConnectionPointType;
5
- x: number;
6
- y: number;
7
- children: (IVDesignerElementProps | IVDesignerGroupProps)[];
8
- }
9
- export default class VDesignerGroup extends VDesignerNode<IVDesignerGroupProps> {
10
- }
@@ -1,68 +0,0 @@
1
- import Konva from "konva";
2
- import { IVDesignerGroupProps } from "../VDesignerGroup";
3
- import { IVDesignerElementProps } from "../VDesignerElement";
4
- import { IVDesignerConnectionProps } from "../VDesignerConnection";
5
- export interface ClientReact {
6
- width: number;
7
- height: number;
8
- x: number;
9
- y: number;
10
- }
11
- export interface PositionDictionary {
12
- [id: number]: {
13
- x: number;
14
- y: number;
15
- };
16
- }
17
- export declare enum DesignerNodeType {
18
- Element = "element",
19
- Group = "group",
20
- Connection = "connection"
21
- }
22
- export declare enum DesignerConnectionPointType {
23
- None = 0,
24
- Top = 2,
25
- Right = 4,
26
- Bottom = 8,
27
- Left = 16,
28
- LeftTop = 32,
29
- RightTop = 64,
30
- LeftBottom = 128,
31
- RightBottom = 256,
32
- Center = 512,
33
- All = 1022
34
- }
35
- export declare const getConnectionPointType: (name: string) => DesignerConnectionPointType.Top | DesignerConnectionPointType.Right | DesignerConnectionPointType.Bottom | DesignerConnectionPointType.Left | DesignerConnectionPointType.LeftTop | DesignerConnectionPointType.RightTop | DesignerConnectionPointType.LeftBottom | DesignerConnectionPointType.RightBottom | DesignerConnectionPointType.Center;
36
- export interface IVDesignerNodePorps {
37
- id: string;
38
- type: DesignerNodeType;
39
- zIndex?: number;
40
- onClick?: (sender: Konva.Group) => void;
41
- }
42
- export interface IVDesignerNode<P extends IVDesignerNodePorps> {
43
- props: P;
44
- draw: () => void;
45
- }
46
- export default class VDesignerNode<P extends IVDesignerGroupProps | IVDesignerElementProps | IVDesignerConnectionProps> implements IVDesignerNode<P> {
47
- private rootContainer;
48
- private layer;
49
- props: P;
50
- private startConnectPointCallback?;
51
- private selectedColor;
52
- private normalColor;
53
- private connectionColor;
54
- constructor(layer: Konva.Layer, props: P, selectedColor: string, normalColor: string, connectionColor: string, startConnectPointCallback?: (id: string, pointType: DesignerConnectionPointType) => void);
55
- private buildElement;
56
- private buildAnchor;
57
- private buildControlAnchor;
58
- private buildAnimated;
59
- private getPosition;
60
- private getAngle;
61
- private getAutoPosition;
62
- private buildConnection;
63
- private bindPointEvent;
64
- private buildConnectionPoints;
65
- private getPointPositions;
66
- private drawGroup;
67
- draw(): void;
68
- }
@@ -1,35 +0,0 @@
1
- import { IBaseProps } from '../../Engine/Base';
2
- import { IVDesignerGroupProps } from './VDesignerGroup';
3
- import { IVDesignerElementProps } from './VDesignerElement';
4
- import { Property } from 'csstype';
5
- import { IVDesignerConnectionProps } from './VDesignerConnection';
6
- import { IVTreeNode } from '../VTree';
7
- type TLength = (string & {}) | 0;
8
- export interface StructureNode extends IVTreeNode {
9
- }
10
- export interface IVDesignerProps extends IBaseProps {
11
- downloadIcon?: JSX.Element;
12
- clearIcon?: JSX.Element;
13
- debugIcon?: JSX.Element;
14
- leftIcon?: JSX.Element;
15
- rightIcon?: JSX.Element;
16
- closeIcon?: JSX.Element;
17
- deleteIcon?: JSX.Element;
18
- toolboxCaption: JSX.Element | string;
19
- contextMenuCaption: JSX.Element | string;
20
- deleteCaption: JSX.Element | string;
21
- selectedColor: string;
22
- normalColor: string;
23
- connectionColor: string;
24
- containerName?: string;
25
- nodeItems?: (IVDesignerElementProps | IVDesignerGroupProps | IVDesignerConnectionProps)[];
26
- isAutoLayout?: boolean;
27
- autosizeHeight: Property.Height<TLength>;
28
- toolbox?: JSX.Element;
29
- }
30
- export interface IDesignerStates {
31
- isToolboxExtend: boolean;
32
- debugNode?: StructureNode;
33
- }
34
- declare const VDesigner: (props: IVDesignerProps) => JSX.Element;
35
- export default VDesigner;
@@ -1,6 +0,0 @@
1
- import { ImageProps } from "next/image";
2
- export interface IVBackgroundProps extends Omit<ImageProps, 'alt'> {
3
- alt: string;
4
- }
5
- declare const VBackground: (props: IVBackgroundProps) => JSX.Element;
6
- export default VBackground;
@@ -1,10 +0,0 @@
1
- import { IBaseInputProps } from "../..";
2
- export interface IVBase64FileProps extends IBaseInputProps {
3
- fileIcon?: JSX.Element;
4
- base64Image: string;
5
- }
6
- export interface IVBase64FileStates {
7
- base64Image: string;
8
- }
9
- declare const VBase64File: (props: IVBase64FileProps) => JSX.Element;
10
- export default VBase64File;
@@ -1,6 +0,0 @@
1
- import { IChildrenProps } from '../../../Engine/Base';
2
- export interface IVLinkProps extends IChildrenProps {
3
- to: string;
4
- }
5
- declare const VLink: (props: IVLinkProps) => JSX.Element;
6
- export default VLink;