cnhis-design-vue 3.2.4-release.6 → 3.2.4-release.8
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +87 -87
- package/es/components/big-table/src/components/edit-form/edit-select.d.ts +1 -1
- package/es/components/big-table/src/hooks/useEdit.d.ts +1 -1
- package/es/components/biunique-chat/index.d.ts +14 -1
- package/es/components/biunique-chat/src/Index.vue.d.ts +14 -1
- package/es/components/biunique-chat/src/Index.vue2.js +1 -1
- package/es/components/biunique-chat/src/components/ChatFile.vue.d.ts +4 -0
- package/es/components/biunique-chat/src/components/ChatFile.vue2.js +1 -1
- package/es/components/biunique-chat/src/components/ChatFooter.vue.d.ts +4 -0
- package/es/components/biunique-chat/src/components/ChatFooter.vue2.js +1 -1
- package/es/components/biunique-chat/src/components/ChatHeader.vue.d.ts +3 -0
- package/es/components/biunique-chat/src/components/ChatMain.vue.d.ts +8 -2
- package/es/components/biunique-chat/src/components/ChatMain.vue2.js +1 -1
- package/es/components/biunique-chat/src/constants/index.d.ts +3 -1
- package/es/components/biunique-chat/src/constants/index.js +1 -1
- package/es/components/biunique-chat/src/hooks/useSession.js +1 -1
- package/es/components/biunique-chat/src/types/index.d.ts +1 -0
- package/es/components/biunique-chat/src/utils/index.d.ts +3 -1
- package/es/components/biunique-chat/src/utils/index.js +1 -1
- package/es/components/biunique-chat/style/index.css +1 -1
- package/es/components/button-print/index.d.ts +3836 -1371
- package/es/components/button-print/src/ButtonPrint.vue.d.ts +3838 -1371
- package/es/components/button-print/src/ButtonPrint.vue2.js +1 -1
- package/es/components/button-print/src/components/NewPrintComponent.vue.d.ts +2068 -0
- package/es/components/button-print/src/components/NewPrintComponent.vue.js +1 -0
- package/es/components/button-print/src/components/NewPrintComponent.vue2.js +1 -0
- package/es/components/button-print/src/components/OldPrintComponent.vue.d.ts +1996 -0
- package/es/components/button-print/src/components/OldPrintComponent.vue.js +1 -0
- package/es/components/button-print/src/components/OldPrintComponent.vue2.js +1 -0
- package/es/components/button-print/src/constants/index.d.ts +2 -0
- package/es/components/button-print/src/constants/index.js +1 -0
- package/es/components/button-print/src/utils/print.d.ts +1 -0
- package/es/components/button-print/src/utils/print.js +1 -1
- package/es/components/button-print/style/index.css +1 -1
- package/es/components/callback/src/components/render/popupMaps.d.ts +8 -0
- package/es/components/classification/index.d.ts +1 -1
- package/es/components/classification/src/components/search-filter/index.vue.d.ts +1 -1
- package/es/components/classification/src/components/set-classification/index.vue.d.ts +1 -1
- package/es/components/classification/src/index.vue.d.ts +1 -4
- package/es/components/expand-field/index.d.ts +13 -0
- package/es/components/expand-field/src/components/FormItemPerson.vue.d.ts +13 -0
- package/es/components/expand-field/src/components/PersonModal.vue.d.ts +13 -0
- package/es/components/expand-field/src/components/form.vue.d.ts +13 -0
- package/es/components/expand-field/src/index.vue.d.ts +13 -0
- package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useTop.js +1 -1
- package/es/components/fabric-chart/src/hooks/temperature/useCenter.js +1 -1
- package/es/components/fabric-chart/src/hooks/temperature/useLeft.js +1 -1
- package/es/components/fabric-chart/src/hooks/temperature/useTemperatureChart.js +1 -1
- package/es/components/fabric-chart/src/interface.d.ts +1 -0
- package/es/components/field-set/index.d.ts +14 -1
- package/es/components/field-set/src/FieldColor.vue.d.ts +5 -25
- package/es/components/field-set/src/FieldFilter.vue.d.ts +488 -0
- package/es/components/field-set/src/FieldFilter.vue.js +1 -0
- package/es/components/field-set/src/FieldFilter.vue2.js +1 -0
- package/es/components/field-set/src/FieldSet.vue.d.ts +5 -25
- package/es/components/field-set/src/Index.vue.d.ts +15 -2
- package/es/components/field-set/src/Index.vue2.js +1 -1
- package/es/components/field-set/src/components/Row.vue.d.ts +6 -9
- package/es/components/field-set/src/components/Row.vue2.js +1 -1
- package/es/components/field-set/src/constants/filter.d.ts +93 -0
- package/es/components/field-set/src/constants/filter.js +1 -0
- package/es/components/field-set/src/types/index.d.ts +14 -1
- package/es/components/field-set/src/utils/index.d.ts +1 -0
- package/es/components/field-set/src/utils/index.js +1 -1
- package/es/components/form-config/index.d.ts +50 -7070
- package/es/components/form-config/src/FormConfig.vue.d.ts +84 -7104
- package/es/components/form-config/src/FormConfig.vue2.js +1 -1
- package/es/components/iho-table/index.d.ts +8 -0
- package/es/components/iho-table/src/IhoTable.vue.d.ts +8 -0
- package/es/components/iho-table/src/IhoTable.vue2.js +1 -1
- package/es/components/iho-table/src/constants/index.d.ts +2 -1
- package/es/components/iho-table/src/constants/index.js +1 -1
- package/es/components/iho-table/src/plugins/defaultConfigPlugin.js +1 -1
- package/es/components/iho-table/src/plugins/index.js +1 -1
- package/es/components/iho-table/src/plugins/pagerScrollPlugin/index.d.ts +1 -0
- package/es/components/iho-table/src/plugins/pagerScrollPlugin/index.js +1 -0
- package/es/components/iho-table/src/plugins/pagerScrollPlugin/pagerScroll.vue.d.ts +26 -0
- package/es/components/iho-table/src/plugins/pagerScrollPlugin/pagerScroll.vue.js +1 -0
- package/es/components/iho-table/src/plugins/pagerScrollPlugin/pagerScroll.vue2.js +1 -0
- package/es/components/iho-table/src/plugins/pagerScrollPlugin/types.d.ts +16 -0
- package/es/components/iho-table/src/plugins/pagerScrollPlugin/types.js +1 -0
- package/es/components/iho-table/src/plugins/pagerScrollPlugin/utils.d.ts +51 -0
- package/es/components/iho-table/src/plugins/pagerScrollPlugin/utils.js +1 -0
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/levelSearchCascadePlugin/levelSearchCascade.vue.d.ts +1 -1
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/editSelect.d.ts +2 -2
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/editSelect.js +1 -1
- package/es/components/iho-table/src/plugins/verticalTablePlugin/src/hooks/index.js +1 -1
- package/es/components/iho-table/src/plugins/verticalTablePlugin/src/hooks/useRowClassName.d.ts +2 -0
- package/es/components/iho-table/src/plugins/verticalTablePlugin/src/hooks/useRowClassName.js +1 -0
- package/es/components/iho-table/src/types/index.d.ts +4 -0
- package/es/components/iho-table/src/utils/index.d.ts +1 -0
- package/es/components/iho-table/src/utils/index.js +1 -1
- package/es/components/iho-table/style/index.css +1 -1
- package/es/components/index.css +1 -1
- package/es/components/scale-view/src/ScaleView.vue2.js +1 -1
- package/es/components/search-cascader/index.d.ts +1 -1
- package/es/components/search-cascader/src/SearchCascader.vue.d.ts +1 -1
- package/es/components/select-label/src/LabelFormContent.vue2.js +1 -1
- package/es/components/select-person/index.d.ts +13 -0
- package/es/components/select-person/src/SearchMultiple.vue.d.ts +6 -0
- package/es/components/select-person/src/SearchOrgAndStaff.vue.d.ts +13 -0
- package/es/components/select-person/src/SearchOrgAndStaff.vue2.js +1 -1
- package/es/components/select-person/src/SelectPerson.vue.d.ts +13 -0
- package/es/components/select-person/src/SelectPerson.vue2.js +1 -1
- package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue.d.ts +1 -1
- package/es/components/table-filter/src/components/classify-filter/components/SelectDynamic.vue.d.ts +1 -1
- package/es/components/table-filter/src/components/classify-filter/components/index.d.ts +1 -1
- package/es/components/table-filter/src/components/classify-filter/index.vue.d.ts +1 -1
- package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue.d.ts +1 -1
- package/es/components/table-filter/src/components/render-widget/components/SelectDynamicOption/index.vue.d.ts +1 -1
- package/es/components/table-filter/src/components/render-widget/components/index.d.ts +1 -1
- package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.d.ts +1 -1
- package/es/shared/assets/img/defaultCover/10review_successful.png.js +1 -1
- package/es/shared/assets/img/defaultCover/11review_fail.png.js +1 -1
- package/es/shared/assets/img/defaultCover/12no_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/13no_menu_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/14no_call_setting.png.js +1 -1
- package/es/shared/assets/img/defaultCover/15no_use_tag.png.js +1 -1
- package/es/shared/assets/img/defaultCover/16no_table_data.png.js +1 -1
- package/es/shared/assets/img/defaultCover/1location.png.js +1 -1
- package/es/shared/assets/img/defaultCover/2notfound.png.js +1 -1
- package/es/shared/assets/img/defaultCover/3loading.png.js +1 -1
- package/es/shared/assets/img/defaultCover/4no_permission.png.js +1 -1
- package/es/shared/assets/img/defaultCover/5no_data.png.js +1 -1
- package/es/shared/assets/img/defaultCover/6no_network.png.js +1 -1
- package/es/shared/assets/img/defaultCover/7no_doctor.png.js +1 -1
- package/es/shared/assets/img/defaultCover/8system_error.png.js +1 -1
- package/es/shared/assets/img/defaultCover/9system_upgrade.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_001.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_002.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_003.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_004.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_005.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_006.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_007.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_008.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_009.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_010.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_011.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_012.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_013.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_014.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_015.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_016.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_017.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_018.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_019.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_020.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_021.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_022.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_023.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_024.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_025.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_026.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_027.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_028.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_029.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_030.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_031.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_032.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_033.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_034.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_035.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_036.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_037.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_038.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_039.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_040.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_041.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_042.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_043.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_044.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_045.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_046.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_047.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_048.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_049.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_050.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_051.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_052.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_053.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_054.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_055.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_056.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_057.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_058.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_059.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_060.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_061.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_062.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_063.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_064.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_065.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_066.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_067.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_068.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_069.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_070.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_071.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_072.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_073.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_074.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_075.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_076.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_077.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_078.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_079.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_080.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_081.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_082.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_083.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_084.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_085.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_086.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_087.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_088.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_089.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_090.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_091.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_092.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_093.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_094.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_095.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_096.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_097.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_098.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_099.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_100.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_101.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_102.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_103.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_104.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_105.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_106.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_107.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_108.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_109.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_110.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_111.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_112.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_113.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_114.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_115.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_116.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_117.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_118.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_119.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_120.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_121.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_122.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_123.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_124.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_125.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_126.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_127.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_128.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_129.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_130.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_131.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_132.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_133.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_134.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_135.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_136.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_137.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_138.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_139.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_140.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_141.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_142.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_143.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_144.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_145.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_146.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_147.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_148.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_149.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_150.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_151.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_152.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_153.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_154.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_155.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_156.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_157.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_158.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_159.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_160.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_161.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_162.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_163.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_164.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_165.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_166.png.js +1 -1
- package/es/shared/assets/img/emoji/emotion_167.png.js +1 -1
- package/es/shared/assets/img/failure.png.js +1 -1
- package/es/shared/assets/img/no-permission.png.js +1 -1
- package/es/shared/assets/img/nodata.png.js +1 -1
- package/es/shared/assets/img/notfound.png.js +1 -1
- package/es/shared/assets/img/qr.png.js +1 -1
- package/es/shared/assets/img/success.png.js +1 -1
- package/es/shared/assets/img/table_style_2.png.js +1 -1
- package/es/shared/assets/img/tooth/l-b-1.png.js +1 -1
- package/es/shared/assets/img/tooth/l-b-2.png.js +1 -1
- package/es/shared/assets/img/tooth/l-b-3.png.js +1 -1
- package/es/shared/assets/img/tooth/l-b-4.png.js +1 -1
- package/es/shared/assets/img/tooth/l-b-5.png.js +1 -1
- package/es/shared/assets/img/tooth/l-b-6.png.js +1 -1
- package/es/shared/assets/img/tooth/l-b-7.png.js +1 -1
- package/es/shared/assets/img/tooth/l-b-8.png.js +1 -1
- package/es/shared/assets/img/tooth/l-t-1.png.js +1 -1
- package/es/shared/assets/img/tooth/l-t-2.png.js +1 -1
- package/es/shared/assets/img/tooth/l-t-3.png.js +1 -1
- package/es/shared/assets/img/tooth/l-t-4.png.js +1 -1
- package/es/shared/assets/img/tooth/l-t-5.png.js +1 -1
- package/es/shared/assets/img/tooth/l-t-6.png.js +1 -1
- package/es/shared/assets/img/tooth/l-t-7.png.js +1 -1
- package/es/shared/assets/img/tooth/l-t-8.png.js +1 -1
- package/es/shared/assets/img/tooth/r-b-1.png.js +1 -1
- package/es/shared/assets/img/tooth/r-b-2.png.js +1 -1
- package/es/shared/assets/img/tooth/r-b-3.png.js +1 -1
- package/es/shared/assets/img/tooth/r-b-4.png.js +1 -1
- package/es/shared/assets/img/tooth/r-b-5.png.js +1 -1
- package/es/shared/assets/img/tooth/r-b-6.png.js +1 -1
- package/es/shared/assets/img/tooth/r-b-7.png.js +1 -1
- package/es/shared/assets/img/tooth/r-b-8.png.js +1 -1
- package/es/shared/assets/img/tooth/r-t-1.png.js +1 -1
- package/es/shared/assets/img/tooth/r-t-2.png.js +1 -1
- package/es/shared/assets/img/tooth/r-t-3.png.js +1 -1
- package/es/shared/assets/img/tooth/r-t-4.png.js +1 -1
- package/es/shared/assets/img/tooth/r-t-5.png.js +1 -1
- package/es/shared/assets/img/tooth/r-t-6.png.js +1 -1
- package/es/shared/assets/img/tooth/r-t-7.png.js +1 -1
- package/es/shared/assets/img/tooth/r-t-8.png.js +1 -1
- package/es/shared/assets/img/video.png.js +1 -1
- package/es/shared/assets/img/video_default_cover.png.js +1 -1
- package/es/shared/assets/img/xb_big.png.js +1 -1
- package/es/shared/assets/img/xb_small.png.js +1 -1
- package/es/shared/package.json.js +1 -1
- package/package.json +2 -2
- package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
- package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +0 -1
- package/es/components/bpmn-workflow/types/ModelingModule.d.ts +0 -1
- package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +0 -1
- package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +0 -86
- package/es/shared/utils/fabricjs/index.d.ts +0 -6823
- package/es/shared/utils/tapable/index.d.ts +0 -139
package/README.md
CHANGED
@@ -1,87 +1,87 @@
|
|
1
|
-
# 安装
|
2
|
-
|
3
|
-
```shell
|
4
|
-
npm i cnhis-design-vue@[版本号]
|
5
|
-
# or
|
6
|
-
yarn add cnhis-design-vue@[版本号] #推荐
|
7
|
-
```
|
8
|
-
|
9
|
-
## 1.全局引入
|
10
|
-
|
11
|
-
```typescript
|
12
|
-
// main.ts
|
13
|
-
import { createApp } from 'vue';
|
14
|
-
import App from './App.vue';
|
15
|
-
import 'cnhis-design-vue/es/packages/index.css';
|
16
|
-
import cui from 'cnhis-design-vue';
|
17
|
-
|
18
|
-
const app = createApp(App);
|
19
|
-
app.use(cui).mount('#app');
|
20
|
-
```
|
21
|
-
|
22
|
-
## 2. 按需引入
|
23
|
-
|
24
|
-
组件现在支持了自动按需引入, 但是样式文件需要额外的处理
|
25
|
-
|
26
|
-
### 2.1 样式处理方式1 (按需引入样式)
|
27
|
-
|
28
|
-
```shell
|
29
|
-
# 安装自动导入样式的插件
|
30
|
-
npm i -d vite-plugin-style-import
|
31
|
-
```
|
32
|
-
|
33
|
-
```typescript
|
34
|
-
// vite.config.ts
|
35
|
-
import { defineConfig } from 'vite';
|
36
|
-
import { createStyleImportPlugin } from 'vite-plugin-style-import';
|
37
|
-
|
38
|
-
export default defineConfig({
|
39
|
-
plugins: [
|
40
|
-
// ...otherPlugins
|
41
|
-
createStyleImportPlugin({
|
42
|
-
libs: [
|
43
|
-
{
|
44
|
-
libraryName: 'cnhis-design-vue',
|
45
|
-
esModule: true,
|
46
|
-
ensureStyleFile: true,
|
47
|
-
resolveStyle: name => {
|
48
|
-
return `cnhis-design-vue/es/components/${ name.slice(2) }/style/index.css`;
|
49
|
-
}
|
50
|
-
}
|
51
|
-
]
|
52
|
-
})
|
53
|
-
]
|
54
|
-
});
|
55
|
-
```
|
56
|
-
|
57
|
-
### 2.2 样式处理方式2 (全局引入样式)
|
58
|
-
|
59
|
-
```typescript
|
60
|
-
// main.ts
|
61
|
-
import 'cnhis-design-vue/es/components/index.css';
|
62
|
-
```
|
63
|
-
|
64
|
-
## 3.FAQ
|
65
|
-
|
66
|
-
### 3.1 项目打包后样式丢失
|
67
|
-
|
68
|
-
处理方法, 将 cnhis-design-vue 从 vendor 包中移除 (没有出现此问题则不需要)
|
69
|
-
|
70
|
-
```typescript
|
71
|
-
// vite.config.ts
|
72
|
-
import { defineConfig } from 'vite';
|
73
|
-
|
74
|
-
export default defineConfig({
|
75
|
-
build: {
|
76
|
-
rollupOptions: {
|
77
|
-
// ..otherOptions
|
78
|
-
output: {
|
79
|
-
dir: './dist',
|
80
|
-
manualChunks: {
|
81
|
-
'cnhis-vendor': ['cnhis-design-vue']
|
82
|
-
}
|
83
|
-
}
|
84
|
-
}
|
85
|
-
}
|
86
|
-
});
|
87
|
-
```
|
1
|
+
# 安装
|
2
|
+
|
3
|
+
```shell
|
4
|
+
npm i cnhis-design-vue@[版本号]
|
5
|
+
# or
|
6
|
+
yarn add cnhis-design-vue@[版本号] #推荐
|
7
|
+
```
|
8
|
+
|
9
|
+
## 1.全局引入
|
10
|
+
|
11
|
+
```typescript
|
12
|
+
// main.ts
|
13
|
+
import { createApp } from 'vue';
|
14
|
+
import App from './App.vue';
|
15
|
+
import 'cnhis-design-vue/es/packages/index.css';
|
16
|
+
import cui from 'cnhis-design-vue';
|
17
|
+
|
18
|
+
const app = createApp(App);
|
19
|
+
app.use(cui).mount('#app');
|
20
|
+
```
|
21
|
+
|
22
|
+
## 2. 按需引入
|
23
|
+
|
24
|
+
组件现在支持了自动按需引入, 但是样式文件需要额外的处理
|
25
|
+
|
26
|
+
### 2.1 样式处理方式1 (按需引入样式)
|
27
|
+
|
28
|
+
```shell
|
29
|
+
# 安装自动导入样式的插件
|
30
|
+
npm i -d vite-plugin-style-import
|
31
|
+
```
|
32
|
+
|
33
|
+
```typescript
|
34
|
+
// vite.config.ts
|
35
|
+
import { defineConfig } from 'vite';
|
36
|
+
import { createStyleImportPlugin } from 'vite-plugin-style-import';
|
37
|
+
|
38
|
+
export default defineConfig({
|
39
|
+
plugins: [
|
40
|
+
// ...otherPlugins
|
41
|
+
createStyleImportPlugin({
|
42
|
+
libs: [
|
43
|
+
{
|
44
|
+
libraryName: 'cnhis-design-vue',
|
45
|
+
esModule: true,
|
46
|
+
ensureStyleFile: true,
|
47
|
+
resolveStyle: name => {
|
48
|
+
return `cnhis-design-vue/es/components/${ name.slice(2) }/style/index.css`;
|
49
|
+
}
|
50
|
+
}
|
51
|
+
]
|
52
|
+
})
|
53
|
+
]
|
54
|
+
});
|
55
|
+
```
|
56
|
+
|
57
|
+
### 2.2 样式处理方式2 (全局引入样式)
|
58
|
+
|
59
|
+
```typescript
|
60
|
+
// main.ts
|
61
|
+
import 'cnhis-design-vue/es/components/index.css';
|
62
|
+
```
|
63
|
+
|
64
|
+
## 3.FAQ
|
65
|
+
|
66
|
+
### 3.1 项目打包后样式丢失
|
67
|
+
|
68
|
+
处理方法, 将 cnhis-design-vue 从 vendor 包中移除 (没有出现此问题则不需要)
|
69
|
+
|
70
|
+
```typescript
|
71
|
+
// vite.config.ts
|
72
|
+
import { defineConfig } from 'vite';
|
73
|
+
|
74
|
+
export default defineConfig({
|
75
|
+
build: {
|
76
|
+
rollupOptions: {
|
77
|
+
// ..otherOptions
|
78
|
+
output: {
|
79
|
+
dir: './dist',
|
80
|
+
manualChunks: {
|
81
|
+
'cnhis-vendor': ['cnhis-design-vue']
|
82
|
+
}
|
83
|
+
}
|
84
|
+
}
|
85
|
+
}
|
86
|
+
});
|
87
|
+
```
|
@@ -11,7 +11,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
11
11
|
type: (NumberConstructor | ObjectConstructor)[];
|
12
12
|
default: number;
|
13
13
|
};
|
14
|
-
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("formChange" | "setOptions")[], "
|
14
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("formChange" | "setOptions")[], "setOptions" | "formChange", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
15
15
|
col: {
|
16
16
|
type: ObjectConstructor;
|
17
17
|
default: () => {};
|
@@ -96,7 +96,7 @@ export declare const comps: {
|
|
96
96
|
type: (NumberConstructor | ObjectConstructor)[];
|
97
97
|
default: number;
|
98
98
|
};
|
99
|
-
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("formChange" | "setOptions")[], "
|
99
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("formChange" | "setOptions")[], "setOptions" | "formChange", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
100
100
|
col: {
|
101
101
|
type: ObjectConstructor;
|
102
102
|
default: () => {};
|
@@ -54,6 +54,7 @@ declare const BiuniqueChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
54
54
|
isChangeSession: boolean;
|
55
55
|
updateSessionItem: import("../../shared/types").AnyObject;
|
56
56
|
isUpdateSession: boolean;
|
57
|
+
currentReferenceMsg: import("../../shared/types").AnyObject;
|
57
58
|
};
|
58
59
|
reConnention: number;
|
59
60
|
openSession: (item: import("../../shared/types").AnyObject) => Promise<void>;
|
@@ -840,6 +841,7 @@ declare const BiuniqueChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
840
841
|
type: BooleanConstructor;
|
841
842
|
};
|
842
843
|
}, {
|
844
|
+
cssVars: import("vue").ComputedRef<import("vue").CSSProperties>;
|
843
845
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
844
846
|
type: {
|
845
847
|
type: StringConstructor;
|
@@ -869,6 +871,7 @@ declare const BiuniqueChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
869
871
|
resetAndSearch: () => void;
|
870
872
|
title: import("vue").ComputedRef<"聊天图片" | "聊天文件">;
|
871
873
|
getDetail: (item: import("../../shared/types").AnyObject) => string;
|
874
|
+
getFileType: (item: import("../../shared/types").AnyObject) => any;
|
872
875
|
NModal: any;
|
873
876
|
NImageGroup: import("vue").DefineComponent<{
|
874
877
|
showToolbar: {
|
@@ -1075,6 +1078,7 @@ declare const BiuniqueChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
1075
1078
|
SearchOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1076
1079
|
OpenOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1077
1080
|
DownloadOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1081
|
+
downloadFile: typeof import("./src/utils").downloadFile;
|
1078
1082
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
1079
1083
|
type: {
|
1080
1084
|
type: StringConstructor;
|
@@ -1245,7 +1249,7 @@ declare const BiuniqueChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
1245
1249
|
needShowTime: (item: import("../../shared/types").AnyObject, index: number) => boolean;
|
1246
1250
|
setScrollToButtom: () => Promise<void>;
|
1247
1251
|
resetInfo: () => void;
|
1248
|
-
|
1252
|
+
setReferenceMsg: (msgItem: import("../../shared/types").AnyObject) => void;
|
1249
1253
|
NAvatar: any;
|
1250
1254
|
NImageGroup: import("vue").DefineComponent<{
|
1251
1255
|
showToolbar: {
|
@@ -1447,6 +1451,7 @@ declare const BiuniqueChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
1447
1451
|
showToolbarTooltip: boolean;
|
1448
1452
|
}>;
|
1449
1453
|
NImage: any;
|
1454
|
+
NIcon: any;
|
1450
1455
|
PersonProfile: import("vue").DefineComponent<{
|
1451
1456
|
userId: {
|
1452
1457
|
type: StringConstructor;
|
@@ -1591,7 +1596,12 @@ declare const BiuniqueChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
1591
1596
|
}>>, {}>;
|
1592
1597
|
images: import("vue").Ref<any[]>;
|
1593
1598
|
formatTime: typeof import("./src/utils").formatTime;
|
1599
|
+
downloadFile: typeof import("./src/utils").downloadFile;
|
1600
|
+
simplifyMessage: typeof import("./src/utils").simplifyMessage;
|
1594
1601
|
MESSAGE_TYPE: typeof import("./src/constants").MESSAGE_TYPE;
|
1602
|
+
AddCircleOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1603
|
+
ChatbubbleEllipsesOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1604
|
+
EllipsisHorizontal: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1595
1605
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1596
1606
|
ChatFooter: import("vue").DefineComponent<{}, {
|
1597
1607
|
inputRef: import("vue").Ref<HTMLDivElement | undefined>;
|
@@ -1623,9 +1633,12 @@ declare const BiuniqueChat: SFCWithInstall<import("vue").DefineComponent<{
|
|
1623
1633
|
}>>, {
|
1624
1634
|
abstract: boolean;
|
1625
1635
|
}>;
|
1636
|
+
NIcon: any;
|
1626
1637
|
images: import("vue").Ref<any[]>;
|
1627
1638
|
alt: string[];
|
1628
1639
|
MESSAGE_TYPE: typeof import("./src/constants").MESSAGE_TYPE;
|
1640
|
+
CloseCircleOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1641
|
+
simplifyMessage: typeof import("./src/utils").simplifyMessage;
|
1629
1642
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1630
1643
|
ChatSearch: import("vue").DefineComponent<{}, {
|
1631
1644
|
cssVars: import("vue").ComputedRef<import("vue").CSSProperties>;
|
@@ -57,6 +57,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
57
57
|
isChangeSession: boolean;
|
58
58
|
updateSessionItem: AnyObject;
|
59
59
|
isUpdateSession: boolean;
|
60
|
+
currentReferenceMsg: AnyObject;
|
60
61
|
};
|
61
62
|
reConnention: number;
|
62
63
|
openSession: (item: AnyObject) => Promise<void>;
|
@@ -843,6 +844,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
843
844
|
type: BooleanConstructor;
|
844
845
|
};
|
845
846
|
}, {
|
847
|
+
cssVars: import("vue").ComputedRef<import("vue").CSSProperties>;
|
846
848
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
847
849
|
type: {
|
848
850
|
type: StringConstructor;
|
@@ -872,6 +874,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
872
874
|
resetAndSearch: () => void;
|
873
875
|
title: import("vue").ComputedRef<"聊天图片" | "聊天文件">;
|
874
876
|
getDetail: (item: AnyObject) => string;
|
877
|
+
getFileType: (item: AnyObject) => any;
|
875
878
|
NModal: any;
|
876
879
|
NImageGroup: import("vue").DefineComponent<{
|
877
880
|
showToolbar: {
|
@@ -1078,6 +1081,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
1078
1081
|
SearchOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1079
1082
|
OpenOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1080
1083
|
DownloadOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1084
|
+
downloadFile: typeof import("./utils").downloadFile;
|
1081
1085
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
1082
1086
|
type: {
|
1083
1087
|
type: StringConstructor;
|
@@ -1248,7 +1252,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
1248
1252
|
needShowTime: (item: AnyObject, index: number) => boolean;
|
1249
1253
|
setScrollToButtom: () => Promise<void>;
|
1250
1254
|
resetInfo: () => void;
|
1251
|
-
|
1255
|
+
setReferenceMsg: (msgItem: AnyObject) => void;
|
1252
1256
|
NAvatar: any;
|
1253
1257
|
NImageGroup: import("vue").DefineComponent<{
|
1254
1258
|
showToolbar: {
|
@@ -1450,6 +1454,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
1450
1454
|
showToolbarTooltip: boolean;
|
1451
1455
|
}>;
|
1452
1456
|
NImage: any;
|
1457
|
+
NIcon: any;
|
1453
1458
|
PersonProfile: import("vue").DefineComponent<{
|
1454
1459
|
userId: {
|
1455
1460
|
type: StringConstructor;
|
@@ -1594,7 +1599,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
1594
1599
|
}>>, {}>;
|
1595
1600
|
images: import("vue").Ref<any[]>;
|
1596
1601
|
formatTime: typeof import("./utils").formatTime;
|
1602
|
+
downloadFile: typeof import("./utils").downloadFile;
|
1603
|
+
simplifyMessage: typeof import("./utils").simplifyMessage;
|
1597
1604
|
MESSAGE_TYPE: typeof import("./constants").MESSAGE_TYPE;
|
1605
|
+
AddCircleOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1606
|
+
ChatbubbleEllipsesOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1607
|
+
EllipsisHorizontal: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1598
1608
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1599
1609
|
ChatFooter: import("vue").DefineComponent<{}, {
|
1600
1610
|
inputRef: import("vue").Ref<HTMLDivElement | undefined>;
|
@@ -1626,9 +1636,12 @@ declare const _default: import("vue").DefineComponent<{
|
|
1626
1636
|
}>>, {
|
1627
1637
|
abstract: boolean;
|
1628
1638
|
}>;
|
1639
|
+
NIcon: any;
|
1629
1640
|
images: import("vue").Ref<any[]>;
|
1630
1641
|
alt: string[];
|
1631
1642
|
MESSAGE_TYPE: typeof import("./constants").MESSAGE_TYPE;
|
1643
|
+
CloseCircleOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1644
|
+
simplifyMessage: typeof import("./utils").simplifyMessage;
|
1632
1645
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
1633
1646
|
ChatSearch: import("vue").DefineComponent<{}, {
|
1634
1647
|
cssVars: import("vue").ComputedRef<import("vue").CSSProperties>;
|
@@ -1 +1 @@
|
|
1
|
-
import{defineComponent as e,ref as s,reactive as o,provide as t,onBeforeUnmount as r,openBlock as n,createElementBlock as i,normalizeStyle as a,unref as c,createVNode as u,withCtx as d,createBlock as m,Fragment as p,createElementVNode as l,renderSlot as h}from"vue";import{NConfigProvider as f,NSpin as S,NLayout as g,NLayoutContent as v}from"naive-ui";import b from"./components/SiderList.vue.js";import I from"./components/ChatHeader.vue.js";import y from"./components/ChatMain.vue.js";import j from"./components/ChatFooter.vue.js";import k from"./components/ChatSearch.vue.js";import{ChatSock as _}from"./utils/chatSock.js";import{instanceAxios as C,readMessageApi as L}from"./api/index.js";import{useTheme as N}from"../../../shared/hooks/useTheme.js";import"@vueuse/core";import"date-fns";import{isNumber as
|
1
|
+
import{defineComponent as e,ref as s,reactive as o,provide as t,onBeforeUnmount as r,openBlock as n,createElementBlock as i,normalizeStyle as a,unref as c,createVNode as u,withCtx as d,createBlock as m,Fragment as p,createElementVNode as l,renderSlot as h}from"vue";import{NConfigProvider as f,NSpin as S,NLayout as g,NLayoutContent as v}from"naive-ui";import b from"./components/SiderList.vue.js";import I from"./components/ChatHeader.vue.js";import y from"./components/ChatMain.vue.js";import j from"./components/ChatFooter.vue.js";import k from"./components/ChatSearch.vue.js";import{ChatSock as _}from"./utils/chatSock.js";import{instanceAxios as C,readMessageApi as L}from"./api/index.js";import{useTheme as N}from"../../../shared/hooks/useTheme.js";import"@vueuse/core";import"date-fns";import{isNumber as M}from"lodash-es";import"@vue/shared";import"../../../shared/utils/index.js";import"@vueuse/shared";import"../../../shared/hooks/selectHooks/useSearchContent.js";import"@vicons/ionicons5";import{SUBSCRIBE_MESSAGE_TYPE as x}from"./constants/index.js";import{InjectionIChatState as U,InjectionIChatStompClient as q,InjectionIChatEmits as T}from"./types/index.js";import"./utils/emoji.js";import{useSession as A}from"./hooks/useSession.js";const E={class:"c-biunique-chat__header"},O={class:"toolbar"};var w=e({__name:"Index",props:{token:{type:String,required:!0},orgId:{type:[String,Number],required:!0},userId:{type:String,required:!0},baseURL:{type:String,default:"/fdp-chat"}},emits:["template-click","unread-message-update"],setup(e,{expose:w,emit:R}){const V=e;C.defaults.baseURL=V.baseURL,C.defaults.headers.Authorization="bearer "+V.token;const J=N(),F=s(!1),G=s(),H=o({orgId:V.orgId,currentSessionItem:{},id:"",userInfo:{id:V.userId},msgList:[],currentMsg:{},isAppendMsg:!1,sessionList:[],isChangeSession:!1,updateSessionItem:{},isUpdateSession:!1,currentReferenceMsg:{}});t(U,H),t(q,G),t(T,R);const{openSession:$,closeSession:z,getCurrentSession:D,setSessionList:W,setUpdateSessionItem:B}=A(H);function K(){const e={headers:{AccessToken:V.token,UserId:V.userId},heartbeatFn(){try{G.value.send("test")}catch(e){G.value.disconnect(),K()}},connectCb(){console.log("连接成功"),G.value.subscribe("/user/topic/single",(async({body:e})=>{try{console.log(JSON.parse(e),"订阅新增消息");const s=JSON.parse(e),{messageVo:o,sessionVo:t}=s;switch(s.event){case x.MESSAGE:{if(s.messageVo.sender===H.userInfo.id)return;const e={receiver:o.sender,lastMessageSendTime:o.sendTime,sortTime:o.sendTime,lastMessage:o.content};o.sender===H.currentSessionItem.receiver&&(H.currentMsg=o,H.isAppendMsg=!0,await L({chatType:"SINGLE",messageIdSet:o.id,receiver:H.userInfo.id,sender:o.sender}),e.unreadNum=0),B(e);break}case x.NEW_SESSION:B(t)}}catch(e){console.log(e)}})),G.value.subscribe("/app/sessionList",(({body:e})=>{try{const s=JSON.parse(e),{currentUser:o,sessionVos:t}=s;if(console.log("body",s),Object.assign(H.userInfo,o),!(null==t?void 0:t.length))return;W(t)}catch(e){console.log(e)}}))},errorCb(e,s){console.log("断线了,正在重连...")}};G.value=new _("/fdp-chat/websocket",e)}return async function(){K()}(),r((()=>{var e;null==(e=G.value)||e.disconnect()})),w({getUnreadData:function(){return H.sessionList.filter((e=>M(e.unreadNum)&&e.unreadNum>0))},openSession:$,closeSession:z,getCurrentSession:D}),(e,s)=>(n(),i("div",{class:"c-biunique-chat",style:a(c(J))},[u(c(f),{abstract:"",namespace:"c-biunique-chat__popover"},{default:d((()=>[F.value?(n(),m(c(S),{key:0,stroke:"#5585f5"})):(n(),i(p,{key:1},[l("div",E,[u(k),l("div",O,[h(e.$slots,"toolbar")])]),u(c(g),{class:"c-biunique-chat__body","has-sider":""},{default:d((()=>[u(b),u(c(v),{class:"chat-content"},{default:d((()=>[u(I),u(y),u(j)])),_:1}),h(e.$slots,"external")])),_:3})],64))])),_:3})],4))}});export{w as default};
|
@@ -1,5 +1,6 @@
|
|
1
1
|
import { PropType } from 'vue';
|
2
2
|
import { AnyObject } from '../../../../shared/types';
|
3
|
+
import { downloadFile } from '../utils';
|
3
4
|
declare const _default: import("vue").DefineComponent<{
|
4
5
|
type: {
|
5
6
|
type: StringConstructor;
|
@@ -9,6 +10,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
9
10
|
type: BooleanConstructor;
|
10
11
|
};
|
11
12
|
}, {
|
13
|
+
cssVars: import("vue").ComputedRef<import("vue").CSSProperties>;
|
12
14
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
13
15
|
type: {
|
14
16
|
type: StringConstructor;
|
@@ -38,6 +40,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
38
40
|
resetAndSearch: () => void;
|
39
41
|
title: import("vue").ComputedRef<"聊天图片" | "聊天文件">;
|
40
42
|
getDetail: (item: AnyObject) => string;
|
43
|
+
getFileType: (item: AnyObject) => any;
|
41
44
|
NModal: any;
|
42
45
|
NImageGroup: import("vue").DefineComponent<{
|
43
46
|
showToolbar: {
|
@@ -244,6 +247,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
244
247
|
SearchOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
245
248
|
OpenOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
246
249
|
DownloadOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
250
|
+
downloadFile: typeof downloadFile;
|
247
251
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
248
252
|
type: {
|
249
253
|
type: StringConstructor;
|
@@ -1 +1 @@
|
|
1
|
-
import{defineComponent as e,ref as t,computed as
|
1
|
+
import{defineComponent as e,ref as t,computed as s,watch as a,openBlock as o,createBlock as n,unref as i,withCtx as l,withDirectives as r,createElementVNode as c,createVNode as m,createElementBlock as p,Fragment as d,renderList as u,toDisplayString as y,vShow as f,normalizeStyle as g}from"vue";import{NModal as v,NImageGroup as h,NImage as w,NInput as b,NIcon as M}from"naive-ui";import{SearchOutline as k,OpenOutline as T,DownloadOutline as I}from"@vicons/ionicons5";import{searchChatRecordApi as S}from"../api/index.js";import{useScrollLoading as _}from"../hooks/useScrollLoading.js";import{format as x,isSameWeek as j,isSameMonth as A}from"date-fns";import{useState as H}from"../hooks/useState.js";import{getFileSize as D,downloadFile as C}from"../utils/index.js";import{last as z}from"lodash-es";import{useDebounceFn as L}from"@vueuse/core";import{useTheme as U}from"../../../../shared/hooks/useTheme.js";import"@vue/shared";import"../../../../shared/utils/index.js";import"@vueuse/shared";import"../../../../shared/hooks/selectHooks/useSearchContent.js";const E={class:"label"},O={class:"image-box"},$={class:"file-type"},F={class:"text"},K={class:"name"},P={class:"detail"},R={class:"opt-box"};var B=e({__name:"ChatFile",props:{type:{type:String,default:"image"},visible:{type:Boolean}},setup(e){const B=e,G=U(),{state:N}=H(),q=t([]),J=t([]),Q=t(),V=t(),W=t(),X=L(ee,500),Y={page:0,hasMore:!0,lastSendTime:x(new Date,"yyyy-MM-dd HH:mm:ss")};async function Z(){var e;try{if(!Y.hasMore)return;Y.page++;const t=await S({orgId:N.orgId,keyword:W.value,endTime:"",startTime:"",lastSendTime:Y.lastSendTime,memberIdSet:[],page:Y.page,recordType:"image"===B.type?"IMAGE":"FILE",sessionKey:N.currentSessionItem.sessionKey,userId:N.userInfo.id});Array.isArray(t)&&0!==t.length&&Array.isArray(t[0].recordList)||(Y.hasMore=!1,console.log("接口返回不是一个数组,或者没有更多消息了"));let s=t||[];if(Array.isArray(t)&&t.length>0&&(s=t[0].recordList),Y.lastSendTime=null==(e=z(s))?void 0:e.sendTime,"image"===B.type){const e=function(e){const t={};e.forEach((e=>{const s=new Date(e.sendTime);let a=x(s,"yyyy年MM月");j(s,new Date)?a="本周":A(s,new Date)&&(a="本月"),t[a]||(t[a]=[]),t[a].push(e.content.msg)}));return Object.entries(t).map((([e,t])=>({label:e,list:t})))}(s);q.value=Y.page>1?q.value.concat(e):e}else{const e=s.map((e=>new Promise((async t=>{const s=await D(e.content.fileUrl);t({...e,size:s})})))),t=await Promise.all(e);J.value=Y.page>1?J.value.concat(t):t}}catch(e){console.log(e)}}function ee(){Object.assign(Y,{page:0,hasMore:!0,lastSendTime:x(new Date,"yyyy-MM-dd HH:mm:ss")}),Z()}_(Q,(()=>{Z()})),_(V,(()=>{Z()}));const te=s((()=>"image"===B.type?"聊天图片":"聊天文件"));function se(e){const{size:t,sendTime:s,senderName:a}=e;return`${t} · ${x(new Date(s),"yyyy/MM/dd HH:mm")} ${a}`}function ae(e){var t;const s=(null==(t=e.content)?void 0:t.msg)||"",a=s.lastIndexOf(".");if(-1!==a){return s.charAt(a+1).toUpperCase()}return"?"}return a((()=>B.visible),(e=>{e?ee():W.value=""})),(t,s)=>(o(),n(i(v),{preset:"dialog",title:i(te),"show-icon":!1,"auto-focus":!1,class:"c-chat-dialog"},{default:l((()=>[r(c("div",{class:"c-chat-dialog__content c-chat-image-wrapper",ref_key:"imageRef",ref:Q},[m(i(h),{"show-toolbar-tooltip":""},{default:l((()=>[(o(!0),p(d,null,u(q.value,(e=>(o(),p("div",{class:"image-item",key:e.label},[c("span",E,y(e.label),1),c("div",O,[(o(!0),p(d,null,u(e.list,(e=>(o(),n(i(w),{key:e,width:"80",height:"80",src:e},null,8,["src"])))),128))])])))),128))])),_:1})],512),[[f,"image"===e.type]]),r(c("div",{class:"c-chat-dialog__content c-chat-file-wrapper",style:g(i(G))},[m(i(b),{clearable:"",placeholder:"搜索文件",value:W.value,"onUpdate:value":s[0]||(s[0]=e=>W.value=e),valueModifiers:{trim:!0},onInput:i(X)},{prefix:l((()=>[m(i(M),{component:i(k)},null,8,["component"])])),_:1},8,["value","onInput"]),c("div",{class:"file-list-box",ref_key:"fileRef",ref:V},[(o(!0),p(d,null,u(J.value,((e,t)=>(o(),p("div",{class:"file-item",key:t},[c("span",$,y(ae(e)),1),c("div",F,[c("span",K,y(e.content.msg),1),c("span",P,y(se(e)),1)]),c("div",R,[m(i(M),{size:16,component:i(T)},null,8,["component"]),m(i(M),{size:16,component:i(I),onClick:()=>i(C)(e.content.fileUr,e.content.msg)},null,8,["component","onClick"])])])))),128))],512)],4),[[f,"image"!==e.type]])])),_:1},8,["title"]))}});export{B as default};
|
@@ -1,6 +1,7 @@
|
|
1
1
|
import { UploadFileInfo } from 'naive-ui';
|
2
2
|
import { AnyObject } from '../../../../shared/types';
|
3
3
|
import { MESSAGE_TYPE } from '../constants';
|
4
|
+
import { simplifyMessage } from '../utils';
|
4
5
|
declare const _default: import("vue").DefineComponent<{}, {
|
5
6
|
inputRef: import("vue").Ref<HTMLDivElement | undefined>;
|
6
7
|
content: import("vue").Ref<string>;
|
@@ -31,8 +32,11 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
31
32
|
}>>, {
|
32
33
|
abstract: boolean;
|
33
34
|
}>;
|
35
|
+
NIcon: any;
|
34
36
|
images: import("vue").Ref<any[]>;
|
35
37
|
alt: string[];
|
36
38
|
MESSAGE_TYPE: typeof MESSAGE_TYPE;
|
39
|
+
CloseCircleOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
40
|
+
simplifyMessage: typeof simplifyMessage;
|
37
41
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
38
42
|
export default _default;
|
@@ -1 +1 @@
|
|
1
|
-
import{defineComponent as
|
1
|
+
import{defineComponent as e,ref as t,watch as n,withDirectives as s,openBlock as i,createElementBlock as o,normalizeStyle as r,unref as a,createElementVNode as c,toDisplayString as l,createVNode as u,createCommentVNode as d,withCtx as f,Fragment as p,renderList as m,createBlock as g,createTextVNode as v,vShow as h}from"vue";import{NIcon as y,NPopover as M,NTooltip as k,NUpload as x,NUploadTrigger as C,NButton as T}from"naive-ui";import{format as b}from"date-fns";import{useState as w}from"../hooks/useState.js";import{useSession as E}from"../hooks/useSession.js";import{images as I,alt as _}from"../utils/emoji.js";import{MESSAGE_TYPE as R}from"../constants/index.js";import{uploadFileApi as j}from"../api/index.js";import{CloseCircleOutline as L}from"@vicons/ionicons5";import{cloneDeep as S}from"lodash-es";import{simplifyMessage as F}from"../utils/index.js";const H={key:0,class:"reference-content-box"},K={class:"reference-content"},D=["innerHTML"],N={class:"tool-box"},J=c("span",null,[c("i",{class:"chat--iconfont chat--icon-face"})],-1),O={class:"emoji-box"},A=c("span",null,"默认表情",-1),G={class:"list-box"},U=["onClick"],X=["src"],z=[c("i",{class:"chat--iconfont chat--icon-good"},null,-1)],B=["onClick"],q=[c("i",{class:"chat--iconfont chat--icon-image"},null,-1)],P=["onClick"],Q=[c("i",{class:"chat--iconfont chat--icon-folder"},null,-1)],V={class:"btn-box"},W=c("span",{class:"tip"},"Enter 发送, Shift + Enter 换行",-1);var Y=e({__name:"ChatFooter",setup(e){const Y=t(),Z=t(""),{state:$,stompClient:ee}=w(),{setCurrentSessionItem:te}=E($),ne=t(!1);function se(e){["Enter"].includes(e.key)&&(function(e){return e.altKey||e.ctrlKey||e.metaKey||e.shiftKey}(e)||(e.preventDefault(),re()))}function ie(){var e,t;Z.value=(null==(t=null==(e=Y.value)?void 0:e.innerText)?void 0:t.trim())||""}async function oe(e,t){const{file:n,name:s}=e.file,i=new FormData;i.append("sender",$.userInfo.id),i.append("file",n);const o=await j(i);if(!o)return console.log("上传失败");ae({chatMessageType:t,msg:t===R.FILE?s:o,url:o})}function re(){if(!(Z.value.length>2e3))return Z.value?void ae({msg:Z.value}):console.log("请输入内容");console.log("请控制在2000字以内")}async function ae(e){const{chatMessageType:t=R.TEXT,msg:n,url:s}=e,i={msg:n,chatMessageType:t};t===R.FILE&&(i.fileUrl=s),[R.TEXT,R.BLEND].includes(t)&&(Y.value.innerHTML="",Z.value=""),$.currentReferenceMsg.id&&(i.referenceContent=S($.currentReferenceMsg),$.currentReferenceMsg.id="");const o=b(new Date,"yyyy-MM-dd HH:mm:ss");$.currentMsg={content:i,sender:$.userInfo.id,id:"",sendTime:o,sending:!0,fail:!1},$.isAppendMsg=!0,te({lastMessageSendTime:o,lastMessage:i,sortTime:o});try{ee.value.send("/app/chat/send",{},JSON.stringify({chatType:"SINGLE",content:i,receiver:$.currentSessionItem.receiver})),$.currentMsg={...$.currentMsg,fail:!1}}catch(e){$.currentMsg={...$.currentMsg,fail:!0}}finally{$.currentMsg={...$.currentMsg,sending:!1}}}return n((()=>$.currentReferenceMsg.id),(e=>{var t;e&&(null==(t=Y.value)||t.focus())})),(e,t)=>s((i(),o("section",{class:"chat-footer",style:r({cursor:a($).id?"default":"not-allowed"})},[a($).currentReferenceMsg.id?(i(),o("div",H,[c("div",K,[c("span",null,l(a($).currentReferenceMsg.senderName)+":",1),c("pre",{innerHTML:a(F)(a($).currentReferenceMsg.content)},null,8,D)]),u(a(y),{component:a(L),onClick:t[0]||(t[0]=()=>a($).currentReferenceMsg.id="")},null,8,["component"])])):d("v-if",!0),c("div",N,[u(a(M),{show:ne.value,"onUpdate:show":t[1]||(t[1]=e=>ne.value=e),placement:"top",trigger:"click","show-arrow":!1,"display-directive":"show",delay:0},{trigger:f((()=>[J])),default:f((()=>[c("div",O,[d(' <span>最近使用</span>\n\t\t\t\t\t<div class="list-box">\n\t\t\t\t\t\t<template v-for="(img, index) in images" :key="index">\n\t\t\t\t\t\t\t<i>\n\t\t\t\t\t\t\t\t<img :src="img" />\n\t\t\t\t\t\t\t</i>\n\t\t\t\t\t\t</template>\n\t\t\t\t\t</div> '),A,c("div",G,[(i(!0),o(p,null,m(a(I),((e,t)=>(i(),o(p,{key:t},[t>0?(i(),g(a(k),{key:0,"show-arrow":!1,trigger:"hover"},{trigger:f((()=>[c("i",{onClick:()=>function(e){ne.value=!1,ae({chatMessageType:R.EMOJI,msg:e})}(t)},[c("img",{src:e},null,8,X)],8,U)])),default:f((()=>[v(" "+l(a(_)[t-1]||"微笑"),1)])),_:2},1024)):d("v-if",!0)],64)))),128))])])])),_:1},8,["show"]),c("span",{onClick:t[2]||(t[2]=()=>ae({chatMessageType:a(R).EMOJI,msg:0}))},z),u(a(x),{abstract:"",multiple:"",accept:"image/*",onChange:t[3]||(t[3]=e=>oe(e,a(R).IMAGE))},{default:f((()=>[u(a(C),{abstract:""},{default:f((({handleClick:e})=>[c("span",{onClick:e},q,8,B)])),_:1})])),_:1}),u(a(x),{abstract:"",multiple:"",accept:"video/*,.pdf,.doc.docx,,.zip,.xlsx,.txt",onChange:t[4]||(t[4]=e=>oe(e,a(R).FILE))},{default:f((()=>[u(a(C),{abstract:""},{default:f((({handleClick:e})=>[c("span",{onClick:e},Q,8,P)])),_:1})])),_:1})]),s(c("div",{ref_key:"inputRef",ref:Y,class:"input-box",contenteditable:"",onKeydown:se,onInput:ie},null,544),[[h,a($).id]]),c("div",V,[W,u(a(T),{type:"primary",round:"",disabled:!Z.value,onClick:re},{default:f((()=>[v("发送")])),_:1},8,["disabled"])])],4)),[[h,a($).id]])}});export{Y as default};
|
@@ -336,6 +336,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
336
336
|
type: BooleanConstructor;
|
337
337
|
};
|
338
338
|
}, {
|
339
|
+
cssVars: import("vue").ComputedRef<import("vue").CSSProperties>;
|
339
340
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
340
341
|
type: {
|
341
342
|
type: StringConstructor;
|
@@ -365,6 +366,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
365
366
|
resetAndSearch: () => void;
|
366
367
|
title: import("vue").ComputedRef<"聊天图片" | "聊天文件">;
|
367
368
|
getDetail: (item: AnyObject) => string;
|
369
|
+
getFileType: (item: AnyObject) => any;
|
368
370
|
NModal: any;
|
369
371
|
NImageGroup: import("vue").DefineComponent<{
|
370
372
|
showToolbar: {
|
@@ -571,6 +573,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
571
573
|
SearchOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
572
574
|
OpenOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
573
575
|
DownloadOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
576
|
+
downloadFile: typeof import("../utils").downloadFile;
|
574
577
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
575
578
|
type: {
|
576
579
|
type: StringConstructor;
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { AnyObject } from '../../../../shared/types';
|
2
|
-
import { formatTime } from '../utils';
|
2
|
+
import { formatTime, downloadFile, simplifyMessage } from '../utils';
|
3
3
|
import { MESSAGE_TYPE } from '../constants';
|
4
4
|
declare const _default: import("vue").DefineComponent<{}, {
|
5
5
|
chatMainRef: import("vue").Ref<HTMLElement | undefined>;
|
@@ -18,7 +18,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
18
18
|
needShowTime: (item: AnyObject, index: number) => boolean;
|
19
19
|
setScrollToButtom: () => Promise<void>;
|
20
20
|
resetInfo: () => void;
|
21
|
-
|
21
|
+
setReferenceMsg: (msgItem: AnyObject) => void;
|
22
22
|
NAvatar: any;
|
23
23
|
NImageGroup: import("vue").DefineComponent<{
|
24
24
|
showToolbar: {
|
@@ -220,6 +220,7 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
220
220
|
showToolbarTooltip: boolean;
|
221
221
|
}>;
|
222
222
|
NImage: any;
|
223
|
+
NIcon: any;
|
223
224
|
PersonProfile: import("vue").DefineComponent<{
|
224
225
|
userId: {
|
225
226
|
type: StringConstructor;
|
@@ -364,6 +365,11 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
364
365
|
}>>, {}>;
|
365
366
|
images: import("vue").Ref<any[]>;
|
366
367
|
formatTime: typeof formatTime;
|
368
|
+
downloadFile: typeof downloadFile;
|
369
|
+
simplifyMessage: typeof simplifyMessage;
|
367
370
|
MESSAGE_TYPE: typeof MESSAGE_TYPE;
|
371
|
+
AddCircleOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
372
|
+
ChatbubbleEllipsesOutline: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
373
|
+
EllipsisHorizontal: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, import("vue").EmitsOptions, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
368
374
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
|
369
375
|
export default _default;
|
@@ -1 +1 @@
|
|
1
|
-
import{defineComponent as e,ref as t,watch as
|
1
|
+
import{defineComponent as e,ref as t,watch as n,openBlock as s,createElementBlock as o,normalizeClass as r,unref as i,createVNode as a,withCtx as c,Fragment as m,renderList as l,toDisplayString as u,createCommentVNode as d,createBlock as p,createElementVNode as f,withModifiers as v}from"vue";import{NImageGroup as g,NAvatar as y,NImage as T,NIcon as M}from"naive-ui";import{format as h}from"date-fns";import{getHistoryRecordApi as k,readMessageApi as S}from"../api/index.js";import{useState as L}from"../hooks/useState.js";import{useSession as _}from"../hooks/useSession.js";import{first as I,last as E,isNumber as j}from"lodash-es";import A from"./PersonProfile.vue.js";import C from"./MessageTemplate.vue.js";import{images as H}from"../utils/emoji.js";import{formatTime as b,simplifyMessage as w,downloadFile as N}from"../utils/index.js";import{MESSAGE_TYPE as P}from"../constants/index.js";import{useScrollLoading as x}from"../hooks/useScrollLoading.js";import{AddCircleOutline as D,ChatbubbleEllipsesOutline as O,EllipsisHorizontal as G}from"@vicons/ionicons5";const R={key:0,class:"time"},J={key:2,class:"message-box"},K=["data-time"],U={key:0,class:"reference-content"},q=["innerHTML"],z=["innerHTML"],F=["src"],X=["href","onClick"],B={class:"quick-menu"};var Q=e({__name:"ChatMain",setup(e){const Q=t(),{state:V,setMsgList:W}=L(),{setCurrentSessionItem:Y}=_(V),Z={page:0,hasMore:!0,lastSendTime:h(new Date,"yyyy-MM-dd HH:mm:ss")};async function $(){try{if(!Z.hasMore)return;Z.page++;const e=await k({sessionKey:V.currentSessionItem.sessionKey,page:Z.page,lastSendTime:Z.lastSendTime});if(!Array.isArray(e)||0===e.length)return Z.hasMore=!1,console.log("接口返回不是一个数组,或者没有更多消息了");const t=I(e).id;Z.lastSendTime=E(e).sendTime,W(Z.page>1?[...e,...V.msgList]:e),1===Z.page&&V.currentSessionItem.unreadNum&&(await S({chatType:"SINGLE",messageIdSet:[t],receiver:V.userInfo.id,sender:V.currentSessionItem.receiver}),Y({unreadNum:0}))}catch(e){console.log(e)}}function ee(e){const{chatMessageType:t,messageTemplate:n}=e.content;return t!==P.TEMPLATE||!!n}function te(e,t){var n,s;const{chatMessageType:o,messageTemplate:r}=e.content;if(o===P.TEMPLATE)return"system"===t?2==(null==(n=null==r?void 0:r.setting)?void 0:n.style.id):2!=(null==(s=null==r?void 0:r.setting)?void 0:s.style.id)}function ne(e){var t,n;const{chatMessageType:s,messageTemplate:o}=e;return s===P.TEMPLATE&&3==(null==(n=null==(t=null==o?void 0:o.setting)?void 0:t.style)?void 0:n.id)}function se(e,t){var n;const s=j(e.sendTime)?e.sendTime:Date.parse(e.sendTime),o=null==(n=V.msgList[t-1])?void 0:n.sendTime;return s-(0===t?0:j(o)?o:Date.parse(o))>3e5}return x(Q,(()=>{$()}),"top"),n((()=>V.id),(e=>{e&&(Object.assign(Z,{page:0,hasMore:!0,lastSendTime:h(new Date,"yyyy-MM-dd HH:mm:ss")}),$())}),{immediate:!0}),n((()=>V.isAppendMsg),(e=>{e&&(W([...V.msgList,V.currentMsg]),V.isAppendMsg=!1,async function(){var e,t,n;const s=null!=(t=null==(e=Q.value)?void 0:e.scrollHeight)?t:0;null==(n=Q.value)||n.scrollTo({top:s,behavior:"auto"})}())}),{immediate:!0}),(e,t)=>(s(),o("div",{class:r(["chat-main",{"home-bg":!i(V).id}]),ref_key:"chatMainRef",ref:Q},[a(i(g),{"show-toolbar-tooltip":""},{default:c((()=>[(s(!0),o(m,null,l(i(V).msgList,((e,t)=>(s(),o(m,{key:t},[ee(e)?(s(),o("div",{key:0,class:r(["message-item",{"message-item--mine":e.sender==i(V).userInfo.id}])},[se(e,t)?(s(),o("p",R,u(i(b)(e.sendTime).recordTime),1)):d("v-if",!0),te(e,"system")?(s(),p(C,{key:1,data:e},null,8,["data"])):(s(),o("div",J,[a(A,{"user-id":e.sender},{trigger:c((()=>[a(i(y),{round:"",size:38,src:e.senderAvatar},null,8,["src"])])),_:2},1032,["user-id"]),e.content?(s(),o("div",{key:0,class:r(["content",{emoji:e.content.chatMessageType===i(P).EMOJI,template:e.content.chatMessageType===i(P).TEMPLATE,"template--3":ne(e.content)}]),"data-time":e.__time},[e.content.chatMessageType===i(P).TEXT?(s(),o(m,{key:0},[e.content.referenceContent?(s(),o("div",U,[f("span",null,u(e.content.referenceContent.senderName)+":",1),f("pre",{innerHTML:i(w)(e.content.referenceContent.content)},null,8,q)])):d("v-if",!0),f("pre",{innerHTML:e.__content},null,8,z)],64)):d("v-if",!0),e.content.chatMessageType===i(P).EMOJI?(s(),o("img",{key:1,src:i(H)[e.__content]},null,8,F)):d("v-if",!0),te(e,"template")?(s(),p(C,{key:2,data:e},null,8,["data"])):d("v-if",!0),e.content.chatMessageType===i(P).IMAGE?(s(),p(i(T),{key:3,width:"240",src:e.__content},null,8,["src"])):d("v-if",!0),e.content.chatMessageType===i(P).FILE?(s(),o("a",{key:4,href:e.content.fileUrl,onClick:v((()=>i(N)(e.content.fileUrl,e.__content)),["prevent"])},u(e.__content),9,X)):d("v-if",!0),f("div",B,[a(i(M),{component:i(D)},null,8,["component"]),a(i(M),{component:i(O),onClick:()=>{return t=e,V.currentReferenceMsg=t,void Object.assign(V.currentReferenceMsg,{chatType:"SINGLE",receiver:V.currentSessionItem.receiver,receiverAvatar:V.currentSessionItem.avatar,receiverName:V.currentSessionItem.name});var t}},null,8,["component","onClick"]),a(i(M),{component:i(G)},null,8,["component"])])],10,K)):d("v-if",!0)]))],2)):d("v-if",!0)],64)))),128))])),_:1})],2))}});export{Q as default};
|