cmcts-c-agent-embedding 1.0.64-vib → 1.0.66-vib
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/.env.example +34 -34
- package/.eslintrc.cjs +14 -14
- package/.prettierignore +3 -3
- package/.prettierrc +8 -8
- package/base.json +21 -21
- package/dist/_basePickBy-1057a1b4.js +1 -0
- package/dist/_basePickBy-cbf78fb3.js +1 -0
- package/dist/_baseUniq-38ea2195.js +1 -0
- package/dist/_baseUniq-52a47b7b.js +1 -0
- package/dist/arc-6b847bc0.js +1 -0
- package/dist/arc-8928af28.js +1 -0
- package/dist/architecture-O4VJ6CD3-42323263.js +1 -0
- package/dist/architecture-O4VJ6CD3-b506967f.js +1 -0
- package/dist/architectureDiagram-VXUJARFQ-1bd867b6.js +1 -0
- package/dist/architectureDiagram-VXUJARFQ-2b851c59.js +1 -0
- package/dist/blockDiagram-VD42YOAC-5cea96b0.js +1 -0
- package/dist/blockDiagram-VD42YOAC-a909b757.js +1 -0
- package/dist/c4Diagram-YG6GDRKO-24d24519.js +1 -0
- package/dist/c4Diagram-YG6GDRKO-54783ab3.js +1 -0
- package/dist/channel-2af69aa2.js +1 -0
- package/dist/channel-f240e622.js +1 -0
- package/dist/chunk-4BX2VUAB-7747ae72.js +1 -0
- package/dist/chunk-4BX2VUAB-d05d937e.js +1 -0
- package/dist/chunk-55IACEB6-5a7b1be3.js +1 -0
- package/dist/chunk-55IACEB6-78729976.js +1 -0
- package/dist/chunk-B4BG7PRW-a97e69ff.js +1 -0
- package/dist/chunk-B4BG7PRW-cbf800c4.js +1 -0
- package/dist/chunk-DI55MBZ5-5dc4f926.js +1 -0
- package/dist/chunk-DI55MBZ5-95d71f6f.js +1 -0
- package/dist/chunk-FMBD7UC4-2c653fda.js +1 -0
- package/dist/chunk-FMBD7UC4-d75ed695.js +1 -0
- package/dist/chunk-QN33PNHL-0bf10733.js +1 -0
- package/dist/chunk-QN33PNHL-b00655c9.js +1 -0
- package/dist/chunk-QZHKN3VN-a979a9fe.js +1 -0
- package/dist/chunk-QZHKN3VN-d57979be.js +1 -0
- package/dist/chunk-TZMSLE5B-6755c559.js +1 -0
- package/dist/chunk-TZMSLE5B-ed6d6d7e.js +1 -0
- package/dist/classDiagram-2ON5EDUG-8b5a2a93.js +1 -0
- package/dist/classDiagram-2ON5EDUG-fa9ecfbb.js +1 -0
- package/dist/classDiagram-v2-WZHVMYZB-8b5a2a93.js +1 -0
- package/dist/classDiagram-v2-WZHVMYZB-fa9ecfbb.js +1 -0
- package/dist/clone-6cd174cf.js +1 -0
- package/dist/clone-8494eb3f.js +1 -0
- package/dist/components/Bot.d.ts.map +1 -1
- package/dist/components/bubbles/BotBubble.d.ts.map +1 -1
- package/dist/components/buttons/ConsultationButton.d.ts +14 -0
- package/dist/components/buttons/ConsultationButton.d.ts.map +1 -0
- package/dist/components/buttons/CopyMessageButton.d.ts +10 -0
- package/dist/components/buttons/CopyMessageButton.d.ts.map +1 -0
- package/dist/components/buttons/EditMessageButton.d.ts +8 -0
- package/dist/components/buttons/EditMessageButton.d.ts.map +1 -0
- package/dist/components/buttons/PopupToast.d.ts +7 -0
- package/dist/components/buttons/PopupToast.d.ts.map +1 -0
- package/dist/components/buttons/ZaloChatButton.d.ts +16 -0
- package/dist/components/buttons/ZaloChatButton.d.ts.map +1 -0
- package/dist/components/demo/ZaloChatDemo.d.ts +2 -0
- package/dist/components/demo/ZaloChatDemo.d.ts.map +1 -0
- package/dist/components/dialogs/EditMessageDialog.d.ts +9 -0
- package/dist/components/dialogs/EditMessageDialog.d.ts.map +1 -0
- package/dist/components/icons/CheckIcon.d.ts +3 -0
- package/dist/components/icons/CheckIcon.d.ts.map +1 -0
- package/dist/components/icons/CopyIcon.d.ts +5 -0
- package/dist/components/icons/CopyIcon.d.ts.map +1 -0
- package/dist/components/icons/EditIcon.d.ts +5 -0
- package/dist/components/icons/EditIcon.d.ts.map +1 -0
- package/dist/components/icons/SupportIcon.d.ts +3 -0
- package/dist/components/icons/SupportIcon.d.ts.map +1 -0
- package/dist/components/inputs/textInput/components/TextInput.d.ts +9 -1
- package/dist/components/inputs/textInput/components/TextInput.d.ts.map +1 -1
- package/dist/components/modals/QuickChatModal.d.ts +10 -0
- package/dist/components/modals/QuickChatModal.d.ts.map +1 -0
- package/dist/components/modals/ZaloHybridWidget.d.ts +9 -0
- package/dist/components/modals/ZaloHybridWidget.d.ts.map +1 -0
- package/dist/components/modals/ZaloOfficialWidget.d.ts +12 -0
- package/dist/components/modals/ZaloOfficialWidget.d.ts.map +1 -0
- package/dist/components/modals/ZaloQRModal.d.ts +8 -0
- package/dist/components/modals/ZaloQRModal.d.ts.map +1 -0
- package/dist/components/modals/ZaloSmartWidget.d.ts +9 -0
- package/dist/components/modals/ZaloSmartWidget.d.ts.map +1 -0
- package/dist/components/modals/ZaloWebChatWidget.d.ts +9 -0
- package/dist/components/modals/ZaloWebChatWidget.d.ts.map +1 -0
- package/dist/components/quickchat/AlwaysOpenChat.d.ts +13 -0
- package/dist/components/quickchat/AlwaysOpenChat.d.ts.map +1 -0
- package/dist/components/quickchat/QuickChatButton.d.ts +10 -0
- package/dist/components/quickchat/QuickChatButton.d.ts.map +1 -0
- package/dist/components/quickchat/QuickChatConfig.d.ts +9 -0
- package/dist/components/quickchat/QuickChatConfig.d.ts.map +1 -0
- package/dist/components/quickchat/QuickChatPanel.d.ts +10 -0
- package/dist/components/quickchat/QuickChatPanel.d.ts.map +1 -0
- package/dist/components/quickchat/QuickChatWidget.d.ts +32 -0
- package/dist/components/quickchat/QuickChatWidget.d.ts.map +1 -0
- package/dist/components/quickchat/index.d.ts +7 -0
- package/dist/components/quickchat/index.d.ts.map +1 -0
- package/dist/cose-bilkent-S5V4N54A-2f5eb275.js +1 -0
- package/dist/cose-bilkent-S5V4N54A-3cda82b5.js +1 -0
- package/dist/cytoscape.esm-9acb9bfe.js +1 -0
- package/dist/dagre-6UL2VRFP-9b648c54.js +1 -0
- package/dist/dagre-6UL2VRFP-e997588d.js +1 -0
- package/dist/defaultLocale-1fe70b7d.js +1 -0
- package/dist/diagram-PSM6KHXK-1234d08d.js +1 -0
- package/dist/diagram-PSM6KHXK-15013de5.js +1 -0
- package/dist/diagram-QEK2KX5R-489b9505.js +1 -0
- package/dist/diagram-QEK2KX5R-9e94df2a.js +1 -0
- package/dist/diagram-S2PKOQOG-6fef3823.js +1 -0
- package/dist/diagram-S2PKOQOG-c943ed25.js +1 -0
- package/dist/erDiagram-Q2GNP2WA-2b1823f2.js +1 -0
- package/dist/erDiagram-Q2GNP2WA-7e6c6a04.js +1 -0
- package/dist/features/bubble/components/BubbleButton.d.ts.map +1 -1
- package/dist/flowDiagram-NV44I4VS-709c6479.js +1 -0
- package/dist/flowDiagram-NV44I4VS-98a84da9.js +1 -0
- package/dist/ganttDiagram-LVOFAZNH-1d379d6a.js +1 -0
- package/dist/ganttDiagram-LVOFAZNH-d8342586.js +1 -0
- package/dist/gitGraph-ZV4HHKMB-788776f3.js +1 -0
- package/dist/gitGraph-ZV4HHKMB-ba420dcc.js +1 -0
- package/dist/gitGraphDiagram-NY62KEGX-804d1363.js +1 -0
- package/dist/gitGraphDiagram-NY62KEGX-919097ea.js +1 -0
- package/dist/graph-834f6046.js +1 -0
- package/dist/graph-db4953aa.js +1 -0
- package/dist/info-63CPKGFF-2dccc483.js +1 -0
- package/dist/info-63CPKGFF-ef40f1c4.js +1 -0
- package/dist/infoDiagram-F6ZHWCRC-579d50b4.js +1 -0
- package/dist/infoDiagram-F6ZHWCRC-c9877bad.js +1 -0
- package/dist/init-cf76ae07.js +1 -0
- package/dist/journeyDiagram-XKPGCS4Q-25d3c922.js +1 -0
- package/dist/journeyDiagram-XKPGCS4Q-2d2cda1c.js +1 -0
- package/dist/kanban-definition-3W4ZIXB7-c556bee0.js +1 -0
- package/dist/kanban-definition-3W4ZIXB7-cdb93ec0.js +1 -0
- package/dist/katex-0a18b0df.js +1 -0
- package/dist/layout-40652dba.js +1 -0
- package/dist/layout-54ffc604.js +1 -0
- package/dist/linear-2f639b72.js +1 -0
- package/dist/linear-ed2367ff.js +1 -0
- package/dist/mermaid-parser.core-0cfa7d2a.js +1 -0
- package/dist/mermaid-parser.core-10bed742.js +1 -0
- package/dist/mindmap-definition-VGOIOE7T-169f5fe5.js +1 -0
- package/dist/mindmap-definition-VGOIOE7T-dea1c792.js +1 -0
- package/dist/ordinal-221e41d7.js +1 -0
- package/dist/packet-HUATNLJX-6f2471ea.js +1 -0
- package/dist/packet-HUATNLJX-c69e28eb.js +1 -0
- package/dist/pie-WTHONI2E-4143e44b.js +1 -0
- package/dist/pie-WTHONI2E-82b1fe3f.js +1 -0
- package/dist/pieDiagram-ADFJNKIX-499eec78.js +1 -0
- package/dist/pieDiagram-ADFJNKIX-657effd5.js +1 -0
- package/dist/quadrantDiagram-AYHSOK5B-138a0c93.js +1 -0
- package/dist/quadrantDiagram-AYHSOK5B-91137c4d.js +1 -0
- package/dist/radar-NJJJXTRR-5e934a95.js +1 -0
- package/dist/radar-NJJJXTRR-94d77527.js +1 -0
- package/dist/requirementDiagram-UZGBJVZJ-a5d9fb39.js +1 -0
- package/dist/requirementDiagram-UZGBJVZJ-d7aeec99.js +1 -0
- package/dist/sankeyDiagram-TZEHDZUN-15053ae0.js +1 -0
- package/dist/sankeyDiagram-TZEHDZUN-aadd2125.js +1 -0
- package/dist/sequenceDiagram-WL72ISMW-12e778ef.js +1 -0
- package/dist/sequenceDiagram-WL72ISMW-9330a98a.js +1 -0
- package/dist/stateDiagram-FKZM4ZOC-01225f0f.js +1 -0
- package/dist/stateDiagram-FKZM4ZOC-af4836d7.js +1 -0
- package/dist/stateDiagram-v2-4FDKWEC3-4774cc10.js +1 -0
- package/dist/stateDiagram-v2-4FDKWEC3-5ef8e019.js +1 -0
- package/dist/timeline-definition-IT6M3QCI-9921f937.js +1 -0
- package/dist/timeline-definition-IT6M3QCI-a7a9bbec.js +1 -0
- package/dist/treemap-75Q7IDZK-100ddeb7.js +1 -0
- package/dist/treemap-75Q7IDZK-851117b4.js +1 -0
- package/dist/utils/redisAndQueue.d.ts +32 -0
- package/dist/utils/redisAndQueue.d.ts.map +1 -0
- package/dist/utils/transcriptApi.d.ts +8 -0
- package/dist/utils/transcriptApi.d.ts.map +1 -0
- package/dist/web-0016ac81.js +1 -0
- package/dist/web-4e6d8ea9.js +1 -0
- package/dist/web.js +1 -1
- package/dist/xychartDiagram-PRI3JC2R-003630a4.js +1 -0
- package/dist/xychartDiagram-PRI3JC2R-df869780.js +1 -0
- package/package.json +78 -78
- package/public/index.html +46 -46
- package/.env +0 -5
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
type ZaloChatButtonProps = {
|
|
2
|
+
className?: string;
|
|
3
|
+
position?: 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left';
|
|
4
|
+
size?: 'small' | 'medium' | 'large';
|
|
5
|
+
showLabel?: boolean;
|
|
6
|
+
chatId?: string;
|
|
7
|
+
title?: string;
|
|
8
|
+
theme?: 'blue' | 'green' | 'purple' | 'gradient';
|
|
9
|
+
pulseAnimation?: boolean;
|
|
10
|
+
autoShow?: boolean;
|
|
11
|
+
showAfterSeconds?: number;
|
|
12
|
+
};
|
|
13
|
+
export declare const ZaloChatButton: (props: ZaloChatButtonProps) => import("solid-js").JSX.Element;
|
|
14
|
+
export declare const ZaloFloatingChat: (props?: Partial<ZaloChatButtonProps>) => import("solid-js").JSX.Element;
|
|
15
|
+
export {};
|
|
16
|
+
//# sourceMappingURL=ZaloChatButton.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ZaloChatButton.d.ts","sourceRoot":"","sources":["../../../src/components/buttons/ZaloChatButton.tsx"],"names":[],"mappings":"AAIA,KAAK,mBAAmB,GAAG;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,cAAc,GAAG,aAAa,GAAG,WAAW,GAAG,UAAU,CAAC;IACrE,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC;IACpC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,GAAG,QAAQ,GAAG,UAAU,CAAC;IACjD,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,eAAO,MAAM,cAAc,UAAW,mBAAmB,mCAsLxD,CAAC;AAGF,eAAO,MAAM,gBAAgB,WAAW,QAAQ,mBAAmB,CAAC,mCAanE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ZaloChatDemo.d.ts","sourceRoot":"","sources":["../../../src/components/demo/ZaloChatDemo.tsx"],"names":[],"mappings":"AASA,eAAO,MAAM,YAAY,sCAsMxB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
interface EditMessageDialogProps {
|
|
2
|
+
isOpen: boolean;
|
|
3
|
+
onClose: () => void;
|
|
4
|
+
originalMessage: string;
|
|
5
|
+
onSave: (newMessage: string) => Promise<void>;
|
|
6
|
+
}
|
|
7
|
+
declare const EditMessageDialog: (props: EditMessageDialogProps) => import("solid-js").JSX.Element;
|
|
8
|
+
export default EditMessageDialog;
|
|
9
|
+
//# sourceMappingURL=EditMessageDialog.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"EditMessageDialog.d.ts","sourceRoot":"","sources":["../../../src/components/dialogs/EditMessageDialog.tsx"],"names":[],"mappings":"AAEA,UAAU,sBAAsB;IAC9B,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,eAAe,EAAE,MAAM,CAAC;IACxB,MAAM,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CAC/C;AAED,QAAA,MAAM,iBAAiB,UAAW,sBAAsB,mCA0EvD,CAAC;AAEF,eAAe,iBAAiB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CheckIcon.d.ts","sourceRoot":"","sources":["../../../src/components/icons/CheckIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAE3C,eAAO,MAAM,SAAS,UAAW,IAAI,gBAAgB,CAAC,aAAa,CAAC,gBAcnE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CopyIcon.d.ts","sourceRoot":"","sources":["../../../src/components/icons/CopyIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAG3C,eAAO,MAAM,QAAQ,UAAW,IAAI,gBAAgB,CAAC,aAAa,CAAC,GAAG;IAAE,MAAM,CAAC,EAAE,OAAO,CAAA;CAAE,gBAiBzF,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"EditIcon.d.ts","sourceRoot":"","sources":["../../../src/components/icons/EditIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAE3C,eAAO,MAAM,QAAQ,UAAW,IAAI,gBAAgB,CAAC,aAAa,CAAC,GAAG;IAAE,MAAM,CAAC,EAAE,OAAO,CAAA;CAAE,gBAiBzF,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SupportIcon.d.ts","sourceRoot":"","sources":["../../../src/components/icons/SupportIcon.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAE3C,eAAO,MAAM,WAAW,UAAW,IAAI,gBAAgB,CAAC,aAAa,CAAC,gBAmBrE,CAAC"}
|
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
import { Setter } from 'solid-js';
|
|
2
2
|
import { FileEvent, IAction, UploadsConfig } from '@/components/Bot';
|
|
3
|
+
type FilePreviewData = string | ArrayBuffer;
|
|
4
|
+
type FilePreview = {
|
|
5
|
+
data: FilePreviewData;
|
|
6
|
+
mime: string;
|
|
7
|
+
name: string;
|
|
8
|
+
preview: string;
|
|
9
|
+
type: string;
|
|
10
|
+
};
|
|
3
11
|
type TextInputProps = {
|
|
4
12
|
placeholder?: string;
|
|
5
13
|
backgroundColor?: string;
|
|
@@ -12,7 +20,7 @@ type TextInputProps = {
|
|
|
12
20
|
onInputChange: (value: string) => void;
|
|
13
21
|
uploadsConfig?: Partial<UploadsConfig>;
|
|
14
22
|
isFullFileUpload?: boolean;
|
|
15
|
-
setPreviews: Setter<
|
|
23
|
+
setPreviews: Setter<FilePreview[]>;
|
|
16
24
|
onMicrophoneClicked: () => void;
|
|
17
25
|
handleFileChange: (event: FileEvent<HTMLInputElement>) => void;
|
|
18
26
|
maxChars?: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextInput.d.ts","sourceRoot":"","sources":["../../../../../src/components/inputs/textInput/components/TextInput.tsx"],"names":[],"mappings":"AAEA,OAAO,EAA6C,MAAM,EAAO,MAAM,UAAU,CAAC;AAElF,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"TextInput.d.ts","sourceRoot":"","sources":["../../../../../src/components/inputs/textInput/components/TextInput.tsx"],"names":[],"mappings":"AAEA,OAAO,EAA6C,MAAM,EAAO,MAAM,UAAU,CAAC;AAElF,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAOrE,KAAK,eAAe,GAAG,MAAM,GAAG,WAAW,CAAC;AAC5C,KAAK,WAAW,GAAG;IACjB,IAAI,EAAE,eAAe,CAAC;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AACF,KAAK,cAAc,GAAG;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,OAAO,GAAG,SAAS,GAAG,IAAI,EAAE,KAAK,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IACvF,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACvC,aAAa,CAAC,EAAE,OAAO,CAAC,aAAa,CAAC,CAAC;IACvC,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,WAAW,EAAE,MAAM,CAAC,WAAW,EAAE,CAAC,CAAC;IACnC,mBAAmB,EAAE,MAAM,IAAI,CAAC;IAChC,gBAAgB,EAAE,CAAC,KAAK,EAAE,SAAS,CAAC,gBAAgB,CAAC,KAAK,IAAI,CAAC;IAC/D,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,eAAe,EAAE,MAAM,CAAC,OAAO,CAAC,CAAC;CAClC,CAAC;AAOF,eAAO,MAAM,SAAS,UAAW,cAAc,mCA0V9C,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { QuickChatConfig } from '../quickchat/QuickChatWidget';
|
|
2
|
+
type QuickChatModalProps = {
|
|
3
|
+
config: QuickChatConfig;
|
|
4
|
+
isOpen: boolean;
|
|
5
|
+
onClose: () => void;
|
|
6
|
+
onMessageSent?: (message: string) => void;
|
|
7
|
+
};
|
|
8
|
+
export declare const QuickChatModal: (props: QuickChatModalProps) => import("solid-js").JSX.Element;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=QuickChatModal.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"QuickChatModal.d.ts","sourceRoot":"","sources":["../../../src/components/modals/QuickChatModal.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAG/D,KAAK,mBAAmB,GAAG;IACzB,MAAM,EAAE,eAAe,CAAC;IACxB,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,aAAa,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CAC3C,CAAC;AAEF,eAAO,MAAM,cAAc,UAAW,mBAAmB,mCA4MxD,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
type ZaloHybridWidgetProps = {
|
|
2
|
+
isOpen: boolean;
|
|
3
|
+
onClose: () => void;
|
|
4
|
+
chatId?: string;
|
|
5
|
+
title?: string;
|
|
6
|
+
};
|
|
7
|
+
export declare const ZaloHybridWidget: (props: ZaloHybridWidgetProps) => import("solid-js").JSX.Element;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=ZaloHybridWidget.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ZaloHybridWidget.d.ts","sourceRoot":"","sources":["../../../src/components/modals/ZaloHybridWidget.tsx"],"names":[],"mappings":"AAIA,KAAK,qBAAqB,GAAG;IAC3B,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,eAAO,MAAM,gBAAgB,UAAW,qBAAqB,mCAgP5D,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
type ZaloOfficialWidgetProps = {
|
|
2
|
+
isOpen: boolean;
|
|
3
|
+
onClose: () => void;
|
|
4
|
+
oaid?: string;
|
|
5
|
+
title?: string;
|
|
6
|
+
welcomeMessage?: string;
|
|
7
|
+
domain?: string;
|
|
8
|
+
};
|
|
9
|
+
export declare const ZaloOfficialWidget: (props: ZaloOfficialWidgetProps) => import("solid-js").JSX.Element;
|
|
10
|
+
export declare const ZaloOfficialChat: (props?: Partial<ZaloOfficialWidgetProps>) => import("solid-js").JSX.Element;
|
|
11
|
+
export {};
|
|
12
|
+
//# sourceMappingURL=ZaloOfficialWidget.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ZaloOfficialWidget.d.ts","sourceRoot":"","sources":["../../../src/components/modals/ZaloOfficialWidget.tsx"],"names":[],"mappings":"AAGA,KAAK,uBAAuB,GAAG;IAC7B,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,eAAO,MAAM,kBAAkB,UAAW,uBAAuB,mCAsLhE,CAAC;AAGF,eAAO,MAAM,gBAAgB,WAAW,QAAQ,uBAAuB,CAAC,mCAsBvE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ZaloQRModal.d.ts","sourceRoot":"","sources":["../../../src/components/modals/ZaloQRModal.tsx"],"names":[],"mappings":"AAGA,KAAK,gBAAgB,GAAG;IACtB,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,eAAO,MAAM,WAAW,UAAW,gBAAgB,mCA2JlD,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
type ZaloSmartWidgetProps = {
|
|
2
|
+
isOpen: boolean;
|
|
3
|
+
onClose: () => void;
|
|
4
|
+
chatId?: string;
|
|
5
|
+
title?: string;
|
|
6
|
+
};
|
|
7
|
+
export declare const ZaloSmartWidget: (props: ZaloSmartWidgetProps) => import("solid-js").JSX.Element;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=ZaloSmartWidget.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ZaloSmartWidget.d.ts","sourceRoot":"","sources":["../../../src/components/modals/ZaloSmartWidget.tsx"],"names":[],"mappings":"AAIA,KAAK,oBAAoB,GAAG;IAC1B,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,eAAO,MAAM,eAAe,UAAW,oBAAoB,mCA8Q1D,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
type ZaloWebChatWidgetProps = {
|
|
2
|
+
isOpen: boolean;
|
|
3
|
+
onClose: () => void;
|
|
4
|
+
chatId?: string;
|
|
5
|
+
title?: string;
|
|
6
|
+
};
|
|
7
|
+
export declare const ZaloWebChatWidget: (props: ZaloWebChatWidgetProps) => import("solid-js").JSX.Element;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=ZaloWebChatWidget.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ZaloWebChatWidget.d.ts","sourceRoot":"","sources":["../../../src/components/modals/ZaloWebChatWidget.tsx"],"names":[],"mappings":"AAGA,KAAK,sBAAsB,GAAG;IAC5B,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,eAAO,MAAM,iBAAiB,UAAW,sBAAsB,mCAqQ9D,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { QuickChatConfig } from './QuickChatWidget';
|
|
2
|
+
type AlwaysOpenChatProps = {
|
|
3
|
+
config?: QuickChatConfig;
|
|
4
|
+
className?: string;
|
|
5
|
+
onMessageSent?: (message: string) => void;
|
|
6
|
+
};
|
|
7
|
+
export declare const AlwaysOpenChat: (props: AlwaysOpenChatProps) => import("solid-js").JSX.Element;
|
|
8
|
+
export declare const AlwaysOpenChatSmall: (props: Omit<AlwaysOpenChatProps, 'config'>) => import("solid-js").JSX.Element;
|
|
9
|
+
export declare const AlwaysOpenChatLarge: (props: Omit<AlwaysOpenChatProps, 'config'>) => import("solid-js").JSX.Element;
|
|
10
|
+
export declare const AlwaysOpenChatBottomLeft: (props: Omit<AlwaysOpenChatProps, 'config'>) => import("solid-js").JSX.Element;
|
|
11
|
+
export declare const AlwaysOpenChatTopRight: (props: Omit<AlwaysOpenChatProps, 'config'>) => import("solid-js").JSX.Element;
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=AlwaysOpenChat.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AlwaysOpenChat.d.ts","sourceRoot":"","sources":["../../../src/components/quickchat/AlwaysOpenChat.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAKpD,KAAK,mBAAmB,GAAG;IACzB,MAAM,CAAC,EAAE,eAAe,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,aAAa,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CAC3C,CAAC;AAmBF,eAAO,MAAM,cAAc,UAAW,mBAAmB,mCAwGxD,CAAC;AAGF,eAAO,MAAM,mBAAmB,UAAW,KAAK,mBAAmB,EAAE,QAAQ,CAAC,mCAE7E,CAAC;AAEF,eAAO,MAAM,mBAAmB,UAAW,KAAK,mBAAmB,EAAE,QAAQ,CAAC,mCAE7E,CAAC;AAEF,eAAO,MAAM,wBAAwB,UAAW,KAAK,mBAAmB,EAAE,QAAQ,CAAC,mCAElF,CAAC;AAEF,eAAO,MAAM,sBAAsB,UAAW,KAAK,mBAAmB,EAAE,QAAQ,CAAC,mCAEhF,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { QuickChatConfig } from './QuickChatWidget';
|
|
2
|
+
type QuickChatButtonProps = {
|
|
3
|
+
config: QuickChatConfig;
|
|
4
|
+
isOpen: boolean;
|
|
5
|
+
onClick: () => void;
|
|
6
|
+
isMobile: boolean;
|
|
7
|
+
};
|
|
8
|
+
export declare const QuickChatButton: (props: QuickChatButtonProps) => import("solid-js").JSX.Element;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=QuickChatButton.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"QuickChatButton.d.ts","sourceRoot":"","sources":["../../../src/components/quickchat/QuickChatButton.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAEpD,KAAK,oBAAoB,GAAG;IAC1B,MAAM,EAAE,eAAe,CAAC;IACxB,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,QAAQ,EAAE,OAAO,CAAC;CACnB,CAAC;AAEF,eAAO,MAAM,eAAe,UAAW,oBAAoB,mCAqM1D,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { QuickChatConfig } from './QuickChatWidget';
|
|
2
|
+
type QuickChatConfigProps = {
|
|
3
|
+
config: QuickChatConfig;
|
|
4
|
+
onConfigChange: (config: QuickChatConfig) => void;
|
|
5
|
+
onClose?: () => void;
|
|
6
|
+
};
|
|
7
|
+
export declare const QuickChatConfigPanel: (props: QuickChatConfigProps) => import("solid-js").JSX.Element;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=QuickChatConfig.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"QuickChatConfig.d.ts","sourceRoot":"","sources":["../../../src/components/quickchat/QuickChatConfig.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAEpD,KAAK,oBAAoB,GAAG;IAC1B,MAAM,EAAE,eAAe,CAAC;IACxB,cAAc,EAAE,CAAC,MAAM,EAAE,eAAe,KAAK,IAAI,CAAC;IAClD,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB,CAAC;AAEF,eAAO,MAAM,oBAAoB,UAAW,oBAAoB,mCAgU/D,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { QuickChatConfig } from './QuickChatWidget';
|
|
2
|
+
type QuickChatPanelProps = {
|
|
3
|
+
config: QuickChatConfig;
|
|
4
|
+
isOpen: boolean;
|
|
5
|
+
onClose: () => void;
|
|
6
|
+
onMessageSent?: (message: string) => void;
|
|
7
|
+
};
|
|
8
|
+
export declare const QuickChatPanel: (props: QuickChatPanelProps) => import("solid-js").JSX.Element;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=QuickChatPanel.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"QuickChatPanel.d.ts","sourceRoot":"","sources":["../../../src/components/quickchat/QuickChatPanel.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAGpD,KAAK,mBAAmB,GAAG;IACzB,MAAM,EAAE,eAAe,CAAC;IACxB,MAAM,EAAE,OAAO,CAAC;IAChB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,aAAa,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CAC3C,CAAC;AAEF,eAAO,MAAM,cAAc,UAAW,mBAAmB,mCA0OxD,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
export interface QuickChatConfig {
|
|
2
|
+
logo?: string;
|
|
3
|
+
brandColor?: string;
|
|
4
|
+
brandName?: string;
|
|
5
|
+
position?: 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left';
|
|
6
|
+
autoOpen?: boolean;
|
|
7
|
+
welcomeMessage?: string;
|
|
8
|
+
zaloEnabled?: boolean;
|
|
9
|
+
zaloOAID?: string;
|
|
10
|
+
zaloWidgetId?: string;
|
|
11
|
+
zaloDomain?: string;
|
|
12
|
+
flowiseEnabled?: boolean;
|
|
13
|
+
customEndpoint?: string;
|
|
14
|
+
theme?: 'light' | 'dark' | 'auto';
|
|
15
|
+
animations?: boolean;
|
|
16
|
+
sounds?: boolean;
|
|
17
|
+
size?: 'small' | 'medium' | 'large';
|
|
18
|
+
showOnPages?: string[];
|
|
19
|
+
hideOnPages?: string[];
|
|
20
|
+
showAfterSeconds?: number;
|
|
21
|
+
showAfterScroll?: number;
|
|
22
|
+
}
|
|
23
|
+
type QuickChatWidgetProps = {
|
|
24
|
+
config?: QuickChatConfig;
|
|
25
|
+
className?: string;
|
|
26
|
+
onChatOpen?: () => void;
|
|
27
|
+
onChatClose?: () => void;
|
|
28
|
+
onMessageSent?: (message: string) => void;
|
|
29
|
+
};
|
|
30
|
+
export declare const QuickChatWidget: (props: QuickChatWidgetProps) => import("solid-js").JSX.Element;
|
|
31
|
+
export {};
|
|
32
|
+
//# sourceMappingURL=QuickChatWidget.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"QuickChatWidget.d.ts","sourceRoot":"","sources":["../../../src/components/quickchat/QuickChatWidget.tsx"],"names":[],"mappings":"AAMA,MAAM,WAAW,eAAe;IAE9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;IAGnB,QAAQ,CAAC,EAAE,cAAc,GAAG,aAAa,GAAG,WAAW,GAAG,UAAU,CAAC;IACrE,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,cAAc,CAAC,EAAE,MAAM,CAAC;IAGxB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,cAAc,CAAC,EAAE,MAAM,CAAC;IAGxB,KAAK,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,CAAC;IAClC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC;IAGpC,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,KAAK,oBAAoB,GAAG;IAC1B,MAAM,CAAC,EAAE,eAAe,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC;IACxB,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;IACzB,aAAa,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CAC3C,CAAC;AAoBF,eAAO,MAAM,eAAe,UAAW,oBAAoB,mCA6H1D,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { QuickChatWidget } from './QuickChatWidget';
|
|
2
|
+
export { QuickChatButton } from './QuickChatButton';
|
|
3
|
+
export { QuickChatPanel } from './QuickChatPanel';
|
|
4
|
+
export { QuickChatConfigPanel } from './QuickChatConfig';
|
|
5
|
+
export { AlwaysOpenChat, AlwaysOpenChatSmall, AlwaysOpenChatLarge, AlwaysOpenChatBottomLeft, AlwaysOpenChatTopRight } from './AlwaysOpenChat';
|
|
6
|
+
export type { QuickChatConfig } from './QuickChatWidget';
|
|
7
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/quickchat/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AACzD,OAAO,EAAE,cAAc,EAAE,mBAAmB,EAAE,mBAAmB,EAAE,wBAAwB,EAAE,sBAAsB,EAAE,MAAM,kBAAkB,CAAC;AAC9I,YAAY,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{aI as t,aJ as e,_ as i,j as n,l as r}from"./web-0016ac81.js";import{c as o}from"./cytoscape.esm-9acb9bfe.js";var s,a,h,l={exports:{}},g={exports:{}},u={exports:{}};function c(){var t;return a||(a=1,t=function(t){return i=[function(e,i){e.exports=t},function(t,e,i){var n,r=i(0).FDLayoutConstants;function o(){}for(n in r)o[n]=r[n];o.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,o.DEFAULT_RADIAL_SEPARATION=r.DEFAULT_EDGE_LENGTH,o.DEFAULT_COMPONENT_SEPERATION=60,o.TILE=!0,o.TILING_PADDING_VERTICAL=10,o.TILING_PADDING_HORIZONTAL=10,o.TREE_REDUCTION_ON_INCREMENTAL=!1,t.exports=o},function(t,e,i){var n,r=i(0).FDLayoutEdge;function o(t,e,i){r.call(this,t,e,i)}for(n in o.prototype=Object.create(r.prototype),r)o[n]=r[n];t.exports=o},function(t,e,i){var n,r=i(0).LGraph;function o(t,e,i){r.call(this,t,e,i)}for(n in o.prototype=Object.create(r.prototype),r)o[n]=r[n];t.exports=o},function(t,e,i){var n,r=i(0).LGraphManager;function o(t){r.call(this,t)}for(n in o.prototype=Object.create(r.prototype),r)o[n]=r[n];t.exports=o},function(t,e,i){var n,r=i(0).FDLayoutNode,o=i(0).IMath;function s(t,e,i,n){r.call(this,t,e,i,n)}for(n in s.prototype=Object.create(r.prototype),r)s[n]=r[n];s.prototype.move=function(){var t=this.graphManager.getLayout();this.displacementX=t.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY=t.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren,Math.abs(this.displacementX)>t.coolingFactor*t.maxNodeDisplacement&&(this.displacementX=t.coolingFactor*t.maxNodeDisplacement*o.sign(this.displacementX)),Math.abs(this.displacementY)>t.coolingFactor*t.maxNodeDisplacement&&(this.displacementY=t.coolingFactor*t.maxNodeDisplacement*o.sign(this.displacementY)),null==this.child||0==this.child.getNodes().length?this.moveBy(this.displacementX,this.displacementY):this.propogateDisplacementToChildren(this.displacementX,this.displacementY),t.totalDisplacement+=Math.abs(this.displacementX)+Math.abs(this.displacementY),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0},s.prototype.propogateDisplacementToChildren=function(t,e){for(var i,n=this.getChild().getNodes(),r=0;r<n.length;r++)null==(i=n[r]).getChild()?(i.moveBy(t,e),i.displacementX+=t,i.displacementY+=e):i.propogateDisplacementToChildren(t,e)},s.prototype.setPred1=function(t){this.pred1=t},s.prototype.getPred1=function(){return pred1},s.prototype.getPred2=function(){return pred2},s.prototype.setNext=function(t){this.next=t},s.prototype.getNext=function(){return next},s.prototype.setProcessed=function(t){this.processed=t},s.prototype.isProcessed=function(){return processed},t.exports=s},function(t,e,i){var n,r=i(0).FDLayout,o=i(4),s=i(3),a=i(5),h=i(2),l=i(1),g=i(0).FDLayoutConstants,u=i(0).LayoutConstants,c=i(0).Point,d=i(0).PointD,p=i(0).Layout,f=i(0).Integer,y=i(0).IGeometry,E=i(0).LGraph,A=i(0).Transform;function N(){r.call(this),this.toBeTiled={}}for(n in N.prototype=Object.create(r.prototype),r)N[n]=r[n];N.prototype.newGraphManager=function(){var t=new o(this);return this.graphManager=t},N.prototype.newGraph=function(t){return new s(null,this.graphManager,t)},N.prototype.newNode=function(t){return new a(this.graphManager,t)},N.prototype.newEdge=function(t){return new h(null,null,t)},N.prototype.initParameters=function(){r.prototype.initParameters.call(this,arguments),this.isSubLayout||(l.DEFAULT_EDGE_LENGTH<10?this.idealEdgeLength=10:this.idealEdgeLength=l.DEFAULT_EDGE_LENGTH,this.useSmartIdealEdgeLengthCalculation=l.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.springConstant=g.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=g.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=g.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=g.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=g.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=g.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.prunedNodesAll=[],this.growTreeIterations=0,this.afterGrowthIterations=0,this.isTreeGrowing=!1,this.isGrowthFinished=!1,this.coolingCycle=0,this.maxCoolingCycle=this.maxIterations/g.CONVERGENCE_CHECK_PERIOD,this.finalTemperature=g.CONVERGENCE_CHECK_PERIOD/this.maxIterations,this.coolingAdjuster=1)},N.prototype.layout=function(){return u.DEFAULT_CREATE_BENDS_AS_NEEDED&&(this.createBendpoints(),this.graphManager.resetAllEdges()),this.level=0,this.classicLayout()},N.prototype.classicLayout=function(){var t,e,i;return this.nodesWithGravity=this.calculateNodesToApplyGravitationTo(),this.graphManager.setAllNodesToApplyGravitation(this.nodesWithGravity),this.calcNoOfChildrenForAllNodes(),this.graphManager.calcLowestCommonAncestors(),this.graphManager.calcInclusionTreeDepths(),this.graphManager.getRoot().calcEstimatedSize(),this.calcIdealEdgeLengths(),this.incremental?l.TREE_REDUCTION_ON_INCREMENTAL&&(this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation(),e=new Set(this.getAllNodes()),i=this.nodesWithGravity.filter((function(t){return e.has(t)})),this.graphManager.setAllNodesToApplyGravitation(i)):0<(t=this.getFlatForest()).length?this.positionNodesRadially(t):(this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation(),e=new Set(this.getAllNodes()),i=this.nodesWithGravity.filter((function(t){return e.has(t)})),this.graphManager.setAllNodesToApplyGravitation(i),this.positionNodesRandomly()),this.initSpringEmbedder(),this.runSpringEmbedder(),!0},N.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished){if(!(0<this.prunedNodesAll.length))return!0;this.isTreeGrowing=!0}if(this.totalIterations%g.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged()){if(!(0<this.prunedNodesAll.length))return!0;this.isTreeGrowing=!0}this.coolingCycle++,0==this.layoutQuality?this.coolingAdjuster=this.coolingCycle:1==this.layoutQuality&&(this.coolingAdjuster=this.coolingCycle/3),this.coolingFactor=Math.max(this.initialCoolingFactor-Math.pow(this.coolingCycle,Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}var t;if(this.isTreeGrowing&&(this.growTreeIterations%10==0&&(0<this.prunedNodesAll.length?(this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation(),t=new Set(this.getAllNodes()),e=this.nodesWithGravity.filter((function(e){return t.has(e)})),this.graphManager.setAllNodesToApplyGravitation(e),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=g.DEFAULT_COOLING_FACTOR_INCREMENTAL):(this.isTreeGrowing=!1,this.isGrowthFinished=!0)),this.growTreeIterations++),this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),this.coolingFactor=g.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var e=!this.isTreeGrowing&&!this.isGrowthFinished,i=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(e,i),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},N.prototype.getPositionsData=function(){for(var t=this.graphManager.getAllNodes(),e={},i=0;i<t.length;i++){var n=t[i].rect,r=t[i].id;e[r]={id:r,x:n.getCenterX(),y:n.getCenterY(),w:n.width,h:n.height}}return e},N.prototype.runSpringEmbedder=function(){this.initialAnimationPeriod=25,this.animationPeriod=this.initialAnimationPeriod;var t=!1;if("during"===g.ANIMATE)this.emit("layoutstarted");else{for(;!t;)t=this.tick();this.graphManager.updateBounds()}},N.prototype.calculateNodesToApplyGravitationTo=function(){for(var t,e=[],i=this.graphManager.getGraphs(),n=i.length,r=0;r<n;r++)(t=i[r]).updateConnected(),t.isConnected||(e=e.concat(t.getNodes()));return e},N.prototype.createBendpoints=function(){for(var t=(t=[]).concat(this.graphManager.getAllEdges()),e=new Set,i=0;i<t.length;i++){var n=t[i];if(!e.has(n)){var r=n.getSource(),o=n.getTarget();if(r==o)n.getBendpoints().push(new d),n.getBendpoints().push(new d),this.createDummyNodesForBendpoints(n),e.add(n);else{var s=[];if(s=(s=s.concat(r.getEdgeListToNode(o))).concat(o.getEdgeListToNode(r)),!e.has(s[0])){if(1<s.length)for(var a=0;a<s.length;a++){var h=s[a];h.getBendpoints().push(new d),this.createDummyNodesForBendpoints(h)}s.forEach((function(t){e.add(t)}))}}}if(e.size==t.length)break}},N.prototype.positionNodesRadially=function(t){for(var e=new c(0,0),i=Math.ceil(Math.sqrt(t.length)),n=0,r=0,o=0,s=new d(0,0),a=0;a<t.length;a++){a%i==0&&(r=n,(o=0)!=a&&(r+=l.DEFAULT_COMPONENT_SEPERATION),n=0);var h=t[a],g=p.findCenterOfTree(h);e.x=o,e.y=r,(s=N.radialLayout(h,g,e)).y>n&&(n=Math.floor(s.y)),o=Math.floor(s.x+l.DEFAULT_COMPONENT_SEPERATION)}this.transform(new d(u.WORLD_CENTER_X-s.x/2,u.WORLD_CENTER_Y-s.y/2))},N.radialLayout=function(t,e,i){var n=Math.max(this.maxDiagonalInTree(t),l.DEFAULT_RADIAL_SEPARATION),r=(e=(N.branchRadialLayout(e,null,0,359,0,n),E.calculateBounds(t)),new A);r.setDeviceOrgX(e.getMinX()),r.setDeviceOrgY(e.getMinY()),r.setWorldOrgX(i.x),r.setWorldOrgY(i.y);for(var o=0;o<t.length;o++)t[o].transform(r);return n=new d(e.getMaxX(),e.getMaxY()),r.inverseTransformPoint(n)},N.branchRadialLayout=function(t,e,i,n,r,o){(s=(n-i+1)/2)<0&&(s+=180);for(var s=(s+i)%360*y.TWO_PI/360,a=r*Math.cos(s),h=(s=r*Math.sin(s),t.setCenter(a,s),[]),l=(h=h.concat(t.getEdges())).length,g=(null!=e&&l--,0),u=h.length,c=t.getEdgesBetween(e);1<c.length;){var d=c[0];0<=(d=(c.splice(0,1),h.indexOf(d)))&&h.splice(d,1),u--,l--}a=null!=e?(h.indexOf(c[0])+1)%u:0;for(var p=Math.abs(n-i)/l,f=a;g!=l;f=++f%u){var E=h[f].getOtherEnd(t);E!=e&&(N.branchRadialLayout(E,t,E=(i+g*p)%360,(E+p)%360,r+o,o),g++)}},N.maxDiagonalInTree=function(t){for(var e=f.MIN_VALUE,i=0;i<t.length;i++){var n=t[i].getDiagonal();e<n&&(e=n)}return e},N.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},N.prototype.groupZeroDegreeMembers=function(){for(var t=this,e={},i=(this.memberGroups={},this.idToDummyNode={},[]),n=this.graphManager.getAllNodes(),r=0;r<n.length;r++){var o=(s=n[r]).getParent();0!==this.getNodeDegreeWithChildren(s)||null!=o.id&&this.getToBeTiled(o)||i.push(s)}for(r=0;r<i.length;r++){var s,h=(s=i[r]).getParent().id;void 0===e[h]&&(e[h]=[]),e[h]=e[h].concat(s)}Object.keys(e).forEach((function(i){if(1<e[i].length){var n="DummyCompound_"+i,r=(t.memberGroups[n]=e[i],e[i][0].getParent()),o=new a(t.graphManager),s=(o.id=n,o.paddingLeft=r.paddingLeft||0,o.paddingRight=r.paddingRight||0,o.paddingBottom=r.paddingBottom||0,o.paddingTop=r.paddingTop||0,t.idToDummyNode[n]=o,t.getGraphManager().add(t.newGraph(),o)),h=r.getChild();h.add(o);for(var l=0;l<e[i].length;l++){var g=e[i][l];h.remove(g),s.add(g)}}}))},N.prototype.clearCompounds=function(){var t={},e={};this.performDFSOnCompounds();for(var i=0;i<this.compoundOrder.length;i++)e[this.compoundOrder[i].id]=this.compoundOrder[i],t[this.compoundOrder[i].id]=[].concat(this.compoundOrder[i].getChild().getNodes()),this.graphManager.remove(this.compoundOrder[i].getChild()),this.compoundOrder[i].child=null;this.graphManager.resetAllNodes(),this.tileCompoundMembers(t,e)},N.prototype.clearZeroDegreeMembers=function(){var t=this,e=this.tiledZeroDegreePack=[];Object.keys(this.memberGroups).forEach((function(i){var n=t.idToDummyNode[i];e[i]=t.tileNodes(t.memberGroups[i],n.paddingLeft+n.paddingRight),n.rect.width=e[i].width,n.rect.height=e[i].height}))},N.prototype.repopulateCompounds=function(){for(var t=this.compoundOrder.length-1;0<=t;t--){var e=this.compoundOrder[t],i=e.id,n=e.paddingLeft,r=e.paddingTop;this.adjustLocations(this.tiledMemberPack[i],e.rect.x,e.rect.y,n,r)}},N.prototype.repopulateZeroDegreeMembers=function(){var t=this,e=this.tiledZeroDegreePack;Object.keys(e).forEach((function(i){var n=t.idToDummyNode[i],r=n.paddingLeft,o=n.paddingTop;t.adjustLocations(e[i],n.rect.x,n.rect.y,r,o)}))},N.prototype.getToBeTiled=function(t){var e=t.id;if(null!=this.toBeTiled[e])return this.toBeTiled[e];if(null==(t=t.getChild()))return this.toBeTiled[e]=!1;for(var i=t.getNodes(),n=0;n<i.length;n++){var r=i[n];if(0<this.getNodeDegree(r))return this.toBeTiled[e]=!1;if(null==r.getChild())this.toBeTiled[r.id]=!1;else if(!this.getToBeTiled(r))return this.toBeTiled[e]=!1}return this.toBeTiled[e]=!0},N.prototype.getNodeDegree=function(t){t.id;for(var e=t.getEdges(),i=0,n=0;n<e.length;n++){var r=e[n];r.getSource().id!==r.getTarget().id&&(i+=1)}return i},N.prototype.getNodeDegreeWithChildren=function(t){var e=this.getNodeDegree(t);if(null!=t.getChild())for(var i=t.getChild().getNodes(),n=0;n<i.length;n++){var r=i[n];e+=this.getNodeDegreeWithChildren(r)}return e},N.prototype.performDFSOnCompounds=function(){this.compoundOrder=[],this.fillCompexOrderByDFS(this.graphManager.getRoot().getNodes())},N.prototype.fillCompexOrderByDFS=function(t){for(var e=0;e<t.length;e++){var i=t[e];null!=i.getChild()&&this.fillCompexOrderByDFS(i.getChild().getNodes()),this.getToBeTiled(i)&&this.compoundOrder.push(i)}},N.prototype.adjustLocations=function(t,e,i,n,r){i+=r;for(var o=e+=n,s=0;s<t.rows.length;s++){for(var a=t.rows[s],h=(e=o,0),l=0;l<a.length;l++){var g=a[l];g.rect.x=e,g.rect.y=i,e+=g.rect.width+t.horizontalPadding,g.rect.height>h&&(h=g.rect.height)}i+=h+t.verticalPadding}},N.prototype.tileCompoundMembers=function(t,e){var i=this;this.tiledMemberPack=[],Object.keys(t).forEach((function(n){var r=e[n];i.tiledMemberPack[n]=i.tileNodes(t[n],r.paddingLeft+r.paddingRight),r.rect.width=i.tiledMemberPack[n].width,r.rect.height=i.tiledMemberPack[n].height}))},N.prototype.tileNodes=function(t,e){var i={rows:[],rowWidth:[],rowHeight:[],width:0,height:e,verticalPadding:l.TILING_PADDING_VERTICAL,horizontalPadding:l.TILING_PADDING_HORIZONTAL};t.sort((function(t,e){return t.rect.width*t.rect.height>e.rect.width*e.rect.height?-1:t.rect.width*t.rect.height<e.rect.width*e.rect.height?1:0}));for(var n=0;n<t.length;n++){var r=t[n];0==i.rows.length?this.insertNodeToRow(i,r,0,e):this.canAddHorizontal(i,r.rect.width,r.rect.height)?this.insertNodeToRow(i,r,this.getShortestRowIndex(i),e):this.insertNodeToRow(i,r,i.rows.length,e),this.shiftToLastRow(i)}return i},N.prototype.insertNodeToRow=function(t,e,i,n){i==t.rows.length&&(t.rows.push([]),t.rowWidth.push(n),t.rowHeight.push(0));n=t.rowWidth[i]+e.rect.width,0<t.rows[i].length&&(n+=t.horizontalPadding),t.rowWidth[i]=n,t.width<n&&(t.width=n),n=e.rect.height;var r=(0<i&&(n+=t.verticalPadding),0);n>t.rowHeight[i]&&(r=t.rowHeight[i],t.rowHeight[i]=n,r=t.rowHeight[i]-r),t.height+=r,t.rows[i].push(e)},N.prototype.getShortestRowIndex=function(t){for(var e=-1,i=Number.MAX_VALUE,n=0;n<t.rows.length;n++)t.rowWidth[n]<i&&(e=n,i=t.rowWidth[n]);return e},N.prototype.getLongestRowIndex=function(t){for(var e=-1,i=Number.MIN_VALUE,n=0;n<t.rows.length;n++)t.rowWidth[n]>i&&(e=n,i=t.rowWidth[n]);return e},N.prototype.canAddHorizontal=function(t,e,i){var n,r,o=this.getShortestRowIndex(t);return o<0||(r=t.rowWidth[o])+t.horizontalPadding+e<=t.width||(n=0,t.rowHeight[o]<i&&0<o&&(n=i+t.verticalPadding-t.rowHeight[o]),o=t.width-r>=e+t.horizontalPadding?(t.height+n)/(r+e+t.horizontalPadding):(t.height+n)/t.width,n=i+t.verticalPadding,(o=o<1?1/o:o)<((r=t.width<e?(t.height+n)/e:(t.height+n)/t.width)<1?1/r:r))},N.prototype.shiftToLastRow=function(t){var e=this.getLongestRowIndex(t),i=t.rowWidth.length-1,n=t.rows[e],r=n[n.length-1],o=r.width+t.horizontalPadding;if(t.width-t.rowWidth[i]>o&&e!=i){n.splice(-1,1),t.rows[i].push(r),t.rowWidth[e]=t.rowWidth[e]-o,t.rowWidth[i]=t.rowWidth[i]+o,t.width=t.rowWidth[instance.getLongestRowIndex(t)];for(var s=Number.MIN_VALUE,a=0;a<n.length;a++)n[a].height>s&&(s=n[a].height);0<e&&(s+=t.verticalPadding),o=t.rowHeight[e]+t.rowHeight[i],t.rowHeight[e]=s,t.rowHeight[i]<r.height+t.verticalPadding&&(t.rowHeight[i]=r.height+t.verticalPadding),r=t.rowHeight[e]+t.rowHeight[i],t.height+=r-o,this.shiftToLastRow(t)}},N.prototype.tilingPreLayout=function(){l.TILE&&(this.groupZeroDegreeMembers(),this.clearCompounds(),this.clearZeroDegreeMembers())},N.prototype.tilingPostLayout=function(){l.TILE&&(this.repopulateZeroDegreeMembers(),this.repopulateCompounds())},N.prototype.reduceTrees=function(){for(var t,e=[],i=!0;i;){for(var n=this.graphManager.getAllNodes(),r=[],o=(i=!1,0);o<n.length;o++)1!=(t=n[o]).getEdges().length||t.getEdges()[0].isInterGraph||null!=t.getChild()||(r.push([t,t.getEdges()[0],t.getOwner()]),i=!0);if(1==i){for(var s=[],a=0;a<r.length;a++)1==r[a][0].getEdges().length&&(s.push(r[a]),r[a][0].getOwner().remove(r[a][0]));e.push(s),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()}}this.prunedNodesAll=e},N.prototype.growTree=function(t){for(var e,i=t[t.length-1],n=0;n<i.length;n++)e=i[n],this.findPlaceforPrunedNode(e),e[2].add(e[0]),e[2].add(e[1],e[1].source,e[1].target);t.splice(t.length-1,1),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()},N.prototype.findPlaceforPrunedNode=function(t){var e=t[0],i=(t=e==t[1].source?t[1].target:t[1].source).startX,n=t.finishX,r=t.startY,o=t.finishY,s=[0,0,0,0];if(0<r)for(var a=i;a<=n;a++)s[0]+=this.grid[a][r-1].length+this.grid[a][r].length-1;if(n<this.grid.length-1)for(a=r;a<=o;a++)s[1]+=this.grid[n+1][a].length+this.grid[n][a].length-1;if(o<this.grid[0].length-1)for(a=i;a<=n;a++)s[2]+=this.grid[a][o+1].length+this.grid[a][o].length-1;if(0<i)for(a=r;a<=o;a++)s[3]+=this.grid[i-1][a].length+this.grid[i][a].length-1;for(var h,l,u,c,d=f.MAX_VALUE,p=0;p<s.length;p++)s[p]<d?(d=s[p],h=1,l=p):s[p]==d&&h++;3==h&&0==d?0==s[0]&&0==s[1]&&0==s[2]?u=1:0==s[0]&&0==s[1]&&0==s[3]?u=0:0==s[0]&&0==s[2]&&0==s[3]?u=3:0==s[1]&&0==s[2]&&0==s[3]&&(u=2):u=2==h&&0==d?(c=Math.floor(2*Math.random()),0==s[0]&&0==s[1]?0==c?0:1:0==s[0]&&0==s[2]?0==c?0:2:0==s[0]&&0==s[3]?0==c?0:3:0==s[1]&&0==s[2]?0==c?1:2:0==s[1]&&0==s[3]?0==c?1:3:0==c?2:3):4==h&&0==d?c=Math.floor(4*Math.random()):l,0==u?e.setCenter(t.getCenterX(),t.getCenterY()-t.getHeight()/2-g.DEFAULT_EDGE_LENGTH-e.getHeight()/2):1==u?e.setCenter(t.getCenterX()+t.getWidth()/2+g.DEFAULT_EDGE_LENGTH+e.getWidth()/2,t.getCenterY()):2==u?e.setCenter(t.getCenterX(),t.getCenterY()+t.getHeight()/2+g.DEFAULT_EDGE_LENGTH+e.getHeight()/2):e.setCenter(t.getCenterX()-t.getWidth()/2-g.DEFAULT_EDGE_LENGTH-e.getWidth()/2,t.getCenterY())},t.exports=N},function(t,e,i){var n={};n.layoutBase=i(0),n.CoSEConstants=i(1),n.CoSEEdge=i(2),n.CoSEGraph=i(3),n.CoSEGraphManager=i(4),n.CoSELayout=i(6),n.CoSENode=i(5),t.exports=n}],n={},e.m=i,e.c=n,e.i=function(t){return t},e.d=function(t,i,n){e.o(t,i)||Object.defineProperty(t,i,{configurable:!1,enumerable:!0,get:n})},e.n=function(t){var i=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(i,"a",i),i},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=7);function e(t){var r;return(n[t]||(r=n[t]={i:t,l:!1,exports:{}},i[t].call(r.exports,r,r.exports,e),r.l=!0,r)).exports}var i,n},g.exports=t(function(){var t;return s||(s=1,t=function(){return e=[function(t,e,i){function n(){}n.QUALITY=1,n.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,n.DEFAULT_INCREMENTAL=!1,n.DEFAULT_ANIMATION_ON_LAYOUT=!0,n.DEFAULT_ANIMATION_DURING_LAYOUT=!1,n.DEFAULT_ANIMATION_PERIOD=50,n.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,n.DEFAULT_GRAPH_MARGIN=15,n.NODE_DIMENSIONS_INCLUDE_LABELS=!1,n.SIMPLE_NODE_HALF_SIZE=(n.SIMPLE_NODE_SIZE=40)/2,n.EMPTY_COMPOUND_NODE_SIZE=40,n.MIN_EDGE_LENGTH=1,n.INITIAL_WORLD_BOUNDARY=(n.WORLD_BOUNDARY=1e6)/1e3,n.WORLD_CENTER_X=1200,n.WORLD_CENTER_Y=900,t.exports=n},function(t,e,i){var n,r=i(2),o=i(8),s=i(9);function a(t,e,i){r.call(this,i),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=i,this.bendpoints=[],this.source=t,this.target=e}for(n in a.prototype=Object.create(r.prototype),r)a[n]=r[n];a.prototype.getSource=function(){return this.source},a.prototype.getTarget=function(){return this.target},a.prototype.isInterGraph=function(){return this.isInterGraph},a.prototype.getLength=function(){return this.length},a.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},a.prototype.getBendpoints=function(){return this.bendpoints},a.prototype.getLca=function(){return this.lca},a.prototype.getSourceInLca=function(){return this.sourceInLca},a.prototype.getTargetInLca=function(){return this.targetInLca},a.prototype.getOtherEnd=function(t){if(this.source===t)return this.target;if(this.target===t)return this.source;throw"Node is not incident with this edge"},a.prototype.getOtherEndInGraph=function(t,e){for(var i=this.getOtherEnd(t),n=e.getGraphManager().getRoot();;){if(i.getOwner()==e)return i;if(i.getOwner()==n)break;i=i.getOwner().getParent()}return null},a.prototype.updateLength=function(){var t=new Array(4);this.isOverlapingSourceAndTarget=o.getIntersection(this.target.getRect(),this.source.getRect(),t),this.isOverlapingSourceAndTarget||(this.lengthX=t[0]-t[2],this.lengthY=t[1]-t[3],Math.abs(this.lengthX)<1&&(this.lengthX=s.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=s.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},a.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=s.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=s.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},t.exports=a},function(t,e,i){t.exports=function(t){this.vGraphObject=t}},function(t,e,i){var n,r=i(2),o=i(10),s=i(13),a=i(0),h=i(16),l=i(4);function g(t,e,i,n){r.call(this,n=null==i&&null==n?e:n),null!=t.graphManager&&(t=t.graphManager),this.estimatedSize=o.MIN_VALUE,this.inclusionTreeDepth=o.MAX_VALUE,this.vGraphObject=n,this.edges=[],this.graphManager=t,this.rect=null!=i&&null!=e?new s(e.x,e.y,i.width,i.height):new s}for(n in g.prototype=Object.create(r.prototype),r)g[n]=r[n];g.prototype.getEdges=function(){return this.edges},g.prototype.getChild=function(){return this.child},g.prototype.getOwner=function(){return this.owner},g.prototype.getWidth=function(){return this.rect.width},g.prototype.setWidth=function(t){this.rect.width=t},g.prototype.getHeight=function(){return this.rect.height},g.prototype.setHeight=function(t){this.rect.height=t},g.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},g.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},g.prototype.getCenter=function(){return new l(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},g.prototype.getLocation=function(){return new l(this.rect.x,this.rect.y)},g.prototype.getRect=function(){return this.rect},g.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},g.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},g.prototype.setRect=function(t,e){this.rect.x=t.x,this.rect.y=t.y,this.rect.width=e.width,this.rect.height=e.height},g.prototype.setCenter=function(t,e){this.rect.x=t-this.rect.width/2,this.rect.y=e-this.rect.height/2},g.prototype.setLocation=function(t,e){this.rect.x=t,this.rect.y=e},g.prototype.moveBy=function(t,e){this.rect.x+=t,this.rect.y+=e},g.prototype.getEdgeListToNode=function(t){var e=[],i=this;return i.edges.forEach((function(n){if(n.target==t){if(n.source!=i)throw"Incorrect edge source!";e.push(n)}})),e},g.prototype.getEdgesBetween=function(t){var e=[],i=this;return i.edges.forEach((function(n){if(n.source!=i&&n.target!=i)throw"Incorrect edge source and/or target";n.target!=t&&n.source!=t||e.push(n)})),e},g.prototype.getNeighborsList=function(){var t=new Set,e=this;return e.edges.forEach((function(i){if(i.source==e)t.add(i.target);else{if(i.target!=e)throw"Incorrect incidency!";t.add(i.source)}})),t},g.prototype.withChildren=function(){var t=new Set;if(t.add(this),null!=this.child)for(var e=this.child.getNodes(),i=0;i<e.length;i++)e[i].withChildren().forEach((function(e){t.add(e)}));return t},g.prototype.getNoOfChildren=function(){var t=0;if(null==this.child)t=1;else for(var e=this.child.getNodes(),i=0;i<e.length;i++)t+=e[i].getNoOfChildren();return 0==t?1:t},g.prototype.getEstimatedSize=function(){if(this.estimatedSize==o.MIN_VALUE)throw"assert failed";return this.estimatedSize},g.prototype.calcEstimatedSize=function(){return null==this.child?this.estimatedSize=(this.rect.width+this.rect.height)/2:(this.estimatedSize=this.child.calcEstimatedSize(),this.rect.width=this.estimatedSize,this.rect.height=this.estimatedSize,this.estimatedSize)},g.prototype.scatter=function(){var t=-a.INITIAL_WORLD_BOUNDARY,e=a.INITIAL_WORLD_BOUNDARY,i=(e=a.WORLD_CENTER_X+h.nextDouble()*(e-t)+t,t=-a.INITIAL_WORLD_BOUNDARY,a.INITIAL_WORLD_BOUNDARY);i=a.WORLD_CENTER_Y+h.nextDouble()*(i-t)+t,this.rect.x=e,this.rect.y=i},g.prototype.updateBounds=function(){if(null==this.getChild())throw"assert failed";var t,e;0!=this.getChild().getNodes().length&&((e=this.getChild()).updateBounds(!0),this.rect.x=e.getLeft(),this.rect.y=e.getTop(),this.setWidth(e.getRight()-e.getLeft()),this.setHeight(e.getBottom()-e.getTop()),a.NODE_DIMENSIONS_INCLUDE_LABELS)&&(t=e.getRight()-e.getLeft(),e=e.getBottom()-e.getTop(),this.labelWidth>t&&(this.rect.x-=(this.labelWidth-t)/2,this.setWidth(this.labelWidth)),this.labelHeight>e)&&("center"==this.labelPos?this.rect.y-=(this.labelHeight-e)/2:"top"==this.labelPos&&(this.rect.y-=this.labelHeight-e),this.setHeight(this.labelHeight))},g.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==o.MAX_VALUE)throw"assert failed";return this.inclusionTreeDepth},g.prototype.transform=function(t){var e=((e=this.rect.x)>a.WORLD_BOUNDARY?e=a.WORLD_BOUNDARY:e<-a.WORLD_BOUNDARY&&(e=-a.WORLD_BOUNDARY),(i=this.rect.y)>a.WORLD_BOUNDARY?i=a.WORLD_BOUNDARY:i<-a.WORLD_BOUNDARY&&(i=-a.WORLD_BOUNDARY),new l(e,i)),i=t.inverseTransformPoint(e);this.setLocation(i.x,i.y)},g.prototype.getLeft=function(){return this.rect.x},g.prototype.getRight=function(){return this.rect.x+this.rect.width},g.prototype.getTop=function(){return this.rect.y},g.prototype.getBottom=function(){return this.rect.y+this.rect.height},g.prototype.getParent=function(){return null==this.owner?null:this.owner.getParent()},t.exports=g},function(t,e,i){function n(t,e){null==t&&null==e?(this.x=0,this.y=0):(this.x=t,this.y=e)}n.prototype.getX=function(){return this.x},n.prototype.getY=function(){return this.y},n.prototype.setX=function(t){this.x=t},n.prototype.setY=function(t){this.y=t},n.prototype.getDifference=function(t){return new DimensionD(this.x-t.x,this.y-t.y)},n.prototype.getCopy=function(){return new n(this.x,this.y)},n.prototype.translate=function(t){return this.x+=t.width,this.y+=t.height,this},t.exports=n},function(t,e,i){var n,r=i(2),o=i(10),s=i(0),a=i(6),h=i(3),l=i(1),g=i(13),u=i(12),c=i(11);function d(t,e,i){r.call(this,i),this.estimatedSize=o.MIN_VALUE,this.margin=s.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=t,null!=e&&e instanceof a?this.graphManager=e:null!=e&&e instanceof Layout&&(this.graphManager=e.graphManager)}for(n in d.prototype=Object.create(r.prototype),r)d[n]=r[n];d.prototype.getNodes=function(){return this.nodes},d.prototype.getEdges=function(){return this.edges},d.prototype.getGraphManager=function(){return this.graphManager},d.prototype.getParent=function(){return this.parent},d.prototype.getLeft=function(){return this.left},d.prototype.getRight=function(){return this.right},d.prototype.getTop=function(){return this.top},d.prototype.getBottom=function(){return this.bottom},d.prototype.isConnected=function(){return this.isConnected},d.prototype.add=function(t,e,i){if(null==e&&null==i){var n=t;if(null==this.graphManager)throw"Graph has no graph mgr!";if(-1<this.getNodes().indexOf(n))throw"Node already in graph!";return(n.owner=this).getNodes().push(n),n}if(n=t,!(-1<this.getNodes().indexOf(e)&&-1<this.getNodes().indexOf(i)))throw"Source or target not in graph!";if(e.owner!=i.owner||e.owner!=this)throw"Both owners must be this graph!";return e.owner!=i.owner?null:(n.source=e,n.target=i,n.isInterGraph=!1,this.getEdges().push(n),e.edges.push(n),i!=e&&i.edges.push(n),n)},d.prototype.remove=function(t){var e=t;if(t instanceof h){if(null==e)throw"Node is null!";if(null==e.owner||e.owner!=this)throw"Owner graph is invalid!";if(null==this.graphManager)throw"Owner graph manager is invalid!";for(var i,n=e.edges.slice(),r=n.length,o=0;o<r;o++)((i=n[o]).isInterGraph?this.graphManager:i.source.owner).remove(i);if(-1==(s=this.nodes.indexOf(e)))throw"Node not in owner node list!";this.nodes.splice(s,1)}else if(t instanceof l){if(null==(i=t))throw"Edge is null!";if(null==i.source||null==i.target)throw"Source and/or target is null!";if(null==i.source.owner||null==i.target.owner||i.source.owner!=this||i.target.owner!=this)throw"Source and/or target owner is invalid!";var s;if(e=i.source.edges.indexOf(i),t=i.target.edges.indexOf(i),!(-1<e&&-1<t))throw"Source and/or target doesn't know this edge!";if(i.source.edges.splice(e,1),i.target!=i.source&&i.target.edges.splice(t,1),-1==(s=i.source.owner.getEdges().indexOf(i)))throw"Not in owner's edge list!";i.source.owner.getEdges().splice(s,1)}},d.prototype.updateLeftTop=function(){for(var t,e=o.MAX_VALUE,i=o.MAX_VALUE,n=this.getNodes(),r=n.length,s=0;s<r;s++){var a,h=n[s];(a=h.getTop())<e&&(e=a),(a=h.getLeft())<i&&(i=a)}return e==o.MAX_VALUE?null:(t=null!=n[0].getParent().paddingLeft?n[0].getParent().paddingLeft:this.margin,this.left=i-t,this.top=e-t,new u(this.left,this.top))},d.prototype.updateBounds=function(t){for(var e,i,n=o.MAX_VALUE,r=-o.MAX_VALUE,s=o.MAX_VALUE,a=-o.MAX_VALUE,h=this.nodes,l=h.length,u=0;u<l;u++){var c=h[u];t&&null!=c.child&&c.updateBounds(),(e=c.getLeft())<n&&(n=e),r<(e=c.getRight())&&(r=e),(e=c.getTop())<s&&(s=e),a<(e=c.getBottom())&&(a=e)}var d=new g(n,s,r-n,a-s);n==o.MAX_VALUE&&(this.left=this.parent.getLeft(),this.right=this.parent.getRight(),this.top=this.parent.getTop(),this.bottom=this.parent.getBottom()),i=null!=h[0].getParent().paddingLeft?h[0].getParent().paddingLeft:this.margin,this.left=d.x-i,this.right=d.x+d.width+i,this.top=d.y-i,this.bottom=d.y+d.height+i},d.calculateBounds=function(t){for(var e=o.MAX_VALUE,i=-o.MAX_VALUE,n=o.MAX_VALUE,r=-o.MAX_VALUE,s=t.length,a=0;a<s;a++){var h,l=t[a];(h=l.getLeft())<e&&(e=h),i<(h=l.getRight())&&(i=h),(h=l.getTop())<n&&(n=h),r<(h=l.getBottom())&&(r=h)}return new g(e,n,i-e,r-n)},d.prototype.getInclusionTreeDepth=function(){return this==this.graphManager.getRoot()?1:this.parent.getInclusionTreeDepth()},d.prototype.getEstimatedSize=function(){if(this.estimatedSize==o.MIN_VALUE)throw"assert failed";return this.estimatedSize},d.prototype.calcEstimatedSize=function(){for(var t=0,e=this.nodes,i=e.length,n=0;n<i;n++)t+=e[n].calcEstimatedSize();return this.estimatedSize=0==t?s.EMPTY_COMPOUND_NODE_SIZE:t/Math.sqrt(this.nodes.length),this.estimatedSize},d.prototype.updateConnected=function(){var t=this;if(0==this.nodes.length)this.isConnected=!0;else{var e,i=new c,n=new Set,r=this.nodes[0];for(r.withChildren().forEach((function(t){i.push(t),n.add(t)}));0!==i.length;)for(var o,s,a=(o=(r=i.shift()).getEdges()).length,h=0;h<a;h++)null==(s=o[h].getOtherEndInGraph(r,this))||n.has(s)||s.withChildren().forEach((function(t){i.push(t),n.add(t)}));this.isConnected=!1,n.size>=this.nodes.length&&(e=0,n.forEach((function(i){i.owner==t&&e++})),e==this.nodes.length)&&(this.isConnected=!0)}},t.exports=d},function(t,e,i){var n,r=i(1);function o(t){n=i(5),this.layout=t,this.graphs=[],this.edges=[]}o.prototype.addRoot=function(){var t=this.layout.newGraph(),e=this.layout.newNode(null);return t=this.add(t,e),this.setRootGraph(t),this.rootGraph},o.prototype.add=function(t,e,i,n,r){if(null==i&&null==n&&null==r){if(null==t)throw"Graph is null!";if(null==e)throw"Parent node is null!";if(-1<this.graphs.indexOf(t))throw"Graph already in this graph mgr!";if(this.graphs.push(t),null!=t.parent)throw"Already has a parent!";if(null!=e.child)throw"Already has a child!";return(t.parent=e).child=t}if(r=i,i=t,t=(n=e).getOwner(),e=r.getOwner(),null==t||t.getGraphManager()!=this)throw"Source not in this graph mgr!";if(null==e||e.getGraphManager()!=this)throw"Target not in this graph mgr!";if(t==e)return i.isInterGraph=!1,t.add(i,n,r);if(i.isInterGraph=!0,i.source=n,i.target=r,-1<this.edges.indexOf(i))throw"Edge already in inter-graph edge list!";if(this.edges.push(i),null==i.source||null==i.target)throw"Edge source and/or target is null!";if(-1!=i.source.edges.indexOf(i)||-1!=i.target.edges.indexOf(i))throw"Edge already in source and/or target incidency list!";return i.source.edges.push(i),i.target.edges.push(i),i},o.prototype.remove=function(t){if(t instanceof n){var e=t;if(e.getGraphManager()!=this)throw"Graph not in this graph mgr";if(e!=this.rootGraph&&(null==e.parent||e.parent.graphManager!=this))throw"Invalid parent node!";for(var i,o=[],s=(o=o.concat(e.getEdges())).length,a=0;a<s;a++)i=o[a],e.remove(i);var h,l=[];for(s=(l=l.concat(e.getNodes())).length,a=0;a<s;a++)h=l[a],e.remove(h);e==this.rootGraph&&this.setRootGraph(null);var g=this.graphs.indexOf(e);this.graphs.splice(g,1),e.parent=null}else if(t instanceof r){if(null==(i=t))throw"Edge is null!";if(!i.isInterGraph)throw"Not an inter-graph edge!";if(null==i.source||null==i.target)throw"Source and/or target is null!";if(-1==i.source.edges.indexOf(i)||-1==i.target.edges.indexOf(i))throw"Source and/or target doesn't know this edge!";if(g=i.source.edges.indexOf(i),i.source.edges.splice(g,1),g=i.target.edges.indexOf(i),i.target.edges.splice(g,1),null==i.source.owner||null==i.source.owner.getGraphManager())throw"Edge owner graph or owner graph manager is null!";if(-1==i.source.owner.getGraphManager().edges.indexOf(i))throw"Not in owner graph manager's edge list!";g=i.source.owner.getGraphManager().edges.indexOf(i),i.source.owner.getGraphManager().edges.splice(g,1)}},o.prototype.updateBounds=function(){this.rootGraph.updateBounds(!0)},o.prototype.getGraphs=function(){return this.graphs},o.prototype.getAllNodes=function(){if(null==this.allNodes){for(var t=[],e=this.getGraphs(),i=e.length,n=0;n<i;n++)t=t.concat(e[n].getNodes());this.allNodes=t}return this.allNodes},o.prototype.resetAllNodes=function(){this.allNodes=null},o.prototype.resetAllEdges=function(){this.allEdges=null},o.prototype.resetAllNodesToApplyGravitation=function(){this.allNodesToApplyGravitation=null},o.prototype.getAllEdges=function(){if(null==this.allEdges){var t=[],e=this.getGraphs();e.length;for(var i=0;i<e.length;i++)t=t.concat(e[i].getEdges());t=t.concat(this.edges),this.allEdges=t}return this.allEdges},o.prototype.getAllNodesToApplyGravitation=function(){return this.allNodesToApplyGravitation},o.prototype.setAllNodesToApplyGravitation=function(t){if(null!=this.allNodesToApplyGravitation)throw"assert failed";this.allNodesToApplyGravitation=t},o.prototype.getRoot=function(){return this.rootGraph},o.prototype.setRootGraph=function(t){if(t.getGraphManager()!=this)throw"Root not in this graph mgr!";null==(this.rootGraph=t).parent&&(t.parent=this.layout.newNode("Root node"))},o.prototype.getLayout=function(){return this.layout},o.prototype.isOneAncestorOfOther=function(t,e){if(null==t||null==e)throw"assert failed";if(t==e)return!0;for(var i,n=t.getOwner();null!=(i=n.getParent());){if(i==e)return!0;if(null==(n=i.getOwner()))break}for(n=e.getOwner();null!=(i=n.getParent());){if(i==t)return!0;if(null==(n=i.getOwner()))break}return!1},o.prototype.calcLowestCommonAncestors=function(){for(var t,e,i,n,r,o=this.getAllEdges(),s=o.length,a=0;a<s;a++)if(e=(t=o[a]).source,i=t.target,t.lca=null,(t.sourceInLca=e)==(t.targetInLca=i))t.lca=e.getOwner();else{for(n=e.getOwner();null==t.lca;){for(r=(t.targetInLca=i).getOwner();null==t.lca;){if(r==n){t.lca=r;break}if(r==this.rootGraph)break;if(null!=t.lca)throw"assert failed";t.targetInLca=r.getParent(),r=t.targetInLca.getOwner()}if(n==this.rootGraph)break;null==t.lca&&(t.sourceInLca=n.getParent(),n=t.sourceInLca.getOwner())}if(null==t.lca)throw"assert failed"}},o.prototype.calcLowestCommonAncestor=function(t,e){if(t==e)return t.getOwner();for(var i=t.getOwner();null!=i;){for(var n=e.getOwner();null!=n;){if(n==i)return n;n=n.getParent().getOwner()}i=i.getParent().getOwner()}return i},o.prototype.calcInclusionTreeDepths=function(t,e){null==t&&null==e&&(t=this.rootGraph,e=1);for(var i,n=t.getNodes(),r=n.length,o=0;o<r;o++)(i=n[o]).inclusionTreeDepth=e,null!=i.child&&this.calcInclusionTreeDepths(i.child,e+1)},o.prototype.includesInvalidEdge=function(){for(var t,e=this.edges.length,i=0;i<e;i++)if(t=this.edges[i],this.isOneAncestorOfOther(t.source,t.target))return!0;return!1},t.exports=o},function(t,e,i){var n,r=i(0);function o(){}for(n in r)o[n]=r[n];o.MAX_ITERATIONS=2500,o.DEFAULT_EDGE_LENGTH=50,o.DEFAULT_SPRING_STRENGTH=.45,o.DEFAULT_REPULSION_STRENGTH=4500,o.DEFAULT_GRAVITY_STRENGTH=.4,o.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,o.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,o.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,o.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,o.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,o.DEFAULT_COOLING_FACTOR_INCREMENTAL=.3,o.COOLING_ADAPTATION_FACTOR=.33,o.ADAPTATION_LOWER_NODE_LIMIT=1e3,o.ADAPTATION_UPPER_NODE_LIMIT=5e3,o.MAX_NODE_DISPLACEMENT=3*(o.MAX_NODE_DISPLACEMENT_INCREMENTAL=100),o.MIN_REPULSION_DIST=o.DEFAULT_EDGE_LENGTH/10,o.CONVERGENCE_CHECK_PERIOD=100,o.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=.1,o.MIN_EDGE_LENGTH=1,o.GRID_CALCULATION_CHECK_PERIOD=10,t.exports=o},function(t,e,i){var n=i(12);function r(){}r.calcSeparationAmount=function(t,e,i,n){if(!t.intersects(e))throw"assert failed";var r=new Array(2),o=(this.decideDirectionsForOverlappingNodes(t,e,r),i[0]=Math.min(t.getRight(),e.getRight())-Math.max(t.x,e.x),i[1]=Math.min(t.getBottom(),e.getBottom())-Math.max(t.y,e.y),t.getX()<=e.getX()&&t.getRight()>=e.getRight()?i[0]+=Math.min(e.getX()-t.getX(),t.getRight()-e.getRight()):e.getX()<=t.getX()&&e.getRight()>=t.getRight()&&(i[0]+=Math.min(t.getX()-e.getX(),e.getRight()-t.getRight())),t.getY()<=e.getY()&&t.getBottom()>=e.getBottom()?i[1]+=Math.min(e.getY()-t.getY(),t.getBottom()-e.getBottom()):e.getY()<=t.getY()&&e.getBottom()>=t.getBottom()&&(i[1]+=Math.min(t.getY()-e.getY(),e.getBottom()-t.getBottom())),Math.abs((e.getCenterY()-t.getCenterY())/(e.getCenterX()-t.getCenterX())));e=(o=e.getCenterY()===t.getCenterY()&&e.getCenterX()===t.getCenterX()?1:o)*i[0],t=i[1]/o,i[0]<t?t=i[0]:e=i[1],i[0]=-1*r[0]*(t/2+n),i[1]=-1*r[1]*(e/2+n)},r.decideDirectionsForOverlappingNodes=function(t,e,i){t.getCenterX()<e.getCenterX()?i[0]=-1:i[0]=1,t.getCenterY()<e.getCenterY()?i[1]=-1:i[1]=1},r.getIntersection2=function(t,e,i){var n=t.getCenterX(),r=t.getCenterY(),o=e.getCenterX(),s=e.getCenterY();if(t.intersects(e))return i[0]=n,i[1]=r,i[2]=o,i[3]=s,!0;var a=t.getX(),h=t.getY(),l=t.getRight(),g=t.getX(),u=t.getBottom(),c=t.getRight(),d=t.getWidthHalf(),p=t.getHeightHalf(),f=e.getX(),y=e.getY(),E=e.getRight(),A=e.getX(),N=e.getBottom(),T=e.getRight(),L=e.getWidthHalf(),_=e.getHeightHalf(),v=!1,m=!1;if(n===o){if(s<r)return i[0]=n,i[1]=h,i[2]=o,i[3]=N,!1;r<s&&(i[0]=n,i[1]=u,i[2]=o,i[3]=y)}else if(r===s){if(o<n)return i[0]=a,i[1]=r,i[2]=E,i[3]=s,!1;n<o&&(i[0]=l,i[1]=r,i[2]=f,i[3]=s)}else{t=t.height/t.width,e=e.height/e.width;var O,I=(s-r)/(o-n),D=void 0,w=void 0,R=void 0;if(-t==I?(o<n?(i[0]=g,i[1]=u):(i[0]=l,i[1]=h),v=!0):t==I&&(o<n?(i[0]=a,i[1]=h):(i[0]=c,i[1]=u),v=!0),-e==I?(n<o?(i[2]=A,i[3]=N):(i[2]=E,i[3]=y),m=!0):e==I&&(n<o?(i[2]=f,i[3]=y):(i[2]=T,i[3]=N),m=!0),v&&m)return!1;if(O=o<n?s<r?(D=this.getCardinalDirection(t,I,4),this.getCardinalDirection(e,I,2)):(D=this.getCardinalDirection(-t,I,3),this.getCardinalDirection(-e,I,1)):s<r?(D=this.getCardinalDirection(-t,I,1),this.getCardinalDirection(-e,I,3)):(D=this.getCardinalDirection(t,I,2),this.getCardinalDirection(e,I,4)),!v)switch(D){case 1:w=h,i[0]=n+-p/I,i[1]=w;break;case 2:w=r+d*I,i[0]=c,i[1]=w;break;case 3:w=u,i[0]=n+p/I,i[1]=w;break;case 4:w=r+-d*I,i[0]=g,i[1]=w}if(!m)switch(O){case 1:R=y,i[2]=o+-_/I,i[3]=R;break;case 2:R=s+L*I,i[2]=T,i[3]=R;break;case 3:R=N,i[2]=o+_/I,i[3]=R;break;case 4:R=s+-L*I,i[2]=A,i[3]=R}}return!1},r.getCardinalDirection=function(t,e,i){return e<t?i:1+i%4},r.getIntersection=function(t,e,i,r){var o,s,a,h,l,g,u,c,d,p,f;return null==r?this.getIntersection2(t,e,i):(o=t.x,t=t.y,s=e.x,e=e.y,a=i.x,i=i.y,p=u=void 0,0==(f=(l=e-t)*(d=a-(h=r.x))-(c=(r=r.y)-i)*(g=o-s))?null:new n((g*(p=h*i-a*r)-d*(u=s*t-o*e))/f,(c*u-l*p)/f))},r.angleOfVector=function(t,e,i,n){var r=void 0;return t!==i?(r=Math.atan((n-e)/(i-t)),i<t?r+=Math.PI:n<e&&(r+=this.TWO_PI)):r=n<e?this.ONE_AND_HALF_PI:this.HALF_PI,r},r.doIntersect=function(t,e,i,n){var r=t.x,o=(t=t.y,e.x),s=(e=e.y,i.x),a=(i=i.y,n.x),h=(o-r)*((n=n.y)-i)-(a-s)*(e-t);return 0!=h&&(e=((t-e)*(a-r)+(o-r)*(n-t))/h,0<(o=((n-i)*(a-r)+(s-a)*(n-t))/h))&&o<1&&0<e&&e<1},r.HALF_PI=.5*Math.PI,r.ONE_AND_HALF_PI=1.5*Math.PI,r.TWO_PI=2*Math.PI,r.THREE_PI=3*Math.PI,t.exports=r},function(t,e,i){function n(){}n.sign=function(t){return 0<t?1:t<0?-1:0},n.floor=function(t){return t<0?Math.ceil(t):Math.floor(t)},n.ceil=function(t){return t<0?Math.floor(t):Math.ceil(t)},t.exports=n},function(t,e,i){function n(){}n.MAX_VALUE=2147483647,n.MIN_VALUE=-2147483648,t.exports=n},function(t,e,i){function n(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function r(t){return{value:t,next:null,prev:null}}function o(t,e,i,n){return null!==t?t.next=e:n.head=e,null!==i?i.prev=e:n.tail=e,e.prev=t,e.next=i,n.length++,e}function s(t,e){var i=t.prev,n=t.next;return null!==i?i.next=n:e.head=n,null!==n?n.prev=i:e.tail=i,t.prev=t.next=null,e.length--,t}function a(t){var e=this;if(!(this instanceof a))throw new TypeError("Cannot call a class as a function");this.length=0,this.head=null,(this.tail=null)!=t&&t.forEach((function(t){return e.push(t)}))}(function(t,e,i){e&&n(t.prototype,e)})(a,[{key:"size",value:function(){return this.length}},{key:"insertBefore",value:function(t,e){return o(e.prev,r(t),e,this)}},{key:"insertAfter",value:function(t,e){return o(e,r(t),e.next,this)}},{key:"insertNodeBefore",value:function(t,e){return o(e.prev,t,e,this)}},{key:"insertNodeAfter",value:function(t,e){return o(e,t,e.next,this)}},{key:"push",value:function(t){return o(this.tail,r(t),null,this)}},{key:"unshift",value:function(t){return o(null,r(t),this.head,this)}},{key:"remove",value:function(t){return s(t,this)}},{key:"pop",value:function(){return s(this.tail,this).value}},{key:"popNode",value:function(){return s(this.tail,this)}},{key:"shift",value:function(){return s(this.head,this).value}},{key:"shiftNode",value:function(){return s(this.head,this)}},{key:"get_object_at",value:function(t){if(t<=this.length()){for(var e=1,i=this.head;e<t;)i=i.next,e++;return i.value}}},{key:"set_object_at",value:function(t,e){if(t<=this.length()){for(var i=1,n=this.head;i<t;)n=n.next,i++;n.value=e}}}]),t.exports=a},function(t,e,i){function n(t,e,i){this.x=null,(this.y=null)==t&&null==e&&null==i?(this.x=0,this.y=0):"number"==typeof t&&"number"==typeof e&&null==i?(this.x=t,this.y=e):"Point"==t.constructor.name&&null==e&&null==i&&(this.x=(i=t).x,this.y=i.y)}n.prototype.getX=function(){return this.x},n.prototype.getY=function(){return this.y},n.prototype.getLocation=function(){return new n(this.x,this.y)},n.prototype.setLocation=function(t,e,i){"Point"==t.constructor.name&&null==e&&null==i?this.setLocation((i=t).x,i.y):"number"==typeof t&&"number"==typeof e&&null==i&&(parseInt(t)==t&&parseInt(e)==e?this.move(t,e):(this.x=Math.floor(t+.5),this.y=Math.floor(e+.5)))},n.prototype.move=function(t,e){this.x=t,this.y=e},n.prototype.translate=function(t,e){this.x+=t,this.y+=e},n.prototype.equals=function(t){return"Point"==t.constructor.name?this.x==t.x&&this.y==t.y:this==t},n.prototype.toString=function(){return(new n).constructor.name+"[x="+this.x+",y="+this.y+"]"},t.exports=n},function(t,e,i){function n(t,e,i,n){this.x=0,this.y=0,this.width=0,this.height=0,null!=t&&null!=e&&null!=i&&null!=n&&(this.x=t,this.y=e,this.width=i,this.height=n)}n.prototype.getX=function(){return this.x},n.prototype.setX=function(t){this.x=t},n.prototype.getY=function(){return this.y},n.prototype.setY=function(t){this.y=t},n.prototype.getWidth=function(){return this.width},n.prototype.setWidth=function(t){this.width=t},n.prototype.getHeight=function(){return this.height},n.prototype.setHeight=function(t){this.height=t},n.prototype.getRight=function(){return this.x+this.width},n.prototype.getBottom=function(){return this.y+this.height},n.prototype.intersects=function(t){return!(this.getRight()<t.x||this.getBottom()<t.y||t.getRight()<this.x||t.getBottom()<this.y)},n.prototype.getCenterX=function(){return this.x+this.width/2},n.prototype.getMinX=function(){return this.getX()},n.prototype.getMaxX=function(){return this.getX()+this.width},n.prototype.getCenterY=function(){return this.y+this.height/2},n.prototype.getMinY=function(){return this.getY()},n.prototype.getMaxY=function(){return this.getY()+this.height},n.prototype.getWidthHalf=function(){return this.width/2},n.prototype.getHeightHalf=function(){return this.height/2},t.exports=n},function(t,e,i){var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};function r(){}r.lastID=0,r.createID=function(t){return r.isPrimitive(t)?t:(null==t.uniqueID&&(t.uniqueID=r.getString(),r.lastID++),t.uniqueID)},r.getString=function(t){return"Object#"+(null==t?r.lastID:t)},r.isPrimitive=function(t){var e=void 0===t?"undefined":n(t);return null==t||"object"!=e&&"function"!=e},t.exports=r},function(t,e,i){function n(t){if(Array.isArray(t)){for(var e=0,i=Array(t.length);e<t.length;e++)i[e]=t[e];return i}return Array.from(t)}var r=i(0),o=i(6),s=i(3),a=i(1),h=i(5),l=i(4),g=i(17),u=i(27);function c(t){u.call(this),this.layoutQuality=r.QUALITY,this.createBendsAsNeeded=r.DEFAULT_CREATE_BENDS_AS_NEEDED,this.incremental=r.DEFAULT_INCREMENTAL,this.animationOnLayout=r.DEFAULT_ANIMATION_ON_LAYOUT,this.animationDuringLayout=r.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=r.DEFAULT_ANIMATION_PERIOD,this.uniformLeafNodeSizes=r.DEFAULT_UNIFORM_LEAF_NODE_SIZES,this.edgeToDummyNodes=new Map,this.graphManager=new o(this),this.isLayoutFinished=!1,this.isSubLayout=!1,this.isRemoteUse=!1,null!=t&&(this.isRemoteUse=t)}c.RANDOM_SEED=1,(c.prototype=Object.create(u.prototype)).getGraphManager=function(){return this.graphManager},c.prototype.getAllNodes=function(){return this.graphManager.getAllNodes()},c.prototype.getAllEdges=function(){return this.graphManager.getAllEdges()},c.prototype.getAllNodesToApplyGravitation=function(){return this.graphManager.getAllNodesToApplyGravitation()},c.prototype.newGraphManager=function(){var t=new o(this);return this.graphManager=t},c.prototype.newGraph=function(t){return new h(null,this.graphManager,t)},c.prototype.newNode=function(t){return new s(this.graphManager,t)},c.prototype.newEdge=function(t){return new a(null,null,t)},c.prototype.checkLayoutSuccess=function(){return null==this.graphManager.getRoot()||0==this.graphManager.getRoot().getNodes().length||this.graphManager.includesInvalidEdge()},c.prototype.runLayout=function(){var t;return this.isLayoutFinished=!1,this.tilingPreLayout&&this.tilingPreLayout(),this.initParameters(),t=!this.checkLayoutSuccess()&&this.layout(),"during"!==r.ANIMATE&&(t&&!this.isSubLayout&&this.doPostLayout(),this.tilingPostLayout&&this.tilingPostLayout(),this.isLayoutFinished=!0,t)},c.prototype.doPostLayout=function(){this.incremental||this.transform(),this.update()},c.prototype.update2=function(){if(this.createBendsAsNeeded&&(this.createBendpointsFromDummyNodes(),this.graphManager.resetAllEdges()),!this.isRemoteUse){for(var t=this.graphManager.getAllEdges(),e=0;e<t.length;e++)t[e];var i=this.graphManager.getRoot().getNodes();for(e=0;e<i.length;e++)i[e];this.update(this.graphManager.getRoot())}},c.prototype.update=function(t){if(null==t)this.update2();else if(t instanceof s){var e=t;if(null!=e.getChild())for(var i=e.getChild().getNodes(),n=0;n<i.length;n++)update(i[n]);null!=e.vGraphObject&&e.vGraphObject.update(e)}else t instanceof a?null!=t.vGraphObject&&t.vGraphObject.update(t):t instanceof h&&null!=t.vGraphObject&&t.vGraphObject.update(t)},c.prototype.initParameters=function(){this.isSubLayout||(this.layoutQuality=r.QUALITY,this.animationDuringLayout=r.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=r.DEFAULT_ANIMATION_PERIOD,this.animationOnLayout=r.DEFAULT_ANIMATION_ON_LAYOUT,this.incremental=r.DEFAULT_INCREMENTAL,this.createBendsAsNeeded=r.DEFAULT_CREATE_BENDS_AS_NEEDED,this.uniformLeafNodeSizes=r.DEFAULT_UNIFORM_LEAF_NODE_SIZES),this.animationDuringLayout&&(this.animationOnLayout=!1)},c.prototype.transform=function(t){if(null==t)this.transform(new l(0,0));else{var e=new g,i=this.graphManager.getRoot().updateLeftTop();if(null!=i){e.setWorldOrgX(t.x),e.setWorldOrgY(t.y),e.setDeviceOrgX(i.x),e.setDeviceOrgY(i.y);for(var n=this.getAllNodes(),r=0;r<n.length;r++)n[r].transform(e)}}},c.prototype.positionNodesRandomly=function(t){if(null==t)this.positionNodesRandomly(this.getGraphManager().getRoot()),this.getGraphManager().getRoot().updateBounds(!0);else for(var e,i,n=t.getNodes(),r=0;r<n.length;r++)null==(i=(e=n[r]).getChild())||0==i.getNodes().length?e.scatter():(this.positionNodesRandomly(i),e.updateBounds())},c.prototype.getFlatForest=function(){for(var t=[],e=!0,i=this.graphManager.getRoot().getNodes(),r=!0,o=0;o<i.length;o++)null!=i[o].getChild()&&(r=!1);if(r)for(var s=new Set,a=[],h=new Map,l=(l=[]).concat(i);0<l.length&&e;){for(a.push(l[0]);0<a.length&&e;){var g=a[0],u=(a.splice(0,1),s.add(g),g.getEdges());for(o=0;o<u.length;o++){var c=u[o].getOtherEnd(g);if(h.get(g)!=c){if(s.has(c)){e=!1;break}a.push(c),h.set(c,g)}}}if(e){var d=[].concat(n(s));for(t.push(d),o=0;o<d.length;o++){var p=d[o];-1<(p=l.indexOf(p))&&l.splice(p,1)}s=new Set,h=new Map}else t=[]}return t},c.prototype.createDummyNodesForBendpoints=function(t){for(var e=[],i=t.source,n=this.graphManager.calcLowestCommonAncestor(t.source,t.target),r=0;r<t.bendpoints.length;r++){var o=this.newNode(null),s=(o.setRect(new Point(0,0),new Dimension(1,1)),n.add(o),this.newEdge(null));this.graphManager.add(s,i,o),e.add(o),i=o}return s=this.newEdge(null),this.graphManager.add(s,i,t.target),this.edgeToDummyNodes.set(t,e),(t.isInterGraph()?this.graphManager:n).remove(t),e},c.prototype.createBendpointsFromDummyNodes=function(){var t=(t=[]).concat(this.graphManager.getAllEdges());t=[].concat(n(this.edgeToDummyNodes.keys())).concat(t);for(var e=0;e<t.length;e++){var i=t[e];if(0<i.bendpoints.length){for(var r=this.edgeToDummyNodes.get(i),o=0;o<r.length;o++){var s=r[o],a=new l(s.getCenterX(),s.getCenterY()),h=i.bendpoints.get(o);h.x=a.x,h.y=a.y,s.getOwner().remove(s)}this.graphManager.add(i,i.source,i.target)}}},c.transform=function(t,e,i,n){var r,o;return null!=i&&null!=n?(r=e,t<=50?r-=(e-e/i)/50*(50-t):r+=(e*n-e)/50*(t-50),r):(i=t<=50?(o=9*e/500,e/10):(o=9*e/50,-8*e),o*t+i)},c.findCenterOfTree=function(t){var e=(e=[]).concat(t),i=[],n=new Map,r=!1,o=null;1!=e.length&&2!=e.length||(r=!0,o=e[0]);for(var s=0;s<e.length;s++){var a=(l=e[s]).getNeighborsList().size;n.set(l,l.getNeighborsList().size),1==a&&i.push(l)}for(h=(h=[]).concat(i);!r;){[].concat(h);var h=[];for(s=0;s<e.length;s++){var l=e[s],g=e.indexOf(l);0<=g&&e.splice(g,1),l.getNeighborsList().forEach((function(t){var e;i.indexOf(t)<0&&(1==(e=n.get(t)-1)&&h.push(t),n.set(t,e))}))}i=i.concat(h),1!=e.length&&2!=e.length||(r=!0,o=e[0])}return o},c.prototype.setGraphManager=function(t){this.graphManager=t},t.exports=c},function(t,e,i){function n(){}n.seed=1,n.x=0,n.nextDouble=function(){return(n.x=1e4*Math.sin(n.seed++))-Math.floor(n.x)},t.exports=n},function(t,e,i){var n=i(4);function r(t,e){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}r.prototype.getWorldOrgX=function(){return this.lworldOrgX},r.prototype.setWorldOrgX=function(t){this.lworldOrgX=t},r.prototype.getWorldOrgY=function(){return this.lworldOrgY},r.prototype.setWorldOrgY=function(t){this.lworldOrgY=t},r.prototype.getWorldExtX=function(){return this.lworldExtX},r.prototype.setWorldExtX=function(t){this.lworldExtX=t},r.prototype.getWorldExtY=function(){return this.lworldExtY},r.prototype.setWorldExtY=function(t){this.lworldExtY=t},r.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},r.prototype.setDeviceOrgX=function(t){this.ldeviceOrgX=t},r.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},r.prototype.setDeviceOrgY=function(t){this.ldeviceOrgY=t},r.prototype.getDeviceExtX=function(){return this.ldeviceExtX},r.prototype.setDeviceExtX=function(t){this.ldeviceExtX=t},r.prototype.getDeviceExtY=function(){return this.ldeviceExtY},r.prototype.setDeviceExtY=function(t){this.ldeviceExtY=t},r.prototype.transformX=function(t){var e=0,i=this.lworldExtX;return 0!=i?this.ldeviceOrgX+(t-this.lworldOrgX)*this.ldeviceExtX/i:e},r.prototype.transformY=function(t){var e=0,i=this.lworldExtY;return 0!=i?this.ldeviceOrgY+(t-this.lworldOrgY)*this.ldeviceExtY/i:e},r.prototype.inverseTransformX=function(t){var e=0,i=this.ldeviceExtX;return 0!=i?this.lworldOrgX+(t-this.ldeviceOrgX)*this.lworldExtX/i:e},r.prototype.inverseTransformY=function(t){var e=0,i=this.ldeviceExtY;return 0!=i?this.lworldOrgY+(t-this.ldeviceOrgY)*this.lworldExtY/i:e},r.prototype.inverseTransformPoint=function(t){return new n(this.inverseTransformX(t.x),this.inverseTransformY(t.y))},t.exports=r},function(t,e,i){var n,r=i(15),o=i(7),s=i(0),a=i(8),h=i(9);function l(){r.call(this),this.useSmartIdealEdgeLengthCalculation=o.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.idealEdgeLength=o.DEFAULT_EDGE_LENGTH,this.springConstant=o.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=o.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=o.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=o.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=o.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=o.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.displacementThresholdPerNode=3*o.DEFAULT_EDGE_LENGTH/100,this.coolingFactor=o.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.initialCoolingFactor=o.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.totalDisplacement=0,this.oldTotalDisplacement=0,this.maxIterations=o.MAX_ITERATIONS}for(n in l.prototype=Object.create(r.prototype),r)l[n]=r[n];l.prototype.initParameters=function(){r.prototype.initParameters.call(this,arguments),this.totalIterations=0,this.notAnimatedIterations=0,this.useFRGridVariant=o.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION,this.grid=[]},l.prototype.calcIdealEdgeLengths=function(){for(var t,e,i,n,r,a=this.getGraphManager().getAllEdges(),h=0;h<a.length;h++)(t=a[h]).idealLength=this.idealEdgeLength,t.isInterGraph&&(e=t.getSource(),i=t.getTarget(),n=t.getSourceInLca().getEstimatedSize(),r=t.getTargetInLca().getEstimatedSize(),this.useSmartIdealEdgeLengthCalculation&&(t.idealLength+=n+r-2*s.SIMPLE_NODE_SIZE),n=t.getLca().getInclusionTreeDepth(),t.idealLength+=o.DEFAULT_EDGE_LENGTH*o.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR*(e.getInclusionTreeDepth()+i.getInclusionTreeDepth()-2*n))},l.prototype.initSpringEmbedder=function(){var t=this.getAllNodes().length;this.incremental?(t>o.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*o.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(t-o.ADAPTATION_LOWER_NODE_LIMIT)/(o.ADAPTATION_UPPER_NODE_LIMIT-o.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-o.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=o.MAX_NODE_DISPLACEMENT_INCREMENTAL):(t>o.ADAPTATION_LOWER_NODE_LIMIT?this.coolingFactor=Math.max(o.COOLING_ADAPTATION_FACTOR,1-(t-o.ADAPTATION_LOWER_NODE_LIMIT)/(o.ADAPTATION_UPPER_NODE_LIMIT-o.ADAPTATION_LOWER_NODE_LIMIT)*(1-o.COOLING_ADAPTATION_FACTOR)):this.coolingFactor=1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=o.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(5*this.getAllNodes().length,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},l.prototype.calcSpringForces=function(){for(var t,e=this.getAllEdges(),i=0;i<e.length;i++)t=e[i],this.calcSpringForce(t,t.idealLength)},l.prototype.calcRepulsionForces=function(){var t,e,i,n,r,s=!(0<arguments.length&&void 0!==arguments[0])||arguments[0],a=1<arguments.length&&void 0!==arguments[1]&&arguments[1],h=this.getAllNodes();if(this.useFRGridVariant)for(this.totalIterations%o.GRID_CALCULATION_CHECK_PERIOD==1&&s&&this.updateGrid(),r=new Set,t=0;t<h.length;t++)i=h[t],this.calculateRepulsionForceOfANode(i,r,s,a),r.add(i);else for(t=0;t<h.length;t++)for(i=h[t],e=t+1;e<h.length;e++)n=h[e],i.getOwner()==n.getOwner()&&this.calcRepulsionForce(i,n)},l.prototype.calcGravitationalForces=function(){for(var t,e=this.getAllNodesToApplyGravitation(),i=0;i<e.length;i++)t=e[i],this.calcGravitationalForce(t)},l.prototype.moveNodes=function(){for(var t=this.getAllNodes(),e=0;e<t.length;e++)t[e].move()},l.prototype.calcSpringForce=function(t,e){var i,n,r=t.getSource(),o=t.getTarget();if(this.uniformLeafNodeSizes&&null==r.getChild()&&null==o.getChild())t.updateLengthSimple();else if(t.updateLength(),t.isOverlapingSourceAndTarget)return;0!=(i=t.getLength())&&(n=(e=this.springConstant*(i-e))*(t.lengthX/i),e*=t.lengthY/i,r.springForceX+=n,r.springForceY+=e,o.springForceX-=n,o.springForceY-=e)},l.prototype.calcRepulsionForce=function(t,e){var i,n,r,s=t.getRect(),l=e.getRect(),g=new Array(2),u=new Array(4);s.intersects(l)?(a.calcSeparationAmount(s,l,g,o.DEFAULT_EDGE_LENGTH/2),n=2*g[0],r=2*g[1],g=t.noOfChildren*e.noOfChildren/(t.noOfChildren+e.noOfChildren),t.repulsionForceX-=g*n,t.repulsionForceY-=g*r,e.repulsionForceX+=g*n,e.repulsionForceY+=g*r):(g=this.uniformLeafNodeSizes&&null==t.getChild()&&null==e.getChild()?(i=l.getCenterX()-s.getCenterX(),l.getCenterY()-s.getCenterY()):(a.getIntersection(s,l,u),i=u[2]-u[0],u[3]-u[1]),s=(i=Math.abs(i)<o.MIN_REPULSION_DIST?h.sign(i)*o.MIN_REPULSION_DIST:i)*i+(g=Math.abs(g)<o.MIN_REPULSION_DIST?h.sign(g)*o.MIN_REPULSION_DIST:g)*g,l=Math.sqrt(s),r=(u=this.repulsionConstant*t.noOfChildren*e.noOfChildren/s)*g/l,t.repulsionForceX-=n=u*i/l,t.repulsionForceY-=r,e.repulsionForceX+=n,e.repulsionForceY+=r)},l.prototype.calcGravitationalForce=function(t){var e,i=t.getOwner(),n=(i.getRight()+i.getLeft())/2,r=(i.getTop()+i.getBottom())/2,o=(n=t.getCenterX()-n,r=t.getCenterY()-r,Math.abs(n)+t.getWidth()/2),s=Math.abs(r)+t.getHeight()/2;t.getOwner()==this.graphManager.getRoot()?((e=i.getEstimatedSize()*this.gravityRangeFactor)<o||e<s)&&(t.gravitationForceX=-this.gravityConstant*n,t.gravitationForceY=-this.gravityConstant*r):((e=i.getEstimatedSize()*this.compoundGravityRangeFactor)<o||e<s)&&(t.gravitationForceX=-this.gravityConstant*n*this.compoundGravityConstant,t.gravitationForceY=-this.gravityConstant*r*this.compoundGravityConstant)},l.prototype.isConverged=function(){var t,e=!1;return this.totalIterations>this.maxIterations/3&&(e=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),t=this.totalDisplacement<this.totalDisplacementThreshold,this.oldTotalDisplacement=this.totalDisplacement,t||e},l.prototype.animate=function(){this.animationDuringLayout&&!this.isSubLayout&&(this.notAnimatedIterations==this.animationPeriod?(this.update(),this.notAnimatedIterations=0):this.notAnimatedIterations++)},l.prototype.calcNoOfChildrenForAllNodes=function(){for(var t,e=this.graphManager.getAllNodes(),i=0;i<e.length;i++)(t=e[i]).noOfChildren=t.getNoOfChildren()},l.prototype.calcGrid=function(t){for(var e=parseInt(Math.ceil((t.getRight()-t.getLeft())/this.repulsionRange)),i=parseInt(Math.ceil((t.getBottom()-t.getTop())/this.repulsionRange)),n=new Array(e),r=0;r<e;r++)n[r]=new Array(i);for(r=0;r<e;r++)for(var o=0;o<i;o++)n[r][o]=new Array;return n},l.prototype.addNodeToGrid=function(t,e,i){for(var n=parseInt(Math.floor((t.getRect().x-e)/this.repulsionRange)),r=parseInt(Math.floor((t.getRect().width+t.getRect().x-e)/this.repulsionRange)),o=parseInt(Math.floor((t.getRect().y-i)/this.repulsionRange)),s=parseInt(Math.floor((t.getRect().height+t.getRect().y-i)/this.repulsionRange)),a=n;a<=r;a++)for(var h=o;h<=s;h++)this.grid[a][h].push(t),t.setGridCoordinates(n,r,o,s)},l.prototype.updateGrid=function(){var t,e,i=this.getAllNodes();for(this.grid=this.calcGrid(this.graphManager.getRoot()),t=0;t<i.length;t++)e=i[t],this.addNodeToGrid(e,this.graphManager.getRoot().getLeft(),this.graphManager.getRoot().getTop())},l.prototype.calculateRepulsionForceOfANode=function(t,e,i,n){if(this.totalIterations%o.GRID_CALCULATION_CHECK_PERIOD==1&&i||n){for(var r=new Set,s=(t.surrounding=new Array,this.grid),a=t.startX-1;a<t.finishX+2;a++)for(var h=t.startY-1;h<t.finishY+2;h++)if(!(a<0||h<0||a>=s.length||h>=s[0].length))for(var l=0;l<s[a][h].length;l++){var g,u,c=s[a][h][l];t.getOwner()!=c.getOwner()||t==c||e.has(c)||r.has(c)||(g=Math.abs(t.getCenterX()-c.getCenterX())-(t.getWidth()/2+c.getWidth()/2),u=Math.abs(t.getCenterY()-c.getCenterY())-(t.getHeight()/2+c.getHeight()/2),g<=this.repulsionRange&&u<=this.repulsionRange&&r.add(c))}t.surrounding=[].concat(function(t){if(Array.isArray(t)){for(var e=0,i=Array(t.length);e<t.length;e++)i[e]=t[e];return i}return Array.from(t)}(r))}for(a=0;a<t.surrounding.length;a++)this.calcRepulsionForce(t,t.surrounding[a])},l.prototype.calcRepulsionRange=function(){return 0},t.exports=l},function(t,e,i){var n,r=i(1),o=i(7);function s(t,e,i){r.call(this,t,e,i),this.idealLength=o.DEFAULT_EDGE_LENGTH}for(n in s.prototype=Object.create(r.prototype),r)s[n]=r[n];t.exports=s},function(t,e,i){var n,r=i(3);function o(t,e,i,n){r.call(this,t,e,i,n),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0,this.startX=0,this.finishX=0,this.startY=0,this.finishY=0,this.surrounding=[]}for(n in o.prototype=Object.create(r.prototype),r)o[n]=r[n];o.prototype.setGridCoordinates=function(t,e,i,n){this.startX=t,this.finishX=e,this.startY=i,this.finishY=n},t.exports=o},function(t,e,i){function n(t,e){this.width=0,this.height=0,null!==t&&null!==e&&(this.height=e,this.width=t)}n.prototype.getWidth=function(){return this.width},n.prototype.setWidth=function(t){this.width=t},n.prototype.getHeight=function(){return this.height},n.prototype.setHeight=function(t){this.height=t},t.exports=n},function(t,e,i){var n=i(14);function r(){this.map={},this.keys=[]}r.prototype.put=function(t,e){var i=n.createID(t);this.contains(i)||(this.map[i]=e,this.keys.push(t))},r.prototype.contains=function(t){return n.createID(t),null!=this.map[t]},r.prototype.get=function(t){return t=n.createID(t),this.map[t]},r.prototype.keySet=function(){return this.keys},t.exports=r},function(t,e,i){var n=i(14);function r(){this.set={}}r.prototype.add=function(t){var e=n.createID(t);this.contains(e)||(this.set[e]=t)},r.prototype.remove=function(t){delete this.set[n.createID(t)]},r.prototype.clear=function(){this.set={}},r.prototype.contains=function(t){return this.set[n.createID(t)]==t},r.prototype.isEmpty=function(){return 0===this.size()},r.prototype.size=function(){return Object.keys(this.set).length},r.prototype.addAllTo=function(t){for(var e=Object.keys(this.set),i=e.length,n=0;n<i;n++)t.push(this.set[e[n]])},r.prototype.size=function(){return Object.keys(this.set).length},r.prototype.addAll=function(t){for(var e=t.length,i=0;i<e;i++){var n=t[i];this.add(n)}},t.exports=r},function(t,e,i){function n(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var r=i(11);function o(t,e){if(!(this instanceof o))throw new TypeError("Cannot call a class as a function");null===e&&void 0===e||(this.compareFunction=this._defaultCompareFunction),e=void 0,e=t instanceof r?t.size():t.length,this._quicksort(t,0,e-1)}(function(t,e,i){e&&n(t.prototype,e),i&&n(t,i)})(o,[{key:"_quicksort",value:function(t,e,i){var n;e<i&&(n=this._partition(t,e,i),this._quicksort(t,e,n),this._quicksort(t,n+1,i))}},{key:"_partition",value:function(t,e,i){for(var n=this._get(t,e),r=e,o=i;;){for(;this.compareFunction(n,this._get(t,o));)o--;for(;this.compareFunction(this._get(t,r),n);)r++;if(!(r<o))return o;this._swap(t,r,o),r++,o--}}},{key:"_get",value:function(t,e){return t instanceof r?t.get_object_at(e):t[e]}},{key:"_set",value:function(t,e,i){t instanceof r?t.set_object_at(e,i):t[e]=i}},{key:"_swap",value:function(t,e,i){var n=this._get(t,e);this._set(t,e,this._get(t,i)),this._set(t,i,n)}},{key:"_defaultCompareFunction",value:function(t,e){return t<e}}]),i=o,t.exports=i},function(t,e,i){function n(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}!function(t,e,i){e&&n(t.prototype,e)}(o,[{key:"getScore",value:function(){return this.score}},{key:"getAlignments",value:function(){return this.alignments}},{key:"computeGrids",value:function(){for(var t=1;t<this.jMax;t++)this.grid[0][t]=this.grid[0][t-1]+this.gap_penalty,this.tracebackGrid[0][t]=[!1,!1,!0];for(var e=1;e<this.iMax;e++)this.grid[e][0]=this.grid[e-1][0]+this.gap_penalty,this.tracebackGrid[e][0]=[!1,!0,!1];for(var i=1;i<this.iMax;i++)for(var n=1;n<this.jMax;n++){var r=[this.sequence1[i-1]===this.sequence2[n-1]?this.grid[i-1][n-1]+this.match_score:this.grid[i-1][n-1]+this.mismatch_penalty,this.grid[i-1][n]+this.gap_penalty,this.grid[i][n-1]+this.gap_penalty],o=this.arrayAllMaxIndexes(r);this.grid[i][n]=r[o[0]],this.tracebackGrid[i][n]=[o.includes(0),o.includes(1),o.includes(2)]}this.score=this.grid[this.iMax-1][this.jMax-1]}},{key:"alignmentTraceback",value:function(){var t=[];for(t.push({pos:[this.sequence1.length,this.sequence2.length],seq1:"",seq2:""});t[0];){var e=t[0],i=this.tracebackGrid[e.pos[0]][e.pos[1]];i[0]&&t.push({pos:[e.pos[0]-1,e.pos[1]-1],seq1:this.sequence1[e.pos[0]-1]+e.seq1,seq2:this.sequence2[e.pos[1]-1]+e.seq2}),i[1]&&t.push({pos:[e.pos[0]-1,e.pos[1]],seq1:this.sequence1[e.pos[0]-1]+e.seq1,seq2:"-"+e.seq2}),i[2]&&t.push({pos:[e.pos[0],e.pos[1]-1],seq1:"-"+e.seq1,seq2:this.sequence2[e.pos[1]-1]+e.seq2}),0===e.pos[0]&&0===e.pos[1]&&this.alignments.push({sequence1:e.seq1,sequence2:e.seq2}),t.shift()}return this.alignments}},{key:"getAllIndexes",value:function(t,e){for(var i=[],n=-1;-1!==(n=t.indexOf(e,n+1));)i.push(n);return i}},{key:"arrayAllMaxIndexes",value:function(t){return this.getAllIndexes(t,Math.max.apply(null,t))}}]);var r=o;function o(t,e){var i=2<arguments.length&&void 0!==arguments[2]?arguments[2]:1,n=3<arguments.length&&void 0!==arguments[3]?arguments[3]:-1,r=4<arguments.length&&void 0!==arguments[4]?arguments[4]:-1;if(!(this instanceof o))throw new TypeError("Cannot call a class as a function");this.sequence1=t,this.sequence2=e,this.match_score=i,this.mismatch_penalty=n,this.gap_penalty=r,this.iMax=t.length+1,this.jMax=e.length+1,this.grid=new Array(this.iMax);for(var s=0;s<this.iMax;s++){this.grid[s]=new Array(this.jMax);for(var a=0;a<this.jMax;a++)this.grid[s][a]=0}this.tracebackGrid=new Array(this.iMax);for(var h=0;h<this.iMax;h++){this.tracebackGrid[h]=new Array(this.jMax);for(var l=0;l<this.jMax;l++)this.tracebackGrid[h][l]=[null,null,null]}this.alignments=[],this.score=-1,this.computeGrids()}t.exports=r},function(t,e,i){function n(){}n.FDLayout=i(18),n.FDLayoutConstants=i(7),n.FDLayoutEdge=i(19),n.FDLayoutNode=i(20),n.DimensionD=i(21),n.HashMap=i(22),n.HashSet=i(23),n.IGeometry=i(8),n.IMath=i(9),n.Integer=i(10),n.Point=i(12),n.PointD=i(4),n.RandomSeed=i(16),n.RectangleD=i(13),n.Transform=i(17),n.UniqueIDGeneretor=i(14),n.Quicksort=i(24),n.LinkedList=i(11),n.LGraphObject=i(2),n.LGraph=i(5),n.LEdge=i(1),n.LGraphManager=i(6),n.LNode=i(3),n.Layout=i(15),n.LayoutConstants=i(0),n.NeedlemanWunsch=i(25),t.exports=n},function(t,e,i){function n(){this.listeners=[]}var r=n.prototype;r.addListener=function(t,e){this.listeners.push({event:t,callback:e})},r.removeListener=function(t,e){for(var i=this.listeners.length;0<=i;i--){var n=this.listeners[i];n.event===t&&n.callback===e&&this.listeners.splice(i,1)}},r.emit=function(t,e){for(var i=0;i<this.listeners.length;i++){var n=this.listeners[i];t===n.event&&n.callback(e)}},t.exports=n}],i={},t.m=e,t.c=i,t.i=function(t){return t},t.d=function(e,i,n){t.o(e,i)||Object.defineProperty(e,i,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var i=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(i,"a",i),i},t.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},t.p="",t(t.s=26);function t(n){var r;return(i[n]||(r=i[n]={i:n,l:!1,exports:{}},e[n].call(r.exports,r,r.exports,t),r.l=!0,r)).exports}var e,i},u.exports=t()),u.exports}())),g.exports}h=function(t){return i=[function(e,i){e.exports=t},function(t,e,i){var n=i(0).layoutBase.LayoutConstants,r=i(0).layoutBase.FDLayoutConstants,o=i(0).CoSEConstants,s=i(0).CoSELayout,a=i(0).CoSENode,h=i(0).layoutBase.PointD,l=i(0).layoutBase.DimensionD,g={ready:function(){},stop:function(){},quality:"default",nodeDimensionsIncludeLabels:!1,refresh:30,fit:!0,padding:10,randomize:!0,nodeRepulsion:4500,idealEdgeLength:50,edgeElasticity:.45,nestingFactor:.1,gravity:.25,numIter:2500,tile:!0,animate:"end",animationDuration:500,tilingPaddingVertical:10,tilingPaddingHorizontal:10,gravityRangeCompound:1.5,gravityCompound:1,gravityRange:3.8,initialEnergyOnIncremental:.5};function u(t){this.options=function(t,e){var i,n={};for(i in t)n[i]=t[i];for(i in e)n[i]=e[i];return n}(g,t),function(t){null!=t.nodeRepulsion&&(o.DEFAULT_REPULSION_STRENGTH=r.DEFAULT_REPULSION_STRENGTH=t.nodeRepulsion),null!=t.idealEdgeLength&&(o.DEFAULT_EDGE_LENGTH=r.DEFAULT_EDGE_LENGTH=t.idealEdgeLength),null!=t.edgeElasticity&&(o.DEFAULT_SPRING_STRENGTH=r.DEFAULT_SPRING_STRENGTH=t.edgeElasticity),null!=t.nestingFactor&&(o.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=r.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=t.nestingFactor),null!=t.gravity&&(o.DEFAULT_GRAVITY_STRENGTH=r.DEFAULT_GRAVITY_STRENGTH=t.gravity),null!=t.numIter&&(o.MAX_ITERATIONS=r.MAX_ITERATIONS=t.numIter),null!=t.gravityRange&&(o.DEFAULT_GRAVITY_RANGE_FACTOR=r.DEFAULT_GRAVITY_RANGE_FACTOR=t.gravityRange),null!=t.gravityCompound&&(o.DEFAULT_COMPOUND_GRAVITY_STRENGTH=r.DEFAULT_COMPOUND_GRAVITY_STRENGTH=t.gravityCompound),null!=t.gravityRangeCompound&&(o.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=r.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=t.gravityRangeCompound),null!=t.initialEnergyOnIncremental&&(o.DEFAULT_COOLING_FACTOR_INCREMENTAL=r.DEFAULT_COOLING_FACTOR_INCREMENTAL=t.initialEnergyOnIncremental),"draft"==t.quality?n.QUALITY=0:"proof"==t.quality?n.QUALITY=2:n.QUALITY=1,o.NODE_DIMENSIONS_INCLUDE_LABELS=r.NODE_DIMENSIONS_INCLUDE_LABELS=n.NODE_DIMENSIONS_INCLUDE_LABELS=t.nodeDimensionsIncludeLabels,o.DEFAULT_INCREMENTAL=r.DEFAULT_INCREMENTAL=n.DEFAULT_INCREMENTAL=!t.randomize,o.ANIMATE=r.ANIMATE=n.ANIMATE=t.animate,o.TILE=t.tile,o.TILING_PADDING_VERTICAL="function"==typeof t.tilingPaddingVertical?t.tilingPaddingVertical.call():t.tilingPaddingVertical,o.TILING_PADDING_HORIZONTAL="function"==typeof t.tilingPaddingHorizontal?t.tilingPaddingHorizontal.call():t.tilingPaddingHorizontal}(this.options)}function c(t){t("layout","cose-bilkent",u)}u.prototype.run=function(){var t,e,i=this.options,n=(this.idToLNode={},this.layout=new s),r=this,o=(r.stopped=!1,this.cy=this.options.cy,this.cy.trigger({type:"layoutstart",layout:this}),n.newGraphManager()),a=(this.gm=o,this.options.eles.nodes()),h=this.options.eles.edges();this.root=o.addRoot(),this.processChildrenList(this.root,this.getTopMostNodes(a),n);for(var l=0;l<h.length;l++){var g=h[l],u=this.idToLNode[g.data("source")],c=this.idToLNode[g.data("target")];u!==c&&0==u.getEdgesBetween(c).length&&(o.add(n.newEdge(),u,c).id=g.id())}function d(){function o(){i.fit&&i.cy.fit(i.eles,i.padding),t||(t=!0,r.cy.one("layoutready",i.ready),r.cy.trigger({type:"layoutready",layout:r}))}for(var s,a,h=r.options.refresh,l=0;l<h&&!s;l++)s=r.stopped||r.layout.tick();s?(n.checkLayoutSuccess()&&!n.isSubLayout&&n.doPostLayout(),n.tilingPostLayout&&n.tilingPostLayout(),n.isLayoutFinished=!0,r.options.eles.nodes().positions(p),o(),r.cy.one("layoutstop",r.options.stop),r.cy.trigger({type:"layoutstop",layout:r}),e&&cancelAnimationFrame(e),t=!1):(a=r.layout.getPositionsData(),i.eles.nodes().positions((function(t,e){if(!(t="number"==typeof t?e:t).isParent()){for(var i=t.id(),n=a[i],r=t;null==n&&(n=a[r.data("parent")]||a["DummyCompound_"+r.data("parent")],a[i]=n,null!=(r=r.parent()[0])););return null!=n?{x:n.x,y:n.y}:{x:t.position("x"),y:t.position("y")}}})),o(),e=requestAnimationFrame(d))}var p=function(t,e){return e=(t="number"==typeof t?e:t).data("id"),{x:(t=r.idToLNode[e]).getRect().getCenterX(),y:t.getRect().getCenterY()}};return n.addListener("layoutstarted",(function(){"during"===r.options.animate&&(e=requestAnimationFrame(d))})),n.runLayout(),"during"!==this.options.animate&&(r.options.eles.nodes().not(":parent").layoutPositions(r,r.options,p),t=!1),this},u.prototype.getTopMostNodes=function(t){for(var e={},i=0;i<t.length;i++)e[t[i].id()]=!0;return t.filter((function(t,i){for(var n=(t="number"==typeof t?i:t).parent()[0];null!=n;){if(e[n.id()])return!1;n=n.parent()[0]}return!0}))},u.prototype.processChildrenList=function(t,e,i){for(var n=e.length,r=0;r<n;r++){var o,s,g,u=e[r],c=u.children(),d=u.layoutDimensions({nodeDimensionsIncludeLabels:this.options.nodeDimensionsIncludeLabels});(d=null!=u.outerWidth()&&null!=u.outerHeight()?t.add(new a(i.graphManager,new h(u.position("x")-d.w/2,u.position("y")-d.h/2),new l(parseFloat(d.w),parseFloat(d.h)))):t.add(new a(this.graphManager))).id=u.data("id"),d.paddingLeft=parseInt(u.css("padding")),d.paddingTop=parseInt(u.css("padding")),d.paddingRight=parseInt(u.css("padding")),d.paddingBottom=parseInt(u.css("padding")),this.options.nodeDimensionsIncludeLabels&&u.isParent()&&(g=u.boundingBox({includeLabels:!0,includeNodes:!1}).w,o=u.boundingBox({includeLabels:!0,includeNodes:!1}).h,s=u.css("text-halign"),d.labelWidth=g,d.labelHeight=o,d.labelPos=s),this.idToLNode[u.data("id")]=d,isNaN(d.rect.x)&&(d.rect.x=0),isNaN(d.rect.y)&&(d.rect.y=0),null!=c&&0<c.length&&(g=i.getGraphManager().add(i.newGraph(),d),this.processChildrenList(g,c,i))}},u.prototype.stop=function(){return this.stopped=!0,this},"undefined"!=typeof cytoscape&&c(cytoscape),t.exports=c}],n={},e.m=i,e.c=n,e.i=function(t){return t},e.d=function(t,i,n){e.o(t,i)||Object.defineProperty(t,i,{configurable:!1,enumerable:!0,get:n})},e.n=function(t){var i=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(i,"a",i),i},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=1);function e(t){var r;return(n[t]||(r=n[t]={i:t,l:!1,exports:{}},i[t].call(r.exports,r,r.exports,e),r.l=!0,r)).exports}var i,n},l.exports=h(c());var d=e(l.exports);function p(t,e){t.forEach((t=>{const i={id:t.id,labelText:t.label,height:t.height,width:t.width,padding:t.padding??0};Object.keys(t).forEach((e=>{["id","label","height","width","padding","x","y"].includes(e)||(i[e]=t[e])})),e.add({group:"nodes",data:i,position:{x:t.x??0,y:t.y??0}})}))}function f(t,e){t.forEach((t=>{const i={id:t.id,source:t.start,target:t.end};Object.keys(t).forEach((e=>{["id","start","end"].includes(e)||(i[e]=t[e])})),e.add({group:"edges",data:i})}))}function y(t){return new Promise((e=>{var i=n("body").append("div").attr("id","cy").attr("style","display:none");const s=o({container:document.getElementById("cy"),style:[{selector:"edge",style:{"curve-style":"bezier"}}]});i.remove(),p(t.nodes,s),f(t.edges,s),s.nodes().forEach((function(t){t.layoutDimensions=()=>{var e=t.data();return{w:e.width,h:e.height}}})),s.layout({name:"cose-bilkent",quality:"proof",styleEnabled:!1,animate:!1}).run(),s.ready((t=>{r.info("Cytoscape ready",t),e(s)}))}))}function E(t){return t.nodes().map((t=>{const e=t.data();t=t.position();const i={id:e.id,x:t.x,y:t.y};return Object.keys(e).forEach((t=>{"id"!==t&&(i[t]=e[t])})),i}))}function A(t){return t.edges().map((t=>{const e=t.data();t=t._private.rscratch;const i={id:e.id,source:e.source,target:e.target,startX:t.startX,startY:t.startY,midX:t.midX,midY:t.midY,endX:t.endX,endY:t.endY};return Object.keys(e).forEach((t=>{["id","source","target"].includes(t)||(i[t]=e[t])})),i}))}async function N(t,e){r.debug("Starting cose-bilkent layout algorithm");try{T(t);var i=await y(t),n=E(i),o=A(i);return r.debug(`Layout completed: ${n.length} nodes, ${o.length} edges`),{nodes:n,edges:o}}catch(t){throw r.error("Error in cose-bilkent layout algorithm:",t),t}}function T(t){if(!t)throw new Error("Layout data is required");if(!t.config)throw new Error("Configuration is required in layout data");if(!t.rootNode)throw new Error("Root node is required");if(!t.nodes||!Array.isArray(t.nodes))throw new Error("No nodes found in layout data");if(Array.isArray(t.edges))return!0;throw new Error("Edges array is required in layout data")}o.use(d),i(p,"addNodes"),i(f,"addEdges"),i(y,"createCytoscapeInstance"),i(E,"extractPositionedNodes"),i(A,"extractPositionedEdges"),i(N,"executeCoseBilkentLayout"),i(T,"validateLayoutData");var L=i((async(t,e,{insertCluster:i,insertEdge:n,insertEdgeLabel:r,insertMarkers:o,insertNode:s,log:a,positionEdgeLabel:h},{})=>{const l={},g={};o(e=e.select("g"),t.markers,t.type,t.diagramId);const u=e.insert("g").attr("class","subgraphs"),c=e.insert("g").attr("class","edgePaths"),d=e.insert("g").attr("class","edgeLabels"),p=e.insert("g").attr("class","nodes"),f=(a.debug("Inserting nodes into DOM for dimension calculation"),await Promise.all(t.nodes.map((async e=>{var n,r,o;e.isGroup?(n={...e},g[e.id]=n,l[e.id]=n,await i(u,e)):(n={...e},l[e.id]=n,o=(r=await s(p,e,{config:t.config,dir:t.direction||"TB"})).node().getBBox(),n.width=o.width,n.height=o.height,n.domId=r,a.debug(`Node ${e.id} dimensions: ${o.width}x`+o.height))}))),a.debug("Running cose-bilkent layout algorithm"),await N({...t,nodes:t.nodes.map((t=>{var e=l[t.id];return{...t,width:e.width,height:e.height}}))},t.config));a.debug("Positioning nodes based on layout results"),f.nodes.forEach((t=>{var e=l[t.id];e?.domId&&(e.domId.attr("transform",`translate(${t.x}, ${t.y})`),e.x=t.x,e.y=t.y,a.debug(`Positioned node ${e.id} at center (${t.x}, ${t.y})`))})),f.edges.forEach((e=>{var i=t.edges.find((t=>t.id===e.id));i&&(i.points=[{x:e.startX,y:e.startY},{x:e.midX,y:e.midY},{x:e.endX,y:e.endY}])})),a.debug("Inserting and positioning edges"),await Promise.all(t.edges.map((async e=>{await r(d,e);var i,o,s=l[e.start??""],u=l[e.end??""];s&&u&&((i=f.edges.find((t=>t.id===e.id)))?(a.debug("APA01 positionedEdge",i),i={...e},o=n(c,i,g,t.type,s,u,t.diagramId),h(i,o)):(i={...e,points:[{x:s.x||0,y:s.y||0},{x:u.x||0,y:u.y||0}]},o=n(c,i,g,t.type,s,u,t.diagramId),h(i,o)))}))),a.debug("Cose-bilkent rendering completed")}),"render"),_=L;export{_ as render};
|