gomtm 0.0.393 → 0.0.395
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +13 -31
- package/dist/esm/block/BlockItem.d.ts +0 -14
- package/dist/esm/block/BlockItem.js +0 -202
- package/dist/esm/block/BlockPage.d.ts +0 -15
- package/dist/esm/block/BlockPage.js +0 -197
- package/dist/esm/block/ChildrenDebug.d.ts +0 -15
- package/dist/esm/block/ChildrenDebug.js +0 -177
- package/dist/esm/block/MtBlockSS.d.ts +0 -6
- package/dist/esm/block/MtBlockSS.js +0 -10
- package/dist/esm/block/block-edit/MtBlockEditor.d.ts +0 -2
- package/dist/esm/block/block-edit/MtBlockEditor.js +0 -8
- package/dist/esm/block/block-store.d.ts +0 -14
- package/dist/esm/block/block-store.js +0 -79
- package/dist/esm/block/blockRegister.d.ts +0 -8
- package/dist/esm/block/blockRegister.js +0 -55
- package/dist/esm/block/blocks/Hello2Block.d.ts +0 -4
- package/dist/esm/block/blocks/Hello2Block.js +0 -12
- package/dist/esm/block/blocks/HelloBlock.d.ts +0 -5
- package/dist/esm/block/blocks/HelloBlock.js +0 -14
- package/dist/esm/block/blocks/HelloText.d.ts +0 -4
- package/dist/esm/block/blocks/HelloText.js +0 -12
- package/dist/esm/block/blocks/hello/Hello.d.ts +0 -4
- package/dist/esm/block/blocks/hello/Hello.js +0 -11
- package/dist/esm/block/blocks/hello/edit.d.ts +0 -5
- package/dist/esm/block/blocks/hello/edit.js +0 -15
- package/dist/esm/block/blocks/hello/index.d.ts +0 -9
- package/dist/esm/block/blocks/hello/index.js +0 -29
- package/dist/esm/block/blocks/hello2/index.d.ts +0 -4
- package/dist/esm/block/blocks/hello2/index.js +0 -12
- package/dist/esm/block/consts.d.ts +0 -1
- package/dist/esm/block/consts.js +0 -4
- package/dist/esm/cli/build.d.ts +0 -2
- package/dist/esm/cli/build.js +0 -60
- package/dist/esm/cli/deployMtWorker.d.ts +0 -2
- package/dist/esm/cli/deployMtWorker.js +0 -19
- package/dist/esm/cli/deploy_cf_worker.d.ts +0 -2
- package/dist/esm/cli/deploy_cf_worker.js +0 -70
- package/dist/esm/cli/deploy_mtxcli.d.ts +0 -2
- package/dist/esm/cli/deploy_mtxcli.js +0 -55
- package/dist/esm/cli/deploy_mtxedge.d.ts +0 -2
- package/dist/esm/cli/deploy_mtxedge.js +0 -55
- package/dist/esm/cli/deploy_mtxui.d.ts +0 -2
- package/dist/esm/cli/deploy_mtxui.js +0 -45
- package/dist/esm/cli/up_cf1.d.ts +0 -2
- package/dist/esm/cli/up_cf1.js +0 -29
- package/dist/esm/cli/utils.d.ts +0 -1
- package/dist/esm/cli/utils.js +0 -5
- package/dist/esm/cli/vc_mtxedge.d.ts +0 -2
- package/dist/esm/cli/vc_mtxedge.js +0 -44
- package/dist/esm/components/MtDate.d.ts +0 -6
- package/dist/esm/components/MtDate.js +0 -17
- package/dist/esm/components/MtmErrorView.d.ts +0 -7
- package/dist/esm/components/MtmErrorView.js +0 -16
- package/dist/esm/components/MtmInstallScript.d.ts +0 -2
- package/dist/esm/components/MtmInstallScript.js +0 -16
- package/dist/esm/components/SSR.d.ts +0 -11
- package/dist/esm/components/SSR.js +0 -76
- package/dist/esm/components/Tag.d.ts +0 -6
- package/dist/esm/components/Tag.js +0 -17
- package/dist/esm/components/auth/AuthPage.d.ts +0 -2
- package/dist/esm/components/auth/AuthPage.js +0 -36
- package/dist/esm/components/auth/LoginScreen2.d.ts +0 -2
- package/dist/esm/components/auth/LoginScreen2.js +0 -106
- package/dist/esm/components/auth/UserAuthForm.d.ts +0 -5
- package/dist/esm/components/auth/UserAuthForm.js +0 -76
- package/dist/esm/components/blog/BlogPostCreateForm.d.ts +0 -2
- package/dist/esm/components/blog/BlogPostCreateForm.js +0 -27
- package/dist/esm/components/blog/BlogPostImportDlgUrl.d.ts +0 -6
- package/dist/esm/components/blog/BlogPostImportDlgUrl.js +0 -94
- package/dist/esm/components/blog/PostEditForm.d.ts +0 -2
- package/dist/esm/components/blog/PostEditForm.js +0 -91
- package/dist/esm/components/blog/post-content.d.ts +0 -5
- package/dist/esm/components/blog/post-content.js +0 -15
- package/dist/esm/components/curdView/curdViewEditor.d.ts +0 -7
- package/dist/esm/components/curdView/curdViewEditor.js +0 -109
- package/dist/esm/components/devtools/GoMtmDebug.d.ts +0 -2
- package/dist/esm/components/devtools/GoMtmDebug.js +0 -48
- package/dist/esm/components/formFieldRender/SchemaFormFieldsRender.d.ts +0 -6
- package/dist/esm/components/formFieldRender/SchemaFormFieldsRender.js +0 -46
- package/dist/esm/components/site/SiteInfo.d.ts +0 -2
- package/dist/esm/components/site/SiteInfo.js +0 -15
- package/dist/esm/components/site/SiteSwitchDlg.d.ts +0 -0
- package/dist/esm/components/site/SiteSwitchDlg.js +0 -1
- package/dist/esm/connectquery/call-unary-method.d.ts +0 -8
- package/dist/esm/connectquery/call-unary-method.js +0 -47
- package/dist/esm/connectquery/connect-query-key.d.ts +0 -16
- package/dist/esm/connectquery/connect-query-key.js +0 -15
- package/dist/esm/connectquery/create-use-infinite-query-options.d.ts +0 -22
- package/dist/esm/connectquery/create-use-infinite-query-options.js +0 -93
- package/dist/esm/connectquery/create-use-query-options.d.ts +0 -21
- package/dist/esm/connectquery/create-use-query-options.js +0 -74
- package/dist/esm/connectquery/default-options.d.ts +0 -6
- package/dist/esm/connectquery/default-options.js +0 -9
- package/dist/esm/connectquery/index.d.ts +0 -16
- package/dist/esm/connectquery/index.js +0 -33
- package/dist/esm/connectquery/method-unary-descriptor.d.ts +0 -4
- package/dist/esm/connectquery/method-unary-descriptor.js +0 -0
- package/dist/esm/connectquery/use-infinite-query.d.ts +0 -14
- package/dist/esm/connectquery/use-infinite-query.js +0 -87
- package/dist/esm/connectquery/use-mutation.d.ts +0 -10
- package/dist/esm/connectquery/use-mutation.js +0 -79
- package/dist/esm/connectquery/use-query.d.ts +0 -14
- package/dist/esm/connectquery/use-query.js +0 -75
- package/dist/esm/connectquery/use-transport.d.ts +0 -7
- package/dist/esm/connectquery/use-transport.js +0 -23
- package/dist/esm/connectquery/utils.d.ts +0 -8
- package/dist/esm/connectquery/utils.js +0 -24
- package/dist/esm/consts.d.ts +0 -34
- package/dist/esm/consts.js +0 -70
- package/dist/esm/curd/CreateFormV2.d.ts +0 -16
- package/dist/esm/curd/CreateFormV2.js +0 -81
- package/dist/esm/curd/CurdView.d.ts +0 -4
- package/dist/esm/curd/CurdView.js +0 -35
- package/dist/esm/curd/CurdViewSS.d.ts +0 -4
- package/dist/esm/curd/CurdViewSS.js +0 -69
- package/dist/esm/curd/DynViews.d.ts +0 -6
- package/dist/esm/curd/DynViews.js +0 -69
- package/dist/esm/curd/ListPageCommands.d.ts +0 -2
- package/dist/esm/curd/ListPageCommands.js +0 -25
- package/dist/esm/curd/create/CurdCreatePanel.d.ts +0 -5
- package/dist/esm/curd/create/CurdCreatePanel.js +0 -47
- package/dist/esm/curd/create/useCurdCreate.d.ts +0 -7
- package/dist/esm/curd/create/useCurdCreate.js +0 -25
- package/dist/esm/curd/edit/CurdEditPanel.d.ts +0 -2
- package/dist/esm/curd/edit/CurdEditPanel.js +0 -60
- package/dist/esm/curd/edit/form-context.d.ts +0 -17
- package/dist/esm/curd/edit/form-context.js +0 -92
- package/dist/esm/curd/edit/formStore.d.ts +0 -17
- package/dist/esm/curd/edit/formStore.js +0 -92
- package/dist/esm/curd/edit/useCurdUpdateForm.d.ts +0 -7
- package/dist/esm/curd/edit/useCurdUpdateForm.js +0 -25
- package/dist/esm/curd/form/CurdEditPanel.d.ts +0 -2
- package/dist/esm/curd/form/CurdEditPanel.js +0 -36
- package/dist/esm/curd/form/FormShell.d.ts +0 -2
- package/dist/esm/curd/form/FormShell.js +0 -9
- package/dist/esm/curd/form/GomtmForm.d.ts +0 -2
- package/dist/esm/curd/form/GomtmForm.js +0 -46
- package/dist/esm/curd/form/formStore.d.ts +0 -31
- package/dist/esm/curd/form/formStore.js +0 -188
- package/dist/esm/curd/form/useCurdUpdateForm.d.ts +0 -7
- package/dist/esm/curd/form/useCurdUpdateForm.js +0 -25
- package/dist/esm/curd/form-context.d.ts +0 -17
- package/dist/esm/curd/form-context.js +0 -89
- package/dist/esm/curd/list-item/ListViewLayoutRender.d.ts +0 -15
- package/dist/esm/curd/list-item/ListViewLayoutRender.js +0 -220
- package/dist/esm/curd/listview/CommonListView.d.ts +0 -9
- package/dist/esm/curd/listview/CommonListView.js +0 -139
- package/dist/esm/curd/listview/CommonListViewV2.d.ts +0 -5
- package/dist/esm/curd/listview/CommonListViewV2.js +0 -66
- package/dist/esm/curd/listview/ListViewComponentsSetup.d.ts +0 -3
- package/dist/esm/curd/listview/ListViewComponentsSetup.js +0 -23
- package/dist/esm/curd/listview/ListViewRender.d.ts +0 -2
- package/dist/esm/curd/listview/ListViewRender.js +0 -20
- package/dist/esm/curd/listview/MtListView.d.ts +0 -3
- package/dist/esm/curd/listview/MtListView.js +0 -50
- package/dist/esm/curd/listview/list-store.d.ts +0 -34
- package/dist/esm/curd/listview/list-store.js +0 -90
- package/dist/esm/curd/listview/listview-layouts/default/index.d.ts +0 -2
- package/dist/esm/curd/listview/listview-layouts/default/index.js +0 -9
- package/dist/esm/curd/listview/listview-layouts/listviewlayout-demo/index.d.ts +0 -2
- package/dist/esm/curd/listview/listview-layouts/listviewlayout-demo/index.js +0 -12
- package/dist/esm/curd/mutationButton.d.ts +0 -7
- package/dist/esm/curd/mutationButton.js +0 -14
- package/dist/esm/curd/remove/RemovePanel.d.ts +0 -13
- package/dist/esm/curd/remove/RemovePanel.js +0 -72
- package/dist/esm/form/ConnectEsUpdateForm.d.ts +0 -17
- package/dist/esm/form/ConnectEsUpdateForm.js +0 -78
- package/dist/esm/form/GoMtmForm.d.ts +0 -5
- package/dist/esm/form/GoMtmForm.js +0 -31
- package/dist/esm/form/SchemaFormView.d.ts +0 -14
- package/dist/esm/form/SchemaFormView.js +0 -44
- package/dist/esm/gomtmQuery.d.ts +0 -7
- package/dist/esm/gomtmQuery.js +0 -86
- package/dist/esm/gomtmpb/descriptions/mtm/conf/conf.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/conf/conf.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/mtps/mtpspb/mtps.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/mtps/mtpspb/mtps.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/ai.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/ai.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/av.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/av.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/bot.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/bot.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/conf.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/conf.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/curd.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/curd.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/cx.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/cx.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/events.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/events.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/git.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/git.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/gitproject.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/gitproject.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/mtm.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/mtm.js +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/sp.d.ts +0 -0
- package/dist/esm/gomtmpb/descriptions/mtm/sppb/sp.js +0 -0
- package/dist/esm/gomtmpb/mtm/conf/conf-ConfService_connectquery.d.ts +0 -53
- package/dist/esm/gomtmpb/mtm/conf/conf-ConfService_connectquery.js +0 -60
- package/dist/esm/gomtmpb/mtm/conf/conf_connect.d.ts +0 -38
- package/dist/esm/gomtmpb/mtm/conf/conf_connect.js +0 -56
- package/dist/esm/gomtmpb/mtm/conf/conf_pb.d.ts +0 -481
- package/dist/esm/gomtmpb/mtm/conf/conf_pb.js +0 -2359
- package/dist/esm/gomtmpb/mtm/mtps/mtpspb/mtps-PsService_connectquery.d.ts +0 -52
- package/dist/esm/gomtmpb/mtm/mtps/mtpspb/mtps-PsService_connectquery.js +0 -59
- package/dist/esm/gomtmpb/mtm/mtps/mtpspb/mtps_connect.d.ts +0 -37
- package/dist/esm/gomtmpb/mtm/mtps/mtpspb/mtps_connect.js +0 -55
- package/dist/esm/gomtmpb/mtm/mtps/mtpspb/mtps_pb.d.ts +0 -154
- package/dist/esm/gomtmpb/mtm/mtps/mtpspb/mtps_pb.js +0 -530
- package/dist/esm/gomtmpb/mtm/sppb/ai-AiService_connectquery.d.ts +0 -22
- package/dist/esm/gomtmpb/mtm/sppb/ai-AiService_connectquery.js +0 -26
- package/dist/esm/gomtmpb/mtm/sppb/ai_connect.d.ts +0 -19
- package/dist/esm/gomtmpb/mtm/sppb/ai_connect.js +0 -32
- package/dist/esm/gomtmpb/mtm/sppb/ai_pb.d.ts +0 -47
- package/dist/esm/gomtmpb/mtm/sppb/ai_pb.js +0 -149
- package/dist/esm/gomtmpb/mtm/sppb/av-AvService_connectquery.d.ts +0 -53
- package/dist/esm/gomtmpb/mtm/sppb/av-AvService_connectquery.js +0 -60
- package/dist/esm/gomtmpb/mtm/sppb/av_connect.d.ts +0 -38
- package/dist/esm/gomtmpb/mtm/sppb/av_connect.js +0 -56
- package/dist/esm/gomtmpb/mtm/sppb/av_pb.d.ts +0 -77
- package/dist/esm/gomtmpb/mtm/sppb/av_pb.js +0 -290
- package/dist/esm/gomtmpb/mtm/sppb/bot-BotService_connectquery.d.ts +0 -173
- package/dist/esm/gomtmpb/mtm/sppb/bot-BotService_connectquery.js +0 -192
- package/dist/esm/gomtmpb/mtm/sppb/bot_connect.d.ts +0 -110
- package/dist/esm/gomtmpb/mtm/sppb/bot_connect.js +0 -180
- package/dist/esm/gomtmpb/mtm/sppb/bot_pb.d.ts +0 -722
- package/dist/esm/gomtmpb/mtm/sppb/bot_pb.js +0 -2291
- package/dist/esm/gomtmpb/mtm/sppb/conf-ConfService_connectquery.d.ts +0 -53
- package/dist/esm/gomtmpb/mtm/sppb/conf-ConfService_connectquery.js +0 -60
- package/dist/esm/gomtmpb/mtm/sppb/conf_connect.d.ts +0 -38
- package/dist/esm/gomtmpb/mtm/sppb/conf_connect.js +0 -56
- package/dist/esm/gomtmpb/mtm/sppb/conf_pb.d.ts +0 -472
- package/dist/esm/gomtmpb/mtm/sppb/conf_pb.js +0 -2357
- package/dist/esm/gomtmpb/mtm/sppb/curd-CurdService_connectquery.d.ts +0 -73
- package/dist/esm/gomtmpb/mtm/sppb/curd-CurdService_connectquery.js +0 -82
- package/dist/esm/gomtmpb/mtm/sppb/curd_connect.d.ts +0 -50
- package/dist/esm/gomtmpb/mtm/sppb/curd_connect.js +0 -79
- package/dist/esm/gomtmpb/mtm/sppb/curd_pb.d.ts +0 -199
- package/dist/esm/gomtmpb/mtm/sppb/curd_pb.js +0 -773
- package/dist/esm/gomtmpb/mtm/sppb/cx-CxService_connectquery.d.ts +0 -133
- package/dist/esm/gomtmpb/mtm/sppb/cx-CxService_connectquery.js +0 -148
- package/dist/esm/gomtmpb/mtm/sppb/cx_connect.d.ts +0 -86
- package/dist/esm/gomtmpb/mtm/sppb/cx_connect.js +0 -141
- package/dist/esm/gomtmpb/mtm/sppb/cx_pb.d.ts +0 -335
- package/dist/esm/gomtmpb/mtm/sppb/cx_pb.js +0 -1618
- package/dist/esm/gomtmpb/mtm/sppb/events_pb.d.ts +0 -231
- package/dist/esm/gomtmpb/mtm/sppb/events_pb.js +0 -874
- package/dist/esm/gomtmpb/mtm/sppb/git-GitService_connectquery.d.ts +0 -63
- package/dist/esm/gomtmpb/mtm/sppb/git-GitService_connectquery.js +0 -71
- package/dist/esm/gomtmpb/mtm/sppb/git_connect.d.ts +0 -44
- package/dist/esm/gomtmpb/mtm/sppb/git_connect.js +0 -67
- package/dist/esm/gomtmpb/mtm/sppb/git_pb.d.ts +0 -108
- package/dist/esm/gomtmpb/mtm/sppb/git_pb.js +0 -311
- package/dist/esm/gomtmpb/mtm/sppb/gitproject-GitProjectService_connectquery.d.ts +0 -12
- package/dist/esm/gomtmpb/mtm/sppb/gitproject-GitProjectService_connectquery.js +0 -15
- package/dist/esm/gomtmpb/mtm/sppb/gitproject_connect.d.ts +0 -13
- package/dist/esm/gomtmpb/mtm/sppb/gitproject_connect.js +0 -19
- package/dist/esm/gomtmpb/mtm/sppb/gitproject_pb.d.ts +0 -23
- package/dist/esm/gomtmpb/mtm/sppb/gitproject_pb.js +0 -67
- package/dist/esm/gomtmpb/mtm/sppb/mtm-MtmService_connectquery.d.ts +0 -392
- package/dist/esm/gomtmpb/mtm/sppb/mtm-MtmService_connectquery.js +0 -433
- package/dist/esm/gomtmpb/mtm/sppb/mtm_connect.d.ts +0 -241
- package/dist/esm/gomtmpb/mtm/sppb/mtm_connect.js +0 -395
- package/dist/esm/gomtmpb/mtm/sppb/mtm_pb.d.ts +0 -1675
- package/dist/esm/gomtmpb/mtm/sppb/mtm_pb.js +0 -6831
- package/dist/esm/gomtmpb/mtm/sppb/sp-SpService_connectquery.d.ts +0 -213
- package/dist/esm/gomtmpb/mtm/sppb/sp-SpService_connectquery.js +0 -236
- package/dist/esm/gomtmpb/mtm/sppb/sp_connect.d.ts +0 -134
- package/dist/esm/gomtmpb/mtm/sppb/sp_connect.js +0 -210
- package/dist/esm/gomtmpb/mtm/sppb/sp_pb.d.ts +0 -684
- package/dist/esm/gomtmpb/mtm/sppb/sp_pb.js +0 -2905
- package/dist/esm/index.d.ts +0 -3
- package/dist/esm/index.js +0 -5
- package/dist/esm/lib/auth/jwt.d.ts +0 -7
- package/dist/esm/lib/auth/jwt.js +0 -43
- package/dist/esm/lib/meta.d.ts +0 -10
- package/dist/esm/lib/meta.js +0 -76
- package/dist/esm/ly/LayoutBase.d.ts +0 -6
- package/dist/esm/ly/LayoutBase.js +0 -83
- package/dist/esm/ly/Lazy.d.ts +0 -2
- package/dist/esm/ly/Lazy.js +0 -12
- package/dist/esm/ly/UserAvatorMenus.d.ts +0 -2
- package/dist/esm/ly/UserAvatorMenus.js +0 -75
- package/dist/esm/ly/dash5/aside.d.ts +0 -2
- package/dist/esm/ly/dash5/aside.js +0 -40
- package/dist/esm/ly/dash5/components/PageCreate.d.ts +0 -4
- package/dist/esm/ly/dash5/components/PageCreate.js +0 -8
- package/dist/esm/ly/dash5/components/PageEdit.d.ts +0 -4
- package/dist/esm/ly/dash5/components/PageEdit.js +0 -8
- package/dist/esm/ly/dash5/components/PageList.d.ts +0 -4
- package/dist/esm/ly/dash5/components/PageList.js +0 -9
- package/dist/esm/ly/dash5/components/PageShow.d.ts +0 -4
- package/dist/esm/ly/dash5/components/PageShow.js +0 -8
- package/dist/esm/ly/dash5/header.d.ts +0 -2
- package/dist/esm/ly/dash5/header.js +0 -124
- package/dist/esm/ly/dash5/index.d.ts +0 -2
- package/dist/esm/ly/dash5/index.js +0 -25
- package/dist/esm/ly/debug-layout/index.d.ts +0 -2
- package/dist/esm/ly/debug-layout/index.js +0 -12
- package/dist/esm/ly/demo-layout/index.d.ts +0 -2
- package/dist/esm/ly/demo-layout/index.js +0 -9
- package/dist/esm/ly/front-layout/PageCmds.d.ts +0 -2
- package/dist/esm/ly/front-layout/PageCmds.js +0 -25
- package/dist/esm/ly/front-layout/PageSearchCmd.d.ts +0 -2
- package/dist/esm/ly/front-layout/PageSearchCmd.js +0 -70
- package/dist/esm/ly/front-layout/header.d.ts +0 -2
- package/dist/esm/ly/front-layout/header.js +0 -18
- package/dist/esm/ly/front-layout/headerv2.d.ts +0 -0
- package/dist/esm/ly/front-layout/headerv2.js +0 -0
- package/dist/esm/ly/front-layout/index.d.ts +0 -2
- package/dist/esm/ly/front-layout/index.js +0 -12
- package/dist/esm/ly/front-layout/main-nav.d.ts +0 -3
- package/dist/esm/ly/front-layout/main-nav.js +0 -116
- package/dist/esm/lzBizComponents.d.ts +0 -5
- package/dist/esm/lzBizComponents.js +0 -15
- package/dist/esm/main.d.ts +0 -2
- package/dist/esm/main.js +0 -34
- package/dist/esm/messageTypeRegistry.d.ts +0 -5
- package/dist/esm/messageTypeRegistry.js +0 -34
- package/dist/esm/mtmFetcher.d.ts +0 -30
- package/dist/esm/mtmFetcher.js +0 -211
- package/dist/esm/providers/AuthProvider.d.ts +0 -9
- package/dist/esm/providers/AuthProvider.js +0 -104
- package/dist/esm/providers/GomtmAppSS.d.ts +0 -2
- package/dist/esm/providers/GomtmAppSS.js +0 -71
- package/dist/esm/providers/LoggerProvider.d.ts +0 -10
- package/dist/esm/providers/LoggerProvider.js +0 -23
- package/dist/esm/providers/ReactQueryProvider.d.ts +0 -4
- package/dist/esm/providers/ReactQueryProvider.js +0 -67
- package/dist/esm/store/App_useTransition.d.ts +0 -2
- package/dist/esm/store/App_useTransition.js +0 -59
- package/dist/esm/store/GomtmAppSetting.d.ts +0 -2
- package/dist/esm/store/GomtmAppSetting.js +0 -18
- package/dist/esm/store/customStorage.d.ts +0 -2
- package/dist/esm/store/customStorage.js +0 -35
- package/dist/esm/store/mtapp-store.d.ts +0 -49
- package/dist/esm/store/mtapp-store.js +0 -157
- package/dist/esm/validations/CrawlerConfig.d.ts +0 -18
- package/dist/esm/validations/CrawlerConfig.js +0 -10
- package/dist/esm/validations/_common.d.ts +0 -57
- package/dist/esm/validations/_common.js +0 -30
- package/dist/esm/validations/auth.d.ts +0 -33
- package/dist/esm/validations/auth.js +0 -18
- package/dist/esm/validations/blog.d.ts +0 -17
- package/dist/esm/validations/blog.js +0 -10
- package/dist/esm/validations/crawlerSchema.d.ts +0 -17
- package/dist/esm/validations/crawlerSchema.js +0 -10
- package/dist/esm/validations/env.d.ts +0 -8
- package/dist/esm/validations/env.js +0 -9
- package/dist/esm/validations/post.d.ts +0 -34
- package/dist/esm/validations/post.js +0 -28
- package/dist/esm/validations/sp.d.ts +0 -18
- package/dist/esm/validations/sp.js +0 -12
- package/dist/esm/validations/spContentModi.d.ts +0 -62
- package/dist/esm/validations/spContentModi.js +0 -30
- package/dist/esm/validations/spHost.d.ts +0 -8
- package/dist/esm/validations/spHost.js +0 -7
- package/dist/esm/validations/spPage.d.ts +0 -14
- package/dist/esm/validations/spPage.js +0 -9
- package/dist/esm/validations/spRoute.d.ts +0 -57
- package/dist/esm/validations/spRoute.js +0 -28
- package/dist/esm/validations/user.d.ts +0 -64
- package/dist/esm/validations/user.js +0 -33
- package/dist/tsconfig.type.tsbuildinfo +0 -1
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import { debounce } from "lodash";
|
|
4
|
-
import { CommandDialog, CommandEmpty, CommandInput, CommandList, CommandSeparator } from "mtxuilib/ui/command";
|
|
5
|
-
import { useState } from "react";
|
|
6
|
-
import { useHotkeys } from "react-hotkeys-hook";
|
|
7
|
-
function PageCommands() {
|
|
8
|
-
const [open, setOpen] = useState(false);
|
|
9
|
-
useHotkeys("alt+d", () => {
|
|
10
|
-
console.log("PageCommands");
|
|
11
|
-
setOpen((open2) => !open2);
|
|
12
|
-
}, []);
|
|
13
|
-
const handleValueChange = (search) => {
|
|
14
|
-
};
|
|
15
|
-
return /* @__PURE__ */ jsxs(CommandDialog, { open, onOpenChange: setOpen, children: [
|
|
16
|
-
/* @__PURE__ */ jsx(CommandInput, { placeholder: "Type a command or search...", onValueChange: debounce(handleValueChange, 500) }),
|
|
17
|
-
/* @__PURE__ */ jsxs(CommandList, { children: [
|
|
18
|
-
/* @__PURE__ */ jsx(CommandEmpty, { children: "No results found." }),
|
|
19
|
-
/* @__PURE__ */ jsx(CommandSeparator, {})
|
|
20
|
-
] })
|
|
21
|
-
] });
|
|
22
|
-
}
|
|
23
|
-
export {
|
|
24
|
-
PageCommands
|
|
25
|
-
};
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __defProps = Object.defineProperties;
|
|
4
|
-
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
5
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
6
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
8
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
9
|
-
var __spreadValues = (a, b) => {
|
|
10
|
-
for (var prop in b || (b = {}))
|
|
11
|
-
if (__hasOwnProp.call(b, prop))
|
|
12
|
-
__defNormalProp(a, prop, b[prop]);
|
|
13
|
-
if (__getOwnPropSymbols)
|
|
14
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
15
|
-
if (__propIsEnum.call(b, prop))
|
|
16
|
-
__defNormalProp(a, prop, b[prop]);
|
|
17
|
-
}
|
|
18
|
-
return a;
|
|
19
|
-
};
|
|
20
|
-
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
21
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
22
|
-
import { Search } from "lucide-react";
|
|
23
|
-
import { CommandDialog, CommandEmpty, CommandInput, CommandList, CommandSeparator } from "mtxuilib/ui/command";
|
|
24
|
-
import { Input } from "mtxuilib/ui/input";
|
|
25
|
-
import { MtForm } from "mtxuilib/ui/ui-mt/MtForm";
|
|
26
|
-
import { useState } from "react";
|
|
27
|
-
import { useForm } from "react-hook-form";
|
|
28
|
-
import { useHotkeys } from "react-hotkeys-hook";
|
|
29
|
-
import { useGomtm } from "../../store/mtapp-store";
|
|
30
|
-
const PageSearchCmd = () => {
|
|
31
|
-
const [open, setOpen] = useState(false);
|
|
32
|
-
useHotkeys("alt+s", () => {
|
|
33
|
-
setOpen((open2) => !open2);
|
|
34
|
-
}, []);
|
|
35
|
-
const globalSearchParams = useGomtm((x) => x.globalSearchParams);
|
|
36
|
-
const setSearchParams = useGomtm((x) => x.setGlobalSearchParams);
|
|
37
|
-
const form = useForm();
|
|
38
|
-
return /* @__PURE__ */ jsxs(MtForm, __spreadProps(__spreadValues({}, form), { children: [
|
|
39
|
-
/* @__PURE__ */ jsx("form", { onSubmit: form.handleSubmit(() => {
|
|
40
|
-
}), children: /* @__PURE__ */ jsxs("div", { className: "relative ml-auto flex-1 md:grow-0", children: [
|
|
41
|
-
/* @__PURE__ */ jsx(Search, { className: "text-muted-foreground absolute left-2.5 top-2.5 h-4 w-4" }),
|
|
42
|
-
/* @__PURE__ */ jsx(
|
|
43
|
-
Input,
|
|
44
|
-
{
|
|
45
|
-
type: "search",
|
|
46
|
-
placeholder: "Search...",
|
|
47
|
-
className: "bg-background w-full rounded-lg pl-8 md:w-[200px] lg:w-[336px]",
|
|
48
|
-
defaultValue: globalSearchParams == null ? void 0 : globalSearchParams.q,
|
|
49
|
-
onChange: (e) => {
|
|
50
|
-
setSearchParams({
|
|
51
|
-
q: e.target.value
|
|
52
|
-
});
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
)
|
|
56
|
-
] }) }),
|
|
57
|
-
/* @__PURE__ */ jsxs(CommandDialog, { open, onOpenChange: setOpen, children: [
|
|
58
|
-
/* @__PURE__ */ jsx(CommandInput, { placeholder: "Type a command or search...", onValueChange: (s) => {
|
|
59
|
-
setOpen(false);
|
|
60
|
-
} }),
|
|
61
|
-
/* @__PURE__ */ jsxs(CommandList, { children: [
|
|
62
|
-
/* @__PURE__ */ jsx(CommandEmpty, { children: "No results found." }),
|
|
63
|
-
/* @__PURE__ */ jsx(CommandSeparator, {})
|
|
64
|
-
] })
|
|
65
|
-
] })
|
|
66
|
-
] }));
|
|
67
|
-
};
|
|
68
|
-
export {
|
|
69
|
-
PageSearchCmd
|
|
70
|
-
};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { MtLink } from "mtxuilib/common/mtlink";
|
|
3
|
-
import { Suspense } from "react";
|
|
4
|
-
import UserAvatorMenus from "../UserAvatorMenus";
|
|
5
|
-
import { PageSearchCmd } from "./PageSearchCmd";
|
|
6
|
-
import { MainNav } from "./main-nav";
|
|
7
|
-
const FrontLayoutHeader = () => {
|
|
8
|
-
return /* @__PURE__ */ jsx("header", { className: "bg-background/95 supports-[backdrop-filter]:bg-background/60 sticky top-0 z-10 w-full border-b backdrop-blur", children: /* @__PURE__ */ jsxs("div", { className: "flex h-14 items-center", children: [
|
|
9
|
-
/* @__PURE__ */ jsx("div", { className: "hidden w-52 items-center justify-center md:flex", children: /* @__PURE__ */ jsx(MtLink, { href: "/", className: "flex items-center space-x-2" }) }),
|
|
10
|
-
/* @__PURE__ */ jsx(MainNav, {}),
|
|
11
|
-
/* @__PURE__ */ jsx("nav", { className: " flex items-center space-x-6 text-sm font-medium" }),
|
|
12
|
-
/* @__PURE__ */ jsx(PageSearchCmd, {}),
|
|
13
|
-
/* @__PURE__ */ jsx("div", { className: "flex flex-1 shrink items-center justify-end space-x-2 pr-4", children: /* @__PURE__ */ jsx("nav", { className: "flex items-center", children: /* @__PURE__ */ jsx(Suspense, { children: /* @__PURE__ */ jsx(UserAvatorMenus, {}) }) }) })
|
|
14
|
-
] }) });
|
|
15
|
-
};
|
|
16
|
-
export {
|
|
17
|
-
FrontLayoutHeader
|
|
18
|
-
};
|
|
File without changes
|
|
File without changes
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { FrontLayoutHeader } from "./header";
|
|
3
|
-
function FrontLayout(props) {
|
|
4
|
-
const { children } = props;
|
|
5
|
-
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
6
|
-
/* @__PURE__ */ jsx(FrontLayoutHeader, {}),
|
|
7
|
-
children
|
|
8
|
-
] });
|
|
9
|
-
}
|
|
10
|
-
export {
|
|
11
|
-
FrontLayout as default
|
|
12
|
-
};
|
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __defProps = Object.defineProperties;
|
|
4
|
-
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
5
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
6
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
8
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
9
|
-
var __spreadValues = (a, b) => {
|
|
10
|
-
for (var prop in b || (b = {}))
|
|
11
|
-
if (__hasOwnProp.call(b, prop))
|
|
12
|
-
__defNormalProp(a, prop, b[prop]);
|
|
13
|
-
if (__getOwnPropSymbols)
|
|
14
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
15
|
-
if (__propIsEnum.call(b, prop))
|
|
16
|
-
__defNormalProp(a, prop, b[prop]);
|
|
17
|
-
}
|
|
18
|
-
return a;
|
|
19
|
-
};
|
|
20
|
-
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
21
|
-
var __objRest = (source, exclude) => {
|
|
22
|
-
var target = {};
|
|
23
|
-
for (var prop in source)
|
|
24
|
-
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
25
|
-
target[prop] = source[prop];
|
|
26
|
-
if (source != null && __getOwnPropSymbols)
|
|
27
|
-
for (var prop of __getOwnPropSymbols(source)) {
|
|
28
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
29
|
-
target[prop] = source[prop];
|
|
30
|
-
}
|
|
31
|
-
return target;
|
|
32
|
-
};
|
|
33
|
-
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
34
|
-
import { MtLink } from "mtxuilib/common/mtlink";
|
|
35
|
-
import { Icons } from "mtxuilib/icons/icons";
|
|
36
|
-
import { cn } from "mtxuilib/lib/utils";
|
|
37
|
-
import { ScrollArea } from "mtxuilib/ui/scroll-area";
|
|
38
|
-
import { Sheet, SheetContent, SheetTrigger } from "mtxuilib/ui/sheet";
|
|
39
|
-
import { MtButton } from "mtxuilib/ui/ui-mt/Button";
|
|
40
|
-
import Link from "next/link";
|
|
41
|
-
import { useRouter } from "next/navigation";
|
|
42
|
-
import { useState } from "react";
|
|
43
|
-
function MainNav() {
|
|
44
|
-
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
45
|
-
/* @__PURE__ */ jsx("div", { className: "flex gap-2 pl-2 md:gap-2", children: /* @__PURE__ */ jsx("div", { className: "pr-1", children: /* @__PURE__ */ jsx("nav", { className: "hidden gap-1 md:flex" }) }) }),
|
|
46
|
-
/* @__PURE__ */ jsx(MobileNav, {})
|
|
47
|
-
] });
|
|
48
|
-
}
|
|
49
|
-
function MobileNav() {
|
|
50
|
-
const [open, setOpen] = useState(false);
|
|
51
|
-
return /* @__PURE__ */ jsxs(Sheet, { open, onOpenChange: setOpen, children: [
|
|
52
|
-
/* @__PURE__ */ jsx(SheetTrigger, { asChild: true, children: /* @__PURE__ */ jsxs(
|
|
53
|
-
MtButton,
|
|
54
|
-
{
|
|
55
|
-
variant: "ghost",
|
|
56
|
-
className: "mr-2 px-0 text-base hover:bg-transparent focus-visible:bg-transparent focus-visible:ring-0 focus-visible:ring-offset-0 md:hidden",
|
|
57
|
-
children: [
|
|
58
|
-
/* @__PURE__ */ jsx(Icons.ellipsis, { className: "h-5 w-5" }),
|
|
59
|
-
/* @__PURE__ */ jsx("span", { className: "sr-only", children: "Toggle Menu" })
|
|
60
|
-
]
|
|
61
|
-
}
|
|
62
|
-
) }),
|
|
63
|
-
/* @__PURE__ */ jsxs(SheetContent, { side: "left", className: "pr-0", children: [
|
|
64
|
-
/* @__PURE__ */ jsx(
|
|
65
|
-
MobileLink,
|
|
66
|
-
{
|
|
67
|
-
href: "/",
|
|
68
|
-
className: "flex items-center",
|
|
69
|
-
onOpenChange: setOpen,
|
|
70
|
-
children: /* @__PURE__ */ jsx(Icons.logo, { className: "mr-2 h-4 w-4" })
|
|
71
|
-
}
|
|
72
|
-
),
|
|
73
|
-
/* @__PURE__ */ jsx(ScrollArea, { className: "my-4 h-[calc(100vh-8rem)] pb-10 pl-2", children: /* @__PURE__ */ jsx("div", { className: "flex flex-col space-y-2" }) })
|
|
74
|
-
] })
|
|
75
|
-
] });
|
|
76
|
-
}
|
|
77
|
-
function MobileLink(_a) {
|
|
78
|
-
var _b = _a, {
|
|
79
|
-
href,
|
|
80
|
-
onOpenChange,
|
|
81
|
-
className,
|
|
82
|
-
children
|
|
83
|
-
} = _b, props = __objRest(_b, [
|
|
84
|
-
"href",
|
|
85
|
-
"onOpenChange",
|
|
86
|
-
"className",
|
|
87
|
-
"children"
|
|
88
|
-
]);
|
|
89
|
-
const router = useRouter();
|
|
90
|
-
return /* @__PURE__ */ jsx(
|
|
91
|
-
Link,
|
|
92
|
-
__spreadProps(__spreadValues({
|
|
93
|
-
href,
|
|
94
|
-
onClick: () => {
|
|
95
|
-
router.push(href.toString());
|
|
96
|
-
onOpenChange == null ? void 0 : onOpenChange(false);
|
|
97
|
-
},
|
|
98
|
-
className: cn(className)
|
|
99
|
-
}, props), {
|
|
100
|
-
children
|
|
101
|
-
})
|
|
102
|
-
);
|
|
103
|
-
}
|
|
104
|
-
function MainNavOld() {
|
|
105
|
-
return /* @__PURE__ */ jsxs("div", { className: "mr-4 hidden md:flex", children: [
|
|
106
|
-
/* @__PURE__ */ jsxs(MtLink, { href: "/", className: "mr-6 flex items-center space-x-2", children: [
|
|
107
|
-
/* @__PURE__ */ jsx(Icons.logo, { className: "size-6" }),
|
|
108
|
-
/* @__PURE__ */ jsx("span", { className: "hidden font-bold sm:inline-block" })
|
|
109
|
-
] }),
|
|
110
|
-
/* @__PURE__ */ jsx("nav", { className: " flex items-center space-x-6 text-sm font-medium" })
|
|
111
|
-
] });
|
|
112
|
-
}
|
|
113
|
-
export {
|
|
114
|
-
MainNav,
|
|
115
|
-
MainNavOld
|
|
116
|
-
};
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsxs } from "react/jsx-runtime";
|
|
3
|
-
function registLazyComponent(name, comp) {
|
|
4
|
-
}
|
|
5
|
-
const LzBizComponent = (props) => {
|
|
6
|
-
const { name } = props;
|
|
7
|
-
return /* @__PURE__ */ jsxs("div", { className: "border bg-red-600 p-2 shadow-sm", children: [
|
|
8
|
-
"missing dyn biz component: ",
|
|
9
|
-
name
|
|
10
|
-
] });
|
|
11
|
-
};
|
|
12
|
-
export {
|
|
13
|
-
LzBizComponent,
|
|
14
|
-
registLazyComponent
|
|
15
|
-
};
|
package/dist/esm/main.d.ts
DELETED
package/dist/esm/main.js
DELETED
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
const import_meta = {};
|
|
3
|
-
import { program } from "commander";
|
|
4
|
-
import dotenv from "dotenv";
|
|
5
|
-
import path from "node:path";
|
|
6
|
-
import { fileURLToPath } from "node:url";
|
|
7
|
-
import { registerCommandTurboBuild } from "./cli/build";
|
|
8
|
-
import { cmdDeployMtworker } from "./cli/deployMtWorker";
|
|
9
|
-
import { cmdDpCfworker } from "./cli/deploy_cf_worker";
|
|
10
|
-
import { cmdDpMtxcli } from "./cli/deploy_mtxcli";
|
|
11
|
-
import { cmdDpMtxedge } from "./cli/deploy_mtxedge";
|
|
12
|
-
import { cmdDpMtxui } from "./cli/deploy_mtxui";
|
|
13
|
-
import { cmdUpMtxui } from "./cli/up_cf1";
|
|
14
|
-
import { cmdVcMtxedge } from "./cli/vc_mtxedge";
|
|
15
|
-
const __filename = fileURLToPath(import_meta.url);
|
|
16
|
-
const __dirname = path.dirname(__filename);
|
|
17
|
-
const packageResolve = import_meta.resolve;
|
|
18
|
-
const envPath = path.resolve("../../../env/dev.env");
|
|
19
|
-
console.log("envPath", envPath);
|
|
20
|
-
const dotenvConfig = dotenv.config({
|
|
21
|
-
path: envPath
|
|
22
|
-
});
|
|
23
|
-
if (dotenvConfig.error) {
|
|
24
|
-
throw new Error("parse env error", dotenvConfig.error);
|
|
25
|
-
}
|
|
26
|
-
registerCommandTurboBuild(program);
|
|
27
|
-
cmdDeployMtworker(program);
|
|
28
|
-
cmdDpMtxedge(program);
|
|
29
|
-
cmdVcMtxedge(program);
|
|
30
|
-
cmdDpMtxcli(program);
|
|
31
|
-
cmdDpMtxui(program);
|
|
32
|
-
cmdDpCfworker(program);
|
|
33
|
-
cmdUpMtxui(program);
|
|
34
|
-
program.parse();
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { IMessageTypeRegistry, ServiceType } from "@bufbuild/protobuf";
|
|
2
|
-
export declare const anypbTypeReg: IMessageTypeRegistry;
|
|
3
|
-
export declare const allServices: Record<string, ServiceType>;
|
|
4
|
-
export declare const registerService: (...s: ServiceType[]) => void;
|
|
5
|
-
export declare const GetMtmServiceByTypeName: (serviceTypeName: string) => ServiceType;
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { createRegistry } from "@bufbuild/protobuf";
|
|
2
|
-
import { BotService } from "./gomtmpb/mtm/sppb/bot_connect";
|
|
3
|
-
import { CmdStartNoVnc, CmdStartSimpleCrawler, ConsumMessageReq, CxPageReq } from "./gomtmpb/mtm/sppb/bot_pb";
|
|
4
|
-
import { CxService } from "./gomtmpb/mtm/sppb/cx_connect";
|
|
5
|
-
import { MtmService } from "./gomtmpb/mtm/sppb/mtm_connect";
|
|
6
|
-
import { SpService } from "./gomtmpb/mtm/sppb/sp_connect";
|
|
7
|
-
const anypbTypeReg = createRegistry(
|
|
8
|
-
CxPageReq,
|
|
9
|
-
ConsumMessageReq,
|
|
10
|
-
CmdStartNoVnc,
|
|
11
|
-
CmdStartSimpleCrawler
|
|
12
|
-
);
|
|
13
|
-
const allServices = {};
|
|
14
|
-
const registerService = (...s) => {
|
|
15
|
-
s.map((item) => {
|
|
16
|
-
const servieTypeName = item.typeName;
|
|
17
|
-
allServices[servieTypeName] = item;
|
|
18
|
-
});
|
|
19
|
-
};
|
|
20
|
-
const GetMtmServiceByTypeName = (serviceTypeName) => {
|
|
21
|
-
return allServices[serviceTypeName];
|
|
22
|
-
};
|
|
23
|
-
registerService(
|
|
24
|
-
MtmService,
|
|
25
|
-
SpService,
|
|
26
|
-
BotService,
|
|
27
|
-
CxService
|
|
28
|
-
);
|
|
29
|
-
export {
|
|
30
|
-
GetMtmServiceByTypeName,
|
|
31
|
-
allServices,
|
|
32
|
-
anypbTypeReg,
|
|
33
|
-
registerService
|
|
34
|
-
};
|
package/dist/esm/mtmFetcher.d.ts
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { ServiceType } from "@bufbuild/protobuf";
|
|
2
|
-
export declare const createQueryKey: (svc: string, method: string, input?: any) => any[];
|
|
3
|
-
export declare const createInfiniteQueryKey: (svc: string, method: string, input: any) => any[];
|
|
4
|
-
interface goMtmQueryFnProps {
|
|
5
|
-
svc: string;
|
|
6
|
-
method: string;
|
|
7
|
-
input?: any;
|
|
8
|
-
options?: {
|
|
9
|
-
url?: string;
|
|
10
|
-
token?: string;
|
|
11
|
-
cookieStr?: string;
|
|
12
|
-
gomtmHost: string;
|
|
13
|
-
cacheEnabled?: boolean;
|
|
14
|
-
};
|
|
15
|
-
}
|
|
16
|
-
export declare const goMtmQueryFn: (props: goMtmQueryFnProps) => Promise<any>;
|
|
17
|
-
export declare const ssrGetBackendUrl: () => string;
|
|
18
|
-
export declare const gomtmApiUrl: () => string;
|
|
19
|
-
export declare function createMtmServiceClient<T extends ServiceType>(service: T, url?: string): import("@connectrpc/connect").PromiseClient<T>;
|
|
20
|
-
export declare function createTransport(): import("@connectrpc/connect").Transport;
|
|
21
|
-
export declare function createMtmServiceClientByName<T extends ServiceType>(svcName: string, url?: string, token?: string, gomtmHost?: string, cacheEnabled?: boolean): import("@connectrpc/connect").PromiseClient<ServiceType>;
|
|
22
|
-
type CustomRequestInit = RequestInit & {
|
|
23
|
-
cookieStr?: string;
|
|
24
|
-
token?: string;
|
|
25
|
-
enableCache?: boolean;
|
|
26
|
-
enableLog?: boolean;
|
|
27
|
-
gomtmHost?: string;
|
|
28
|
-
};
|
|
29
|
-
export declare const gomtmFetcher: (initGlobal?: CustomRequestInit) => (input: string | URL | globalThis.Request, init?: CustomRequestInit) => Promise<Response>;
|
|
30
|
-
export {};
|
package/dist/esm/mtmFetcher.js
DELETED
|
@@ -1,211 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
3
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
4
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
5
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
6
|
-
var __spreadValues = (a, b) => {
|
|
7
|
-
for (var prop in b || (b = {}))
|
|
8
|
-
if (__hasOwnProp.call(b, prop))
|
|
9
|
-
__defNormalProp(a, prop, b[prop]);
|
|
10
|
-
if (__getOwnPropSymbols)
|
|
11
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
12
|
-
if (__propIsEnum.call(b, prop))
|
|
13
|
-
__defNormalProp(a, prop, b[prop]);
|
|
14
|
-
}
|
|
15
|
-
return a;
|
|
16
|
-
};
|
|
17
|
-
var __async = (__this, __arguments, generator) => {
|
|
18
|
-
return new Promise((resolve, reject) => {
|
|
19
|
-
var fulfilled = (value) => {
|
|
20
|
-
try {
|
|
21
|
-
step(generator.next(value));
|
|
22
|
-
} catch (e) {
|
|
23
|
-
reject(e);
|
|
24
|
-
}
|
|
25
|
-
};
|
|
26
|
-
var rejected = (value) => {
|
|
27
|
-
try {
|
|
28
|
-
step(generator.throw(value));
|
|
29
|
-
} catch (e) {
|
|
30
|
-
reject(e);
|
|
31
|
-
}
|
|
32
|
-
};
|
|
33
|
-
var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
|
|
34
|
-
step((generator = generator.apply(__this, __arguments)).next());
|
|
35
|
-
});
|
|
36
|
-
};
|
|
37
|
-
import { toPlainMessage } from "@bufbuild/protobuf";
|
|
38
|
-
import { createPromiseClient } from "@connectrpc/connect";
|
|
39
|
-
import { createConnectTransport } from "@connectrpc/connect-web";
|
|
40
|
-
import { camelCase, merge } from "lodash";
|
|
41
|
-
import { fetchMiddleWithCache } from "mtxlib/http/fetchMiddleWithCache";
|
|
42
|
-
import { CONST_HeaderMtmHost, MTM_API_PREFIX } from "./consts";
|
|
43
|
-
import { CurdService } from "./gomtmpb/mtm/sppb/curd_connect";
|
|
44
|
-
import { MtmService } from "./gomtmpb/mtm/sppb/mtm_connect";
|
|
45
|
-
import { MtmError } from "./gomtmpb/mtm/sppb/mtm_pb";
|
|
46
|
-
const allServices = [
|
|
47
|
-
MtmService,
|
|
48
|
-
CurdService
|
|
49
|
-
];
|
|
50
|
-
const createQueryKey = (svc, method, input) => {
|
|
51
|
-
return [svc, method, input || {}];
|
|
52
|
-
};
|
|
53
|
-
const createInfiniteQueryKey = (svc, method, input) => {
|
|
54
|
-
return [...createQueryKey(svc, method, input), "infinite"];
|
|
55
|
-
};
|
|
56
|
-
const goMtmQueryFn = (props) => __async(void 0, null, function* () {
|
|
57
|
-
var _a, _b, _c;
|
|
58
|
-
const client = createMtmServiceClientByName(
|
|
59
|
-
props.svc,
|
|
60
|
-
(_a = props.options) == null ? void 0 : _a.url,
|
|
61
|
-
(_b = props.options) == null ? void 0 : _b.token,
|
|
62
|
-
(_c = props.options) == null ? void 0 : _c.gomtmHost
|
|
63
|
-
);
|
|
64
|
-
if (!client) {
|
|
65
|
-
throw new Error(`missing mtmclient:"${props.svc}"`);
|
|
66
|
-
}
|
|
67
|
-
const methodName = camelCase(props.method);
|
|
68
|
-
const methodFn = client[methodName];
|
|
69
|
-
if (!methodFn) {
|
|
70
|
-
throw new Error(`missing mtmclient method:"${props.svc}.${methodName}"`);
|
|
71
|
-
}
|
|
72
|
-
try {
|
|
73
|
-
const data = yield methodFn(props.input);
|
|
74
|
-
return toPlainMessage(data);
|
|
75
|
-
} catch (e) {
|
|
76
|
-
console.log("[goMtmQueryFn]\u51FA\u9519", e);
|
|
77
|
-
return toPlainMessage(new MtmError({
|
|
78
|
-
errCode: "error call gomtm client",
|
|
79
|
-
errMessage: e.toString()
|
|
80
|
-
}));
|
|
81
|
-
}
|
|
82
|
-
});
|
|
83
|
-
const ssrGetBackendUrl = () => {
|
|
84
|
-
var _a;
|
|
85
|
-
if (typeof window == "undefined") {
|
|
86
|
-
if ((_a = process == null ? void 0 : process.env) == null ? void 0 : _a.MTM_BACKEND) {
|
|
87
|
-
return process.env.MTM_BACKEND;
|
|
88
|
-
}
|
|
89
|
-
if (process.env.VERCEL_URL) {
|
|
90
|
-
return `https://${process.env.VERCEL_URL}`;
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
return "";
|
|
94
|
-
};
|
|
95
|
-
const gomtmApiUrl = () => {
|
|
96
|
-
const baseUrl = ssrGetBackendUrl();
|
|
97
|
-
const apiUrl = new URL(MTM_API_PREFIX, baseUrl).toString();
|
|
98
|
-
console.info("gomtm apiUrl:", baseUrl);
|
|
99
|
-
return apiUrl;
|
|
100
|
-
};
|
|
101
|
-
function createMtmServiceClient(service, url) {
|
|
102
|
-
return createPromiseClient(
|
|
103
|
-
service,
|
|
104
|
-
createTransport()
|
|
105
|
-
);
|
|
106
|
-
}
|
|
107
|
-
function createTransport() {
|
|
108
|
-
return createConnectTransport({
|
|
109
|
-
baseUrl: gomtmApiUrl(),
|
|
110
|
-
fetch: gomtmFetcher(),
|
|
111
|
-
useHttpGet: true
|
|
112
|
-
});
|
|
113
|
-
}
|
|
114
|
-
function createMtmServiceClientByName(svcName, url, token, gomtmHost, cacheEnabled) {
|
|
115
|
-
let svcType = void 0;
|
|
116
|
-
for (const a of allServices) {
|
|
117
|
-
if (a.typeName == svcName) {
|
|
118
|
-
svcType = a;
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
if (!svcType) {
|
|
122
|
-
throw new Error(`unknown svcType ${svcName}`);
|
|
123
|
-
}
|
|
124
|
-
const baseUrl = url || gomtmApiUrl();
|
|
125
|
-
return createPromiseClient(
|
|
126
|
-
svcType,
|
|
127
|
-
createConnectTransport({
|
|
128
|
-
baseUrl,
|
|
129
|
-
fetch: gomtmFetcher({
|
|
130
|
-
cookieStr: token,
|
|
131
|
-
token,
|
|
132
|
-
gomtmHost,
|
|
133
|
-
enableCache: cacheEnabled
|
|
134
|
-
})
|
|
135
|
-
})
|
|
136
|
-
);
|
|
137
|
-
}
|
|
138
|
-
const gomtmFetcher = (initGlobal) => {
|
|
139
|
-
const token = initGlobal == null ? void 0 : initGlobal.token;
|
|
140
|
-
return (input, init) => __async(void 0, null, function* () {
|
|
141
|
-
if (init) {
|
|
142
|
-
delete init.mode;
|
|
143
|
-
delete init.credentials;
|
|
144
|
-
}
|
|
145
|
-
const req = merge(init, initGlobal, {
|
|
146
|
-
redirect: "follow"
|
|
147
|
-
}) || {};
|
|
148
|
-
if (!init) {
|
|
149
|
-
init = {};
|
|
150
|
-
}
|
|
151
|
-
if (init.body instanceof Uint8Array) {
|
|
152
|
-
const decoder = new TextDecoder();
|
|
153
|
-
init.body = decoder.decode(init.body);
|
|
154
|
-
}
|
|
155
|
-
let cookieStr1 = initGlobal == null ? void 0 : initGlobal.cookieStr;
|
|
156
|
-
if (typeof window == "undefined") {
|
|
157
|
-
cookieStr1 = (yield import("next/headers")).headers().get("cookie") || "";
|
|
158
|
-
}
|
|
159
|
-
let gomtmHost = initGlobal == null ? void 0 : initGlobal.gomtmHost;
|
|
160
|
-
if (!gomtmHost && typeof window == "undefined") {
|
|
161
|
-
gomtmHost = (yield import("next/headers")).headers().get("host") || "";
|
|
162
|
-
}
|
|
163
|
-
init = __spreadValues(__spreadValues({}, init), {
|
|
164
|
-
headers: __spreadValues(__spreadValues(__spreadValues({
|
|
165
|
-
// ...init.headers,
|
|
166
|
-
"Content-Type": "application/json"
|
|
167
|
-
}, cookieStr1 && { "Cookie": cookieStr1 }), token && { "Authorization": "Bearer " + token }), gomtmHost && { [CONST_HeaderMtmHost]: gomtmHost })
|
|
168
|
-
});
|
|
169
|
-
let fetcher = fetch;
|
|
170
|
-
req.enableCache = initGlobal == null ? void 0 : initGlobal.enableCache;
|
|
171
|
-
if (req.enableCache) {
|
|
172
|
-
fetcher = fetchMiddleWithCache(fetch);
|
|
173
|
-
}
|
|
174
|
-
try {
|
|
175
|
-
console.info("[mtmfetch]", {
|
|
176
|
-
input,
|
|
177
|
-
init
|
|
178
|
-
});
|
|
179
|
-
const responseData = yield fetcher(input, init);
|
|
180
|
-
return responseData;
|
|
181
|
-
} catch (e) {
|
|
182
|
-
console.error("[mtmfetch error]", {
|
|
183
|
-
input,
|
|
184
|
-
error: e,
|
|
185
|
-
init
|
|
186
|
-
});
|
|
187
|
-
const errorRsp = {
|
|
188
|
-
errCode: "-1",
|
|
189
|
-
errMessage: (e == null ? void 0 : e.toString()) || "unknow error"
|
|
190
|
-
};
|
|
191
|
-
const errorResponse = new Response(JSON.stringify(errorRsp), {
|
|
192
|
-
status: 200,
|
|
193
|
-
headers: {
|
|
194
|
-
"Content-Type": "application/json"
|
|
195
|
-
}
|
|
196
|
-
});
|
|
197
|
-
return errorResponse;
|
|
198
|
-
}
|
|
199
|
-
});
|
|
200
|
-
};
|
|
201
|
-
export {
|
|
202
|
-
createInfiniteQueryKey,
|
|
203
|
-
createMtmServiceClient,
|
|
204
|
-
createMtmServiceClientByName,
|
|
205
|
-
createQueryKey,
|
|
206
|
-
createTransport,
|
|
207
|
-
goMtmQueryFn,
|
|
208
|
-
gomtmApiUrl,
|
|
209
|
-
gomtmFetcher,
|
|
210
|
-
ssrGetBackendUrl
|
|
211
|
-
};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export declare function isRoleMatch(currentRoles: string[], allowRoles?: string[]): boolean;
|
|
2
|
-
export declare function useAuth(): {
|
|
3
|
-
userId: any;
|
|
4
|
-
};
|
|
5
|
-
export declare function useLogout(): () => void;
|
|
6
|
-
export declare function useLogin(): {
|
|
7
|
-
login: (values: any) => Promise<void>;
|
|
8
|
-
};
|
|
9
|
-
export declare function useIsLogined(): boolean;
|