@glodon-aiot/agent-cli-ui 2.4.7
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/README.git.md +73 -0
- package/README.lib.md +135 -0
- package/dist/es/AgentClientUI.mjs +155 -0
- package/dist/es/Dialog/AgentChat/index.mjs +757 -0
- package/dist/es/Dialog/AgentChat/style.less.mjs +4 -0
- package/dist/es/Dialog/ConnectToNetwork/index.mjs +92 -0
- package/dist/es/Dialog/ConnectToNetwork/style.less.mjs +4 -0
- package/dist/es/Dialog/FileCard/doc-icons/doc.svg.mjs +4 -0
- package/dist/es/Dialog/FileCard/doc-icons/docx.svg.mjs +4 -0
- package/dist/es/Dialog/FileCard/doc-icons/pdf.svg.mjs +4 -0
- package/dist/es/Dialog/FileCard/index.mjs +142 -0
- package/dist/es/Dialog/FileCard/style.less.mjs +4 -0
- package/dist/es/Dialog/FilePreview/index.mjs +90 -0
- package/dist/es/Dialog/FilePreview/style.less.mjs +4 -0
- package/dist/es/Dialog/Greeting/index.mjs +31 -0
- package/dist/es/Dialog/Greeting/style.less.mjs +4 -0
- package/dist/es/Dialog/HistoryContent/index.mjs +14 -0
- package/dist/es/Dialog/HistoryContent/style.less.mjs +4 -0
- package/dist/es/Dialog/HistoryItem/index.mjs +355 -0
- package/dist/es/Dialog/HistoryItem/style.less.mjs +4 -0
- package/dist/es/Dialog/HistoryItem/think.svg.mjs +4 -0
- package/dist/es/Dialog/KnowledgeDoc/index.mjs +46 -0
- package/dist/es/Dialog/KnowledgeDoc/style.less.mjs +4 -0
- package/dist/es/Dialog/KnowledgeList/KnowledgeSelect/index.mjs +68 -0
- package/dist/es/Dialog/KnowledgeList/KnowledgeSelect/style.less.mjs +4 -0
- package/dist/es/Dialog/KnowledgeList/index.mjs +69 -0
- package/dist/es/Dialog/KnowledgeList/style.less.mjs +4 -0
- package/dist/es/Dialog/PromptManager/PromptList/PromptListItem.mjs +89 -0
- package/dist/es/Dialog/PromptManager/PromptList/PublicPromptList.mjs +48 -0
- package/dist/es/Dialog/PromptManager/PromptList/access/empty.svg.mjs +4 -0
- package/dist/es/Dialog/PromptManager/PromptList/style.less.mjs +4 -0
- package/dist/es/Dialog/PromptManager/index.mjs +128 -0
- package/dist/es/Dialog/PromptManager/style.less.mjs +4 -0
- package/dist/es/Dialog/PromptSetting/index.mjs +130 -0
- package/dist/es/Dialog/PromptSetting/style.less.mjs +4 -0
- package/dist/es/Dialog/Recommend/RecommendItem.mjs +96 -0
- package/dist/es/Dialog/Recommend/index.mjs +60 -0
- package/dist/es/Dialog/Recommend/style.less.mjs +4 -0
- package/dist/es/Dialog/Recommend/tip.svg.mjs +4 -0
- package/dist/es/Dialog/ReferCollapse/index.mjs +65 -0
- package/dist/es/Dialog/ReferCollapse/style.less.mjs +4 -0
- package/dist/es/Dialog/SearchReference/index.mjs +64 -0
- package/dist/es/Dialog/SearchReference/style.less.mjs +4 -0
- package/dist/es/Dialog/SessionAction/index.mjs +232 -0
- package/dist/es/Dialog/SessionAction/style.less.mjs +4 -0
- package/dist/es/Dialog/SessionList/index.mjs +197 -0
- package/dist/es/Dialog/SessionList/style.less.mjs +4 -0
- package/dist/es/Dialog/SessionListDrawer/HistorySessionList/NameEditPanel.mjs +48 -0
- package/dist/es/Dialog/SessionListDrawer/HistorySessionList/SessionItem.mjs +142 -0
- package/dist/es/Dialog/SessionListDrawer/HistorySessionList/doc-icons/doc.svg.mjs +4 -0
- package/dist/es/Dialog/SessionListDrawer/HistorySessionList/doc-icons/docx.svg.mjs +4 -0
- package/dist/es/Dialog/SessionListDrawer/HistorySessionList/doc-icons/pdf.svg.mjs +4 -0
- package/dist/es/Dialog/SessionListDrawer/HistorySessionList/index.mjs +120 -0
- package/dist/es/Dialog/SessionListDrawer/HistorySessionList/style.less.mjs +4 -0
- package/dist/es/Dialog/SessionListDrawer/index.mjs +44 -0
- package/dist/es/Dialog/SessionListDrawer/style.less.mjs +4 -0
- package/dist/es/Dialog/SessionRefer/ReferItem/index.mjs +94 -0
- package/dist/es/Dialog/SessionRefer/ReferItem/style.less.mjs +4 -0
- package/dist/es/Dialog/SessionRefer/index.mjs +86 -0
- package/dist/es/Dialog/SessionRefer/style.less.mjs +4 -0
- package/dist/es/Dialog/SessionRelated/index.mjs +43 -0
- package/dist/es/Dialog/SessionRelated/style.less.mjs +4 -0
- package/dist/es/Dialog/UploadKnowledgeFiles/ClearModal/index.mjs +51 -0
- package/dist/es/Dialog/UploadKnowledgeFiles/ClearModal/style.less.mjs +4 -0
- package/dist/es/Dialog/UploadKnowledgeFiles/index.mjs +368 -0
- package/dist/es/Dialog/UploadKnowledgeFiles/style.less.mjs +4 -0
- package/dist/es/Dialog/UploadingPrompt/index.mjs +67 -0
- package/dist/es/Dialog/UploadingPrompt/style.less.mjs +4 -0
- package/dist/es/Dialog/index.mjs +128 -0
- package/dist/es/Dialog/style.less.mjs +4 -0
- package/dist/es/FileCard/doc-icons/doc.svg.mjs +4 -0
- package/dist/es/FileCard/doc-icons/docx.svg.mjs +4 -0
- package/dist/es/FileCard/doc-icons/pdf.svg.mjs +4 -0
- package/dist/es/FileItem/index.mjs +85 -0
- package/dist/es/FileItem/style.less.mjs +4 -0
- package/dist/es/Footer/FooterWarning.mjs +25 -0
- package/dist/es/Footer/index.mjs +18 -0
- package/dist/es/Footer/style.less.mjs +4 -0
- package/dist/es/Iconfont/index.mjs +12 -0
- package/dist/es/InputProgress/index.mjs +39 -0
- package/dist/es/InputProgress/style.less.mjs +4 -0
- package/dist/es/QuillEditor/index.mjs +219 -0
- package/dist/es/QuillEditor/style.less.mjs +4 -0
- package/dist/es/_virtual/_cloneBuffer.mjs +4 -0
- package/dist/es/_virtual/_commonjsHelpers.mjs +8 -0
- package/dist/es/_virtual/_nodeUtil.mjs +4 -0
- package/dist/es/_virtual/index.mjs +4 -0
- package/dist/es/_virtual/index2.mjs +4 -0
- package/dist/es/_virtual/index3.mjs +4 -0
- package/dist/es/_virtual/index4.mjs +4 -0
- package/dist/es/_virtual/isBuffer.mjs +4 -0
- package/dist/es/_virtual/jsx-runtime.mjs +7 -0
- package/dist/es/_virtual/jsx-runtime2.mjs +4 -0
- package/dist/es/_virtual/minio-zj.mjs +4 -0
- package/dist/es/_virtual/react-jsx-runtime.production.min.mjs +4 -0
- package/dist/es/assets/brand.svg.mjs +4 -0
- package/dist/es/assets/icon.svg.mjs +4 -0
- package/dist/es/components/Copy/index.mjs +44 -0
- package/dist/es/components/Copy/style.less.mjs +4 -0
- package/dist/es/components/JsonDisplay/index.mjs +16 -0
- package/dist/es/components/JsonDisplay/style.less.mjs +4 -0
- package/dist/es/components/Markdown/Code/index.mjs +69 -0
- package/dist/es/components/Markdown/Image/index.mjs +26 -0
- package/dist/es/components/Markdown/index.mjs +48 -0
- package/dist/es/components/Markdown/style.less.mjs +4 -0
- package/dist/es/components/WebLink/index.mjs +26 -0
- package/dist/es/constant.mjs +96 -0
- package/dist/es/context.mjs +7 -0
- package/dist/es/favicon.ico +0 -0
- package/dist/es/favicon2.ico +0 -0
- package/dist/es/font/font_4108228_4w5nlhafpte.js +1 -0
- package/dist/es/font/font_4439177_0sppkcnqiqgs.js +1 -0
- package/dist/es/font/gos-font.js +64 -0
- package/dist/es/images/empty.svg +40 -0
- package/dist/es/images/loading.gif +0 -0
- package/dist/es/images/logo.png +0 -0
- package/dist/es/images/map-example.png +0 -0
- package/dist/es/images/sketch.png +0 -0
- package/dist/es/index.html +43 -0
- package/dist/es/index.mjs +325 -0
- package/dist/es/logo192.png +0 -0
- package/dist/es/logo512.png +0 -0
- package/dist/es/manifest.json +25 -0
- package/dist/es/node_modules/@babel/runtime/helpers/esm/extends.mjs +13 -0
- package/dist/es/node_modules/@glodon-aiot/minio/dist/minio-zj.mjs +26485 -0
- package/dist/es/node_modules/@socket.io/component-emitter/lib/esm/index.mjs +54 -0
- package/dist/es/node_modules/ahooks/es/useKeyPress/index.mjs +221 -0
- package/dist/es/node_modules/ahooks/es/useLatest/index.mjs +8 -0
- package/dist/es/node_modules/ahooks/es/useMemoizedFn/index.mjs +19 -0
- package/dist/es/node_modules/ahooks/es/useUnmount/index.mjs +17 -0
- package/dist/es/node_modules/ahooks/es/utils/createEffectWithTarget.mjs +27 -0
- package/dist/es/node_modules/ahooks/es/utils/depsAreSame.mjs +11 -0
- package/dist/es/node_modules/ahooks/es/utils/depsEqual.mjs +7 -0
- package/dist/es/node_modules/ahooks/es/utils/domTarget.mjs +13 -0
- package/dist/es/node_modules/ahooks/es/utils/index.mjs +12 -0
- package/dist/es/node_modules/ahooks/es/utils/isAppleDevice.mjs +5 -0
- package/dist/es/node_modules/ahooks/es/utils/isBrowser.mjs +5 -0
- package/dist/es/node_modules/ahooks/es/utils/isDev.mjs +5 -0
- package/dist/es/node_modules/ahooks/es/utils/useDeepCompareWithTarget.mjs +11 -0
- package/dist/es/node_modules/ahooks/es/utils/useEffectWithTarget.mjs +7 -0
- package/dist/es/node_modules/antd/es/calendar/locale/zh_CN.mjs +4 -0
- package/dist/es/node_modules/antd/es/date-picker/locale/zh_CN.mjs +23 -0
- package/dist/es/node_modules/antd/es/locale/zh_CN.mjs +132 -0
- package/dist/es/node_modules/antd/es/time-picker/locale/zh_CN.mjs +8 -0
- package/dist/es/node_modules/base64-js/index.mjs +47 -0
- package/dist/es/node_modules/buffer/index.mjs +927 -0
- package/dist/es/node_modules/classnames/index.mjs +42 -0
- package/dist/es/node_modules/copy-to-clipboard/index.mjs +46 -0
- package/dist/es/node_modules/engine.io-client/build/esm/contrib/has-cors.mjs +9 -0
- package/dist/es/node_modules/engine.io-client/build/esm/contrib/parseqs.mjs +18 -0
- package/dist/es/node_modules/engine.io-client/build/esm/contrib/parseuri.mjs +24 -0
- package/dist/es/node_modules/engine.io-client/build/esm/contrib/yeast.mjs +19 -0
- package/dist/es/node_modules/engine.io-client/build/esm/globalThis.browser.mjs +4 -0
- package/dist/es/node_modules/engine.io-client/build/esm/socket.mjs +317 -0
- package/dist/es/node_modules/engine.io-client/build/esm/transport.mjs +113 -0
- package/dist/es/node_modules/engine.io-client/build/esm/transports/index.mjs +11 -0
- package/dist/es/node_modules/engine.io-client/build/esm/transports/polling.mjs +273 -0
- package/dist/es/node_modules/engine.io-client/build/esm/transports/websocket-constructor.browser.mjs +8 -0
- package/dist/es/node_modules/engine.io-client/build/esm/transports/websocket.mjs +87 -0
- package/dist/es/node_modules/engine.io-client/build/esm/transports/webtransport.mjs +52 -0
- package/dist/es/node_modules/engine.io-client/build/esm/transports/xmlhttprequest.browser.mjs +21 -0
- package/dist/es/node_modules/engine.io-client/build/esm/util.mjs +23 -0
- package/dist/es/node_modules/engine.io-parser/build/esm/commons.mjs +21 -0
- package/dist/es/node_modules/engine.io-parser/build/esm/contrib/base64-arraybuffer.mjs +14 -0
- package/dist/es/node_modules/engine.io-parser/build/esm/decodePacket.browser.mjs +39 -0
- package/dist/es/node_modules/engine.io-parser/build/esm/encodePacket.browser.mjs +28 -0
- package/dist/es/node_modules/engine.io-parser/build/esm/index.mjs +105 -0
- package/dist/es/node_modules/ieee754/index.mjs +28 -0
- package/dist/es/node_modules/js-base64/base64.mjs +31 -0
- package/dist/es/node_modules/lodash/_Hash.mjs +22 -0
- package/dist/es/node_modules/lodash/_ListCache.mjs +22 -0
- package/dist/es/node_modules/lodash/_Map.mjs +6 -0
- package/dist/es/node_modules/lodash/_MapCache.mjs +22 -0
- package/dist/es/node_modules/lodash/_Stack.mjs +20 -0
- package/dist/es/node_modules/lodash/_Symbol.mjs +5 -0
- package/dist/es/node_modules/lodash/_Uint8Array.mjs +5 -0
- package/dist/es/node_modules/lodash/_apply.mjs +17 -0
- package/dist/es/node_modules/lodash/_arrayLikeKeys.mjs +21 -0
- package/dist/es/node_modules/lodash/_assignMergeValue.mjs +10 -0
- package/dist/es/node_modules/lodash/_assignValue.mjs +11 -0
- package/dist/es/node_modules/lodash/_assocIndexOf.mjs +12 -0
- package/dist/es/node_modules/lodash/_baseAssignValue.mjs +14 -0
- package/dist/es/node_modules/lodash/_baseCreate.mjs +17 -0
- package/dist/es/node_modules/lodash/_baseFor.mjs +5 -0
- package/dist/es/node_modules/lodash/_baseGetTag.mjs +11 -0
- package/dist/es/node_modules/lodash/_baseIsArguments.mjs +10 -0
- package/dist/es/node_modules/lodash/_baseIsNative.mjs +15 -0
- package/dist/es/node_modules/lodash/_baseIsTypedArray.mjs +13 -0
- package/dist/es/node_modules/lodash/_baseKeysIn.mjs +16 -0
- package/dist/es/node_modules/lodash/_baseMerge.mjs +22 -0
- package/dist/es/node_modules/lodash/_baseMergeDeep.mjs +33 -0
- package/dist/es/node_modules/lodash/_baseRest.mjs +11 -0
- package/dist/es/node_modules/lodash/_baseSetToString.mjs +14 -0
- package/dist/es/node_modules/lodash/_baseTimes.mjs +9 -0
- package/dist/es/node_modules/lodash/_baseTrim.mjs +9 -0
- package/dist/es/node_modules/lodash/_baseUnary.mjs +9 -0
- package/dist/es/node_modules/lodash/_cloneArrayBuffer.mjs +10 -0
- package/dist/es/node_modules/lodash/_cloneBuffer.mjs +17 -0
- package/dist/es/node_modules/lodash/_cloneTypedArray.mjs +10 -0
- package/dist/es/node_modules/lodash/_copyArray.mjs +10 -0
- package/dist/es/node_modules/lodash/_copyObject.mjs +16 -0
- package/dist/es/node_modules/lodash/_coreJsData.mjs +5 -0
- package/dist/es/node_modules/lodash/_createAssigner.mjs +17 -0
- package/dist/es/node_modules/lodash/_createBaseFor.mjs +14 -0
- package/dist/es/node_modules/lodash/_defineProperty.mjs +11 -0
- package/dist/es/node_modules/lodash/_freeGlobal.mjs +5 -0
- package/dist/es/node_modules/lodash/_getMapData.mjs +10 -0
- package/dist/es/node_modules/lodash/_getNative.mjs +11 -0
- package/dist/es/node_modules/lodash/_getPrototype.mjs +5 -0
- package/dist/es/node_modules/lodash/_getRawTag.mjs +16 -0
- package/dist/es/node_modules/lodash/_getValue.mjs +7 -0
- package/dist/es/node_modules/lodash/_hashClear.mjs +9 -0
- package/dist/es/node_modules/lodash/_hashDelete.mjs +8 -0
- package/dist/es/node_modules/lodash/_hashGet.mjs +14 -0
- package/dist/es/node_modules/lodash/_hashHas.mjs +10 -0
- package/dist/es/node_modules/lodash/_hashSet.mjs +10 -0
- package/dist/es/node_modules/lodash/_initCloneObject.mjs +11 -0
- package/dist/es/node_modules/lodash/_isIndex.mjs +9 -0
- package/dist/es/node_modules/lodash/_isIterateeCall.mjs +15 -0
- package/dist/es/node_modules/lodash/_isKeyable.mjs +8 -0
- package/dist/es/node_modules/lodash/_isMasked.mjs +12 -0
- package/dist/es/node_modules/lodash/_isPrototype.mjs +9 -0
- package/dist/es/node_modules/lodash/_listCacheClear.mjs +7 -0
- package/dist/es/node_modules/lodash/_listCacheDelete.mjs +13 -0
- package/dist/es/node_modules/lodash/_listCacheGet.mjs +10 -0
- package/dist/es/node_modules/lodash/_listCacheHas.mjs +9 -0
- package/dist/es/node_modules/lodash/_listCacheSet.mjs +10 -0
- package/dist/es/node_modules/lodash/_mapCacheClear.mjs +15 -0
- package/dist/es/node_modules/lodash/_mapCacheDelete.mjs +10 -0
- package/dist/es/node_modules/lodash/_mapCacheGet.mjs +9 -0
- package/dist/es/node_modules/lodash/_mapCacheHas.mjs +9 -0
- package/dist/es/node_modules/lodash/_mapCacheSet.mjs +10 -0
- package/dist/es/node_modules/lodash/_nativeCreate.mjs +5 -0
- package/dist/es/node_modules/lodash/_nativeKeysIn.mjs +11 -0
- package/dist/es/node_modules/lodash/_nodeUtil.mjs +17 -0
- package/dist/es/node_modules/lodash/_objectToString.mjs +8 -0
- package/dist/es/node_modules/lodash/_overArg.mjs +9 -0
- package/dist/es/node_modules/lodash/_overRest.mjs +16 -0
- package/dist/es/node_modules/lodash/_root.mjs +5 -0
- package/dist/es/node_modules/lodash/_safeGet.mjs +8 -0
- package/dist/es/node_modules/lodash/_setToString.mjs +6 -0
- package/dist/es/node_modules/lodash/_shortOut.mjs +17 -0
- package/dist/es/node_modules/lodash/_stackClear.mjs +9 -0
- package/dist/es/node_modules/lodash/_stackDelete.mjs +8 -0
- package/dist/es/node_modules/lodash/_stackGet.mjs +7 -0
- package/dist/es/node_modules/lodash/_stackHas.mjs +7 -0
- package/dist/es/node_modules/lodash/_stackSet.mjs +18 -0
- package/dist/es/node_modules/lodash/_toSource.mjs +18 -0
- package/dist/es/node_modules/lodash/_trimmedEndIndex.mjs +10 -0
- package/dist/es/node_modules/lodash/constant.mjs +9 -0
- package/dist/es/node_modules/lodash/debounce.mjs +57 -0
- package/dist/es/node_modules/lodash/eq.mjs +7 -0
- package/dist/es/node_modules/lodash/identity.mjs +7 -0
- package/dist/es/node_modules/lodash/isArguments.mjs +10 -0
- package/dist/es/node_modules/lodash/isArray.mjs +4 -0
- package/dist/es/node_modules/lodash/isArrayLike.mjs +10 -0
- package/dist/es/node_modules/lodash/isArrayLikeObject.mjs +10 -0
- package/dist/es/node_modules/lodash/isBuffer.mjs +12 -0
- package/dist/es/node_modules/lodash/isFunction.mjs +13 -0
- package/dist/es/node_modules/lodash/isLength.mjs +8 -0
- package/dist/es/node_modules/lodash/isObject.mjs +8 -0
- package/dist/es/node_modules/lodash/isObjectLike.mjs +7 -0
- package/dist/es/node_modules/lodash/isPlainObject.mjs +17 -0
- package/dist/es/node_modules/lodash/isSymbol.mjs +10 -0
- package/dist/es/node_modules/lodash/isTypedArray.mjs +7 -0
- package/dist/es/node_modules/lodash/keysIn.mjs +11 -0
- package/dist/es/node_modules/lodash/merge.mjs +10 -0
- package/dist/es/node_modules/lodash/now.mjs +7 -0
- package/dist/es/node_modules/lodash/stubFalse.mjs +7 -0
- package/dist/es/node_modules/lodash/toNumber.mjs +23 -0
- package/dist/es/node_modules/lodash/toPlainObject.mjs +10 -0
- package/dist/es/node_modules/object-assign/index.mjs +34 -0
- package/dist/es/node_modules/rc-pagination/es/locale/zh_CN.mjs +18 -0
- package/dist/es/node_modules/rc-picker/es/locale/zh_CN.mjs +31 -0
- package/dist/es/node_modules/react/cjs/react-jsx-runtime.production.min.mjs +45 -0
- package/dist/es/node_modules/react/jsx-runtime.mjs +8 -0
- package/dist/es/node_modules/react-fast-compare/index.mjs +78 -0
- package/dist/es/node_modules/react-infinite-scroll-component/dist/index.es.mjs +188 -0
- package/dist/es/node_modules/react-quill/dist/quill.snow.css.mjs +4 -0
- package/dist/es/node_modules/socket.io-client/build/esm/contrib/backo2.mjs +26 -0
- package/dist/es/node_modules/socket.io-client/build/esm/index.mjs +25 -0
- package/dist/es/node_modules/socket.io-client/build/esm/manager.mjs +242 -0
- package/dist/es/node_modules/socket.io-client/build/esm/on.mjs +8 -0
- package/dist/es/node_modules/socket.io-client/build/esm/socket.mjs +608 -0
- package/dist/es/node_modules/socket.io-client/build/esm/url.mjs +19 -0
- package/dist/es/node_modules/socket.io-parser/build/esm/binary.mjs +52 -0
- package/dist/es/node_modules/socket.io-parser/build/esm/index.mjs +203 -0
- package/dist/es/node_modules/socket.io-parser/build/esm/is-binary.mjs +26 -0
- package/dist/es/node_modules/toggle-selection/index.mjs +25 -0
- package/dist/es/node_modules/tslib/tslib.es6.mjs +15 -0
- package/dist/es/node_modules/uuid/dist/esm-browser/native.mjs +6 -0
- package/dist/es/node_modules/uuid/dist/esm-browser/rng.mjs +10 -0
- package/dist/es/node_modules/uuid/dist/esm-browser/stringify.mjs +9 -0
- package/dist/es/node_modules/uuid/dist/esm-browser/v4.mjs +19 -0
- package/dist/es/packages/agent-cli-sdk/src/AgentSession.mjs +243 -0
- package/dist/es/packages/agent-cli-sdk/src/BotClient.mjs +242 -0
- package/dist/es/packages/agent-cli-sdk/src/Config.mjs +34 -0
- package/dist/es/packages/agent-cli-sdk/src/DialogSession.mjs +281 -0
- package/dist/es/packages/agent-cli-sdk/src/EventBus.mjs +64 -0
- package/dist/es/packages/agent-cli-sdk/src/Logger.mjs +31 -0
- package/dist/es/packages/agent-cli-sdk/src/PayloadTypes.mjs +4 -0
- package/dist/es/packages/agent-cli-sdk/src/Session.mjs +527 -0
- package/dist/es/packages/agent-cli-sdk/src/api/fetchEventSource/fetch.mjs +112 -0
- package/dist/es/packages/agent-cli-sdk/src/api/fetchEventSource/parse.mjs +97 -0
- package/dist/es/packages/agent-cli-sdk/src/api/index.mjs +48 -0
- package/dist/es/packages/agent-cli-sdk/src/utils.mjs +11 -0
- package/dist/es/packages/apis/dist/es/aecpilot/cosntant.mjs +5 -0
- package/dist/es/packages/apis/dist/es/aecpilot/model.mjs +9 -0
- package/dist/es/packages/apis/dist/es/aecpilotui/index.mjs +8 -0
- package/dist/es/packages/apis/dist/es/agentcliui/index.mjs +414 -0
- package/dist/es/packages/apis/dist/es/base/index.mjs +154 -0
- package/dist/es/packages/apis/dist/es/cvforce/index.mjs +431 -0
- package/dist/es/packages/apis/dist/es/cvforce/model.mjs +6 -0
- package/dist/es/packages/apis/dist/es/node_modules/uuid/dist/esm-browser/native.mjs +6 -0
- package/dist/es/packages/apis/dist/es/node_modules/uuid/dist/esm-browser/rng.mjs +10 -0
- package/dist/es/packages/apis/dist/es/node_modules/uuid/dist/esm-browser/stringify.mjs +9 -0
- package/dist/es/packages/apis/dist/es/node_modules/uuid/dist/esm-browser/v4.mjs +19 -0
- package/dist/es/packages/apis/dist/es/utils/fetchEventSource/fetch.mjs +106 -0
- package/dist/es/packages/apis/dist/es/utils/fetchEventSource/parse.mjs +97 -0
- package/dist/es/robots.txt +3 -0
- package/dist/es/style.less.mjs +4 -0
- package/dist/es/types.mjs +4 -0
- package/dist/es/utils/clipboard.mjs +38 -0
- package/dist/es/utils/index.mjs +33 -0
- package/dist/lib/favicon.ico +0 -0
- package/dist/lib/favicon2.ico +0 -0
- package/dist/lib/font/font_4108228_4w5nlhafpte.js +1 -0
- package/dist/lib/font/font_4439177_0sppkcnqiqgs.js +1 -0
- package/dist/lib/font/gos-font.js +64 -0
- package/dist/lib/images/empty.svg +40 -0
- package/dist/lib/images/loading.gif +0 -0
- package/dist/lib/images/logo.png +0 -0
- package/dist/lib/images/map-example.png +0 -0
- package/dist/lib/images/sketch.png +0 -0
- package/dist/lib/index.html +43 -0
- package/dist/lib/index.js +169 -0
- package/dist/lib/logo192.png +0 -0
- package/dist/lib/logo512.png +0 -0
- package/dist/lib/manifest.json +25 -0
- package/dist/lib/robots.txt +3 -0
- package/dist/src/AgentClientUI.d.ts +4 -0
- package/dist/src/ConnectToNetwork/index.d.ts +13 -0
- package/dist/src/Dialog/AgentChat/index.d.ts +17 -0
- package/dist/src/Dialog/ChatEmptyView/index.d.ts +6 -0
- package/dist/src/Dialog/ConnectToNetwork/index.d.ts +13 -0
- package/dist/src/Dialog/FileCard/index.d.ts +22 -0
- package/dist/src/Dialog/FilePreview/index.d.ts +20 -0
- package/dist/src/Dialog/Greeting/index.d.ts +7 -0
- package/dist/src/Dialog/HistoryContent/index.d.ts +5 -0
- package/dist/src/Dialog/HistoryItem/index.d.ts +17 -0
- package/dist/src/Dialog/KnowledgeDoc/index.d.ts +9 -0
- package/dist/src/Dialog/KnowledgeList/KnowledgeSelect/index.d.ts +12 -0
- package/dist/src/Dialog/KnowledgeList/index.d.ts +13 -0
- package/dist/src/Dialog/PromptManager/PromptList/EditPromptModal/index.d.ts +11 -0
- package/dist/src/Dialog/PromptManager/PromptList/PrivatePromptList.d.ts +12 -0
- package/dist/src/Dialog/PromptManager/PromptList/PromptListItem.d.ts +13 -0
- package/dist/src/Dialog/PromptManager/PromptList/PublicPromptList.d.ts +12 -0
- package/dist/src/Dialog/PromptManager/index.d.ts +13 -0
- package/dist/src/Dialog/PromptSetting/index.d.ts +14 -0
- package/dist/src/Dialog/Recommend/RecommendItem.d.ts +12 -0
- package/dist/src/Dialog/Recommend/index.d.ts +14 -0
- package/dist/src/Dialog/ReferCollapse/index.d.ts +8 -0
- package/dist/src/Dialog/SearchReference/index.d.ts +7 -0
- package/dist/src/Dialog/SessionAction/index.d.ts +11 -0
- package/dist/src/Dialog/SessionList/index.d.ts +20 -0
- package/dist/src/Dialog/SessionListDrawer/HistorySessionList/NameEditPanel.d.ts +9 -0
- package/dist/src/Dialog/SessionListDrawer/HistorySessionList/SessionItem.d.ts +16 -0
- package/dist/src/Dialog/SessionListDrawer/HistorySessionList/index.d.ts +9 -0
- package/dist/src/Dialog/SessionListDrawer/index.d.ts +9 -0
- package/dist/src/Dialog/SessionRefer/ReferItem/index.d.ts +9 -0
- package/dist/src/Dialog/SessionRefer/index.d.ts +8 -0
- package/dist/src/Dialog/SessionRelated/index.d.ts +9 -0
- package/dist/src/Dialog/UploadFiles/ClearModal/index.d.ts +7 -0
- package/dist/src/Dialog/UploadFiles/index.d.ts +21 -0
- package/dist/src/Dialog/UploadKnowledgeFiles/ClearModal/index.d.ts +7 -0
- package/dist/src/Dialog/UploadKnowledgeFiles/index.d.ts +22 -0
- package/dist/src/Dialog/UploadingPrompt/index.d.ts +9 -0
- package/dist/src/Dialog/index.d.ts +9 -0
- package/dist/src/FileCard/index.d.ts +21 -0
- package/dist/src/FileItem/index.d.ts +11 -0
- package/dist/src/Footer/FooterWarning.d.ts +8 -0
- package/dist/src/Footer/index.d.ts +7 -0
- package/dist/src/Greeting/index.d.ts +7 -0
- package/dist/src/Iconfont/font_4108228_8te6zfkclqu.d.ts +0 -0
- package/dist/src/Iconfont/font_4439177_7rytwlvbmjj.d.ts +0 -0
- package/dist/src/Iconfont/index.d.ts +3 -0
- package/dist/src/InputProgress/index.d.ts +7 -0
- package/dist/src/QuillEditor/index.d.ts +19 -0
- package/dist/src/components/Copy/index.d.ts +5 -0
- package/dist/src/components/Header/index.d.ts +6 -0
- package/dist/src/components/JsonDisplay/index.d.ts +6 -0
- package/dist/src/components/Markdown/Code/index.d.ts +3 -0
- package/dist/src/components/Markdown/Image/index.d.ts +3 -0
- package/dist/src/components/Markdown/index.d.ts +6 -0
- package/dist/src/components/PDFViewer/index.d.ts +7 -0
- package/dist/src/components/WebLink/index.d.ts +7 -0
- package/dist/src/constant.d.ts +11 -0
- package/dist/src/context.d.ts +5 -0
- package/dist/src/index.d.ts +33 -0
- package/dist/src/types.d.ts +183 -0
- package/dist/src/utils/clipboard.d.ts +11 -0
- package/dist/src/utils/fetchEventSource/fetch.d.ts +44 -0
- package/dist/src/utils/fetchEventSource/index.d.ts +1 -0
- package/dist/src/utils/fetchEventSource/parse.d.ts +36 -0
- package/dist/src/utils/index.d.ts +17 -0
- package/package.json +138 -0
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { _ as a } from "./_baseGetTag.mjs";
|
|
2
|
+
import { _ as c } from "./_getPrototype.mjs";
|
|
3
|
+
import { i as n } from "./isObjectLike.mjs";
|
|
4
|
+
var i = a, s = c, p = n, b = "[object Object]", f = Function.prototype, j = Object.prototype, e = f.toString, u = j.hasOwnProperty, l = e.call(Object);
|
|
5
|
+
function O(r) {
|
|
6
|
+
if (!p(r) || i(r) != b)
|
|
7
|
+
return !1;
|
|
8
|
+
var o = s(r);
|
|
9
|
+
if (o === null)
|
|
10
|
+
return !0;
|
|
11
|
+
var t = u.call(o, "constructor") && o.constructor;
|
|
12
|
+
return typeof t == "function" && t instanceof t && e.call(t) == l;
|
|
13
|
+
}
|
|
14
|
+
var y = O;
|
|
15
|
+
export {
|
|
16
|
+
y as i
|
|
17
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { _ as a } from "./_arrayLikeKeys.mjs";
|
|
2
|
+
import { _ as s } from "./_baseKeysIn.mjs";
|
|
3
|
+
import { i as e } from "./isArrayLike.mjs";
|
|
4
|
+
var i = a, y = s, k = e;
|
|
5
|
+
function n(r) {
|
|
6
|
+
return k(r) ? i(r, !0) : y(r);
|
|
7
|
+
}
|
|
8
|
+
var t = n;
|
|
9
|
+
export {
|
|
10
|
+
t as k
|
|
11
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { getDefaultExportFromCjs as t } from "../../_virtual/_commonjsHelpers.mjs";
|
|
2
|
+
import { _ as o } from "./_baseMerge.mjs";
|
|
3
|
+
import { _ as s } from "./_createAssigner.mjs";
|
|
4
|
+
var m = o, g = s, f = g(function(e, r, a) {
|
|
5
|
+
m(e, r, a);
|
|
6
|
+
}), i = f;
|
|
7
|
+
const c = /* @__PURE__ */ t(i);
|
|
8
|
+
export {
|
|
9
|
+
c as default
|
|
10
|
+
};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { _ as o } from "./_baseTrim.mjs";
|
|
2
|
+
import { i as n } from "./isObject.mjs";
|
|
3
|
+
import { i as m } from "./isSymbol.mjs";
|
|
4
|
+
var b = o, s = n, e = m, f = 0 / 0, p = /^[-+]0x[0-9a-f]+$/i, y = /^0b[01]+$/i, a = /^0o[0-7]+$/i, c = parseInt;
|
|
5
|
+
function I(r) {
|
|
6
|
+
if (typeof r == "number")
|
|
7
|
+
return r;
|
|
8
|
+
if (e(r))
|
|
9
|
+
return f;
|
|
10
|
+
if (s(r)) {
|
|
11
|
+
var t = typeof r.valueOf == "function" ? r.valueOf() : r;
|
|
12
|
+
r = s(t) ? t + "" : t;
|
|
13
|
+
}
|
|
14
|
+
if (typeof r != "string")
|
|
15
|
+
return r === 0 ? r : +r;
|
|
16
|
+
r = b(r);
|
|
17
|
+
var i = y.test(r);
|
|
18
|
+
return i || a.test(r) ? c(r.slice(2), i ? 2 : 8) : p.test(r) ? f : +r;
|
|
19
|
+
}
|
|
20
|
+
var x = I;
|
|
21
|
+
export {
|
|
22
|
+
x as t
|
|
23
|
+
};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/*
|
|
2
|
+
object-assign
|
|
3
|
+
(c) Sindre Sorhus
|
|
4
|
+
@license MIT
|
|
5
|
+
*/
|
|
6
|
+
var s = Object.getOwnPropertySymbols, u = Object.prototype.hasOwnProperty, l = Object.prototype.propertyIsEnumerable;
|
|
7
|
+
function b(n) {
|
|
8
|
+
if (n == null)
|
|
9
|
+
throw new TypeError("Object.assign cannot be called with null or undefined");
|
|
10
|
+
return Object(n);
|
|
11
|
+
}
|
|
12
|
+
function i() {
|
|
13
|
+
try {
|
|
14
|
+
if (!Object.assign)
|
|
15
|
+
return !1;
|
|
16
|
+
var n = new String("abc");
|
|
17
|
+
if (n[5] = "de", Object.getOwnPropertyNames(n)[0] === "5")
|
|
18
|
+
return !1;
|
|
19
|
+
for (var c = {}, r = 0; r < 10; r++)
|
|
20
|
+
c["_" + String.fromCharCode(r)] = r;
|
|
21
|
+
var a = Object.getOwnPropertyNames(c).map(function(e) {
|
|
22
|
+
return c[e];
|
|
23
|
+
});
|
|
24
|
+
if (a.join("") !== "0123456789")
|
|
25
|
+
return !1;
|
|
26
|
+
var t = {};
|
|
27
|
+
return "abcdefghijklmnopqrst".split("").forEach(function(e) {
|
|
28
|
+
t[e] = e;
|
|
29
|
+
}), Object.keys(Object.assign({}, t)).join("") === "abcdefghijklmnopqrst";
|
|
30
|
+
} catch (e) {
|
|
31
|
+
return !1;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
i();
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
const e = {
|
|
2
|
+
// Options.jsx
|
|
3
|
+
items_per_page: "条/页",
|
|
4
|
+
jump_to: "跳至",
|
|
5
|
+
jump_to_confirm: "确定",
|
|
6
|
+
page: "页",
|
|
7
|
+
// Pagination.jsx
|
|
8
|
+
prev_page: "上一页",
|
|
9
|
+
next_page: "下一页",
|
|
10
|
+
prev_5: "向前 5 页",
|
|
11
|
+
next_5: "向后 5 页",
|
|
12
|
+
prev_3: "向前 3 页",
|
|
13
|
+
next_3: "向后 3 页",
|
|
14
|
+
page_size: "页码"
|
|
15
|
+
};
|
|
16
|
+
export {
|
|
17
|
+
e as default
|
|
18
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
var e = {
|
|
2
|
+
locale: "zh_CN",
|
|
3
|
+
today: "今天",
|
|
4
|
+
now: "此刻",
|
|
5
|
+
backToToday: "返回今天",
|
|
6
|
+
ok: "确定",
|
|
7
|
+
timeSelect: "选择时间",
|
|
8
|
+
dateSelect: "选择日期",
|
|
9
|
+
weekSelect: "选择周",
|
|
10
|
+
clear: "清除",
|
|
11
|
+
month: "月",
|
|
12
|
+
year: "年",
|
|
13
|
+
previousMonth: "上个月 (翻页上键)",
|
|
14
|
+
nextMonth: "下个月 (翻页下键)",
|
|
15
|
+
monthSelect: "选择月份",
|
|
16
|
+
yearSelect: "选择年份",
|
|
17
|
+
decadeSelect: "选择年代",
|
|
18
|
+
yearFormat: "YYYY年",
|
|
19
|
+
dayFormat: "D日",
|
|
20
|
+
dateFormat: "YYYY年M月D日",
|
|
21
|
+
dateTimeFormat: "YYYY年M月D日 HH时mm分ss秒",
|
|
22
|
+
previousYear: "上一年 (Control键加左方向键)",
|
|
23
|
+
nextYear: "下一年 (Control键加右方向键)",
|
|
24
|
+
previousDecade: "上一年代",
|
|
25
|
+
nextDecade: "下一年代",
|
|
26
|
+
previousCentury: "上一世纪",
|
|
27
|
+
nextCentury: "下一世纪"
|
|
28
|
+
};
|
|
29
|
+
export {
|
|
30
|
+
e as default
|
|
31
|
+
};
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { __exports as n } from "../../../_virtual/react-jsx-runtime.production.min.mjs";
|
|
2
|
+
import "../../object-assign/index.mjs";
|
|
3
|
+
import s from "react";
|
|
4
|
+
/** @license React v17.0.2
|
|
5
|
+
* react-jsx-runtime.production.min.js
|
|
6
|
+
*
|
|
7
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
8
|
+
*
|
|
9
|
+
* This source code is licensed under the MIT license found in the
|
|
10
|
+
* LICENSE file in the root directory of this source tree.
|
|
11
|
+
*/
|
|
12
|
+
var u = s, l = 60103;
|
|
13
|
+
n.Fragment = 60107;
|
|
14
|
+
if (typeof Symbol == "function" && Symbol.for) {
|
|
15
|
+
var i = Symbol.for;
|
|
16
|
+
l = i("react.element"), n.Fragment = i("react.fragment");
|
|
17
|
+
}
|
|
18
|
+
var y = u.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, a = Object.prototype.hasOwnProperty, c = {
|
|
19
|
+
key: !0,
|
|
20
|
+
ref: !0,
|
|
21
|
+
__self: !0,
|
|
22
|
+
__source: !0
|
|
23
|
+
};
|
|
24
|
+
function m(o, r, _) {
|
|
25
|
+
var e, t = {}, f = null, p = null;
|
|
26
|
+
_ !== void 0 && (f = "" + _), r.key !== void 0 && (f = "" + r.key), r.ref !== void 0 && (p = r.ref);
|
|
27
|
+
for (e in r)
|
|
28
|
+
a.call(r, e) && !c.hasOwnProperty(e) && (t[e] = r[e]);
|
|
29
|
+
if (o && o.defaultProps)
|
|
30
|
+
for (e in r = o.defaultProps, r)
|
|
31
|
+
t[e] === void 0 && (t[e] = r[e]);
|
|
32
|
+
return {
|
|
33
|
+
$$typeof: l,
|
|
34
|
+
type: o,
|
|
35
|
+
key: f,
|
|
36
|
+
ref: p,
|
|
37
|
+
props: t,
|
|
38
|
+
_owner: y.current
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
n.jsx = m;
|
|
42
|
+
n.jsxs = m;
|
|
43
|
+
export {
|
|
44
|
+
n as default
|
|
45
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { __module as o } from "../../_virtual/jsx-runtime2.mjs";
|
|
2
|
+
import "./cjs/react-jsx-runtime.production.min.mjs";
|
|
3
|
+
import { __exports as r } from "../../_virtual/react-jsx-runtime.production.min.mjs";
|
|
4
|
+
o.exports = r;
|
|
5
|
+
var e = o.exports;
|
|
6
|
+
export {
|
|
7
|
+
e as j
|
|
8
|
+
};
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { getDefaultExportFromCjs as s } from "../../_virtual/_commonjsHelpers.mjs";
|
|
2
|
+
var a = typeof Element != "undefined", c = typeof Map == "function", i = typeof Set == "function", l = typeof ArrayBuffer == "function" && !!ArrayBuffer.isView;
|
|
3
|
+
function u(e, r) {
|
|
4
|
+
if (e === r)
|
|
5
|
+
return !0;
|
|
6
|
+
if (e && r && typeof e == "object" && typeof r == "object") {
|
|
7
|
+
if (e.constructor !== r.constructor)
|
|
8
|
+
return !1;
|
|
9
|
+
var f, t, n;
|
|
10
|
+
if (Array.isArray(e)) {
|
|
11
|
+
if (f = e.length, f != r.length)
|
|
12
|
+
return !1;
|
|
13
|
+
for (t = f; t-- !== 0; )
|
|
14
|
+
if (!u(e[t], r[t]))
|
|
15
|
+
return !1;
|
|
16
|
+
return !0;
|
|
17
|
+
}
|
|
18
|
+
var o;
|
|
19
|
+
if (c && e instanceof Map && r instanceof Map) {
|
|
20
|
+
if (e.size !== r.size)
|
|
21
|
+
return !1;
|
|
22
|
+
for (o = e.entries(); !(t = o.next()).done; )
|
|
23
|
+
if (!r.has(t.value[0]))
|
|
24
|
+
return !1;
|
|
25
|
+
for (o = e.entries(); !(t = o.next()).done; )
|
|
26
|
+
if (!u(t.value[1], r.get(t.value[0])))
|
|
27
|
+
return !1;
|
|
28
|
+
return !0;
|
|
29
|
+
}
|
|
30
|
+
if (i && e instanceof Set && r instanceof Set) {
|
|
31
|
+
if (e.size !== r.size)
|
|
32
|
+
return !1;
|
|
33
|
+
for (o = e.entries(); !(t = o.next()).done; )
|
|
34
|
+
if (!r.has(t.value[0]))
|
|
35
|
+
return !1;
|
|
36
|
+
return !0;
|
|
37
|
+
}
|
|
38
|
+
if (l && ArrayBuffer.isView(e) && ArrayBuffer.isView(r)) {
|
|
39
|
+
if (f = e.length, f != r.length)
|
|
40
|
+
return !1;
|
|
41
|
+
for (t = f; t-- !== 0; )
|
|
42
|
+
if (e[t] !== r[t])
|
|
43
|
+
return !1;
|
|
44
|
+
return !0;
|
|
45
|
+
}
|
|
46
|
+
if (e.constructor === RegExp)
|
|
47
|
+
return e.source === r.source && e.flags === r.flags;
|
|
48
|
+
if (e.valueOf !== Object.prototype.valueOf && typeof e.valueOf == "function" && typeof r.valueOf == "function")
|
|
49
|
+
return e.valueOf() === r.valueOf();
|
|
50
|
+
if (e.toString !== Object.prototype.toString && typeof e.toString == "function" && typeof r.toString == "function")
|
|
51
|
+
return e.toString() === r.toString();
|
|
52
|
+
if (n = Object.keys(e), f = n.length, f !== Object.keys(r).length)
|
|
53
|
+
return !1;
|
|
54
|
+
for (t = f; t-- !== 0; )
|
|
55
|
+
if (!Object.prototype.hasOwnProperty.call(r, n[t]))
|
|
56
|
+
return !1;
|
|
57
|
+
if (a && e instanceof Element)
|
|
58
|
+
return !1;
|
|
59
|
+
for (t = f; t-- !== 0; )
|
|
60
|
+
if (!((n[t] === "_owner" || n[t] === "__v" || n[t] === "__o") && e.$$typeof) && !u(e[n[t]], r[n[t]]))
|
|
61
|
+
return !1;
|
|
62
|
+
return !0;
|
|
63
|
+
}
|
|
64
|
+
return e !== e && r !== r;
|
|
65
|
+
}
|
|
66
|
+
var p = function(r, f) {
|
|
67
|
+
try {
|
|
68
|
+
return u(r, f);
|
|
69
|
+
} catch (t) {
|
|
70
|
+
if ((t.message || "").match(/stack|recursion/i))
|
|
71
|
+
return console.warn("react-fast-compare cannot handle circular refs"), !1;
|
|
72
|
+
throw t;
|
|
73
|
+
}
|
|
74
|
+
};
|
|
75
|
+
const v = /* @__PURE__ */ s(p);
|
|
76
|
+
export {
|
|
77
|
+
v as default
|
|
78
|
+
};
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
import h, { Component as T } from "react";
|
|
2
|
+
/*! *****************************************************************************
|
|
3
|
+
Copyright (c) Microsoft Corporation. All rights reserved.
|
|
4
|
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
5
|
+
this file except in compliance with the License. You may obtain a copy of the
|
|
6
|
+
License at http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
+
|
|
8
|
+
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
9
|
+
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
|
10
|
+
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
|
11
|
+
MERCHANTABLITY OR NON-INFRINGEMENT.
|
|
12
|
+
|
|
13
|
+
See the Apache Version 2.0 License for specific language governing permissions
|
|
14
|
+
and limitations under the License.
|
|
15
|
+
***************************************************************************** */
|
|
16
|
+
var u = function(o, r) {
|
|
17
|
+
return u = Object.setPrototypeOf || {
|
|
18
|
+
__proto__: []
|
|
19
|
+
} instanceof Array && function(t, e) {
|
|
20
|
+
t.__proto__ = e;
|
|
21
|
+
} || function(t, e) {
|
|
22
|
+
for (var n in e)
|
|
23
|
+
e.hasOwnProperty(n) && (t[n] = e[n]);
|
|
24
|
+
}, u(o, r);
|
|
25
|
+
};
|
|
26
|
+
function S(o, r) {
|
|
27
|
+
u(o, r);
|
|
28
|
+
function t() {
|
|
29
|
+
this.constructor = o;
|
|
30
|
+
}
|
|
31
|
+
o.prototype = r === null ? Object.create(r) : (t.prototype = r.prototype, new t());
|
|
32
|
+
}
|
|
33
|
+
var a = function() {
|
|
34
|
+
return a = Object.assign || function(r) {
|
|
35
|
+
for (var t, e = 1, n = arguments.length; e < n; e++) {
|
|
36
|
+
t = arguments[e];
|
|
37
|
+
for (var i in t)
|
|
38
|
+
Object.prototype.hasOwnProperty.call(t, i) && (r[i] = t[i]);
|
|
39
|
+
}
|
|
40
|
+
return r;
|
|
41
|
+
}, a.apply(this, arguments);
|
|
42
|
+
};
|
|
43
|
+
function _(o, r, t, e) {
|
|
44
|
+
var n, i = !1, s = 0;
|
|
45
|
+
function p() {
|
|
46
|
+
n && clearTimeout(n);
|
|
47
|
+
}
|
|
48
|
+
function g() {
|
|
49
|
+
p(), i = !0;
|
|
50
|
+
}
|
|
51
|
+
typeof r != "boolean" && (e = t, t = r, r = void 0);
|
|
52
|
+
function f() {
|
|
53
|
+
var w = this, d = Date.now() - s, E = arguments;
|
|
54
|
+
if (i)
|
|
55
|
+
return;
|
|
56
|
+
function c() {
|
|
57
|
+
s = Date.now(), t.apply(w, E);
|
|
58
|
+
}
|
|
59
|
+
function y() {
|
|
60
|
+
n = void 0;
|
|
61
|
+
}
|
|
62
|
+
e && !n && c(), p(), e === void 0 && d > o ? c() : r !== !0 && (n = setTimeout(e ? y : c, e === void 0 ? o - d : o));
|
|
63
|
+
}
|
|
64
|
+
return f.cancel = g, f;
|
|
65
|
+
}
|
|
66
|
+
var l = {
|
|
67
|
+
Pixel: "Pixel",
|
|
68
|
+
Percent: "Percent"
|
|
69
|
+
}, m = {
|
|
70
|
+
unit: l.Percent,
|
|
71
|
+
value: 0.8
|
|
72
|
+
};
|
|
73
|
+
function v(o) {
|
|
74
|
+
return typeof o == "number" ? {
|
|
75
|
+
unit: l.Percent,
|
|
76
|
+
value: o * 100
|
|
77
|
+
} : typeof o == "string" ? o.match(/^(\d*(\.\d+)?)px$/) ? {
|
|
78
|
+
unit: l.Pixel,
|
|
79
|
+
value: parseFloat(o)
|
|
80
|
+
} : o.match(/^(\d*(\.\d+)?)%$/) ? {
|
|
81
|
+
unit: l.Percent,
|
|
82
|
+
value: parseFloat(o)
|
|
83
|
+
} : (console.warn('scrollThreshold format is invalid. Valid formats: "120px", "50%"...'), m) : (console.warn("scrollThreshold should be string or number"), m);
|
|
84
|
+
}
|
|
85
|
+
var D = (
|
|
86
|
+
/** @class */
|
|
87
|
+
function(o) {
|
|
88
|
+
S(r, o);
|
|
89
|
+
function r(t) {
|
|
90
|
+
var e = o.call(this, t) || this;
|
|
91
|
+
return e.lastScrollTop = 0, e.actionTriggered = !1, e.startY = 0, e.currentY = 0, e.dragging = !1, e.maxPullDownDistance = 0, e.getScrollableTarget = function() {
|
|
92
|
+
return e.props.scrollableTarget instanceof HTMLElement ? e.props.scrollableTarget : typeof e.props.scrollableTarget == "string" ? document.getElementById(e.props.scrollableTarget) : (e.props.scrollableTarget === null && console.warn(`You are trying to pass scrollableTarget but it is null. This might
|
|
93
|
+
happen because the element may not have been added to DOM yet.
|
|
94
|
+
See https://github.com/ankeetmaini/react-infinite-scroll-component/issues/59 for more info.
|
|
95
|
+
`), null);
|
|
96
|
+
}, e.onStart = function(n) {
|
|
97
|
+
e.lastScrollTop || (e.dragging = !0, n instanceof MouseEvent ? e.startY = n.pageY : n instanceof TouchEvent && (e.startY = n.touches[0].pageY), e.currentY = e.startY, e._infScroll && (e._infScroll.style.willChange = "transform", e._infScroll.style.transition = "transform 0.2s cubic-bezier(0,0,0.31,1)"));
|
|
98
|
+
}, e.onMove = function(n) {
|
|
99
|
+
e.dragging && (n instanceof MouseEvent ? e.currentY = n.pageY : n instanceof TouchEvent && (e.currentY = n.touches[0].pageY), !(e.currentY < e.startY) && (e.currentY - e.startY >= Number(e.props.pullDownToRefreshThreshold) && e.setState({
|
|
100
|
+
pullToRefreshThresholdBreached: !0
|
|
101
|
+
}), !(e.currentY - e.startY > e.maxPullDownDistance * 1.5) && e._infScroll && (e._infScroll.style.overflow = "visible", e._infScroll.style.transform = "translate3d(0px, " + (e.currentY - e.startY) + "px, 0px)")));
|
|
102
|
+
}, e.onEnd = function() {
|
|
103
|
+
e.startY = 0, e.currentY = 0, e.dragging = !1, e.state.pullToRefreshThresholdBreached && (e.props.refreshFunction && e.props.refreshFunction(), e.setState({
|
|
104
|
+
pullToRefreshThresholdBreached: !1
|
|
105
|
+
})), requestAnimationFrame(function() {
|
|
106
|
+
e._infScroll && (e._infScroll.style.overflow = "auto", e._infScroll.style.transform = "none", e._infScroll.style.willChange = "unset");
|
|
107
|
+
});
|
|
108
|
+
}, e.onScrollListener = function(n) {
|
|
109
|
+
typeof e.props.onScroll == "function" && setTimeout(function() {
|
|
110
|
+
return e.props.onScroll && e.props.onScroll(n);
|
|
111
|
+
}, 0);
|
|
112
|
+
var i = e.props.height || e._scrollableNode ? n.target : document.documentElement.scrollTop ? document.documentElement : document.body;
|
|
113
|
+
if (!e.actionTriggered) {
|
|
114
|
+
var s = e.props.inverse ? e.isElementAtTop(i, e.props.scrollThreshold) : e.isElementAtBottom(i, e.props.scrollThreshold);
|
|
115
|
+
s && e.props.hasMore && (e.actionTriggered = !0, e.setState({
|
|
116
|
+
showLoader: !0
|
|
117
|
+
}), e.props.next && e.props.next()), e.lastScrollTop = i.scrollTop;
|
|
118
|
+
}
|
|
119
|
+
}, e.state = {
|
|
120
|
+
showLoader: !1,
|
|
121
|
+
pullToRefreshThresholdBreached: !1,
|
|
122
|
+
prevDataLength: t.dataLength
|
|
123
|
+
}, e.throttledOnScrollListener = _(150, e.onScrollListener).bind(e), e.onStart = e.onStart.bind(e), e.onMove = e.onMove.bind(e), e.onEnd = e.onEnd.bind(e), e;
|
|
124
|
+
}
|
|
125
|
+
return r.prototype.componentDidMount = function() {
|
|
126
|
+
if (typeof this.props.dataLength == "undefined")
|
|
127
|
+
throw new Error('mandatory prop "dataLength" is missing. The prop is needed when loading more content. Check README.md for usage');
|
|
128
|
+
if (this._scrollableNode = this.getScrollableTarget(), this.el = this.props.height ? this._infScroll : this._scrollableNode || window, this.el && this.el.addEventListener("scroll", this.throttledOnScrollListener), typeof this.props.initialScrollY == "number" && this.el && this.el instanceof HTMLElement && this.el.scrollHeight > this.props.initialScrollY && this.el.scrollTo(0, this.props.initialScrollY), this.props.pullDownToRefresh && this.el && (this.el.addEventListener("touchstart", this.onStart), this.el.addEventListener("touchmove", this.onMove), this.el.addEventListener("touchend", this.onEnd), this.el.addEventListener("mousedown", this.onStart), this.el.addEventListener("mousemove", this.onMove), this.el.addEventListener("mouseup", this.onEnd), this.maxPullDownDistance = this._pullDown && this._pullDown.firstChild && this._pullDown.firstChild.getBoundingClientRect().height || 0, this.forceUpdate(), typeof this.props.refreshFunction != "function"))
|
|
129
|
+
throw new Error(`Mandatory prop "refreshFunction" missing.
|
|
130
|
+
Pull Down To Refresh functionality will not work
|
|
131
|
+
as expected. Check README.md for usage'`);
|
|
132
|
+
}, r.prototype.componentWillUnmount = function() {
|
|
133
|
+
this.el && (this.el.removeEventListener("scroll", this.throttledOnScrollListener), this.props.pullDownToRefresh && (this.el.removeEventListener("touchstart", this.onStart), this.el.removeEventListener("touchmove", this.onMove), this.el.removeEventListener("touchend", this.onEnd), this.el.removeEventListener("mousedown", this.onStart), this.el.removeEventListener("mousemove", this.onMove), this.el.removeEventListener("mouseup", this.onEnd)));
|
|
134
|
+
}, r.prototype.componentDidUpdate = function(t) {
|
|
135
|
+
this.props.dataLength !== t.dataLength && (this.actionTriggered = !1, this.setState({
|
|
136
|
+
showLoader: !1
|
|
137
|
+
}));
|
|
138
|
+
}, r.getDerivedStateFromProps = function(t, e) {
|
|
139
|
+
var n = t.dataLength !== e.prevDataLength;
|
|
140
|
+
return n ? a(a({}, e), {
|
|
141
|
+
prevDataLength: t.dataLength
|
|
142
|
+
}) : null;
|
|
143
|
+
}, r.prototype.isElementAtTop = function(t, e) {
|
|
144
|
+
e === void 0 && (e = 0.8);
|
|
145
|
+
var n = t === document.body || t === document.documentElement ? window.screen.availHeight : t.clientHeight, i = v(e);
|
|
146
|
+
return i.unit === l.Pixel ? t.scrollTop <= i.value + n - t.scrollHeight + 1 : t.scrollTop <= i.value / 100 + n - t.scrollHeight + 1;
|
|
147
|
+
}, r.prototype.isElementAtBottom = function(t, e) {
|
|
148
|
+
e === void 0 && (e = 0.8);
|
|
149
|
+
var n = t === document.body || t === document.documentElement ? window.screen.availHeight : t.clientHeight, i = v(e);
|
|
150
|
+
return i.unit === l.Pixel ? t.scrollTop + n >= t.scrollHeight - i.value : t.scrollTop + n >= i.value / 100 * t.scrollHeight;
|
|
151
|
+
}, r.prototype.render = function() {
|
|
152
|
+
var t = this, e = a({
|
|
153
|
+
height: this.props.height || "auto",
|
|
154
|
+
overflow: "auto",
|
|
155
|
+
WebkitOverflowScrolling: "touch"
|
|
156
|
+
}, this.props.style), n = this.props.hasChildren || !!(this.props.children && this.props.children instanceof Array && this.props.children.length), i = this.props.pullDownToRefresh && this.props.height ? {
|
|
157
|
+
overflow: "auto"
|
|
158
|
+
} : {};
|
|
159
|
+
return h.createElement("div", {
|
|
160
|
+
style: i,
|
|
161
|
+
className: "infinite-scroll-component__outerdiv"
|
|
162
|
+
}, h.createElement("div", {
|
|
163
|
+
className: "infinite-scroll-component " + (this.props.className || ""),
|
|
164
|
+
ref: function(s) {
|
|
165
|
+
return t._infScroll = s;
|
|
166
|
+
},
|
|
167
|
+
style: e
|
|
168
|
+
}, this.props.pullDownToRefresh && h.createElement("div", {
|
|
169
|
+
style: {
|
|
170
|
+
position: "relative"
|
|
171
|
+
},
|
|
172
|
+
ref: function(s) {
|
|
173
|
+
return t._pullDown = s;
|
|
174
|
+
}
|
|
175
|
+
}, h.createElement("div", {
|
|
176
|
+
style: {
|
|
177
|
+
position: "absolute",
|
|
178
|
+
left: 0,
|
|
179
|
+
right: 0,
|
|
180
|
+
top: -1 * this.maxPullDownDistance
|
|
181
|
+
}
|
|
182
|
+
}, this.state.pullToRefreshThresholdBreached ? this.props.releaseToRefreshContent : this.props.pullDownToRefreshContent)), this.props.children, !this.state.showLoader && !n && this.props.hasMore && this.props.loader, this.state.showLoader && this.props.hasMore && this.props.loader, !this.props.hasMore && this.props.endMessage));
|
|
183
|
+
}, r;
|
|
184
|
+
}(T)
|
|
185
|
+
);
|
|
186
|
+
export {
|
|
187
|
+
D as default
|
|
188
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
function i(t) {
|
|
2
|
+
t = t || {}, this.ms = t.min || 100, this.max = t.max || 1e4, this.factor = t.factor || 2, this.jitter = t.jitter > 0 && t.jitter <= 1 ? t.jitter : 0, this.attempts = 0;
|
|
3
|
+
}
|
|
4
|
+
i.prototype.duration = function() {
|
|
5
|
+
var t = this.ms * Math.pow(this.factor, this.attempts++);
|
|
6
|
+
if (this.jitter) {
|
|
7
|
+
var r = Math.random(), e = Math.floor(r * this.jitter * t);
|
|
8
|
+
t = Math.floor(r * 10) & 1 ? t + e : t - e;
|
|
9
|
+
}
|
|
10
|
+
return Math.min(t, this.max) | 0;
|
|
11
|
+
};
|
|
12
|
+
i.prototype.reset = function() {
|
|
13
|
+
this.attempts = 0;
|
|
14
|
+
};
|
|
15
|
+
i.prototype.setMin = function(t) {
|
|
16
|
+
this.ms = t;
|
|
17
|
+
};
|
|
18
|
+
i.prototype.setMax = function(t) {
|
|
19
|
+
this.max = t;
|
|
20
|
+
};
|
|
21
|
+
i.prototype.setJitter = function(t) {
|
|
22
|
+
this.jitter = t;
|
|
23
|
+
};
|
|
24
|
+
export {
|
|
25
|
+
i as Backoff
|
|
26
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { url as l } from "./url.mjs";
|
|
2
|
+
import { Manager as i } from "./manager.mjs";
|
|
3
|
+
import { Socket as d } from "./socket.mjs";
|
|
4
|
+
import { protocol as q } from "../../../socket.io-parser/build/esm/index.mjs";
|
|
5
|
+
const c = {};
|
|
6
|
+
function a(t, e) {
|
|
7
|
+
typeof t == "object" && (e = t, t = void 0), e = e || {};
|
|
8
|
+
const n = l(t, e.path || "/socket.io"), f = n.source, o = n.id, s = n.path, m = c[o] && s in c[o].nsps, u = e.forceNew || e["force new connection"] || e.multiplex === !1 || m;
|
|
9
|
+
let r;
|
|
10
|
+
return u ? r = new i(f, e) : (c[o] || (c[o] = new i(f, e)), r = c[o]), n.query && !e.query && (e.query = n.queryKey), r.socket(n.path, e);
|
|
11
|
+
}
|
|
12
|
+
Object.assign(a, {
|
|
13
|
+
Manager: i,
|
|
14
|
+
Socket: d,
|
|
15
|
+
io: a,
|
|
16
|
+
connect: a
|
|
17
|
+
});
|
|
18
|
+
export {
|
|
19
|
+
i as Manager,
|
|
20
|
+
d as Socket,
|
|
21
|
+
a as connect,
|
|
22
|
+
a as default,
|
|
23
|
+
a as io,
|
|
24
|
+
q as protocol
|
|
25
|
+
};
|