mixdashboards 1.1.13 → 1.1.15
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/dist/{AgGridTable-Bi7O66-r.cjs → AgGridTable-B0ARi6iQ.cjs} +39 -39
- package/dist/{AgGridTable-BjGMC3qC.js → AgGridTable-CiUB86Yi.js} +34 -35
- package/dist/{BaseComponent-B38Blgw3.js → BaseComponent-7Sa7XOg-.js} +3 -3
- package/dist/{BaseComponent-9njJjeix.cjs → BaseComponent-BabOc6Kc.cjs} +1 -1
- package/dist/{EChartComponentBase-DJScukmS.js → EChartComponentBase-DCKFGbqb.js} +2 -2
- package/dist/{EChartComponentBase-BwbycwwW.cjs → EChartComponentBase-DM6aSCAR.cjs} +1 -1
- package/dist/{EmergencyPlanPanel-BxzP1xYW.cjs → EmergencyPlanPanel-B95hRGD5.cjs} +1 -1
- package/dist/{EmergencyPlanPanel-D3GF-xQQ.js → EmergencyPlanPanel-BJ1w9aHu.js} +1 -1
- package/dist/{HistoryPlanDialog-DpaiRZgi.js → HistoryPlanDialog-0jjitoAV.js} +1 -1
- package/dist/{HistoryPlanDialog-DQXCUsy4.cjs → HistoryPlanDialog-DjIJTjzR.cjs} +1 -1
- package/dist/{MixiotAppDetailPage-BGfF3qrm.js → MixiotAppDetailPage-DcAZ_rZN.js} +1 -1
- package/dist/{MixiotAppDetailPage-CL1Sd9HJ.cjs → MixiotAppDetailPage-JpvZKz0u.cjs} +1 -1
- package/dist/{MonitoringMap-Wzsw3hVH.cjs → MonitoringMap-BFTZh1EC.cjs} +1 -1
- package/dist/{MonitoringMap-DQkO116Z.js → MonitoringMap-D6HBxlBf.js} +2 -2
- package/dist/{UniverSheet-Bne7JZyr.cjs → UniverSheet-0biXXXxr.cjs} +1 -1
- package/dist/{UniverSheet-Cd2a9LPx.js → UniverSheet-B4uisgP1.js} +2 -2
- package/dist/{accelerationChart-BJhVC_l5.cjs → accelerationChart-BDRSdpFi.cjs} +1 -1
- package/dist/{accelerationChart-BUsbSkwA.js → accelerationChart-Bw7lk5Ds.js} +19 -19
- package/dist/{actionItem-B3B4MFcW.js → actionItem-CvYP-t6r.js} +2 -2
- package/dist/{actionItem-DxB7IvtW.cjs → actionItem-DThWcN9C.cjs} +1 -1
- package/dist/{alarmLevelChart-DC-q2AgI.js → alarmLevelChart-687B7l09.js} +2 -2
- package/dist/{alarmLevelChart-DC_hx4Pn.cjs → alarmLevelChart-tIuQCLIZ.cjs} +1 -1
- package/dist/{alertTable-CHfA0TR-.cjs → alertTable-DRMDbKnY.cjs} +1 -1
- package/dist/{alertTable-CGRDnNPw.js → alertTable-VF9l7Yae.js} +2 -2
- package/dist/{aliasObjectSelectorDemo-DGoLPE4i.cjs → aliasObjectSelectorDemo-CM81kBda.cjs} +1 -1
- package/dist/{aliasObjectSelectorDemo-DuGQCEcG.js → aliasObjectSelectorDemo-W1sOe5E-.js} +7 -7
- package/dist/{annualRainfallChart-CLxVqN5Z.cjs → annualRainfallChart-CqR6pOpX.cjs} +1 -1
- package/dist/{annualRainfallChart-Dr8KKYOG.js → annualRainfallChart-NcsPJb-C.js} +2 -2
- package/dist/{aqi-rBhSWA_m.js → aqi-3Gq00rd7.js} +2 -2
- package/dist/{aqi-BmYGSf2e.cjs → aqi-CZ_4TrPd.cjs} +1 -1
- package/dist/{aqiIndass-DqJBc799.js → aqiIndass-BZ7HrCcK.js} +16 -16
- package/dist/{aqiIndass-Cpqau5M0.cjs → aqiIndass-C1bAEiH_.cjs} +1 -1
- package/dist/{areaDeformCurve-DpHWg6pf.js → areaDeformCurve-DQ3jFm7O.js} +2 -2
- package/dist/{areaDeformCurve-B924KVWX.cjs → areaDeformCurve-DgQjsOl5.cjs} +1 -1
- package/dist/{arrayCard-Bzjg3HKN.cjs → arrayCard-BVII-4mg.cjs} +1 -1
- package/dist/{arrayCard-C7anoYI-.js → arrayCard-BvkmBFMi.js} +2 -2
- package/dist/{audio-DTiS2piX.js → audio-86V-n6Mh.js} +2 -2
- package/dist/{audio-aADcgdZP.cjs → audio-DAVcGaCv.cjs} +1 -1
- package/dist/{bar-D32xICYZ.js → bar-D0uX_Pwu.js} +2 -2
- package/dist/{bar-DqY55XnC.cjs → bar-DdCjm6M9.cjs} +1 -1
- package/dist/{basicShapeToolbox-D8q86CzB.js → basicShapeToolbox-cjpSxBSI.js} +12 -12
- package/dist/{basicShapeToolbox-BvJjH4fV.cjs → basicShapeToolbox-vlF8ai0y.cjs} +1 -1
- package/dist/{bmp-DIFGLoNl.cjs → bmp-DmCehXiK.cjs} +1 -1
- package/dist/{bmp-DU3vm7yj.js → bmp-L5PC6_bj.js} +2 -2
- package/dist/{box-DTQKGR9g.js → box-BBDYqZhV.js} +16 -16
- package/dist/{box-C8pOZXek.cjs → box-DCe5iz-w.cjs} +1 -1
- package/dist/{chartConfigPanel-D4vk7zWs.cjs → chartConfigPanel-BDGfFdm5.cjs} +1 -1
- package/dist/{chartConfigPanel-Bz82sVyH.js → chartConfigPanel-BG38-Lo9.js} +1 -1
- package/dist/{circleBar-B48h_-uK.cjs → circleBar-BBrdfpn6.cjs} +1 -1
- package/dist/{circleBar-ClO05bgq.js → circleBar-CnStKTJz.js} +2 -2
- package/dist/{clock-D8ZXhy53.js → clock-CfoMLhjJ.js} +2 -2
- package/dist/{clock-DB94wQje.cjs → clock-D4FqM5tD.cjs} +1 -1
- package/dist/{clt-cxeCTOaA.cjs → clt-DrF15d3K.cjs} +1 -1
- package/dist/{clt-BX0SNGZr.js → clt-mVBTHfPs.js} +2 -2
- package/dist/{cmc-BvnYrQrR.cjs → cmc-BEKqMpSQ.cjs} +1 -1
- package/dist/{cmc-Co13D559.js → cmc-kC4VJ8V0.js} +17 -17
- package/dist/{cmp-Dd56EQ09.cjs → cmp-BBKmso3S.cjs} +1 -1
- package/dist/{cmp-B4cYCR4p.js → cmp-CEeDDeHU.js} +2 -2
- package/dist/{conclusionCard-Bla25-qd.js → conclusionCard-Drlv8OIb.js} +2 -2
- package/dist/{conclusionCard-Cd3DoD1l.cjs → conclusionCard-glbRT95d.cjs} +1 -1
- package/dist/{controlList-Dx4wSpA7.js → controlList-2sHPYEnd.js} +3 -3
- package/dist/{controlList-CyT_LYgr.cjs → controlList-V6TbbBW2.cjs} +1 -1
- package/dist/{controlRecordList-DsxYHRrs.cjs → controlRecordList-CqMshyV4.cjs} +1 -1
- package/dist/{controlRecordList-BAI_15ZN.js → controlRecordList-kZuqwCCC.js} +3 -3
- package/dist/{controlRecordListAPP-Zfiwcrmq.cjs → controlRecordListAPP-BevyiiWD.cjs} +1 -1
- package/dist/{controlRecordListAPP-BQlABx3f.js → controlRecordListAPP-rsphOVsE.js} +2 -2
- package/dist/{crd-IsqkYOAy.js → crd-1Q8p4BGc.js} +56 -57
- package/dist/crd-z0xGDAjD.cjs +1 -0
- package/dist/{ctrBtn-LwuY-nVR.js → ctrBtn-CDT6KYFl.js} +12 -12
- package/dist/{ctrBtn-C3OqkyNS.cjs → ctrBtn-DNMQrtKl.cjs} +1 -1
- package/dist/{ctrSet-B0nYCdwh.cjs → ctrSet-B8m_Qs1d.cjs} +1 -1
- package/dist/{ctrSet-Qb5XEdD4.js → ctrSet-DF2TcM9X.js} +13 -13
- package/dist/{ctrSwitch-B3jo3Gx0.js → ctrSwitch-_QtKcaSt.js} +3 -3
- package/dist/{ctrSwitch-Bps4Ak15.cjs → ctrSwitch-eUtgP6uT.cjs} +1 -1
- package/dist/{dataManagement-BFxVtU33.cjs → dataManagement-D1uUQ_Ex.cjs} +1 -1
- package/dist/{dataManagement-CVHalRKp.js → dataManagement-xM0ruay1.js} +2 -2
- package/dist/{dataReport-Bk79cBkV.cjs → dataReport-DbQ_m74F.cjs} +1 -1
- package/dist/{dataReport-B2AiDMdM.js → dataReport-XrPAwXcb.js} +2 -2
- package/dist/{dataTable-D9sSJRQn.js → dataTable-BIy_sh-b.js} +1 -1
- package/dist/{dataTable-Dh7s14jM.cjs → dataTable-G_Elyj_e.cjs} +1 -1
- package/dist/{datetime-C25d1bAc.cjs → datetime-CLJrKpiX.cjs} +1 -1
- package/dist/{datetime-CEKzNAlD.js → datetime-Dyw8-i5g.js} +2 -2
- package/dist/{deepClusterSlipSurface-DODVh-Qw.js → deepClusterSlipSurface-CcoFFz6r.js} +26 -26
- package/dist/{deepClusterSlipSurface-BLZL2xX6.cjs → deepClusterSlipSurface-Cthw-rk5.cjs} +1 -1
- package/dist/{deepDataMatrix-D_NPV2sQ.cjs → deepDataMatrix-C8yzdPMG.cjs} +1 -1
- package/dist/{deepDataMatrix-9iClruS0.js → deepDataMatrix-Dy-9hAeO.js} +16 -16
- package/dist/{deepDisplacement3D-C6puNK1m.cjs → deepDisplacement3D-B3jtZ9_l.cjs} +1 -1
- package/dist/{deepDisplacement3D-C5YMqHiD.js → deepDisplacement3D-BqAQle8x.js} +2 -2
- package/dist/{deepDisplacementChart-DhQO428W.cjs → deepDisplacementChart-BT5FC0DX.cjs} +1 -1
- package/dist/{deepDisplacementChart-9sQF6tFO.js → deepDisplacementChart-BdEWrVgi.js} +20 -20
- package/dist/{deepDisplacementChart-DEn2yqGO.js → deepDisplacementChart-C1jrx9vY.js} +25 -25
- package/dist/{deepDisplacementChart-D-dqPlzq.cjs → deepDisplacementChart-DL5yJXj2.cjs} +1 -1
- package/dist/{deepDisplacementView-tzX-vzxO.cjs → deepDisplacementView-B722va1V.cjs} +1 -1
- package/dist/{deepDisplacementView-Cux6lFtG.js → deepDisplacementView-DLOv9gJ6.js} +1 -1
- package/dist/{deepNodeTemperatureChart--GH8-4O7.js → deepNodeTemperatureChart-D5ZY6ywC.js} +27 -27
- package/dist/{deepNodeTemperatureChart-Cyfnw2BR.cjs → deepNodeTemperatureChart-Dj3Xm6SY.cjs} +1 -1
- package/dist/{deepTangentAngleChart-DPMDFXiA.cjs → deepTangentAngleChart-9HyIvRNJ.cjs} +1 -1
- package/dist/{deepTangentAngleChart-Dae_3j30.js → deepTangentAngleChart-DVDa5Zxc.js} +26 -26
- package/dist/{deepTemperatureField-Cr2e_Ytp.js → deepTemperatureField-BO4TyQ_g.js} +3 -3
- package/dist/{deepTemperatureField-B3Eu4zqv.cjs → deepTemperatureField-cbehgtiQ.cjs} +1 -1
- package/dist/{deepTrendChart-8fniZ16K.js → deepTrendChart-BRdRCV_a.js} +14 -14
- package/dist/{deepTrendChart-BPYqojQ2.cjs → deepTrendChart-D9yoOBuy.cjs} +1 -1
- package/dist/{deviceOnlineStatus-mJ0KVMo4.cjs → deviceOnlineStatus-43VQlj7e.cjs} +1 -1
- package/dist/{deviceOnlineStatus-DP7-u5lC.js → deviceOnlineStatus-BAas3BvQ.js} +2 -2
- package/dist/{deviceStatus-Ih0jQNYO.js → deviceStatus-2Jyg0ILJ.js} +10 -10
- package/dist/{deviceStatus-B0AxN-cY.cjs → deviceStatus-CcrMdiqm.cjs} +1 -1
- package/dist/{displacementDataTable-BbZjdMtX.js → displacementDataTable-Cuy2--YT.js} +12 -12
- package/dist/{displacementDataTable-Dkka_jGJ.cjs → displacementDataTable-VumJPDi3.cjs} +1 -1
- package/dist/{displacementTrajectoryChart-DDwm-jr2.cjs → displacementTrajectoryChart-knwhmSBU.cjs} +1 -1
- package/dist/{displacementTrajectoryChart-BZDSkYoZ.js → displacementTrajectoryChart-qLo3xtpZ.js} +23 -23
- package/dist/{displacementTrendChart-DZZaVi86.js → displacementTrendChart-D2Ronskq.js} +34 -34
- package/dist/{displacementTrendChart-CUeVa58Q.cjs → displacementTrendChart-DbAH_mjd.cjs} +1 -1
- package/dist/{dxf-BOfmTSO8.cjs → dxf-BAH7igHZ.cjs} +1 -1
- package/dist/{dxf-DYC74yWV.js → dxf-BSXyBPzC.js} +2 -2
- package/dist/{dzc-DUFiz7a_.cjs → dzc-D105FzEq.cjs} +1 -1
- package/dist/{dzc-BU7yYW4I.js → dzc-DvtA7L0o.js} +2 -2
- package/dist/{emergencyPlan-DDb6j7YU.cjs → emergencyPlan-CAs6Mk1Y.cjs} +1 -1
- package/dist/{emergencyPlan-DabL46QK.js → emergencyPlan-CFmxsb7R.js} +3 -3
- package/dist/{evn-DrreVqnm.cjs → evn-D-e0vp61.cjs} +1 -1
- package/dist/{evn-DhdColcF.js → evn-DtTKI8zs.js} +2 -2
- package/dist/{evolutionChart-QuGAgjXo.cjs → evolutionChart-6EMuwRiR.cjs} +1 -1
- package/dist/{evolutionChart-aedDj0mQ.js → evolutionChart-uRWhCC8C.js} +3 -3
- package/dist/{fileViewer-CvNnUxUK.cjs → fileViewer-CPG-66F1.cjs} +1 -1
- package/dist/{fileViewer-oBpWIjGb.js → fileViewer-Cxo-Sbha.js} +2 -2
- package/dist/{filterBar-CwHODFoy.cjs → filterBar-CI0jzG-8.cjs} +1 -1
- package/dist/{filterBar-DYpEssxC.js → filterBar-DchvCgB0.js} +2 -2
- package/dist/{fireCombustionCurve-wbKsWk4E.js → fireCombustionCurve-fvldUBQh.js} +3 -3
- package/dist/{fireCombustionCurve-lu2qH6_b.cjs → fireCombustionCurve-qOiCa6aW.cjs} +1 -1
- package/dist/{fireFilterBar-B8su74tt.cjs → fireFilterBar-B8J3V0n-.cjs} +1 -1
- package/dist/{fireFilterBar-9_fqGo2q.js → fireFilterBar-D7mx1XUg.js} +2 -2
- package/dist/{fireHistoryTable-C1C95uYN.js → fireHistoryTable-CP0kgqS6.js} +2 -2
- package/dist/{fireHistoryTable-pOJz1_Rp.cjs → fireHistoryTable-r_xPEo29.cjs} +1 -1
- package/dist/{gag-LSkHPD7f.cjs → gag-BhUKp8vX.cjs} +1 -1
- package/dist/{gag-BGUeQKJJ.js → gag-n3ajZOT8.js} +2 -2
- package/dist/{gasStationList-4TtBLsqC.js → gasStationList-CRZGXdZ-.js} +3 -3
- package/dist/{gasStationList-DJTrXjkv.cjs → gasStationList-DX9Q2lFd.cjs} +1 -1
- package/dist/{geo3dViewer-CK89hYK7.cjs → geo3dViewer-CfPFjRsL.cjs} +1 -1
- package/dist/{geo3dViewer-DIjv75YP.js → geo3dViewer-DFD75mZU.js} +3 -3
- package/dist/{glbModel-BDgY9S4f.cjs → glbModel-BrwlvZq6.cjs} +1 -1
- package/dist/{glbModel-IOIVpCjq.js → glbModel-x4OZxfPi.js} +2 -2
- package/dist/{globalObjectSelector-B2dkzNyk.js → globalObjectSelector-Bx2SbcG0.js} +1 -1
- package/dist/{globalObjectSelector-N7s0yyOp.cjs → globalObjectSelector-PiWbhkZ4.cjs} +1 -1
- package/dist/{gnssFilterBar-BF_tbN4_.js → gnssFilterBar-8ie4Hrtf.js} +2 -2
- package/dist/{gnssFilterBar-8eSkGWMH.cjs → gnssFilterBar-BY7YScHH.cjs} +1 -1
- package/dist/{gnssHistoryTable-DUjRjXoS.js → gnssHistoryTable-DH3MNQRj.js} +2 -2
- package/dist/{gnssHistoryTable-X_cgOa6r.cjs → gnssHistoryTable-lvtSQu6T.cjs} +1 -1
- package/dist/{gnssMapView-DnF2bYAD.cjs → gnssMapView-BalPUoGu.cjs} +2 -2
- package/dist/{gnssMapView-BnwPDey9.js → gnssMapView-eqR9-FLA.js} +4 -4
- package/dist/{gnssSectionProfile-D0sbRu3A.js → gnssSectionProfile-C2v9LYEI.js} +2 -2
- package/dist/{gnssSectionProfile-DoEXHKTy.cjs → gnssSectionProfile-fXM6wumD.cjs} +1 -1
- package/dist/{gnssTimeSeriesChart-Csm6PwRv.cjs → gnssTimeSeriesChart-DK08VGh2.cjs} +1 -1
- package/dist/{gnssTimeSeriesChart-glTixABx.js → gnssTimeSeriesChart-DO4m_7q7.js} +2 -2
- package/dist/{gnssXYTrajectory-4c8JDd_b.cjs → gnssXYTrajectory-CDgAcydt.cjs} +1 -1
- package/dist/{gnssXYTrajectory-BMCO0sb0.js → gnssXYTrajectory-Jdb53wOw.js} +2 -2
- package/dist/{grd-D1enzYOI.cjs → grd-BcVJB4b5.cjs} +1 -1
- package/dist/{grd-BTGTCp0z.js → grd-Bf5VZY3M.js} +19 -19
- package/dist/{grdIndass-B6fwa_k8.cjs → grdIndass-CTaKBOun.cjs} +1 -1
- package/dist/{grdIndass-Dn62HL6y.js → grdIndass-DrBidpYt.js} +2 -2
- package/dist/{grg-DMOF8h8j.js → grg-57h3YudF.js} +5 -5
- package/dist/{grg-B5128EcW.cjs → grg-DR1f44AO.cjs} +1 -1
- package/dist/{gridview-Dewc5Eax.js → gridview-BEiHeWnU.js} +2 -2
- package/dist/{gridview-Ddin99YO.cjs → gridview-DUOWjiqv.cjs} +1 -1
- package/dist/{groundwaterFilterBar-mukvYHDm.js → groundwaterFilterBar-Djh4tnLM.js} +2 -2
- package/dist/{groundwaterFilterBar-2uj_Hf_Q.cjs → groundwaterFilterBar-WfAm45Iv.cjs} +1 -1
- package/dist/{groundwaterProfileChart-DDVsfzyr.cjs → groundwaterProfileChart-B9NrkncY.cjs} +2 -2
- package/dist/{groundwaterProfileChart-BPTP8WBi.js → groundwaterProfileChart-Dvme4PHf.js} +3 -3
- package/dist/{groundwaterTimeCurve-jtQFr0hU.js → groundwaterTimeCurve-DLhsSDRO.js} +3 -3
- package/dist/{groundwaterTimeCurve-Zzn-sEsW.cjs → groundwaterTimeCurve-pLt2KuEY.cjs} +1 -1
- package/dist/{groupCard-DWjFdiH0.cjs → groupCard-DK5_osdM.cjs} +1 -1
- package/dist/{groupCard-B3fp05QD.js → groupCard-QV7NnbBa.js} +2 -2
- package/dist/{headerBar-BkpSQMNy.js → headerBar-CBTHBko2.js} +2 -2
- package/dist/{headerBar-B6lX3WST.cjs → headerBar-DcMgFL7n.cjs} +1 -1
- package/dist/{history-DqPjJP_E.cjs → history-BKLujk4W.cjs} +1 -1
- package/dist/{history-DgSlSTUD.js → history-BvM7EXsN.js} +11 -11
- package/dist/{index-Bo49zvKb.cjs → index-Cm7hGuPj.cjs} +13 -13
- package/dist/{index-BbXEpgom.js → index-DUL649KZ.js} +3422 -3379
- package/dist/{insarDeformChart-8UyVWXTx.cjs → insarDeformChart-D13o5hNr.cjs} +1 -1
- package/dist/{insarDeformChart-DNBHbVuk.js → insarDeformChart-DPq39rTv.js} +2 -2
- package/dist/{insarImageViewer-BeykgIJy.js → insarImageViewer-BLYbI4bm.js} +2 -2
- package/dist/{insarImageViewer-B8PhDcuG.cjs → insarImageViewer-BoqwF7sg.cjs} +1 -1
- package/dist/{kds-CS473Sia.js → kds-B2xqXmO8.js} +2 -2
- package/dist/{kds-BJwYrjV_.cjs → kds-B8Jdw9vL.cjs} +1 -1
- package/dist/{kpiCard-OMuCQe7O.cjs → kpiCard-BGsf7G30.cjs} +1 -1
- package/dist/{kpiCard-CNgj9P9s.js → kpiCard-DRR1gTcG.js} +2 -2
- package/dist/{landslideMap-NaGM5jJE.cjs → landslideMap-CD2LDzJA.cjs} +1 -1
- package/dist/{landslideMap-DMNcfDYF.js → landslideMap-DDlN9f2H.js} +9 -9
- package/dist/{landslideWarning-V1wB3aWq.cjs → landslideWarning-27SNVapD.cjs} +1 -1
- package/dist/{landslideWarning-DU-dDiiS.js → landslideWarning-r1zdMCih.js} +26 -26
- package/dist/{layerTabs-VfYlv6Ks.cjs → layerTabs-B86d5HH7.cjs} +1 -1
- package/dist/{layerTabs-Bgi7pfof.js → layerTabs-BjHiCU_F.js} +2 -2
- package/dist/{leaflet-src-4AJHN6it.js → leaflet-src-CAGnqnjZ.js} +1 -1
- package/dist/{leaflet-src-WG2ob5HA.cjs → leaflet-src-DYGpvxW6.cjs} +1 -1
- package/dist/{lerc-CEea2nO1.cjs → lerc-5z3DZffX.cjs} +1 -1
- package/dist/{lerc-BDiJ3I_S.js → lerc-Dh5beGkQ.js} +2 -2
- package/dist/{lin-BO1pGlXr.js → lin-DDWiOEA0.js} +6 -6
- package/dist/{lin-B_rN6QBj.cjs → lin-r6oOjphh.cjs} +1 -1
- package/dist/{linIndass-BGpoCQ4j.js → linIndass-CWcaOARi.js} +10 -10
- package/dist/{linIndass-B7XnW5XO.cjs → linIndass-CYCVyf-Z.cjs} +1 -1
- package/dist/{lst-BBl9nn63.js → lst-BKViAE6J.js} +2 -2
- package/dist/{lst-BeB_Gi9l.cjs → lst-Jc5oufSH.cjs} +1 -1
- package/dist/{manualEntry-C3qifAlP.js → manualEntry-CR0vY9l1.js} +2 -2
- package/dist/{manualEntry-BQVUqtm7.cjs → manualEntry-DpKGLaSi.cjs} +1 -1
- package/dist/{mapBackground-CDS60ZJC.js → mapBackground-BmlSVAtG.js} +3 -3
- package/dist/{mapBackground-D3-V7S-d.cjs → mapBackground-Cx8KweQ8.cjs} +1 -1
- package/dist/{mappingList-DnoAuivo.cjs → mappingList-BZz7GqJ4.cjs} +1 -1
- package/dist/{mappingList-B0jG2LlO.js → mappingList-C92OnAaA.js} +3 -3
- package/dist/{markdownViewer-BlXaqjhL.js → markdownViewer-ICTPV_72.js} +2 -2
- package/dist/{markdownViewer-BMkbW1Cl.cjs → markdownViewer-O5ng8kl7.cjs} +1 -1
- package/dist/materialFileUrl-C_Aqly-o.cjs +1 -0
- package/dist/{materialFileUrl-hKqW_JAq.js → materialFileUrl-CfFfqtB7.js} +5 -4
- package/dist/{mix-control-modal-BEXucxt5.js → mix-control-modal-CGLYKUCc.js} +5 -5
- package/dist/{mix-control-modal-aUWGjwZP.cjs → mix-control-modal-oxp6LmrP.cjs} +1 -1
- package/dist/{mixGrid-B5pKpGT3.cjs → mixGrid-DO73I4-D.cjs} +1 -1
- package/dist/{mixGrid-DQf7U1_8.js → mixGrid-DnxCOTqm.js} +2 -2
- package/dist/mixdashboards.cjs +1 -1
- package/dist/mixdashboards.css +1 -1
- package/dist/mixdashboards.js +1 -1
- package/dist/{mjpegCamera-CJgiIk0q.cjs → mjpegCamera-DSMbdhJe.cjs} +1 -1
- package/dist/{mjpegCamera-C6pxWuEr.js → mjpegCamera-Dj5Lyrml.js} +2 -2
- package/dist/{monitorAlert-BPd1b_Cx.cjs → monitorAlert-C0e3mU_8.cjs} +1 -1
- package/dist/{monitorAlert-ZNF5siqY.js → monitorAlert-FwFl3Tjd.js} +12 -12
- package/dist/{monitorData-DIxZYNVr.js → monitorData-CnFHs2-k.js} +10 -10
- package/dist/{monitorData-slk6ogNe.cjs → monitorData-ICqlDSYT.cjs} +1 -1
- package/dist/{monitorSpeedChart-BRwbLD8B.cjs → monitorSpeedChart-B_02qTZy.cjs} +1 -1
- package/dist/{monitorSpeedChart-DCO39Aka.js → monitorSpeedChart-XCq3duqZ.js} +1 -1
- package/dist/{mxa-Bp4RH0w3.cjs → mxa-B9Ioifrx.cjs} +1 -1
- package/dist/{mxa-DFq19ply.js → mxa-DkvNrmvM.js} +2 -2
- package/dist/{myValue-g8shJQA9.cjs → myValue-CJZpYcAp.cjs} +1 -1
- package/dist/{myValue-BvItzUMv.js → myValue-aYi3bo7x.js} +2 -2
- package/dist/{myValueList-A_UGyNxN.js → myValueList-BIZ2JfrI.js} +2 -2
- package/dist/{myValueList-DnZBoJXp.cjs → myValueList-CFnHg4pl.cjs} +1 -1
- package/dist/objectList-B_BnqBg1.js +1842 -0
- package/dist/objectList-BgyTh2e7.cjs +1 -0
- package/dist/{objectListAPP-DxRImk8W.cjs → objectListAPP-B7Yk07oG.cjs} +1 -1
- package/dist/{objectListAPP-CdewSo8l.js → objectListAPP-Bq1S1FGu.js} +3 -3
- package/dist/{percentBar-Cq5ACj9c.cjs → percentBar-DmrRQirp.cjs} +1 -1
- package/dist/{percentBar-BvmYW_u6.js → percentBar-L0Ur3boP.js} +2 -2
- package/dist/{photo-t11P9WKh.js → photo-9c2Vrzor.js} +3 -3
- package/dist/{photo-B-kxNdb5.cjs → photo-BzVvbKrh.cjs} +1 -1
- package/dist/{pie-yTahcSl_.js → pie-BVbkpFWj.js} +2 -2
- package/dist/{pie-0s6FwVBt.cjs → pie-CeeMdBgu.cjs} +1 -1
- package/dist/{placeholder-DBmyvwFn.cjs → placeholder-C07ZscJc.cjs} +1 -1
- package/dist/{placeholder-D_CaQ-hg.js → placeholder-CUYSWWf8.js} +1 -1
- package/dist/{pressBtn-CP4kJr-P.js → pressBtn-Ds60I7hM.js} +3 -3
- package/dist/{pressBtn-JFezb7Yx.cjs → pressBtn-sqz6yim1.cjs} +1 -1
- package/dist/{processTable-BXswsnmt.js → processTable-COz7CKEG.js} +2 -2
- package/dist/{processTable-DRdI9ExW.cjs → processTable-CytoNBR2.cjs} +1 -1
- package/dist/{progressBar-Sn6tAxTY.cjs → progressBar-BxHPc2DD.cjs} +1 -1
- package/dist/{progressBar-D1Xh5APg.js → progressBar-CUnuEFaQ.js} +2 -2
- package/dist/{progressCircle-DLk9v_Os.cjs → progressCircle-BUNOFiUO.cjs} +1 -1
- package/dist/{progressCircle-BMpJVwIE.js → progressCircle-DWKJHFm-.js} +2 -2
- package/dist/{qrcode-BDtn3Ql7.cjs → qrcode-DJrUuI_e.cjs} +1 -1
- package/dist/{qrcode-BqlqV7Jf.js → qrcode-elzi9Ev5.js} +2 -2
- package/dist/{raceBar-BpvWNCV7.cjs → raceBar-BWYiOHgT.cjs} +2 -2
- package/dist/{raceBar-zSL-J18j.js → raceBar-C1Js5fWq.js} +156 -136
- package/dist/{rad-DSfVfaMa.cjs → rad-B__LOwb8.cjs} +1 -1
- package/dist/{rad-CZhY-L-z.js → rad-Dau_xw7q.js} +2 -2
- package/dist/{radarMapViewer-B4tTLLyl.js → radarMapViewer-0jrnj6Nm.js} +2 -2
- package/dist/{radarMapViewer-GmzS18dJ.cjs → radarMapViewer-30nLi5D4.cjs} +1 -1
- package/dist/{rainfallFilterBar-ijVmoglb.js → rainfallFilterBar-CnNMm1L4.js} +2 -2
- package/dist/{rainfallFilterBar-DHaVjXt5.cjs → rainfallFilterBar-io0Xy92q.cjs} +1 -1
- package/dist/{rainfallTimeCurve-B3_bl5L6.js → rainfallTimeCurve-CO3kxkO1.js} +3 -3
- package/dist/{rainfallTimeCurve-Crz3Adzh.cjs → rainfallTimeCurve-CsQNzhJI.cjs} +1 -1
- package/dist/{rangeLin-BOEsEaV1.js → rangeLin-C9p4yw-H.js} +8 -8
- package/dist/{rangeLin-DpEbvxsg.cjs → rangeLin-F-eJUSOD.cjs} +1 -1
- package/dist/{realtimeEvolutionMap-C2u4a2JL.js → realtimeEvolutionMap-BSHmiJdM.js} +2 -2
- package/dist/{realtimeEvolutionMap-BwQJkus6.cjs → realtimeEvolutionMap-DbPSlUVo.cjs} +1 -1
- package/dist/{regionBar-P1fqv7Vb.cjs → regionBar-BqpQ17-j.cjs} +1 -1
- package/dist/{regionBar-BQr-kq-M.js → regionBar-DcIaWt42.js} +2 -2
- package/dist/{request-D9N74QdZ.cjs → request-BNiCZV7_.cjs} +1 -1
- package/dist/{request-Bn2gQLgM.js → request-CEUCACCR.js} +5 -5
- package/dist/{retainer1-Fnw0-Jvy.js → retainer1-BYe-4QPq.js} +3 -3
- package/dist/{retainer1-BCh8WSOq.cjs → retainer1-CtwKT7UP.cjs} +1 -1
- package/dist/{retainer2-nPyFv6Hs.js → retainer2-C8M7swsz.js} +3 -3
- package/dist/{retainer2-_3NOOefF.cjs → retainer2-CQf-EzAl.cjs} +1 -1
- package/dist/{retainerRecordList-C_UsUKsQ.js → retainerRecordList-B-xwovFD.js} +3 -3
- package/dist/{retainerRecordList-BaOTTQQN.cjs → retainerRecordList-DyRQQ0N-.cjs} +1 -1
- package/dist/{retainerRecordListAPP-BgKyfAMh.js → retainerRecordListAPP-CMNYP6hk.js} +3 -3
- package/dist/{retainerRecordListAPP-CE3l6WrB.cjs → retainerRecordListAPP-UPROwhvr.cjs} +1 -1
- package/dist/{ringTopN-Dz0EoM-A.js → ringTopN-FlVjUrQT.js} +2 -2
- package/dist/{ringTopN-DEv30Ms2.cjs → ringTopN-tPWwyl2Y.cjs} +1 -1
- package/dist/{riskRegionTable-BODT2UTF.cjs → riskRegionTable-BbJAvy7W.cjs} +1 -1
- package/dist/{riskRegionTable-Dot8zD_6.js → riskRegionTable-BjZoKdPt.js} +2 -2
- package/dist/{sankey-CYTyQB-L.cjs → sankey-CbPDXthr.cjs} +1 -1
- package/dist/{sankey-CbEUEE5B.js → sankey-Df3nSWC_.js} +7 -7
- package/dist/{scd-Btsiastw.js → scd-B9eeXnYU.js} +344 -348
- package/dist/scd-Ds6_WZDt.cjs +1 -0
- package/dist/{sideMenu-BxJRAAdM.js → sideMenu-BZ8iCENQ.js} +2 -2
- package/dist/{sideMenu-dnpq3qTF.cjs → sideMenu-CCohX7e6.cjs} +1 -1
- package/dist/{slopeStability-DX7WP5ZW.cjs → slopeStability-CO2BLtaT.cjs} +1 -1
- package/dist/{slopeStability-DrooNf1g.js → slopeStability-ChLLwaQA.js} +19 -19
- package/dist/{speedCurve-CNUJ5ScK.js → speedCurve-B7vwk0ti.js} +2 -2
- package/dist/{speedCurve-BT8wnfZI.cjs → speedCurve-DC8GN7er.cjs} +1 -1
- package/dist/{stackedBar-X8Y4lVgT.cjs → stackedBar-Bdt1ii7n.cjs} +1 -1
- package/dist/{stackedBar-nIfO6Aa3.js → stackedBar-p5hQcLfe.js} +2 -2
- package/dist/{stationList-D7lGCblu.js → stationList-4JLmJjJs.js} +3 -3
- package/dist/{stationList-DVzvGGHI.cjs → stationList-BHhnU7rg.cjs} +1 -1
- package/dist/{stressFilterBar-D5xktTRI.cjs → stressFilterBar-CDvVQZhK.cjs} +1 -1
- package/dist/{stressFilterBar-DqeqFHm7.js → stressFilterBar-D5uGrRbV.js} +2 -2
- package/dist/{stressTimeCurve-DfjNQ0rU.js → stressTimeCurve-BmXoUDOP.js} +3 -3
- package/dist/{stressTimeCurve-Bhhb-eqB.cjs → stressTimeCurve-Chj7Kmdb.cjs} +1 -1
- package/dist/{swiper-DuNuvT_N.js → swiper-CkVk-qls.js} +2 -2
- package/dist/{swiper-XCpwFkWS.cjs → swiper-OOktak53.cjs} +1 -1
- package/dist/{tablemanCreate-Cp5DaYUd.cjs → tablemanCreate-D6UFJZIo.cjs} +1 -1
- package/dist/{tablemanCreate-Cp9nOGg2.js → tablemanCreate-Hi3dHyzp.js} +3 -3
- package/dist/{tablemanDetail-DvZdgdHD.js → tablemanDetail-Bpuptxn4.js} +4 -4
- package/dist/{tablemanDetail-3ZMWkdpz.cjs → tablemanDetail-CHy58vFi.cjs} +1 -1
- package/dist/{tablemanList-DZdb1FUR.js → tablemanList-C16Timv1.js} +4 -4
- package/dist/{tablemanList-OLxgUmAi.cjs → tablemanList-C_bH6tMi.cjs} +1 -1
- package/dist/{tablemanTableList-CqsnRIHS.js → tablemanTableList-BW1WE2Ph.js} +3 -3
- package/dist/{tablemanTableList-BN6QjYEV.cjs → tablemanTableList-Duc6n-hm.cjs} +1 -1
- package/dist/{tablemanUpdate-CHs5OgAG.js → tablemanUpdate-Cvrm6nnk.js} +3 -3
- package/dist/{tablemanUpdate-E3d7A3WM.cjs → tablemanUpdate-DIpc92Cl.cjs} +1 -1
- package/dist/{terminalConfigList-BlgcWy40.cjs → terminalConfigList-C8dkmhQS.cjs} +1 -1
- package/dist/{terminalConfigList-BEBNi1Nl.js → terminalConfigList-yGZl93f_.js} +3 -3
- package/dist/{terminalList-Bl5BPmF9.cjs → terminalList-CanK2pyt.cjs} +1 -1
- package/dist/{terminalList-CJpH2Z-r.js → terminalList-dgawgsuV.js} +3 -3
- package/dist/{terminalListAPP-Dgvz8I3j.cjs → terminalListAPP-0iTXcRsu.cjs} +1 -1
- package/dist/{terminalListAPP-BpONJQOA.js → terminalListAPP-DNQzjxMX.js} +3 -3
- package/dist/{textbox-CJnSDwg7.js → textbox-88HaqHYa.js} +2 -2
- package/dist/{textbox-DR0bQEX7.cjs → textbox-CJP0S05E.cjs} +1 -1
- package/dist/{timeQueryBar-FJDQv-gp.js → timeQueryBar-B6WFuoFy.js} +1 -1
- package/dist/{timeQueryBar-Cmyan_30.cjs → timeQueryBar-B7m2zNqC.cjs} +1 -1
- package/dist/{timeSeries-t4uZvXRF.js → timeSeries-CBEMu62t.js} +12 -12
- package/dist/{timeSeries-_RLSUPmg.cjs → timeSeries-pv1B8rAD.cjs} +1 -1
- package/dist/{timeSeriesCurve-BxWiI6w-.js → timeSeriesCurve-C8I6T04V.js} +3 -3
- package/dist/{timeSeriesCurve-BUuLFQ8A.cjs → timeSeriesCurve-DfKXoiJf.cjs} +1 -1
- package/dist/{toggleBtn-BcpJcxpU.cjs → toggleBtn-D892Lgcg.cjs} +1 -1
- package/dist/{toggleBtn-Cx44qVci.js → toggleBtn-DxOPkmCn.js} +2 -2
- package/dist/{trajectoryConfigPanel-BTUv5OVS.cjs → trajectoryConfigPanel-2_KO7Fm_.cjs} +1 -1
- package/dist/{trajectoryConfigPanel-dyo30nx9.js → trajectoryConfigPanel-CiHG2Nj3.js} +1 -1
- package/dist/{trajectoryScatter-CK4_Z1iU.cjs → trajectoryScatter-ceIqjQdd.cjs} +1 -1
- package/dist/{trajectoryScatter-BghFGqxH.js → trajectoryScatter-gYFCMKo8.js} +2 -2
- package/dist/{universalConfigPanel-Cvlpgn-j.cjs → universalConfigPanel-BuJ0pSOp.cjs} +1 -1
- package/dist/{universalConfigPanel-yJFrQDBa.js → universalConfigPanel-T07C_JVG.js} +1 -1
- package/dist/{universalTable-CvBC-L9Z.js → universalTable-C6iYcfCe.js} +2 -2
- package/dist/{universalTable-CRJ7Rx0P.cjs → universalTable-DA2F0v4F.cjs} +1 -1
- package/dist/useMixiotPanelPopperClass-DDtFtXLr.cjs +1 -0
- package/dist/useMixiotPanelPopperClass-DtvQI0g1.js +52 -0
- package/dist/{useTablemanApi-fqoMpRxe.cjs → useTablemanApi-BbUulkUz.cjs} +1 -1
- package/dist/{useTablemanApi-BAt370b-.js → useTablemanApi-Ch3eQRoG.js} +1 -1
- package/dist/{useTablemanFormPanel-Cxo0WsI1.cjs → useTablemanFormPanel-BdBoaHFU.cjs} +1 -1
- package/dist/{useTablemanFormPanel-BKbM39_H.js → useTablemanFormPanel-EtmBEDl7.js} +2 -2
- package/dist/{useTablemanListActions-DRXW-WTa.cjs → useTablemanListActions-Dlfnpnld.cjs} +1 -1
- package/dist/{useTablemanListActions-CYauYy6z.js → useTablemanListActions-gqs6gpza.js} +4 -4
- package/dist/{video-C1N8Ikkh.js → video-BVmqEL79.js} +2 -2
- package/dist/{video-BN19nKK_.cjs → video-jHJpadOt.cjs} +1 -1
- package/dist/{videoMonitor-PKypdwRl.cjs → videoMonitor-BZkwTydy.cjs} +1 -1
- package/dist/{videoMonitor-fkEuZ25x.js → videoMonitor-BwdC2_nR.js} +8 -8
- package/dist/{vlu-B8tqM9md.js → vlu-BSasXwGB.js} +2 -2
- package/dist/{vlu-DrABl6SW.cjs → vlu-DONKeVps.cjs} +1 -1
- package/dist/{warningOverview-_rp_SbLs.js → warningOverview-7bSJ0uSZ.js} +3 -3
- package/dist/{warningOverview-DaTHPveq.cjs → warningOverview-DVtqkIDv.cjs} +1 -1
- package/dist/{weather-B_XCWwDa.cjs → weather--IcwH6Si.cjs} +1 -1
- package/dist/{weather-qvsptrt0.js → weather-CVLrwzcA.js} +2 -2
- package/dist/{windLin-BDtJUYBu.js → windLin-ByNz1LOX.js} +2 -2
- package/dist/{windLin-P84T5W3o.cjs → windLin-C-BHdrGl.cjs} +1 -1
- package/package.json +1 -1
- package/dist/crd-C6iegy7d.cjs +0 -1
- package/dist/materialFileUrl-8YHw7z1T.cjs +0 -1
- package/dist/objectList-BcSCvy54.cjs +0 -1
- package/dist/objectList-DgVJlA1o.js +0 -1828
- package/dist/scd-DwdWl6Wz.cjs +0 -1
- package/dist/useMixiotPanelPopperClass-2tTzKUsO.cjs +0 -1
- package/dist/useMixiotPanelPopperClass-UGlVKJTK.js +0 -53
|
@@ -40,9 +40,9 @@ import "element-plus/es/components/base/style/css";
|
|
|
40
40
|
import "element-plus/es/components/pagination/style/css";
|
|
41
41
|
import { defineComponent as Wi, getCurrentInstance as ca, h as ha, markRaw as Ys, toRaw as ua, createVNode as ys, render as Wo, computed as Fe, ref as Pt, watch as ot, onMounted as Pr, onBeforeUnmount as Dr, openBlock as Zt, createElementBlock as Di, withModifiers as Ft, Fragment as ga, renderList as pa, createBlock as fa, withCtx as ma, createTextVNode as va, toDisplayString as Ca, toRef as wa, nextTick as Ke, normalizeStyle as Sa, unref as ya, mergeProps as ba, createCommentVNode as Ra } from "vue";
|
|
42
42
|
import { useI18n as Fa } from "vue-i18n";
|
|
43
|
-
import {
|
|
43
|
+
import { useElementSize as xa } from "@vueuse/core";
|
|
44
|
+
import { t as Ea, _ as Mr } from "./index-DUL649KZ.js";
|
|
44
45
|
import "element-plus/es/components/checkbox/style/css";
|
|
45
|
-
import { _ as Mr } from "./index-BbXEpgom.js";
|
|
46
46
|
var Nt = class {
|
|
47
47
|
constructor() {
|
|
48
48
|
this.allSyncListeners = /* @__PURE__ */ new Map(), this.allAsyncListeners = /* @__PURE__ */ new Map(), this.globalSyncListeners = /* @__PURE__ */ new Set(), this.globalAsyncListeners = /* @__PURE__ */ new Set(), this.asyncFunctionsQueue = [], this.scheduled = !1, this.firedEvents = {};
|
|
@@ -33381,60 +33381,59 @@ const kS = {
|
|
|
33381
33381
|
ariaSearchFilterValues: "Search filter values"
|
|
33382
33382
|
};
|
|
33383
33383
|
function LS(e, t) {
|
|
33384
|
-
const i =
|
|
33385
|
-
function
|
|
33384
|
+
const i = Pt(!1);
|
|
33385
|
+
function s() {
|
|
33386
33386
|
if (t.value === "dark") {
|
|
33387
|
-
|
|
33387
|
+
i.value = !0;
|
|
33388
33388
|
return;
|
|
33389
33389
|
}
|
|
33390
33390
|
if (t.value === "light") {
|
|
33391
|
-
|
|
33391
|
+
i.value = !1;
|
|
33392
33392
|
return;
|
|
33393
33393
|
}
|
|
33394
|
-
const
|
|
33395
|
-
if (
|
|
33396
|
-
|
|
33394
|
+
const c = e.value;
|
|
33395
|
+
if (c != null && c.closest(".mixiot-panel--dark")) {
|
|
33396
|
+
i.value = !0;
|
|
33397
33397
|
return;
|
|
33398
33398
|
}
|
|
33399
|
-
if (
|
|
33400
|
-
|
|
33399
|
+
if (c != null && c.closest(".mixiot-panel--light")) {
|
|
33400
|
+
i.value = !1;
|
|
33401
33401
|
return;
|
|
33402
33402
|
}
|
|
33403
|
-
|
|
33404
|
-
s.value = i.value || u.classList.contains("dark") || u.getAttribute("data-theme") === "dark";
|
|
33403
|
+
i.value = Ea();
|
|
33405
33404
|
}
|
|
33406
|
-
const
|
|
33407
|
-
const
|
|
33408
|
-
return
|
|
33405
|
+
const o = Fe(() => {
|
|
33406
|
+
const c = e.value, h = c == null ? void 0 : c.closest(".mixiot-panel--dark, .mixiot-panel--light");
|
|
33407
|
+
return h || document.documentElement;
|
|
33409
33408
|
});
|
|
33410
|
-
let
|
|
33411
|
-
function
|
|
33412
|
-
|
|
33413
|
-
|
|
33409
|
+
let r = null, n = !1;
|
|
33410
|
+
function l() {
|
|
33411
|
+
n || (n = !0, requestAnimationFrame(() => {
|
|
33412
|
+
n = !1, s();
|
|
33414
33413
|
}));
|
|
33415
33414
|
}
|
|
33416
|
-
function
|
|
33417
|
-
var
|
|
33418
|
-
|
|
33419
|
-
const
|
|
33420
|
-
if (!
|
|
33421
|
-
const
|
|
33422
|
-
|
|
33415
|
+
function a() {
|
|
33416
|
+
var u;
|
|
33417
|
+
r == null || r.disconnect(), r = null;
|
|
33418
|
+
const c = e.value;
|
|
33419
|
+
if (!c) return;
|
|
33420
|
+
const h = (u = c.closest(".mix-component")) != null ? u : c;
|
|
33421
|
+
r = new MutationObserver(() => l()), r.observe(h, { attributes: !0, attributeFilter: ["class"] }), r.observe(document.documentElement, {
|
|
33423
33422
|
attributes: !0,
|
|
33424
33423
|
attributeFilter: ["class", "data-theme"]
|
|
33425
33424
|
});
|
|
33426
33425
|
}
|
|
33427
|
-
ot([e, t
|
|
33428
|
-
|
|
33426
|
+
ot([e, t], () => {
|
|
33427
|
+
l(), a();
|
|
33429
33428
|
}, { immediate: !0 });
|
|
33430
|
-
function
|
|
33431
|
-
|
|
33429
|
+
function d() {
|
|
33430
|
+
l();
|
|
33432
33431
|
}
|
|
33433
33432
|
return Pr(() => {
|
|
33434
|
-
window.addEventListener("mix-dashboard-theme-change",
|
|
33433
|
+
window.addEventListener("mix-dashboard-theme-change", d);
|
|
33435
33434
|
}), Dr(() => {
|
|
33436
|
-
|
|
33437
|
-
}), { isDarkMode:
|
|
33435
|
+
r == null || r.disconnect(), window.removeEventListener("mix-dashboard-theme-change", d);
|
|
33436
|
+
}), { isDarkMode: i, themeRoot: o };
|
|
33438
33437
|
}
|
|
33439
33438
|
function OS(e, t) {
|
|
33440
33439
|
const i = getComputedStyle(e), s = (o, r) => i.getPropertyValue(o).trim() || r;
|
|
@@ -33563,7 +33562,7 @@ const GS = /* @__PURE__ */ Wi({
|
|
|
33563
33562
|
return mS.withPart(F ? nS : Nl).withParams(M);
|
|
33564
33563
|
}), u = Fe(
|
|
33565
33564
|
() => r.value === "zh-CN" || r.value === "cn" ? kS : IS
|
|
33566
|
-
), g = Pt([]), p =
|
|
33565
|
+
), g = Pt([]), p = xa(n);
|
|
33567
33566
|
function m() {
|
|
33568
33567
|
if (!s.showCheckbox) return;
|
|
33569
33568
|
const F = s.rowSelection === "multiple", M = s.isRowSelectable, k = x({
|
|
@@ -27,16 +27,16 @@ var f = (u, t, s) => new Promise((e, i) => {
|
|
|
27
27
|
r((s = s.apply(u, t)).next());
|
|
28
28
|
});
|
|
29
29
|
import { ref as I, inject as T, watch as g, onMounted as U, onBeforeUnmount as W } from "vue";
|
|
30
|
-
import {
|
|
30
|
+
import { v as d, w as E, A as h, x as P, d as v, a as M, l as Y, y as B, z as x, B as q, E as K, G as $ } from "./index-DUL649KZ.js";
|
|
31
31
|
const N = (u, t, s, e, i) => f(null, null, function* () {
|
|
32
32
|
try {
|
|
33
|
-
const a = yield new (yield import("./history-
|
|
33
|
+
const a = yield new (yield import("./history-BvM7EXsN.js")).default().getHistoryData(u, i);
|
|
34
34
|
s(a);
|
|
35
35
|
} catch (n) {
|
|
36
36
|
console.error("获取历史数据时出错:", n);
|
|
37
37
|
} finally {
|
|
38
38
|
if (t) {
|
|
39
|
-
const { formatRequest: n } = yield import("./request-
|
|
39
|
+
const { formatRequest: n } = yield import("./request-CEUCACCR.js"), a = n(u.conf, u.uid, i);
|
|
40
40
|
t.registerComponent({
|
|
41
41
|
id: u.conf.id,
|
|
42
42
|
request: a,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var j=Object.defineProperty,E=Object.defineProperties;var A=Object.getOwnPropertyDescriptors;var I=Object.getOwnPropertySymbols;var C=Object.prototype.hasOwnProperty,O=Object.prototype.propertyIsEnumerable;var w=(p,t,s)=>t in p?j(p,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):p[t]=s,g=(p,t)=>{for(var s in t||(t={}))C.call(t,s)&&w(p,s,t[s]);if(I)for(var s of I(t))O.call(t,s)&&w(p,s,t[s]);return p},S=(p,t)=>E(p,A(t));var d=(p,t,s)=>new Promise((e,i)=>{var n=l=>{try{r(s.next(l))}catch(o){i(o)}},a=l=>{try{r(s.throw(l))}catch(o){i(o)}},r=l=>l.done?e(l.value):Promise.resolve(l.value).then(n,a);r((s=s.apply(p,t)).next())});const f=require("vue"),c=require("./index-Bo49zvKb.cjs"),T=(p,t,s,e,i)=>d(null,null,function*(){try{const a=yield new(yield Promise.resolve().then(()=>require("./history-DqPjJP_E.cjs"))).default().getHistoryData(p,i);s(a)}catch(n){console.error("获取历史数据时出错:",n)}finally{if(t){const{formatRequest:n}=yield Promise.resolve().then(()=>require("./request-D9N74QdZ.cjs")),a=n(p.conf,p.uid,i);t.registerComponent({id:p.conf.id,request:a,onUpdate:(r,l)=>{r==="realtime"&&e(l)}})}}}),R=(p,t)=>{t&&t.unregisterComponent(p.conf.id)};class D{constructor(t){this.props=t}scriptUid(t){var s;return(s=t.uid)!=null?s:t.fv}indexIdentityKey(t){return t.is_alias?"alias":"uid"}mosaicResult(t,s){return t.fv?{block_mapping:"influxdbproxy",action:"get_mosaic_list",object_id:t.object_id,keys:[t.fv],page_index:1,page_size:s||1,order_by:"created",order_type:"desc"}:null}statisticsListCondition(t,s,e,i){const n=this.scriptUid(t);if(!n||!c.handlePermission(e,n)||!t.periodUnit)return null;const a=c.getStatisticsTimeRange(t.periodUnit,t.periodValue);return{block_mapping:"statistics",action:i,script_uid:n,where_and:JSON.stringify([["object_id","=",t.object_id],["start_time",">=",a[0]],["start_time","<=",a[1]]]),page_size:Number(s)||20,page_index:1,order_by:"created",order_type:"desc"}}statisticsResult(t,s){return this.statisticsListCondition(t,s,c.ACTION_ENTITIES.statistics,"get_statistics_page")}calculateResult(t,s){return this.statisticsListCondition(t,s,c.ACTION_ENTITIES.calculate,"get_calculate_page")}blockResult(t,s,e,i){return S(g({},this.indexResult(t,s)),{block_mapping:e,action:i})}indexResult(t,s){const e=this.indexIdentityKey(t);return!t[e]||!t.object_id||!c.handlePermission(c.ACTION_ENTITIES.index,t[e])?null:{page_index:1,page_size:s,block_mapping:"index",action:"get_index_result_list",where_and:JSON.stringify([[e,"=",t[e]],["object_id","=",t.object_id]]),order_by:"created",order_type:"asc"}}deviationResult(t,s){return this.blockResult(t,s,"deviation","get_deviation_result_list")}stabilityResult(t,s){return this.blockResult(t,s,"stability","get_stability_result_list")}balanceResult(t,s){return this.blockResult(t,s,"balance","get_balance_result_list")}incrementResult(t,s){return this.blockResult(t,s,"increment","get_increment_result_list")}riskResult(t,s){return this.blockResult(t,s,"risk","get_risk_result_list")}isValidPlatformCondition(t){const s=t==null?void 0:t.action;return typeof s=="string"&&s.trim()!==""}applyHistoryObjectResolution(t){const{conf:s,uid:e}=this.props,{common:i}=s,n=i.useAlias||!1,a=i.multiObject||!1,r=sessionStorage.getItem(c.ALIAS_MAPPING_KEY),l=JSON.parse(r||"{}"),o=a?t.object_alias:i.object_alias,u=a?t.object_id:i.object_id;return t.object_id=n?o?l[o]:e:u||e,c.handlePermission(c.ACTION_ENTITIES.object,t.object_id)?!!t.object_id:(delete t.object_id,!1)}mosaicBucketKey(t,s){var e;return`${(e=t.object_id)!=null?e:""}::${s||1}`}fillResponseFromMosaicRows(t,s,e){t.forEach(i=>{const n=s.fv,a="time";e.data.push(i[n]),e.time.push(c.dayjs(i[a]).format("YYYY-MM-DD HH:mm:ss"))})}postMosaicBatchMerged(t,s,e){var o;const i=[],n=new Set;for(const{item:u}of s){const h=u.fv;h&&!n.has(h)&&(n.add(h),i.push(h))}const a=(o=s[0])==null?void 0:o.item,r=a?this.mosaicResult(a,t):null;if(!r||i.length===0){for(const{index:u}of s)e[u]={data:[],time:[]};return Promise.resolve()}const l=S(g({},r),{keys:i});return new Promise(u=>{c.api.platform(h=>{var b,m;const y=(m=(b=h==null?void 0:h.result)==null?void 0:b.data)!=null?m:[];for(const{index:v,item:_}of s){const k={data:[],time:[]};this.fillResponseFromMosaicRows(y,_,k),e[v]=k}u()},l)})}postDataItem(t){var u;const{conf:s}=this.props,{common:e,options:i}=s,n=e.source||"mosaic",a=i.points||1,r={data:[],time:[]};if(!this.applyHistoryObjectResolution(t))return Promise.resolve(r);const l=this[`${n}Result`],o=(u=l==null?void 0:l.call(this,t,a))!=null?u:null;return o==null?Promise.resolve(r):new Promise(h=>{c.api.platform(y=>{(y.result.data.sort((m,v)=>c.dayjs(m.created).valueOf()-c.dayjs(v.created).valueOf())||[]).forEach(m=>{const v=["statistics","calculate"].includes(n)?"data":t.fv,_=["statistics","calculate"].includes(n)?"start_time":"time";r.data.push(m[v]),r.time.push(c.dayjs(m[_]).format("YYYY-MM-DD HH:mm:ss"))}),h(r)},o)})}initHistory(){return d(this,null,function*(){const{data:t,common:s,options:e}=this.props.conf,i=s.source||"mosaic",n=e.points||1;if(i!=="mosaic")return Promise.all(t.map(o=>this.postDataItem(o)));const a=t.length,r=new Array(a),l=new Map;for(let o=0;o<a;o++){const u=t[o];if(!this.applyHistoryObjectResolution(u)){r[o]={data:[],time:[]};continue}if(this.mosaicResult(u,n)==null){r[o]={data:[],time:[]};continue}const y=this.mosaicBucketKey(u,n);let b=l.get(y);b||(b=[],l.set(y,b)),b.push({index:o,item:u})}return yield Promise.all(Array.from(l.values()).map(o=>this.postMosaicBatchMerged(n,o,r))),r})}}class N extends D{constructor(t,s){super(t),this.linkWatchStop=null,this.componentType=s,this.session=f.ref(f.inject("session",null)),this.Style=f.ref({}),this.linkStore=c.useLinkStore()}extractStyles(){return{}}init(){return d(this,null,function*(){var t;this.Style.value=this.extractStyles(),this.applyTheme(),yield this.expandAliasData((t=this.props.conf)==null?void 0:t.data)})}setHistoryData(t){}onPreview(){return d(this,null,function*(){var n;const{common:t,data:s}=this.props.conf,e=this.getSource(),i=yield this.expandAliasData(s);if(this.props.conf.data=i,t.multiObject&&Array.isArray(i)){const a=new Set,r=new Map;(yield Promise.all(i.map(o=>d(this,null,function*(){return{item:o,objectIds:yield this.resolveObjectIds(o)}})))).forEach(({item:o,objectIds:u})=>{u.length>1&&r.set(String((t==null?void 0:t.object_alias)||(o==null?void 0:o.object_alias)||(o==null?void 0:o.alias)||(o==null?void 0:o.object_id)||(o==null?void 0:o.uid)||""),u),u.forEach(h=>{!h||a.has(h)||(a.add(h),this.subscribeBySource(e,h,o.uid))})})}else{const a=yield this.resolveObjectId(),r=(n=i==null?void 0:i[0])==null?void 0:n.uid;this.subscribeBySource(e,a,r)}})}setSocketData(t){if(!t)return;const{data:s}=this.props.conf;!s||!Array.isArray(s)||s.forEach(e=>{try{const i=this.extractDataValue(t,e.fv);e.value=i!=null?i:"--"}catch(i){e.value="--"}})}onLinkEvent(t){}getLinkChannel(){var t;return((t=this.Style.value)==null?void 0:t.linkChannel)||""}publish(t){const s=this.getLinkChannel();if(!s){console.warn(`[${this.componentType}] 未配置联动频道,无法发布事件`);return}this.linkStore.publish(s,this.componentType,t)}shouldHandleEvent(t){return!(!t||this.props.mode==="edit"||t.topic.source===this.componentType)}setupLinkWatch(){this.linkWatchStop&&this.linkWatchStop(),this.linkWatchStop=f.watch(()=>{const t=this.getLinkChannel();return t?this.linkStore.channels[t]:null},t=>{this.shouldHandleEvent(t)&&this.onLinkEvent(t)},{deep:!0,immediate:!0})}stopLinkWatch(){this.linkWatchStop&&(this.linkWatchStop(),this.linkWatchStop=null)}isLocalIotSubscribeMode(){return localStorage.getItem("dashboardUseLocalToken")==="1"||localStorage.getItem("dashboardUseLocalToken")==="true"}subscribe(t,s,e,i){if(!this.session.value){console.warn(`[${this.componentType}] Session 未初始化,无法订阅`);return}const n={event:t,block:s,object_id:e};i&&Object.assign(n,i);const a=this.isLocalIotSubscribeMode()?{action:"sub_event",block_mapping:"mmq",event:n}:{action:"sub_agent_event",event:n},r=this.props.conf.id;this.session.value.componentRequests&&(this.session.value.componentRequests.has(r)||this.session.value.componentRequests.set(r,[]),this.session.value.componentRequests.get(r).push(a)),this.session.value.send({type:"send_message",message:a})}subscribeMmqEvent(t,s,e=""){if(!this.session.value){console.warn(`[${this.componentType}] Session 未初始化,无法订阅`);return}const i={event:t,block:s,object_id:e};e||Reflect.deleteProperty(i,"object_id");const n={action:"sub_event",block_mapping:"mmq",event:i},a=this.props.conf.id;this.session.value.componentRequests&&(this.session.value.componentRequests.has(a)||this.session.value.componentRequests.set(a,[]),this.session.value.componentRequests.get(a).push(n)),this.session.value.send({type:"send_message",message:n})}subscribeFv(t){c.handlePermission(c.ACTION_ENTITIES.object,t)&&this.subscribe("recv_fv","mosaic",t)}subscribeRetainerOpen(t){c.handlePermission(c.ACTION_ENTITIES.object,t)&&this.subscribe("retainer_open","retainer",t)}subscribeRetainerClose(t){c.handlePermission(c.ACTION_ENTITIES.object,t)&&this.subscribe("retainer_close","retainer",t)}subscribeRetainerEvent(t){c.handlePermission(c.ACTION_ENTITIES.object,t)&&this.subscribe("retainer_event","retainer",t)}subscribeRetainer(t){this.subscribeRetainerOpen(t),this.subscribeRetainerClose(t),this.subscribeRetainerEvent(t)}subscribeStatisticsRealtimeResult(t){c.handlePermission(c.ACTION_ENTITIES.object,t)&&this.subscribe("statistics_realtime_result","statistics",t)}subscribeStatistics(t){var e,i;const s=(i=(e=this.props.conf.data)==null?void 0:e[0])==null?void 0:i.uid;c.handlePermission(c.ACTION_ENTITIES.object,t)&&c.handlePermission(c.ACTION_ENTITIES.statistics,s)&&this.subscribeStatisticsWithUid(t,s)}subscribeStatisticsWithUid(t,s){this.subscribe("statistics_result","statistics",t,{uid:s,type:"statistics"})}subscribeCalculate(t){var e,i;const s=(i=(e=this.props.conf.data)==null?void 0:e[0])==null?void 0:i.uid;this.subscribeCalculateWithUid(s)}subscribeCalculateWithUid(t){c.handlePermission(c.ACTION_ENTITIES.calculate,t)&&this.subscribe("statistics_result","statistics","",{uid:t,type:"calculate"})}shouldSkipStatisticsCalculateSocket(t){var i,n,a;const s=(i=this.props.conf)==null?void 0:i.data;if(!Array.isArray(s)||!s.length)return!1;const e=t!=null&&t!==""?(n=s.find(r=>(r==null?void 0:r.uid)===t))==null?void 0:n.periodUnit:(a=s[0])==null?void 0:a.periodUnit;return typeof e=="string"&&e.startsWith("last")}subscribeBySource(t,s,e){switch(t){case"mosaic":this.subscribeFv(s);break;case"statisticsRealtime":this.subscribeStatisticsRealtimeResult(s);break;case"statistics":if(this.shouldSkipStatisticsCalculateSocket(e))return;e?this.subscribeStatisticsWithUid(s,e):this.subscribeStatistics(s);break;case"calculate":if(this.shouldSkipStatisticsCalculateSocket(e))return;e?this.subscribeCalculateWithUid(e):this.subscribeCalculate(s);break;default:console.warn(`[${this.componentType}] 未知的数据源类型: ${t}`)}}extractDataValue(t,s){var e;return!t||!t.event?null:t.event==="recv_fv"&&t.block==="mosaic"?!s||!t.data?null:t.data[s]:t.event==="statistics_realtime_result"&&t.block==="statistics"?(e=t.data)==null?void 0:e.data:t.event==="statistics_result"&&t.block==="statistics"?t.data:null}getOptionValue(t,s){var i,n;const e=(n=(i=this.props.conf)==null?void 0:i.options)==null?void 0:n[t];return e==null?s:typeof e=="object"&&"value"in e?e.value:e}applyTheme(){c.applyThemeStyles(this.props.theme,this.Style.value)}getSource(){var t,s;return((s=(t=this.props.conf)==null?void 0:t.common)==null?void 0:s.source)||"mosaic"}isStatistics(){return["statistics","calculate","statisticsRealtime","calculateRealtime"].includes(this.getSource())}resolveObjectId(t){return d(this,null,function*(){return(yield this.resolveObjectIds(t))[0]||""})}resolveObjectIds(t){return d(this,null,function*(){const{uid:s,conf:e}=this.props,{common:i,data:n}=e,a=t||i||n[0]||{},l=(yield this.expandAliasData([a])).map(o=>String((o==null?void 0:o.object_id)||(o==null?void 0:o.objectid)||s)).filter(Boolean);return l.length>0&&a&&typeof a=="object"&&(a.object_id=l[0],a.objectid=l[0]),l.length>0?l:[String((a==null?void 0:a.object_id)||(a==null?void 0:a.objectid)||"")].filter(Boolean)})}expandAliasData(t){return d(this,null,function*(){var i;const s=Array.isArray(t)?t:[],e=[];for(const n of s){if(!n||typeof n!="object"){e.push(n);continue}const a={common:n,data:[n],options:(i=this.props.conf)==null?void 0:i.options};if(!String(n.object_alias||n.alias||"").trim()){e.push(n);continue}if(!(yield c.loadAliasMappingFromJsonIfNeeded(a))){e.push(n);continue}const l=c.expandAliasItems([n]);l.length>0?e.push(...l):e.push(n)}return e})}handleNull(t,s){return c.handleNullData(t,this.props,s)}getPreviewHelper(){return{preview:()=>T(this.props,this.session.value,t=>this.setHistoryData(t),t=>{let s=t;s.datetime=c.dayjs(s.datetime).format("YYYY-MM-DD HH:mm:ss"),this.setSocketData(s)},this.componentType),unregister:()=>R(this.props,this.session.value)}}getDebouncedInit(){return c.debounce(()=>this.init(),200)}cleanup(){}needsHistoryData(){return!0}setupLifecycle(){const t=this.getDebouncedInit(),s=this.getPreviewHelper();f.onMounted(()=>d(this,null,function*(){var i,n,a,r;const e={common:(i=this.props.conf)==null?void 0:i.common,data:(n=this.props.conf)==null?void 0:n.data,options:(a=this.props.conf)==null?void 0:a.options};if(this.props.mode==="preview"&&(yield c.loadAliasMappingFromJsonIfNeeded(e),Array.isArray((r=this.props.conf)==null?void 0:r.data)&&this.props.conf.data.length&&(this.props.conf.data=yield this.expandAliasData(this.props.conf.data))),yield this.init(),this.props.mode==="preview"){if(this.needsHistoryData())try{const l=yield this.initHistory();this.setHistoryData(l)}catch(l){console.error(`[${this.componentType}] 获取历史数据失败:`,l)}this.session.value&&(this.session.value.unregisterComponent(this.props.conf.id),this.session.value.registerComponent({id:this.props.conf.id,request:null,onUpdate:(l,o)=>{if(l==="realtime"){let u=o;u.datetime=c.dayjs(u.datetime).format("YYYY-MM-DD HH:mm:ss"),this.setSocketData(u)}}})),this.onPreview()}this.setupLinkWatch()})),f.onBeforeUnmount(()=>{this.cleanup(),s.unregister(),this.stopLinkWatch()}),f.watch(()=>this.props.conf,()=>{this.props.mode==="edit"&&t()},{deep:!0}),f.watch(()=>this.props.theme,()=>{this.init()}),f.watch(()=>{var e;return(e=this.Style.value)==null?void 0:e.linkChannel},()=>{this.setupLinkWatch()})}getStyle(){return this.Style}getType(){return this.componentType}dispatchModal(t,s,e){this.props.mode==="preview"&&window.dispatchEvent(new CustomEvent("mix-modal",{detail:{action:t,layerId:s,sheetIndex:e!=null?e:-1}}))}triggerModalByKey(t){var e,i;if(this.props.mode!=="preview")return;const s=(e=this.props.conf)==null?void 0:e.modalBinding;if(s&&s.enabled&&s.mode==="key"){const a=(s.map||{})[t];if(!a||!a.layerId)return;const r=a.action||"toggle",l=(i=s.sheetIndex)!=null?i:-1;this.dispatchModal(r,a.layerId,l)}}}exports.BaseComponent=N;exports.preview=T;exports.unregister=R;
|
|
1
|
+
"use strict";var j=Object.defineProperty,E=Object.defineProperties;var A=Object.getOwnPropertyDescriptors;var I=Object.getOwnPropertySymbols;var C=Object.prototype.hasOwnProperty,O=Object.prototype.propertyIsEnumerable;var w=(p,t,s)=>t in p?j(p,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):p[t]=s,g=(p,t)=>{for(var s in t||(t={}))C.call(t,s)&&w(p,s,t[s]);if(I)for(var s of I(t))O.call(t,s)&&w(p,s,t[s]);return p},S=(p,t)=>E(p,A(t));var d=(p,t,s)=>new Promise((e,i)=>{var n=l=>{try{r(s.next(l))}catch(o){i(o)}},a=l=>{try{r(s.throw(l))}catch(o){i(o)}},r=l=>l.done?e(l.value):Promise.resolve(l.value).then(n,a);r((s=s.apply(p,t)).next())});const f=require("vue"),c=require("./index-Cm7hGuPj.cjs"),T=(p,t,s,e,i)=>d(null,null,function*(){try{const a=yield new(yield Promise.resolve().then(()=>require("./history-BKLujk4W.cjs"))).default().getHistoryData(p,i);s(a)}catch(n){console.error("获取历史数据时出错:",n)}finally{if(t){const{formatRequest:n}=yield Promise.resolve().then(()=>require("./request-BNiCZV7_.cjs")),a=n(p.conf,p.uid,i);t.registerComponent({id:p.conf.id,request:a,onUpdate:(r,l)=>{r==="realtime"&&e(l)}})}}}),R=(p,t)=>{t&&t.unregisterComponent(p.conf.id)};class D{constructor(t){this.props=t}scriptUid(t){var s;return(s=t.uid)!=null?s:t.fv}indexIdentityKey(t){return t.is_alias?"alias":"uid"}mosaicResult(t,s){return t.fv?{block_mapping:"influxdbproxy",action:"get_mosaic_list",object_id:t.object_id,keys:[t.fv],page_index:1,page_size:s||1,order_by:"created",order_type:"desc"}:null}statisticsListCondition(t,s,e,i){const n=this.scriptUid(t);if(!n||!c.handlePermission(e,n)||!t.periodUnit)return null;const a=c.getStatisticsTimeRange(t.periodUnit,t.periodValue);return{block_mapping:"statistics",action:i,script_uid:n,where_and:JSON.stringify([["object_id","=",t.object_id],["start_time",">=",a[0]],["start_time","<=",a[1]]]),page_size:Number(s)||20,page_index:1,order_by:"created",order_type:"desc"}}statisticsResult(t,s){return this.statisticsListCondition(t,s,c.ACTION_ENTITIES.statistics,"get_statistics_page")}calculateResult(t,s){return this.statisticsListCondition(t,s,c.ACTION_ENTITIES.calculate,"get_calculate_page")}blockResult(t,s,e,i){return S(g({},this.indexResult(t,s)),{block_mapping:e,action:i})}indexResult(t,s){const e=this.indexIdentityKey(t);return!t[e]||!t.object_id||!c.handlePermission(c.ACTION_ENTITIES.index,t[e])?null:{page_index:1,page_size:s,block_mapping:"index",action:"get_index_result_list",where_and:JSON.stringify([[e,"=",t[e]],["object_id","=",t.object_id]]),order_by:"created",order_type:"asc"}}deviationResult(t,s){return this.blockResult(t,s,"deviation","get_deviation_result_list")}stabilityResult(t,s){return this.blockResult(t,s,"stability","get_stability_result_list")}balanceResult(t,s){return this.blockResult(t,s,"balance","get_balance_result_list")}incrementResult(t,s){return this.blockResult(t,s,"increment","get_increment_result_list")}riskResult(t,s){return this.blockResult(t,s,"risk","get_risk_result_list")}isValidPlatformCondition(t){const s=t==null?void 0:t.action;return typeof s=="string"&&s.trim()!==""}applyHistoryObjectResolution(t){const{conf:s,uid:e}=this.props,{common:i}=s,n=i.useAlias||!1,a=i.multiObject||!1,r=sessionStorage.getItem(c.ALIAS_MAPPING_KEY),l=JSON.parse(r||"{}"),o=a?t.object_alias:i.object_alias,u=a?t.object_id:i.object_id;return t.object_id=n?o?l[o]:e:u||e,c.handlePermission(c.ACTION_ENTITIES.object,t.object_id)?!!t.object_id:(delete t.object_id,!1)}mosaicBucketKey(t,s){var e;return`${(e=t.object_id)!=null?e:""}::${s||1}`}fillResponseFromMosaicRows(t,s,e){t.forEach(i=>{const n=s.fv,a="time";e.data.push(i[n]),e.time.push(c.dayjs(i[a]).format("YYYY-MM-DD HH:mm:ss"))})}postMosaicBatchMerged(t,s,e){var o;const i=[],n=new Set;for(const{item:u}of s){const h=u.fv;h&&!n.has(h)&&(n.add(h),i.push(h))}const a=(o=s[0])==null?void 0:o.item,r=a?this.mosaicResult(a,t):null;if(!r||i.length===0){for(const{index:u}of s)e[u]={data:[],time:[]};return Promise.resolve()}const l=S(g({},r),{keys:i});return new Promise(u=>{c.api.platform(h=>{var b,m;const y=(m=(b=h==null?void 0:h.result)==null?void 0:b.data)!=null?m:[];for(const{index:v,item:_}of s){const k={data:[],time:[]};this.fillResponseFromMosaicRows(y,_,k),e[v]=k}u()},l)})}postDataItem(t){var u;const{conf:s}=this.props,{common:e,options:i}=s,n=e.source||"mosaic",a=i.points||1,r={data:[],time:[]};if(!this.applyHistoryObjectResolution(t))return Promise.resolve(r);const l=this[`${n}Result`],o=(u=l==null?void 0:l.call(this,t,a))!=null?u:null;return o==null?Promise.resolve(r):new Promise(h=>{c.api.platform(y=>{(y.result.data.sort((m,v)=>c.dayjs(m.created).valueOf()-c.dayjs(v.created).valueOf())||[]).forEach(m=>{const v=["statistics","calculate"].includes(n)?"data":t.fv,_=["statistics","calculate"].includes(n)?"start_time":"time";r.data.push(m[v]),r.time.push(c.dayjs(m[_]).format("YYYY-MM-DD HH:mm:ss"))}),h(r)},o)})}initHistory(){return d(this,null,function*(){const{data:t,common:s,options:e}=this.props.conf,i=s.source||"mosaic",n=e.points||1;if(i!=="mosaic")return Promise.all(t.map(o=>this.postDataItem(o)));const a=t.length,r=new Array(a),l=new Map;for(let o=0;o<a;o++){const u=t[o];if(!this.applyHistoryObjectResolution(u)){r[o]={data:[],time:[]};continue}if(this.mosaicResult(u,n)==null){r[o]={data:[],time:[]};continue}const y=this.mosaicBucketKey(u,n);let b=l.get(y);b||(b=[],l.set(y,b)),b.push({index:o,item:u})}return yield Promise.all(Array.from(l.values()).map(o=>this.postMosaicBatchMerged(n,o,r))),r})}}class N extends D{constructor(t,s){super(t),this.linkWatchStop=null,this.componentType=s,this.session=f.ref(f.inject("session",null)),this.Style=f.ref({}),this.linkStore=c.useLinkStore()}extractStyles(){return{}}init(){return d(this,null,function*(){var t;this.Style.value=this.extractStyles(),this.applyTheme(),yield this.expandAliasData((t=this.props.conf)==null?void 0:t.data)})}setHistoryData(t){}onPreview(){return d(this,null,function*(){var n;const{common:t,data:s}=this.props.conf,e=this.getSource(),i=yield this.expandAliasData(s);if(this.props.conf.data=i,t.multiObject&&Array.isArray(i)){const a=new Set,r=new Map;(yield Promise.all(i.map(o=>d(this,null,function*(){return{item:o,objectIds:yield this.resolveObjectIds(o)}})))).forEach(({item:o,objectIds:u})=>{u.length>1&&r.set(String((t==null?void 0:t.object_alias)||(o==null?void 0:o.object_alias)||(o==null?void 0:o.alias)||(o==null?void 0:o.object_id)||(o==null?void 0:o.uid)||""),u),u.forEach(h=>{!h||a.has(h)||(a.add(h),this.subscribeBySource(e,h,o.uid))})})}else{const a=yield this.resolveObjectId(),r=(n=i==null?void 0:i[0])==null?void 0:n.uid;this.subscribeBySource(e,a,r)}})}setSocketData(t){if(!t)return;const{data:s}=this.props.conf;!s||!Array.isArray(s)||s.forEach(e=>{try{const i=this.extractDataValue(t,e.fv);e.value=i!=null?i:"--"}catch(i){e.value="--"}})}onLinkEvent(t){}getLinkChannel(){var t;return((t=this.Style.value)==null?void 0:t.linkChannel)||""}publish(t){const s=this.getLinkChannel();if(!s){console.warn(`[${this.componentType}] 未配置联动频道,无法发布事件`);return}this.linkStore.publish(s,this.componentType,t)}shouldHandleEvent(t){return!(!t||this.props.mode==="edit"||t.topic.source===this.componentType)}setupLinkWatch(){this.linkWatchStop&&this.linkWatchStop(),this.linkWatchStop=f.watch(()=>{const t=this.getLinkChannel();return t?this.linkStore.channels[t]:null},t=>{this.shouldHandleEvent(t)&&this.onLinkEvent(t)},{deep:!0,immediate:!0})}stopLinkWatch(){this.linkWatchStop&&(this.linkWatchStop(),this.linkWatchStop=null)}isLocalIotSubscribeMode(){return localStorage.getItem("dashboardUseLocalToken")==="1"||localStorage.getItem("dashboardUseLocalToken")==="true"}subscribe(t,s,e,i){if(!this.session.value){console.warn(`[${this.componentType}] Session 未初始化,无法订阅`);return}const n={event:t,block:s,object_id:e};i&&Object.assign(n,i);const a=this.isLocalIotSubscribeMode()?{action:"sub_event",block_mapping:"mmq",event:n}:{action:"sub_agent_event",event:n},r=this.props.conf.id;this.session.value.componentRequests&&(this.session.value.componentRequests.has(r)||this.session.value.componentRequests.set(r,[]),this.session.value.componentRequests.get(r).push(a)),this.session.value.send({type:"send_message",message:a})}subscribeMmqEvent(t,s,e=""){if(!this.session.value){console.warn(`[${this.componentType}] Session 未初始化,无法订阅`);return}const i={event:t,block:s,object_id:e};e||Reflect.deleteProperty(i,"object_id");const n={action:"sub_event",block_mapping:"mmq",event:i},a=this.props.conf.id;this.session.value.componentRequests&&(this.session.value.componentRequests.has(a)||this.session.value.componentRequests.set(a,[]),this.session.value.componentRequests.get(a).push(n)),this.session.value.send({type:"send_message",message:n})}subscribeFv(t){c.handlePermission(c.ACTION_ENTITIES.object,t)&&this.subscribe("recv_fv","mosaic",t)}subscribeRetainerOpen(t){c.handlePermission(c.ACTION_ENTITIES.object,t)&&this.subscribe("retainer_open","retainer",t)}subscribeRetainerClose(t){c.handlePermission(c.ACTION_ENTITIES.object,t)&&this.subscribe("retainer_close","retainer",t)}subscribeRetainerEvent(t){c.handlePermission(c.ACTION_ENTITIES.object,t)&&this.subscribe("retainer_event","retainer",t)}subscribeRetainer(t){this.subscribeRetainerOpen(t),this.subscribeRetainerClose(t),this.subscribeRetainerEvent(t)}subscribeStatisticsRealtimeResult(t){c.handlePermission(c.ACTION_ENTITIES.object,t)&&this.subscribe("statistics_realtime_result","statistics",t)}subscribeStatistics(t){var e,i;const s=(i=(e=this.props.conf.data)==null?void 0:e[0])==null?void 0:i.uid;c.handlePermission(c.ACTION_ENTITIES.object,t)&&c.handlePermission(c.ACTION_ENTITIES.statistics,s)&&this.subscribeStatisticsWithUid(t,s)}subscribeStatisticsWithUid(t,s){this.subscribe("statistics_result","statistics",t,{uid:s,type:"statistics"})}subscribeCalculate(t){var e,i;const s=(i=(e=this.props.conf.data)==null?void 0:e[0])==null?void 0:i.uid;this.subscribeCalculateWithUid(s)}subscribeCalculateWithUid(t){c.handlePermission(c.ACTION_ENTITIES.calculate,t)&&this.subscribe("statistics_result","statistics","",{uid:t,type:"calculate"})}shouldSkipStatisticsCalculateSocket(t){var i,n,a;const s=(i=this.props.conf)==null?void 0:i.data;if(!Array.isArray(s)||!s.length)return!1;const e=t!=null&&t!==""?(n=s.find(r=>(r==null?void 0:r.uid)===t))==null?void 0:n.periodUnit:(a=s[0])==null?void 0:a.periodUnit;return typeof e=="string"&&e.startsWith("last")}subscribeBySource(t,s,e){switch(t){case"mosaic":this.subscribeFv(s);break;case"statisticsRealtime":this.subscribeStatisticsRealtimeResult(s);break;case"statistics":if(this.shouldSkipStatisticsCalculateSocket(e))return;e?this.subscribeStatisticsWithUid(s,e):this.subscribeStatistics(s);break;case"calculate":if(this.shouldSkipStatisticsCalculateSocket(e))return;e?this.subscribeCalculateWithUid(e):this.subscribeCalculate(s);break;default:console.warn(`[${this.componentType}] 未知的数据源类型: ${t}`)}}extractDataValue(t,s){var e;return!t||!t.event?null:t.event==="recv_fv"&&t.block==="mosaic"?!s||!t.data?null:t.data[s]:t.event==="statistics_realtime_result"&&t.block==="statistics"?(e=t.data)==null?void 0:e.data:t.event==="statistics_result"&&t.block==="statistics"?t.data:null}getOptionValue(t,s){var i,n;const e=(n=(i=this.props.conf)==null?void 0:i.options)==null?void 0:n[t];return e==null?s:typeof e=="object"&&"value"in e?e.value:e}applyTheme(){c.applyThemeStyles(this.props.theme,this.Style.value)}getSource(){var t,s;return((s=(t=this.props.conf)==null?void 0:t.common)==null?void 0:s.source)||"mosaic"}isStatistics(){return["statistics","calculate","statisticsRealtime","calculateRealtime"].includes(this.getSource())}resolveObjectId(t){return d(this,null,function*(){return(yield this.resolveObjectIds(t))[0]||""})}resolveObjectIds(t){return d(this,null,function*(){const{uid:s,conf:e}=this.props,{common:i,data:n}=e,a=t||i||n[0]||{},l=(yield this.expandAliasData([a])).map(o=>String((o==null?void 0:o.object_id)||(o==null?void 0:o.objectid)||s)).filter(Boolean);return l.length>0&&a&&typeof a=="object"&&(a.object_id=l[0],a.objectid=l[0]),l.length>0?l:[String((a==null?void 0:a.object_id)||(a==null?void 0:a.objectid)||"")].filter(Boolean)})}expandAliasData(t){return d(this,null,function*(){var i;const s=Array.isArray(t)?t:[],e=[];for(const n of s){if(!n||typeof n!="object"){e.push(n);continue}const a={common:n,data:[n],options:(i=this.props.conf)==null?void 0:i.options};if(!String(n.object_alias||n.alias||"").trim()){e.push(n);continue}if(!(yield c.loadAliasMappingFromJsonIfNeeded(a))){e.push(n);continue}const l=c.expandAliasItems([n]);l.length>0?e.push(...l):e.push(n)}return e})}handleNull(t,s){return c.handleNullData(t,this.props,s)}getPreviewHelper(){return{preview:()=>T(this.props,this.session.value,t=>this.setHistoryData(t),t=>{let s=t;s.datetime=c.dayjs(s.datetime).format("YYYY-MM-DD HH:mm:ss"),this.setSocketData(s)},this.componentType),unregister:()=>R(this.props,this.session.value)}}getDebouncedInit(){return c.debounce(()=>this.init(),200)}cleanup(){}needsHistoryData(){return!0}setupLifecycle(){const t=this.getDebouncedInit(),s=this.getPreviewHelper();f.onMounted(()=>d(this,null,function*(){var i,n,a,r;const e={common:(i=this.props.conf)==null?void 0:i.common,data:(n=this.props.conf)==null?void 0:n.data,options:(a=this.props.conf)==null?void 0:a.options};if(this.props.mode==="preview"&&(yield c.loadAliasMappingFromJsonIfNeeded(e),Array.isArray((r=this.props.conf)==null?void 0:r.data)&&this.props.conf.data.length&&(this.props.conf.data=yield this.expandAliasData(this.props.conf.data))),yield this.init(),this.props.mode==="preview"){if(this.needsHistoryData())try{const l=yield this.initHistory();this.setHistoryData(l)}catch(l){console.error(`[${this.componentType}] 获取历史数据失败:`,l)}this.session.value&&(this.session.value.unregisterComponent(this.props.conf.id),this.session.value.registerComponent({id:this.props.conf.id,request:null,onUpdate:(l,o)=>{if(l==="realtime"){let u=o;u.datetime=c.dayjs(u.datetime).format("YYYY-MM-DD HH:mm:ss"),this.setSocketData(u)}}})),this.onPreview()}this.setupLinkWatch()})),f.onBeforeUnmount(()=>{this.cleanup(),s.unregister(),this.stopLinkWatch()}),f.watch(()=>this.props.conf,()=>{this.props.mode==="edit"&&t()},{deep:!0}),f.watch(()=>this.props.theme,()=>{this.init()}),f.watch(()=>{var e;return(e=this.Style.value)==null?void 0:e.linkChannel},()=>{this.setupLinkWatch()})}getStyle(){return this.Style}getType(){return this.componentType}dispatchModal(t,s,e){this.props.mode==="preview"&&window.dispatchEvent(new CustomEvent("mix-modal",{detail:{action:t,layerId:s,sheetIndex:e!=null?e:-1}}))}triggerModalByKey(t){var e,i;if(this.props.mode!=="preview")return;const s=(e=this.props.conf)==null?void 0:e.modalBinding;if(s&&s.enabled&&s.mode==="key"){const a=(s.map||{})[t];if(!a||!a.layerId)return;const r=a.action||"toggle",l=(i=s.sheetIndex)!=null?i:-1;this.dispatchModal(r,a.layerId,l)}}}exports.BaseComponent=N;exports.preview=T;exports.unregister=R;
|
|
@@ -15,8 +15,8 @@ var d = (s, t, e) => new Promise((r, n) => {
|
|
|
15
15
|
i((e = e.apply(s, t)).next());
|
|
16
16
|
});
|
|
17
17
|
import { nextTick as f, inject as m, watch as C } from "vue";
|
|
18
|
-
import { B as g } from "./BaseComponent-
|
|
19
|
-
import {
|
|
18
|
+
import { B as g } from "./BaseComponent-7Sa7XOg-.js";
|
|
19
|
+
import { I as p, J as O, K as y, L as b } from "./index-DUL649KZ.js";
|
|
20
20
|
import { i as D, d as R } from "./echarts-Bp7QN4X6.js";
|
|
21
21
|
const l = (s) => s.isConnected && s.offsetWidth > 0 && s.offsetHeight > 0;
|
|
22
22
|
function j(s, t) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var f=(a,t,e)=>new Promise((r,n)=>{var o=s=>{try{i(e.next(s))}catch(h){n(h)}},u=s=>{try{i(e.throw(s))}catch(h){n(h)}},i=s=>s.done?r(s.value):Promise.resolve(s.value).then(o,u);i((e=e.apply(a,t)).next())});const d=require("vue"),g=require("./BaseComponent-
|
|
1
|
+
"use strict";var f=(a,t,e)=>new Promise((r,n)=>{var o=s=>{try{i(e.next(s))}catch(h){n(h)}},u=s=>{try{i(e.throw(s))}catch(h){n(h)}},i=s=>s.done?r(s.value):Promise.resolve(s.value).then(o,u);i((e=e.apply(a,t)).next())});const d=require("vue"),g=require("./BaseComponent-BabOc6Kc.cjs"),c=require("./index-Cm7hGuPj.cjs"),C=require("./echarts-BB8O2KSA.cjs"),l=a=>a.isConnected&&a.offsetWidth>0&&a.offsetHeight>0;function O(a,t){let e=!1,r=null;const n=()=>{if(e)return!0;const i=document.getElementById(a);return!i||!l(i)?!1:(t(i),!0)},o=i=>{r=c.elementResizeDetectorMaker({strategy:"scroll"});const s=()=>{if(n()&&r){try{r.uninstall(i)}catch(h){}r=null}};r.listenTo(i,s);for(let h=i.parentElement,p=0;h&&p<4;p++,h=h.parentElement)r.listenTo(h,s);s()},u=(i=0)=>{if(!n())if(i<120)requestAnimationFrame(()=>u(i+1));else{const s=document.getElementById(a);s&&o(s)}};return u(),()=>{if(e=!0,r){const i=document.getElementById(a);if(i)try{r.uninstall(i)}catch(s){}r=null}}}class m extends g.BaseComponent{constructor(t,e){super(t,e),this.chartObj=null,this.erd=null,this.cancelDomWait=null,this.chartReady=null,this.hadValidSize=!1,this.echartId=`${e}_${Math.random().toString(16).slice(4,12)}`}getChartOption(){return{}}init(){return f(this,null,function*(){this.Style.value=this.extractStyles(),this.applyTheme(),this.ensureData(),yield d.nextTick(),yield this.ensureChartReady()})}extractStyles(){return{bgColor:this.getOptionValue("bgColor","#fff"),titleColor:this.getOptionValue("titleColor","#111"),textColor:this.getOptionValue("textColor","#111"),radiusSize:this.getOptionValue("radiusSize",8),textSize:this.getOptionValue("textSize",12),isHideTitle:this.getOptionValue("isHideTitle",!1),top:this.getOptionValue("top",30),bottom:this.getOptionValue("bottom",40),left:this.getOptionValue("left",40),right:this.getOptionValue("right",20),points:this.getOptionValue("points",10)}}ensureData(){var t;(t=this.props.conf.data)!=null&&t.length||(this.props.conf.data=this.getDefaultData())}getDefaultData(){return[{name:"参数一",fv:"",color:"#4162ff"}]}getChartDom(){const t=document.getElementById(this.echartId);return t instanceof HTMLElement?t:null}ensureChartReady(){return this.chartReady?this.chartReady:(this.chartReady=new Promise(t=>{var n;const e=()=>{this.chartReady=null,t()},r=this.getChartDom();if(r&&l(r)){this.mountChart(r),e();return}(n=this.cancelDomWait)==null||n.call(this),this.cancelDomWait=O(this.echartId,o=>{this.mountChart(o),e()})}),this.chartReady)}bindChartResize(t){this.erd||(this.hadValidSize=l(t),this.erd=c.elementResizeDetectorMaker({strategy:"scroll"}),this.erd.listenTo(t,()=>{!this.chartObj||!l(t)||(this.chartObj.resize(),this.hadValidSize||(this.hadValidSize=!0,this.applyChartOption(!0)))}))}mountChart(t){l(t)&&(this.chartObj||(this.chartObj=C.init(t),this.bindChartResize(t)),this.applyChartOption(!0))}initChart(t){const e=t!=null?t:this.getChartDom();if(!e||!l(e)){this.ensureChartReady();return}this.mountChart(e)}setupResizeListener(t){!this.chartObj||!l(t)||this.bindChartResize(t)}applyChartOption(t=!0){if(!this.chartObj)return;const e=this.getChartDom();e&&!l(e)||(this.chartObj.setOption(this.getChartOption(),t),this.chartObj.resize())}repaintChart(){this.ensureChartReady().then(()=>this.applyChartOption(!0))}hasData(){return c.hasDataSource(this.props.conf)}getTimeAxis(){return c.getxAxisDataTime(this.Style.value.points,this.props.mode,this.hasData())}updateChart(t){this.ensureChartReady().then(()=>{this.chartObj&&(this.chartObj.setOption(t),this.chartObj.resize())})}cleanup(){var e;(e=this.cancelDomWait)==null||e.call(this),this.cancelDomWait=null,this.chartReady=null,this.hadValidSize=!1;const t=this.getChartDom();if(this.erd&&t){try{this.erd.uninstall(t)}catch(r){}this.erd=null}this.chartObj&&(this.chartObj.clear(),C.dispose(this.chartObj),this.chartObj=null)}setupLifecycle(){const t=d.inject(c.MIX_PREVIEW_LAYOUT_KEY,null);t&&d.watch(t,()=>this.repaintChart()),super.setupLifecycle()}getEchartId(){return this.echartId}getChartInstance(){return this.chartObj}}exports.EChartComponentBase=m;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),V=require("./index-
|
|
1
|
+
"use strict";const e=require("vue"),V=require("./index-Cm7hGuPj.cjs"),w={class:"lw-panel-section lw-plan-section"},g={class:"lw-plan-toolbar"},b=["disabled"],y={class:"lw-plan-table"},k={class:"lw-step-no"},x=["onClick"],S={key:0},C=e.defineComponent({__name:"EmergencyPlanPanel",props:{plans:{},currentPlan:{},execution:{}},emits:["select-plan","start-plan","report-warning","complete-step"],setup(o,{emit:m}){var u,d;const a=o,i=m,s=e.ref(String((d=(u=a.currentPlan)==null?void 0:u.warningLevel)!=null?d:4)),r=e.computed(()=>{const n=parseInt(s.value);return a.plans.find(t=>t.warningLevel===n)||null}),c=e.computed(()=>{var n;return a.execution.status!=="idle"&&a.execution.steps.length>0?a.execution.steps:((n=r.value)==null?void 0:n.steps)||[]}),p=e.computed(()=>{const n=a.execution.status;return n==="running"?"lw-status-running":n==="completed"?"lw-status-done":"lw-status-idle"}),E=e.computed(()=>({idle:"未启动",running:"预案进行中",completed:"已完成",aborted:"已中止"})[a.execution.status]||"未启动");function N(){r.value&&i("select-plan",r.value)}function v(n){a.execution.status==="running"&&n.status==="pending"&&i("complete-step",n)}return e.watch(()=>a.currentPlan,n=>{n&&(s.value=String(n.warningLevel))}),(n,t)=>(e.openBlock(),e.createElementBlock("div",w,[t[7]||(t[7]=e.createElementVNode("div",{class:"lw-panel-header"},[e.createElementVNode("span",{class:"lw-panel-title"},"应急预案")],-1)),e.createElementVNode("div",g,[t[4]||(t[4]=e.createElementVNode("span",{class:"lw-plan-label"},"预案执行步骤",-1)),e.withDirectives(e.createElementVNode("select",{"onUpdate:modelValue":t[0]||(t[0]=l=>s.value=l),class:"lw-select lw-select-sm",onChange:N},[...t[3]||(t[3]=[e.createElementVNode("option",{value:"4"},"Ⅳ级预警",-1),e.createElementVNode("option",{value:"3"},"Ⅲ级预警",-1),e.createElementVNode("option",{value:"2"},"Ⅱ级预警",-1),e.createElementVNode("option",{value:"1"},"Ⅰ级预警",-1)])],544),[[e.vModelSelect,s.value]]),e.createElementVNode("span",{class:e.normalizeClass(["lw-plan-status",p.value])},e.toDisplayString(E.value),3),e.createElementVNode("button",{class:"lw-btn-primary lw-btn-sm",disabled:o.execution.status==="running",onClick:t[1]||(t[1]=l=>n.$emit("start-plan"))},e.toDisplayString(o.execution.status==="running"?"预案进行中":"启动预案"),9,b),e.createElementVNode("button",{class:"lw-btn-primary lw-btn-sm lw-btn-warn",onClick:t[2]||(t[2]=l=>n.$emit("report-warning"))},"报告预警情况")]),e.createElementVNode("div",y,[e.createElementVNode("table",null,[t[6]||(t[6]=e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("th",null,"#"),e.createElementVNode("th",null,"步骤"),e.createElementVNode("th",null,"责任人"),e.createElementVNode("th",null,"时限"),e.createElementVNode("th",null,"状态")])],-1)),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,l=>(e.openBlock(),e.createElementBlock("tr",{key:l.stepId},[e.createElementVNode("td",k,e.toDisplayString(l.stepNo),1),e.createElementVNode("td",null,e.toDisplayString(l.stepName),1),e.createElementVNode("td",null,e.toDisplayString(l.responsibleName),1),e.createElementVNode("td",null,e.toDisplayString(l.timeLimitDisplay),1),e.createElementVNode("td",null,[e.createElementVNode("span",{class:e.normalizeClass(["lw-step-status","lw-step-"+l.status]),onClick:P=>v(l)},e.toDisplayString(l.statusText),11,x)])]))),128)),c.value.length===0?(e.openBlock(),e.createElementBlock("tr",S,[...t[5]||(t[5]=[e.createElementVNode("td",{colspan:"5",class:"lw-no-data"},"该等级暂无预案",-1)])])):e.createCommentVNode("",!0)])])])]))}}),f=V._export_sfc(C,[["__scopeId","data-v-2e51d84b"]]);exports.EmergencyPlanPanel=f;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent as k, ref as P, computed as i, watch as S, openBlock as u, createElementBlock as r, createElementVNode as t, withDirectives as L, vModelSelect as h, normalizeClass as g, toDisplayString as a, Fragment as E, renderList as N, createCommentVNode as $ } from "vue";
|
|
2
|
-
import { _ as D } from "./index-
|
|
2
|
+
import { _ as D } from "./index-DUL649KZ.js";
|
|
3
3
|
const I = { class: "lw-panel-section lw-plan-section" }, V = { class: "lw-plan-toolbar" }, _ = ["disabled"], B = { class: "lw-plan-table" }, T = { class: "lw-step-no" }, z = ["onClick"], F = { key: 0 }, M = /* @__PURE__ */ k({
|
|
4
4
|
__name: "EmergencyPlanPanel",
|
|
5
5
|
props: {
|
|
@@ -20,7 +20,7 @@ var B = (l, v) => {
|
|
|
20
20
|
return d;
|
|
21
21
|
};
|
|
22
22
|
import { defineComponent as F, openBlock as c, createElementBlock as h, createElementVNode as e, Fragment as S, renderList as E, normalizeClass as U, normalizeStyle as Z, toDisplayString as r, createCommentVNode as L, ref as R, watch as ie, computed as I, createBlock as K, Teleport as Q, withModifiers as P, withDirectives as D, vModelCheckbox as de, vModelText as W } from "vue";
|
|
23
|
-
import { _ as H } from "./index-
|
|
23
|
+
import { _ as H } from "./index-DUL649KZ.js";
|
|
24
24
|
const ce = { class: "lw-panel-section" }, re = { class: "lw-panel-header" }, pe = { class: "lw-panel-actions" }, ue = { class: "lw-warning-table" }, ve = ["onClick"], me = { key: 0 }, he = /* @__PURE__ */ F({
|
|
25
25
|
__name: "WarningOverviewPanel",
|
|
26
26
|
props: {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var A=Object.defineProperty,z=Object.defineProperties;var W=Object.getOwnPropertyDescriptors;var C=Object.getOwnPropertySymbols;var j=Object.prototype.hasOwnProperty,R=Object.prototype.propertyIsEnumerable;var O=(o,p,c)=>p in o?A(o,p,{enumerable:!0,configurable:!0,writable:!0,value:c}):o[p]=c,B=(o,p)=>{for(var c in p||(p={}))j.call(p,c)&&O(o,c,p[c]);if(C)for(var c of C(p))R.call(p,c)&&O(o,c,p[c]);return o},w=(o,p)=>z(o,W(p));var L=(o,p)=>{var c={};for(var m in o)j.call(o,m)&&p.indexOf(m)<0&&(c[m]=o[m]);if(o!=null&&C)for(var m of C(o))p.indexOf(m)<0&&R.call(o,m)&&(c[m]=o[m]);return c};const e=require("vue"),D=require("./index-Bo49zvKb.cjs"),q={class:"lw-panel-section"},H={class:"lw-panel-header"},J={class:"lw-panel-actions"},G={class:"lw-warning-table"},Y=["onClick"],Z={key:0},K=e.defineComponent({__name:"WarningOverviewPanel",props:{warnings:{},currentWarning:{},levelColors:{}},emits:["select-warning","manage-plans","history-plans"],setup(o){const p=o,c={1:"#e74c3c",2:"#ff6600",3:"#f39c12",4:"#3498db"};function m(u){var d;return((d=p.levelColors)==null?void 0:d[u])||c[u]||"#999"}function k(u){if(!u)return"--";const d=u.match(/(\d{2}:\d{2}:\d{2})$/);return d?d[1]:u}return(u,d)=>(e.openBlock(),e.createElementBlock("div",q,[e.createElementVNode("div",H,[d[2]||(d[2]=e.createElementVNode("span",{class:"lw-panel-title"},"预警数据概览",-1)),e.createElementVNode("div",J,[e.createElementVNode("button",{class:"lw-btn-outline",onClick:d[0]||(d[0]=a=>u.$emit("manage-plans"))},"应急预案库管理"),e.createElementVNode("button",{class:"lw-btn-outline",onClick:d[1]||(d[1]=a=>u.$emit("history-plans"))},"历史应急预案")])]),e.createElementVNode("div",G,[e.createElementVNode("table",null,[d[4]||(d[4]=e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("th",null,"预警等级"),e.createElementVNode("th",null,"预警区域"),e.createElementVNode("th",null,"触发时间"),e.createElementVNode("th",null,"最近人员和设备编号"),e.createElementVNode("th",null,"与预警区距离")])],-1)),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.warnings,a=>{var g,_;return e.openBlock(),e.createElementBlock("tr",{key:a.warningId,class:e.normalizeClass({"lw-row-active":((g=o.currentWarning)==null?void 0:g.warningId)===a.warningId}),onClick:y=>u.$emit("select-warning",a)},[e.createElementVNode("td",null,[e.createElementVNode("span",{class:"lw-level-badge",style:e.normalizeStyle({color:m(a.warningLevel)})},e.toDisplayString(a.warningLevelName),5)]),e.createElementVNode("td",null,e.toDisplayString(a.regionName),1),e.createElementVNode("td",null,e.toDisplayString(k(a.triggerTime)),1),e.createElementVNode("td",null,e.toDisplayString(((_=a.nearestObject)==null?void 0:_.objectName)||"--"),1),e.createElementVNode("td",null,e.toDisplayString(a.nearestObject?`${a.nearestObject.distance} ${a.nearestObject.unit}`:"--"),1)],10,Y)}),128)),o.warnings.length===0?(e.openBlock(),e.createElementBlock("tr",Z,[...d[3]||(d[3]=[e.createElementVNode("td",{colspan:"5",class:"lw-no-data"},"暂无预警数据",-1)])])):e.createCommentVNode("",!0)])])])]))}}),Q=D._export_sfc(K,[["__scopeId","data-v-68afecd8"]]),X={class:"pld-body"},ee={class:"pld-tabs"},te=["onClick"],ne={class:"pld-level-tabs"},le=["onClick"],oe={class:"pld-step-list"},se=["onUpdate:modelValue"],ae={class:"pld-step-no"},ie=["onUpdate:modelValue"],ce=["onUpdate:modelValue"],de=["onUpdate:modelValue"],re={key:0,class:"pld-empty"},pe={class:"pld-actions"},me=["disabled"],ue={key:1,class:"pld-ai"},ve={class:"pld-ai-grid"},Ee={class:"pld-ai-card"},Ne={class:"pld-ai-card-value"},he={class:"pld-ai-card"},ge={class:"pld-ai-card-value"},Ve={class:"pld-ai-card"},be={class:"pld-ai-card-value"},_e={class:"pld-ai-card"},ke={class:"pld-ai-card-value"},ye={class:"pld-ai-info"},fe={class:"pld-ai-roster"},$e={class:"pld-footer"},Se={key:0,class:"pld-dirty-hint"},Ce=e.defineComponent({__name:"PlanLibraryDialog",props:{visible:{type:Boolean},plans:{},mobileObjects:{default:()=>[]},currentWarning:{default:null}},emits:["close","update:plans"],setup(o,{emit:p}){const c=o,m=p,k=[{label:"步骤配置",value:"steps"},{label:"智能预警预案",value:"ai"}],u=[{label:"Ⅰ级预警",value:1},{label:"Ⅱ级预警",value:2},{label:"Ⅲ级预警",value:3},{label:"Ⅳ级预警",value:4}],d=e.ref("steps"),a=e.ref(4),g=e.ref([]),_=e.ref("");e.watch(()=>c.visible,i=>{if(i){const t=JSON.stringify(c.plans);g.value=JSON.parse(t),_.value=t}},{immediate:!0});const y=e.computed(()=>{if(!c.visible)return!1;const i=g.value.map(t=>w(B({},t),{steps:t.steps.map(s=>{const h=s,{__checked:N}=h;return L(h,["__checked"])})}));return JSON.stringify(i)!==_.value});function $(i){const t=g.value.find(N=>N.warningLevel===i);if(t)return t;const s={planId:`PLAN_L${i}_NEW`,planName:"Ⅰ/Ⅱ/Ⅲ/Ⅳ 级预警预案".split("/")[i-1]+"预警预案",warningLevel:i,applicableRegionIds:[],status:"enabled",steps:[]};return g.value.push(s),s}const S=e.computed(()=>$(a.value).steps),n=e.computed(()=>S.value.some(i=>i.__checked));function l(){const i=$(a.value),t=String(i.steps.length+1).padStart(2,"0"),s={stepId:`STEP_L${a.value}_${Date.now()}`,stepNo:t,stepName:"",responsibleName:"",responsibleRole:"manual",timeLimitMinutes:0,timeLimitDisplay:"",status:"pending",statusText:"待启动"};i.steps.push(s)}function r(){const i=$(a.value);i.steps=i.steps.filter(t=>!t.__checked)}const v={1:"立即响应",2:"10 分钟内",3:"20 分钟内",4:"30 分钟内"},E={1:"预警区方圆 1000 米",2:"预警区方圆 600 米",3:"预警区方圆 400 米",4:"预警区方圆 300 米"},T={1:"值班调度员 4 人、现场安全员 6 人、机动疏导人员 12 人",2:"值班调度员 3 人、现场安全员 4 人、机动疏导人员 8 人",3:"值班调度员 2 人、现场安全员 3 人、机动疏导人员 6 人",4:"值班调度员 2 人、现场安全员 2 人、机动疏导人员 4 人"},f=e.computed(()=>{const i=a.value,t=["Ⅰ","Ⅱ","Ⅲ","Ⅳ"][i-1]||"Ⅳ",s=c.mobileObjects.filter(b=>b.status==="in_warning_area"||b.status==="near_warning_area"),N={};s.forEach(b=>{N[b.objectType]=(N[b.objectType]||0)+1});const V={excavator:"挖机",truck:"卡车",drone:"无人机",person:"人员"},h=Object.entries(N).filter(([b])=>b!=="person").map(([b,F])=>`${V[b]||b} ${F} 台`),P=h.length>0?h.join("、"):"无",M=h.length<=2?"低风险区间":h.length<=4?"中风险区间":"高风险区间",U=h.length>0?`当前预警区内共识别 ${h.join("、")},设备数量处于${M},系统自动匹配 ${t} 级预警。`:`当前预警区内未识别到设备,系统保持 ${t} 级预警基线响应。`;return{levelText:`${t}级预警`,responseTime:v[i]||"30 分钟内",responseRange:E[i]||"预警区方圆 300 米",equipmentText:P,matchReason:U,rosterText:T[i]||T[4]}});function I(){const i=g.value.map(t=>w(B({},t),{steps:t.steps.map(s=>{const h=s,{__checked:N}=h;return L(h,["__checked"])})}));m("update:plans",i),m("close")}function x(){y.value&&!window.confirm("有未保存的修改,确定要放弃吗?")||m("close")}return(i,t)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[o.visible?(e.openBlock(),e.createElementBlock("div",{key:0,class:"pld-mask",onClick:e.withModifiers(x,["self"])},[e.createElementVNode("div",{class:"pld-dialog",onClick:t[0]||(t[0]=e.withModifiers(()=>{},["stop"]))},[t[7]||(t[7]=e.createElementVNode("div",{class:"pld-header"},[e.createElementVNode("span",{class:"pld-title"},"应急预案库管理")],-1)),e.createElementVNode("div",X,[e.createElementVNode("div",ee,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(k,s=>e.createElementVNode("button",{key:s.value,class:e.normalizeClass(["pld-tab",{"is-active":d.value===s.value}]),onClick:N=>d.value=s.value},e.toDisplayString(s.label),11,te)),64))]),d.value==="steps"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",ne,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(u,s=>e.createElementVNode("button",{key:s.value,class:e.normalizeClass(["pld-level-tab",{"is-active":a.value===s.value}]),onClick:N=>a.value=s.value},e.toDisplayString(s.label),11,le)),64))]),e.createElementVNode("div",oe,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,(s,N)=>(e.openBlock(),e.createElementBlock("div",{key:s.stepId||N,class:"pld-step-row"},[e.withDirectives(e.createElementVNode("input",{type:"checkbox","onUpdate:modelValue":V=>s.__checked=V,class:"pld-check"},null,8,se),[[e.vModelCheckbox,s.__checked]]),e.createElementVNode("span",ae,e.toDisplayString(String(N+1).padStart(2,"0")),1),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":V=>s.stepName=V,class:"pld-input pld-step-name",placeholder:"步骤名称"},null,8,ie),[[e.vModelText,s.stepName]]),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":V=>s.responsibleName=V,class:"pld-input pld-step-resp",placeholder:"责任人"},null,8,ce),[[e.vModelText,s.responsibleName]]),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":V=>s.timeLimitDisplay=V,class:"pld-input pld-step-time",placeholder:"时限"},null,8,de),[[e.vModelText,s.timeLimitDisplay]])]))),128)),S.value.length===0?(e.openBlock(),e.createElementBlock("div",re,' 该等级暂无步骤,点击下方"添加步骤"新增 ')):e.createCommentVNode("",!0)]),e.createElementVNode("div",pe,[e.createElementVNode("button",{class:"pld-btn pld-btn-ghost",onClick:l},"+ 添加步骤"),e.createElementVNode("button",{class:"pld-btn pld-btn-danger",disabled:!n.value,onClick:r},"删除选中",8,me)])],64)):(e.openBlock(),e.createElementBlock("div",ue,[t[5]||(t[5]=e.createElementVNode("div",{class:"pld-ai-title"},"预案匹配",-1)),t[6]||(t[6]=e.createElementVNode("div",{class:"pld-ai-subtitle"},"自动匹配规则",-1)),e.createElementVNode("div",ve,[e.createElementVNode("div",Ee,[t[1]||(t[1]=e.createElementVNode("div",{class:"pld-ai-card-label"},"预警级别",-1)),e.createElementVNode("div",Ne,e.toDisplayString(f.value.levelText),1)]),e.createElementVNode("div",he,[t[2]||(t[2]=e.createElementVNode("div",{class:"pld-ai-card-label"},"响应时限",-1)),e.createElementVNode("div",ge,e.toDisplayString(f.value.responseTime),1)]),e.createElementVNode("div",Ve,[t[3]||(t[3]=e.createElementVNode("div",{class:"pld-ai-card-label"},"响应范围",-1)),e.createElementVNode("div",be,e.toDisplayString(f.value.responseRange),1)]),e.createElementVNode("div",_e,[t[4]||(t[4]=e.createElementVNode("div",{class:"pld-ai-card-label"},"预警区内设备",-1)),e.createElementVNode("div",ke,e.toDisplayString(f.value.equipmentText),1)])]),e.createElementVNode("div",ye,e.toDisplayString(f.value.matchReason),1),e.createElementVNode("div",fe,e.toDisplayString(f.value.rosterText),1)]))]),e.createElementVNode("div",$e,[y.value?(e.openBlock(),e.createElementBlock("span",Se,"· 有未保存的修改")):e.createCommentVNode("",!0),e.createElementVNode("button",{class:"pld-btn pld-btn-ghost",onClick:x},"取消"),e.createElementVNode("button",{class:"pld-btn pld-btn-primary",onClick:I},"保存")])])])):e.createCommentVNode("",!0)]))}}),Be=D._export_sfc(Ce,[["__scopeId","data-v-26110cae"]]),we={class:"hpd-header"},Le={class:"hpd-sub"},De={class:"hpd-body"},Te={class:"hpd-toolbar"},xe=["disabled"],Oe={class:"hpd-list"},je=["onClick"],Re={class:"hpd-name"},Ie={class:"hpd-count"},Pe=["onClick"],Me={class:"hpd-arrow"},Ue={key:0,class:"hpd-item-body"},Fe={class:"hpd-table"},Ae={key:0},ze={key:0,class:"hpd-empty-all"},We={class:"hpd-footer"},qe=e.defineComponent({__name:"HistoryPlanDialog",props:{visible:{type:Boolean},plans:{}},emits:["close"],setup(o){const p=o,c={1:"#e74c3c",2:"#ff6600",3:"#f39c12",4:"#3498db"},m=e.ref(null),k=e.computed(()=>[...p.plans].sort((n,l)=>n.warningLevel-l.warningLevel));function u(n){return["Ⅰ","Ⅱ","Ⅲ","Ⅳ"][n-1]||String(n)}function d(n){m.value=m.value===n?null:n}function a(n){const l=String(n!=null?n:"");return/[",\n]/.test(l)?`"${l.replace(/"/g,'""')}"`:l}function g(n){const l=[`预案名称,${a(n.planName)}`,`预警等级,${u(n.warningLevel)} 级`,`适用场景,${a((n.scenarioType||[]).join("/"))}`,""].join(`
|
|
1
|
+
"use strict";var A=Object.defineProperty,z=Object.defineProperties;var W=Object.getOwnPropertyDescriptors;var C=Object.getOwnPropertySymbols;var j=Object.prototype.hasOwnProperty,R=Object.prototype.propertyIsEnumerable;var O=(o,p,c)=>p in o?A(o,p,{enumerable:!0,configurable:!0,writable:!0,value:c}):o[p]=c,B=(o,p)=>{for(var c in p||(p={}))j.call(p,c)&&O(o,c,p[c]);if(C)for(var c of C(p))R.call(p,c)&&O(o,c,p[c]);return o},w=(o,p)=>z(o,W(p));var L=(o,p)=>{var c={};for(var m in o)j.call(o,m)&&p.indexOf(m)<0&&(c[m]=o[m]);if(o!=null&&C)for(var m of C(o))p.indexOf(m)<0&&R.call(o,m)&&(c[m]=o[m]);return c};const e=require("vue"),D=require("./index-Cm7hGuPj.cjs"),q={class:"lw-panel-section"},H={class:"lw-panel-header"},J={class:"lw-panel-actions"},G={class:"lw-warning-table"},Y=["onClick"],Z={key:0},K=e.defineComponent({__name:"WarningOverviewPanel",props:{warnings:{},currentWarning:{},levelColors:{}},emits:["select-warning","manage-plans","history-plans"],setup(o){const p=o,c={1:"#e74c3c",2:"#ff6600",3:"#f39c12",4:"#3498db"};function m(u){var d;return((d=p.levelColors)==null?void 0:d[u])||c[u]||"#999"}function k(u){if(!u)return"--";const d=u.match(/(\d{2}:\d{2}:\d{2})$/);return d?d[1]:u}return(u,d)=>(e.openBlock(),e.createElementBlock("div",q,[e.createElementVNode("div",H,[d[2]||(d[2]=e.createElementVNode("span",{class:"lw-panel-title"},"预警数据概览",-1)),e.createElementVNode("div",J,[e.createElementVNode("button",{class:"lw-btn-outline",onClick:d[0]||(d[0]=a=>u.$emit("manage-plans"))},"应急预案库管理"),e.createElementVNode("button",{class:"lw-btn-outline",onClick:d[1]||(d[1]=a=>u.$emit("history-plans"))},"历史应急预案")])]),e.createElementVNode("div",G,[e.createElementVNode("table",null,[d[4]||(d[4]=e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("th",null,"预警等级"),e.createElementVNode("th",null,"预警区域"),e.createElementVNode("th",null,"触发时间"),e.createElementVNode("th",null,"最近人员和设备编号"),e.createElementVNode("th",null,"与预警区距离")])],-1)),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.warnings,a=>{var g,_;return e.openBlock(),e.createElementBlock("tr",{key:a.warningId,class:e.normalizeClass({"lw-row-active":((g=o.currentWarning)==null?void 0:g.warningId)===a.warningId}),onClick:y=>u.$emit("select-warning",a)},[e.createElementVNode("td",null,[e.createElementVNode("span",{class:"lw-level-badge",style:e.normalizeStyle({color:m(a.warningLevel)})},e.toDisplayString(a.warningLevelName),5)]),e.createElementVNode("td",null,e.toDisplayString(a.regionName),1),e.createElementVNode("td",null,e.toDisplayString(k(a.triggerTime)),1),e.createElementVNode("td",null,e.toDisplayString(((_=a.nearestObject)==null?void 0:_.objectName)||"--"),1),e.createElementVNode("td",null,e.toDisplayString(a.nearestObject?`${a.nearestObject.distance} ${a.nearestObject.unit}`:"--"),1)],10,Y)}),128)),o.warnings.length===0?(e.openBlock(),e.createElementBlock("tr",Z,[...d[3]||(d[3]=[e.createElementVNode("td",{colspan:"5",class:"lw-no-data"},"暂无预警数据",-1)])])):e.createCommentVNode("",!0)])])])]))}}),Q=D._export_sfc(K,[["__scopeId","data-v-68afecd8"]]),X={class:"pld-body"},ee={class:"pld-tabs"},te=["onClick"],ne={class:"pld-level-tabs"},le=["onClick"],oe={class:"pld-step-list"},se=["onUpdate:modelValue"],ae={class:"pld-step-no"},ie=["onUpdate:modelValue"],ce=["onUpdate:modelValue"],de=["onUpdate:modelValue"],re={key:0,class:"pld-empty"},pe={class:"pld-actions"},me=["disabled"],ue={key:1,class:"pld-ai"},ve={class:"pld-ai-grid"},Ee={class:"pld-ai-card"},Ne={class:"pld-ai-card-value"},he={class:"pld-ai-card"},ge={class:"pld-ai-card-value"},Ve={class:"pld-ai-card"},be={class:"pld-ai-card-value"},_e={class:"pld-ai-card"},ke={class:"pld-ai-card-value"},ye={class:"pld-ai-info"},fe={class:"pld-ai-roster"},$e={class:"pld-footer"},Se={key:0,class:"pld-dirty-hint"},Ce=e.defineComponent({__name:"PlanLibraryDialog",props:{visible:{type:Boolean},plans:{},mobileObjects:{default:()=>[]},currentWarning:{default:null}},emits:["close","update:plans"],setup(o,{emit:p}){const c=o,m=p,k=[{label:"步骤配置",value:"steps"},{label:"智能预警预案",value:"ai"}],u=[{label:"Ⅰ级预警",value:1},{label:"Ⅱ级预警",value:2},{label:"Ⅲ级预警",value:3},{label:"Ⅳ级预警",value:4}],d=e.ref("steps"),a=e.ref(4),g=e.ref([]),_=e.ref("");e.watch(()=>c.visible,i=>{if(i){const t=JSON.stringify(c.plans);g.value=JSON.parse(t),_.value=t}},{immediate:!0});const y=e.computed(()=>{if(!c.visible)return!1;const i=g.value.map(t=>w(B({},t),{steps:t.steps.map(s=>{const h=s,{__checked:N}=h;return L(h,["__checked"])})}));return JSON.stringify(i)!==_.value});function $(i){const t=g.value.find(N=>N.warningLevel===i);if(t)return t;const s={planId:`PLAN_L${i}_NEW`,planName:"Ⅰ/Ⅱ/Ⅲ/Ⅳ 级预警预案".split("/")[i-1]+"预警预案",warningLevel:i,applicableRegionIds:[],status:"enabled",steps:[]};return g.value.push(s),s}const S=e.computed(()=>$(a.value).steps),n=e.computed(()=>S.value.some(i=>i.__checked));function l(){const i=$(a.value),t=String(i.steps.length+1).padStart(2,"0"),s={stepId:`STEP_L${a.value}_${Date.now()}`,stepNo:t,stepName:"",responsibleName:"",responsibleRole:"manual",timeLimitMinutes:0,timeLimitDisplay:"",status:"pending",statusText:"待启动"};i.steps.push(s)}function r(){const i=$(a.value);i.steps=i.steps.filter(t=>!t.__checked)}const v={1:"立即响应",2:"10 分钟内",3:"20 分钟内",4:"30 分钟内"},E={1:"预警区方圆 1000 米",2:"预警区方圆 600 米",3:"预警区方圆 400 米",4:"预警区方圆 300 米"},T={1:"值班调度员 4 人、现场安全员 6 人、机动疏导人员 12 人",2:"值班调度员 3 人、现场安全员 4 人、机动疏导人员 8 人",3:"值班调度员 2 人、现场安全员 3 人、机动疏导人员 6 人",4:"值班调度员 2 人、现场安全员 2 人、机动疏导人员 4 人"},f=e.computed(()=>{const i=a.value,t=["Ⅰ","Ⅱ","Ⅲ","Ⅳ"][i-1]||"Ⅳ",s=c.mobileObjects.filter(b=>b.status==="in_warning_area"||b.status==="near_warning_area"),N={};s.forEach(b=>{N[b.objectType]=(N[b.objectType]||0)+1});const V={excavator:"挖机",truck:"卡车",drone:"无人机",person:"人员"},h=Object.entries(N).filter(([b])=>b!=="person").map(([b,F])=>`${V[b]||b} ${F} 台`),P=h.length>0?h.join("、"):"无",M=h.length<=2?"低风险区间":h.length<=4?"中风险区间":"高风险区间",U=h.length>0?`当前预警区内共识别 ${h.join("、")},设备数量处于${M},系统自动匹配 ${t} 级预警。`:`当前预警区内未识别到设备,系统保持 ${t} 级预警基线响应。`;return{levelText:`${t}级预警`,responseTime:v[i]||"30 分钟内",responseRange:E[i]||"预警区方圆 300 米",equipmentText:P,matchReason:U,rosterText:T[i]||T[4]}});function I(){const i=g.value.map(t=>w(B({},t),{steps:t.steps.map(s=>{const h=s,{__checked:N}=h;return L(h,["__checked"])})}));m("update:plans",i),m("close")}function x(){y.value&&!window.confirm("有未保存的修改,确定要放弃吗?")||m("close")}return(i,t)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[o.visible?(e.openBlock(),e.createElementBlock("div",{key:0,class:"pld-mask",onClick:e.withModifiers(x,["self"])},[e.createElementVNode("div",{class:"pld-dialog",onClick:t[0]||(t[0]=e.withModifiers(()=>{},["stop"]))},[t[7]||(t[7]=e.createElementVNode("div",{class:"pld-header"},[e.createElementVNode("span",{class:"pld-title"},"应急预案库管理")],-1)),e.createElementVNode("div",X,[e.createElementVNode("div",ee,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(k,s=>e.createElementVNode("button",{key:s.value,class:e.normalizeClass(["pld-tab",{"is-active":d.value===s.value}]),onClick:N=>d.value=s.value},e.toDisplayString(s.label),11,te)),64))]),d.value==="steps"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",ne,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(u,s=>e.createElementVNode("button",{key:s.value,class:e.normalizeClass(["pld-level-tab",{"is-active":a.value===s.value}]),onClick:N=>a.value=s.value},e.toDisplayString(s.label),11,le)),64))]),e.createElementVNode("div",oe,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,(s,N)=>(e.openBlock(),e.createElementBlock("div",{key:s.stepId||N,class:"pld-step-row"},[e.withDirectives(e.createElementVNode("input",{type:"checkbox","onUpdate:modelValue":V=>s.__checked=V,class:"pld-check"},null,8,se),[[e.vModelCheckbox,s.__checked]]),e.createElementVNode("span",ae,e.toDisplayString(String(N+1).padStart(2,"0")),1),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":V=>s.stepName=V,class:"pld-input pld-step-name",placeholder:"步骤名称"},null,8,ie),[[e.vModelText,s.stepName]]),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":V=>s.responsibleName=V,class:"pld-input pld-step-resp",placeholder:"责任人"},null,8,ce),[[e.vModelText,s.responsibleName]]),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":V=>s.timeLimitDisplay=V,class:"pld-input pld-step-time",placeholder:"时限"},null,8,de),[[e.vModelText,s.timeLimitDisplay]])]))),128)),S.value.length===0?(e.openBlock(),e.createElementBlock("div",re,' 该等级暂无步骤,点击下方"添加步骤"新增 ')):e.createCommentVNode("",!0)]),e.createElementVNode("div",pe,[e.createElementVNode("button",{class:"pld-btn pld-btn-ghost",onClick:l},"+ 添加步骤"),e.createElementVNode("button",{class:"pld-btn pld-btn-danger",disabled:!n.value,onClick:r},"删除选中",8,me)])],64)):(e.openBlock(),e.createElementBlock("div",ue,[t[5]||(t[5]=e.createElementVNode("div",{class:"pld-ai-title"},"预案匹配",-1)),t[6]||(t[6]=e.createElementVNode("div",{class:"pld-ai-subtitle"},"自动匹配规则",-1)),e.createElementVNode("div",ve,[e.createElementVNode("div",Ee,[t[1]||(t[1]=e.createElementVNode("div",{class:"pld-ai-card-label"},"预警级别",-1)),e.createElementVNode("div",Ne,e.toDisplayString(f.value.levelText),1)]),e.createElementVNode("div",he,[t[2]||(t[2]=e.createElementVNode("div",{class:"pld-ai-card-label"},"响应时限",-1)),e.createElementVNode("div",ge,e.toDisplayString(f.value.responseTime),1)]),e.createElementVNode("div",Ve,[t[3]||(t[3]=e.createElementVNode("div",{class:"pld-ai-card-label"},"响应范围",-1)),e.createElementVNode("div",be,e.toDisplayString(f.value.responseRange),1)]),e.createElementVNode("div",_e,[t[4]||(t[4]=e.createElementVNode("div",{class:"pld-ai-card-label"},"预警区内设备",-1)),e.createElementVNode("div",ke,e.toDisplayString(f.value.equipmentText),1)])]),e.createElementVNode("div",ye,e.toDisplayString(f.value.matchReason),1),e.createElementVNode("div",fe,e.toDisplayString(f.value.rosterText),1)]))]),e.createElementVNode("div",$e,[y.value?(e.openBlock(),e.createElementBlock("span",Se,"· 有未保存的修改")):e.createCommentVNode("",!0),e.createElementVNode("button",{class:"pld-btn pld-btn-ghost",onClick:x},"取消"),e.createElementVNode("button",{class:"pld-btn pld-btn-primary",onClick:I},"保存")])])])):e.createCommentVNode("",!0)]))}}),Be=D._export_sfc(Ce,[["__scopeId","data-v-26110cae"]]),we={class:"hpd-header"},Le={class:"hpd-sub"},De={class:"hpd-body"},Te={class:"hpd-toolbar"},xe=["disabled"],Oe={class:"hpd-list"},je=["onClick"],Re={class:"hpd-name"},Ie={class:"hpd-count"},Pe=["onClick"],Me={class:"hpd-arrow"},Ue={key:0,class:"hpd-item-body"},Fe={class:"hpd-table"},Ae={key:0},ze={key:0,class:"hpd-empty-all"},We={class:"hpd-footer"},qe=e.defineComponent({__name:"HistoryPlanDialog",props:{visible:{type:Boolean},plans:{}},emits:["close"],setup(o){const p=o,c={1:"#e74c3c",2:"#ff6600",3:"#f39c12",4:"#3498db"},m=e.ref(null),k=e.computed(()=>[...p.plans].sort((n,l)=>n.warningLevel-l.warningLevel));function u(n){return["Ⅰ","Ⅱ","Ⅲ","Ⅳ"][n-1]||String(n)}function d(n){m.value=m.value===n?null:n}function a(n){const l=String(n!=null?n:"");return/[",\n]/.test(l)?`"${l.replace(/"/g,'""')}"`:l}function g(n){const l=[`预案名称,${a(n.planName)}`,`预警等级,${u(n.warningLevel)} 级`,`适用场景,${a((n.scenarioType||[]).join("/"))}`,""].join(`
|
|
2
2
|
`),r=[["步骤编号","步骤名称","责任人","责任角色","时限"].join(","),...n.steps.map((v,E)=>[String(E+1).padStart(2,"0"),a(v.stepName),a(v.responsibleName),a(v.responsibleRole),a(v.timeLimit)].join(","))].join(`
|
|
3
3
|
`);return l+r}function _(n,l){const r=new Blob(["\uFEFF"+l],{type:"text/csv;charset=utf-8;"}),v=URL.createObjectURL(r),E=document.createElement("a");E.href=v,E.download=n,document.body.appendChild(E),E.click(),document.body.removeChild(E),URL.revokeObjectURL(v)}function y(){const n=new Date,l=r=>String(r).padStart(2,"0");return`${n.getFullYear()}${l(n.getMonth()+1)}${l(n.getDate())}_${l(n.getHours())}${l(n.getMinutes())}`}function $(n){const l=g(n);_(`应急预案_${u(n.warningLevel)}级_${n.planName}_${y()}.csv`,l)}function S(){const n=k.value.map(g).join(`
|
|
4
4
|
|
|
@@ -4,7 +4,7 @@ import "element-plus/es/components/loading/style/css";
|
|
|
4
4
|
import "element-plus/es/components/icon/style/css";
|
|
5
5
|
import { defineComponent as u, openBlock as i, createElementBlock as o, createElementVNode as e, createVNode as p, withCtx as f, unref as g, renderSlot as a, toDisplayString as x, createCommentVNode as v, withDirectives as h } from "vue";
|
|
6
6
|
import { ArrowLeft as b } from "@element-plus/icons-vue";
|
|
7
|
-
import { _ as k } from "./index-
|
|
7
|
+
import { _ as k } from "./index-DUL649KZ.js";
|
|
8
8
|
const y = { class: "mixiot-app-detail-page" }, D = { class: "mixiot-app-detail-page__header" }, $ = { class: "mixiot-app-detail-page__title-wrap" }, w = { class: "mixiot-app-detail-page__title" }, C = {
|
|
9
9
|
key: 0,
|
|
10
10
|
class: "mixiot-app-detail-page__extra"
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("element-plus/es");require("element-plus/es/components/base/style/css");require("element-plus/es/components/loading/style/css");require("element-plus/es/components/icon/style/css");const e=require("vue"),c=require("@element-plus/icons-vue"),d=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("element-plus/es");require("element-plus/es/components/base/style/css");require("element-plus/es/components/loading/style/css");require("element-plus/es/components/icon/style/css");const e=require("vue"),c=require("@element-plus/icons-vue"),d=require("./index-Cm7hGuPj.cjs"),p={class:"mixiot-app-detail-page"},_={class:"mixiot-app-detail-page__header"},u={class:"mixiot-app-detail-page__title-wrap"},m={class:"mixiot-app-detail-page__title"},g={key:0,class:"mixiot-app-detail-page__extra"},v={class:"mixiot-app-detail-page__body"},f=e.defineComponent({__name:"MixiotAppDetailPage",props:{title:{default:""},loading:{type:Boolean,default:!1}},emits:["back"],setup(o,{emit:l}){const n=l;return(t,i)=>{const r=a.ElIcon,s=a.ElLoadingDirective;return e.openBlock(),e.createElementBlock("div",p,[e.createElementVNode("header",_,[e.createElementVNode("button",{type:"button",class:"mixiot-app-detail-page__back","aria-label":"返回",onClick:i[0]||(i[0]=k=>n("back"))},[e.createVNode(r,null,{default:e.withCtx(()=>[e.createVNode(e.unref(c.ArrowLeft))]),_:1})]),e.createElementVNode("div",u,[e.renderSlot(t.$slots,"title",{},()=>[e.createElementVNode("span",m,e.toDisplayString(o.title),1)],!0)]),t.$slots.extra?(e.openBlock(),e.createElementBlock("div",g,[e.renderSlot(t.$slots,"extra",{},void 0,!0)])):e.createCommentVNode("",!0)]),e.withDirectives((e.openBlock(),e.createElementBlock("div",v,[e.renderSlot(t.$slots,"default",{},void 0,!0)])),[[s,o.loading]])])}}}),x=d._export_sfc(f,[["__scopeId","data-v-c7691748"]]);exports.default=x;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var Be=Object.defineProperty;var _e=Object.getOwnPropertySymbols;var Ve=Object.prototype.hasOwnProperty,Re=Object.prototype.propertyIsEnumerable;var ve=Math.pow,Se=(s,t,e)=>t in s?Be(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e,ke=(s,t)=>{for(var e in t||(t={}))Ve.call(t,e)&&Se(s,e,t[e]);if(_e)for(var e of _e(t))Re.call(t,e)&&Se(s,e,t[e]);return s};var ge=(s,t,e)=>new Promise((o,r)=>{var i=m=>{try{c(e.next(m))}catch(p){r(p)}},a=m=>{try{c(e.throw(m))}catch(p){r(p)}},c=m=>m.done?o(m.value):Promise.resolve(m.value).then(i,a);c((e=e.apply(s,t)).next())});const n=require("vue"),Ee=require("./index-Bo49zvKb.cjs"),H=require("./leaflet-src-WG2ob5HA.cjs");;/* empty css */const u=require("./three.module-CjayKmiG.cjs"),De=require("./OrbitControls-uuLGjaqy.cjs"),Ne=require("./CSS2DRenderer-nQ2DN9Uc.cjs"),Me=require("./ExtensionUtilities-ClTuwtC-.cjs"),Pe={class:"lw-filter-bar"},Fe=["value"],Ie={key:0,value:"",disabled:""},Ue=["value"],Oe=["value"],$e={class:"lw-time-btns"},Ge=["onClick"],We={class:"lw-date-range"},He=n.defineComponent({__name:"FilterBar",props:{filters:{},regions:{},lines:{},deviceNames:{}},emits:["update:filters","query","start-section"],setup(s,{emit:t}){const e=s,o=t,r=[{label:"一天内",value:"day"},{label:"一周内",value:"week"},{label:"一个月内",value:"month"}],i=n.reactive(ke({},e.filters)),a=n.computed(()=>{if(!i.regionId)return e.lines;const M=e.regions.find(y=>y.regionName===i.regionId);return M?e.lines.filter(y=>y.regionId===M.regionId):e.lines}),c=n.computed(()=>e.deviceNames);function m(){i.lineId&&!a.value.some(M=>M.lineName===i.lineId)&&(i.lineId=""),f()}function p(){f()}function x(M){i.quickRange=M,f()}function f(){o("update:filters",ke({},i))}return(M,y)=>(n.openBlock(),n.createElementBlock("div",Pe,[n.withDirectives(n.createElementVNode("select",{"onUpdate:modelValue":y[0]||(y[0]=w=>i.regionId=w),class:"lw-select",onChange:m},[y[6]||(y[6]=n.createElementVNode("option",{value:""},"全部区域",-1)),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.regions,w=>(n.openBlock(),n.createElementBlock("option",{key:w.regionId,value:w.regionName},n.toDisplayString(w.regionName),9,Fe))),128))],544),[[n.vModelSelect,i.regionId]]),n.withDirectives(n.createElementVNode("select",{"onUpdate:modelValue":y[1]||(y[1]=w=>i.lineId=w),class:"lw-select",onChange:p},[y[7]||(y[7]=n.createElementVNode("option",{value:""},"全部监测线",-1)),a.value.length===0?(n.openBlock(),n.createElementBlock("option",Ie,"(该区域暂无监测线)")):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.value,w=>(n.openBlock(),n.createElementBlock("option",{key:w.lineId,value:w.lineName},n.toDisplayString(w.lineName),9,Ue))),128))],544),[[n.vModelSelect,i.lineId]]),n.withDirectives(n.createElementVNode("select",{"onUpdate:modelValue":y[2]||(y[2]=w=>i.deviceId=w),class:"lw-select",onChange:f},[y[8]||(y[8]=n.createElementVNode("option",{value:""},"全部监测点",-1)),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(c.value,w=>(n.openBlock(),n.createElementBlock("option",{key:w,value:w},n.toDisplayString(w),9,Oe))),128))],544),[[n.vModelSelect,i.deviceId]]),n.createElementVNode("div",$e,[(n.openBlock(),n.createElementBlock(n.Fragment,null,n.renderList(r,w=>n.createElementVNode("button",{key:w.value,class:n.normalizeClass(["lw-time-btn",{active:i.quickRange===w.value}]),onClick:T=>x(w.value)},n.toDisplayString(w.label),11,Ge)),64))]),n.createElementVNode("div",We,[n.withDirectives(n.createElementVNode("input",{type:"datetime-local","onUpdate:modelValue":y[3]||(y[3]=w=>i.startTime=w),class:"lw-date-input",onChange:f},null,544),[[n.vModelText,i.startTime]]),y[9]||(y[9]=n.createElementVNode("span",{class:"lw-date-sep"},"至",-1)),n.withDirectives(n.createElementVNode("input",{type:"datetime-local","onUpdate:modelValue":y[4]||(y[4]=w=>i.endTime=w),class:"lw-date-input",onChange:f},null,544),[[n.vModelText,i.endTime]])]),y[10]||(y[10]=n.createElementVNode("div",{class:"lw-spacer"},null,-1)),n.createElementVNode("button",{class:"lw-btn-section",onClick:y[5]||(y[5]=w=>o("start-section"))},"剖面图绘制")]))}}),qe=Ee._export_sfc(He,[["__scopeId","data-v-151e0d5e"]]);function Le(s,t){if(t==="cf"){const o=s.cf;return o<50?[0/255,170/255,255/255]:o<150?[255/255,230/255,0/255]:o<300?[255/255,145/255,0/255]:o<500?[240/255,70/255,40/255]:[180/255,0/255,0/255]}if(t==="av"){const o=s.av;return o<-.6?[0/255,80/255,220/255]:o<-.1?[0/255,170/255,255/255]:Math.abs(o)<.1?[0/255,220/255,120/255]:o<.6?[255/255,185/255,0/255]:[220/255,30/255,30/255]}const e=Math.abs(s.rr);return s.rr<0?e<5?[0/255,180/255,255/255]:e<20?[0/255,120/255,255/255]:e<60?[40/255,70/255,220/255]:[20/255,35/255,150/255]:e<5?[255/255,230/255,0/255]:e<20?[255/255,165/255,0/255]:e<60?[235/255,85/255,0/255]:[180/255,0/255,0/255]}u.Mesh.prototype.raycast=Me.acceleratedRaycast;class je{constructor(t){this.container=t,this.raycaster=new u.Raycaster,this.animFrameId=0,this.needsUpdate=!0,this.nodeEntries=new Map,this.resizeObserver=null,this.deviceMarkers=new Map,this.radarLayers=new Map,this.animate=()=>{if(this.animFrameId=requestAnimationFrame(this.animate),this.controls.update(),!this.needsUpdate)return;const o=this.camera.position.clone().sub(this.controls.target);this.dynamicLight.position.copy(o),this.renderer.render(this.scene,this.camera),this.labelRenderer.render(this.scene,this.camera),this.needsUpdate=!1},u.Object3D.DEFAULT_UP.set(0,0,1),this.scene=new u.Scene,this.camera=new u.PerspectiveCamera(50,t.clientWidth/Math.max(t.clientHeight,1),.1,1e5),this.camera.position.set(500,-500,500),this.camera.up.set(0,0,1),this.renderer=new u.WebGLRenderer({antialias:!0,alpha:!0}),this.renderer.setPixelRatio(window.devicePixelRatio),this.renderer.setSize(t.clientWidth,t.clientHeight),t.appendChild(this.renderer.domElement),this.labelRenderer=new Ne.CSS2DRenderer,this.labelRenderer.setSize(t.clientWidth,t.clientHeight),this.labelRenderer.domElement.style.position="absolute",this.labelRenderer.domElement.style.top="0",this.labelRenderer.domElement.style.left="0",this.labelRenderer.domElement.style.pointerEvents="none",this.labelRenderer.domElement.style.overflow="visible",t.appendChild(this.labelRenderer.domElement),this.controls=new De.OrbitControls(this.camera,this.renderer.domElement),this.controls.enableDamping=!1,this.controls.mouseButtons={LEFT:u.MOUSE.ROTATE,MIDDLE:u.MOUSE.PAN,RIGHT:u.MOUSE.PAN},this.controls.addEventListener("change",()=>{this.updateCameraNearFar(),this.needsUpdate=!0});const e=new u.AmbientLight(8947848,4);this.dynamicLight=new u.DirectionalLight(16777215,2),this.scene.add(e,this.dynamicLight),this.scene.add(new u.AxesHelper(250)),this.resizeObserver=new ResizeObserver(()=>this.resize()),this.resizeObserver.observe(t),this.animate()}loadDocument(t,e){return ge(this,null,function*(){this.clearModel();const o=this.flattenNodes(t.rootNode),r=o.filter(a=>a.mesh&&a.mesh.positions.length>0);e==null||e(`构建场景树 (${o.length} 节点)...`),this.buildGroupTree(t.rootNode,this.scene);let i=0;for(const a of r)this.createMeshForNode(a),i++,i%5===0&&(e==null||e(`创建网格 ${i}/${r.length}...`),yield new Promise(c=>setTimeout(c,0)));this.fitContent(),this.needsUpdate=!0})}flattenNodes(t){const e=[t];for(const o of t.children)e.push(...this.flattenNodes(o));return e}buildGroupTree(t,e){const o=new u.Group;o.name=t.name,o.visible=t.visible,e.add(o);const r={node:t,group:o};this.nodeEntries.set(t.id,r);for(const i of t.children)this.buildGroupTree(i,o)}createMeshForNode(t){var c,m;const e=this.nodeEntries.get(t.id);if(!e||!t.mesh)return;const{positions:o,indices:r,edgePositions:i}=t.mesh;if(o.length>0&&r.length>0){const p=new u.BufferGeometry;p.setAttribute("position",new u.BufferAttribute(o,3)),p.setIndex(new u.BufferAttribute(r,1)),p.computeVertexNormals(),p.computeBoundingBox(),p.boundsTree=new Me.MeshBVH(p);const x=new u.MeshLambertMaterial({color:new u.Color(t.color),side:u.DoubleSide,flatShading:!0}),f=new u.Mesh(p,x);f.name=t.name+"_mesh",e.group.add(f),e.meshObj=f}const a=(m=(c=t.raw)==null?void 0:c.displayMode)!=null?m:0;if(i.length>0&&a>0){const p=new u.BufferGeometry;p.setAttribute("position",new u.BufferAttribute(i,3)),p.computeBoundingBox();const x=new u.LineBasicMaterial({color:0,linewidth:1}),f=new u.LineSegments(p,x);f.name=t.name+"_edges",e.group.add(f),e.edgeObj=f}}setNodeVisible(t,e){const o=this.nodeEntries.get(t);o&&(this.setNodeVisibleRecursive(o.node,e),this.needsUpdate=!0)}setNodeVisibleRecursive(t,e){t.visible=e;const o=this.nodeEntries.get(t.id);o&&(o.group.visible=e);for(const r of t.children)this.setNodeVisibleRecursive(r,e)}fitContent(){try{this.scene.updateMatrixWorld(!0);const t=new u.Box3;if(this.scene.traverse(i=>{if(!(i instanceof u.AxesHelper)&&(i instanceof u.Mesh||i instanceof u.LineSegments)){const a=i.geometry;if(a&&a.attributes.position&&(a.computeBoundingBox(),a.boundingBox&&!a.boundingBox.isEmpty())){const c=a.boundingBox.clone();c.applyMatrix4(i.matrixWorld),t.union(c)}}}),t.isEmpty())return;const e=t.getCenter(new u.Vector3),o=t.getSize(new u.Vector3);console.log("[SceneManager] 模型包围盒 min:",t.min.toArray(),"max:",t.max.toArray(),"center:",e.toArray(),"size:",o.toArray());const r=Math.max(o.x,o.y,o.z);this.controls.target.copy(e),this.camera.position.set(e.x+r*.8,e.y-r*.8,e.z+r*.6),this.updateCameraNearFar(),this.controls.update(),this.needsUpdate=!0}catch(t){console.warn("[fitContent] error:",t)}}getVisibleMeshEntries(){const t=[];return this.nodeEntries.forEach(e=>{e.meshObj&&e.group.visible&&e.node.mesh&&t.push(e)}),t}addSectionLines(t,e){const o=new u.BufferGeometry;o.setAttribute("position",new u.BufferAttribute(t,3));const r=new u.LineBasicMaterial({color:e,linewidth:2,depthTest:!1}),i=new u.LineSegments(o,r);return i.renderOrder=999,i.name="__section_result__",this.scene.add(i),this.needsUpdate=!0,i}addSectionPath(t,e=16776960){const o=[];for(let c=0;c<t.length-1;c++)o.push(t[c].x,t[c].y,t[c].z),o.push(t[c+1].x,t[c+1].y,t[c+1].z);const r=new u.BufferGeometry;r.setAttribute("position",new u.BufferAttribute(new Float32Array(o),3));const i=new u.LineBasicMaterial({color:e,linewidth:3,depthTest:!1}),a=new u.LineSegments(r,i);return a.renderOrder=1e3,a.name="__section_path__",this.scene.add(a),this.needsUpdate=!0,a}clearSectionResults(){const t=[];this.scene.traverse(e=>{(e.name==="__section_result__"||e.name==="__section_path__")&&t.push(e)}),t.forEach(e=>{e.removeFromParent(),e.geometry&&e.geometry.dispose(),e.material&&e.material.dispose()}),this.needsUpdate=!0}setTransparency(t){this.nodeEntries.forEach(e=>{if(e.meshObj){const o=e.meshObj.material;o.transparent=t,o.opacity=t?.4:1,o.depthWrite=!t,o.needsUpdate=!0}}),this.needsUpdate=!0}pickPoint(t){const e=this.renderer.domElement.getBoundingClientRect(),o=new u.Vector2((t.clientX-e.left)/e.width*2-1,-((t.clientY-e.top)/e.height)*2+1);this.raycaster.setFromCamera(o,this.camera);const r=[];this.scene.traverse(a=>{a instanceof u.Mesh&&a.name.endsWith("_mesh")&&a.visible&&r.push(a)});const i=this.raycaster.intersectObjects(r,!1);return i.length>0?i[0].point.clone():null}addPickMarker(t,e=16711680){const o=new u.SphereGeometry(1,16,16),r=new u.MeshBasicMaterial({color:e,depthTest:!1}),i=new u.Mesh(o,r);i.position.copy(t),i.renderOrder=998,i.name="__pick_marker__";const a=this.camera.position.distanceTo(this.controls.target);return i.scale.setScalar(a*.008),this.scene.add(i),this.needsUpdate=!0,i}addPickLine(t,e){const o=new u.BufferGeometry;o.setAttribute("position",new u.BufferAttribute(new Float32Array([t.x,t.y,t.z,e.x,e.y,e.z]),3));const r=new u.LineBasicMaterial({color:16776960,linewidth:2,depthTest:!1}),i=new u.LineSegments(o,r);return i.renderOrder=998,i.name="__pick_line__",this.scene.add(i),this.needsUpdate=!0,i}clearPickMarkers(){const t=[];this.scene.traverse(e=>{(e.name==="__pick_marker__"||e.name==="__pick_line__")&&t.push(e)}),t.forEach(e=>{e.removeFromParent(),e.geometry&&e.geometry.dispose(),e.material&&e.material.dispose()}),this.needsUpdate=!0}addRadarLayer(t,e,o){if(this.removeRadarLayer(t),e.length===0)return;const r=new Float32Array(e.length*3),i=new Float32Array(e.length*3);for(let p=0;p<e.length;p++){const x=e[p],f=p*3;r[f]=x.e,r[f+1]=x.n,r[f+2]=x.rl;const M=Le(x,o);i[f]=M[0],i[f+1]=M[1],i[f+2]=M[2]}const a=new u.BufferGeometry;a.setAttribute("position",new u.BufferAttribute(r,3)),a.setAttribute("color",new u.BufferAttribute(i,3)),a.computeBoundingSphere();const c=new u.PointsMaterial({size:5,sizeAttenuation:!1,vertexColors:!0,depthWrite:!1,depthTest:!1,toneMapped:!1}),m=new u.Points(a,c);m.renderOrder=900,m.name=`__radar_layer_${t}__`,this.scene.add(m),this.radarLayers.set(t,{cloud:m,pointIndex:e}),this.needsUpdate=!0}setRadarLayerVisible(t,e){const o=this.radarLayers.get(t);o&&(o.cloud.visible=e,this.needsUpdate=!0)}updateRadarLayerColors(t,e,o){const r=this.radarLayers.get(t);if(!r)return;const i=r.cloud.geometry.getAttribute("color"),a=i.array;for(let c=0;c<e.length;c++){const m=Le(e[c],o),p=c*3;a[p]=m[0],a[p+1]=m[1],a[p+2]=m[2]}i.needsUpdate=!0,this.needsUpdate=!0}pickRadarPoint(t){const e=this.renderer.domElement.getBoundingClientRect(),o=new u.Vector2((t.clientX-e.left)/e.width*2-1,-((t.clientY-e.top)/e.height)*2+1),r=new u.Vector3;let i=.002,a=null;for(const[c,m]of this.radarLayers){if(!m.cloud.visible)continue;const x=m.cloud.geometry.getAttribute("position").array;for(let f=0;f<x.length;f+=3){if(r.set(x[f],x[f+1],x[f+2]).project(this.camera),r.z<-1||r.z>1)continue;const M=r.x-o.x,y=r.y-o.y,w=M*M+y*y;w<i&&(i=w,a={layerId:c,point:m.pointIndex[f/3]})}}return a}removeRadarLayer(t){const e=this.radarLayers.get(t);e&&(this.scene.remove(e.cloud),e.cloud.geometry.dispose(),e.cloud.material.dispose(),this.radarLayers.delete(t),this.needsUpdate=!0)}clearAllRadarLayers(){for(const[t]of this.radarLayers)this.removeRadarLayer(t)}addDeviceMarker(t,e,o){this.removeDeviceMarker(t);const r=new Ne.CSS2DObject(o);return r.position.set(e.e,e.n,e.rl),r.name=`__device_marker_${t}__`,this.scene.add(r),this.deviceMarkers.set(t,r),this.needsUpdate=!0,r}updateDeviceMarkerPosition(t,e){const o=this.deviceMarkers.get(t);o&&(o.position.set(e.e,e.n,e.rl),this.needsUpdate=!0)}removeDeviceMarker(t){const e=this.deviceMarkers.get(t);e&&(this.scene.remove(e),this.deviceMarkers.delete(t),this.needsUpdate=!0)}removeAllDeviceMarkers(){for(const[t]of this.deviceMarkers)this.removeDeviceMarker(t)}setDeviceMarkerVisible(t,e){const o=this.deviceMarkers.get(t);o&&(o.visible=e,this.needsUpdate=!0)}setDeviceMarkersVisible(t){for(const[,e]of this.deviceMarkers)e.visible=t;this.needsUpdate=!0}clearModel(){const t=[];this.scene.children.forEach(e=>{e instanceof u.Group&&t.push(e)}),t.forEach(e=>{e.traverse(o=>{if(o.geometry&&o.geometry.dispose(),o.material){const r=o.material;Array.isArray(r)?r.forEach(i=>i.dispose()):r.dispose()}}),e.removeFromParent()}),this.nodeEntries.clear(),this.clearSectionResults()}resize(){const t=this.container.clientWidth,e=this.container.clientHeight;e<1||(this.camera.aspect=t/e,this.camera.updateProjectionMatrix(),this.renderer.setSize(t,e),this.labelRenderer.setSize(t,e),this.needsUpdate=!0)}updateCameraNearFar(){const t=this.camera.position.distanceTo(this.controls.target);t<1?(this.camera.near=.001,this.camera.far=100):t<10?(this.camera.near=.01,this.camera.far=1e3):t<100?(this.camera.near=.1,this.camera.far=1e4):t<1e3?(this.camera.near=1,this.camera.far=1e5):t<1e4?(this.camera.near=10,this.camera.far=1e6):t<1e5?(this.camera.near=100,this.camera.far=1e7):(this.camera.near=1e3,this.camera.far=1e8),this.camera.updateProjectionMatrix()}requestUpdate(){this.needsUpdate=!0}dispose(){var t;cancelAnimationFrame(this.animFrameId),(t=this.resizeObserver)==null||t.disconnect(),this.clearModel(),this.clearAllRadarLayers(),this.removeAllDeviceMarkers(),this.controls.dispose(),this.renderer.dispose(),this.renderer.domElement.remove(),this.labelRenderer.domElement.remove()}}function Ye(s){const e=JSON.parse(s).properties,o=Xe(e.materials||[]),r=new Map;o.forEach(c=>r.set(c.id,c));const i=e.nodes,a=Ze(i,r);return{name:e.name||"Untitled",id:e.id||"",version:e.version||"",materials:o,rootNode:a}}function Xe(s){return s.map(t=>{var e,o,r;return{id:((e=t.properties)==null?void 0:e.id)||"",name:((o=t.properties)==null?void 0:o.name)||"",color:typeof((r=t.properties)==null?void 0:r.color)=="number"?t.properties.color:8947848}})}function Ze(s,t){var r;if(!s||s.length===0)return Ae("root");const e=new Map,o=[];for(const i of s){const a=Je(i,t);e.set(a.id,a),o.push({node:a,parentId:i.parentId})}for(const{node:i,parentId:a}of o)a&&e.has(a)&&e.get(a).children.push(i);return((r=o[0])==null?void 0:r.node)||Ae("root")}function Ae(s){return{id:"empty",name:s,classKey:"EmptyNode",visible:!0,color:8947848,children:[],raw:{}}}function Je(s,t){const e=s.properties||{},o=s.classKey||"";let r=8947848,i;if(e.materialId){i=e.materialId;const m=t.get(i);m&&(r=m.color)}else typeof e.color=="number"&&(r=e.color);const a={id:e.id||Math.random().toString(36).slice(2),name:e.name||o,classKey:o,visible:e.visible!==void 0?!!e.visible:!0,color:r,materialId:i,children:[],raw:e},c=Qe(o,e);return c&&(a.mesh=c),a}function Qe(s,t){if(s==="TriMeshNode"&&t.savedData)return Ke(t.savedData);if(s==="ShapeNode"||s==="MultiShapeNode")return et(t);if((s==="GeoPlineNode"||s==="PlineNode")&&t.points)return tt(t)}function Ke(s){try{const t=typeof s=="string"?JSON.parse(s):s;if(!t.pos||!t.idx)return;const e=new Float32Array(t.pos),o=new Uint32Array(t.idx),r=t.uv?new Float32Array(t.uv):new Float32Array(0),i=t.edgePos?new Float32Array(t.edgePos):new Float32Array(0),a=Ce(e,o);return{positions:e,indices:o,normals:a,uvs:r,edgePositions:i}}catch(t){return}}function et(s){const t=s.shape;if(!t)return;const e=t.properties||t,o=e.mesh||e._mesh;if(!o)return;const r=o.properties||o,i=r.faces||r._faces;if(!i)return;const a=i.properties||i;if(!a.position)return;const c=ye(a.position),m=nt(a.index),p=a.normal?ye(a.normal):Ce(c,m),x=a.uv?ye(a.uv):new Float32Array(0),f=r.edges||r._lines,M=(f==null?void 0:f.properties)||f,y=M!=null&&M.position?ye(M.position):new Float32Array(0);if(c.length!==0)return{positions:c,indices:m,normals:p,uvs:x,edgePositions:y}}function tt(s){const t=s.points;if(!t||!Array.isArray(t))return;const e=t.map(r=>r.properties?{x:r.properties.x||0,y:r.properties.y||0,z:r.properties.z||0}:{x:r.x||0,y:r.y||0,z:r.z||0});if(e.length<2)return;const o=[];for(let r=0;r<e.length-1;r++)o.push(e[r].x,e[r].y,e[r].z),o.push(e[r+1].x,e[r+1].y,e[r+1].z);return{positions:new Float32Array(0),indices:new Uint32Array(0),normals:new Float32Array(0),uvs:new Float32Array(0),edgePositions:new Float32Array(o)}}function ye(s){var t;return s instanceof Float32Array?s:(t=s==null?void 0:s.properties)!=null&&t.buffer?new Float32Array(s.properties.buffer):Array.isArray(s)?new Float32Array(s):new Float32Array(0)}function nt(s){var t;return s instanceof Uint32Array?s:(t=s==null?void 0:s.properties)!=null&&t.buffer?new Uint32Array(s.properties.buffer):Array.isArray(s)?new Uint32Array(s):new Uint32Array(0)}function Ce(s,t){if(s.length===0||t.length===0)return new Float32Array(0);const e=new Float32Array(s.length);for(let o=0;o<t.length;o+=3){const r=t[o],i=t[o+1],a=t[o+2],c=s[r*3],m=s[r*3+1],p=s[r*3+2],x=s[i*3],f=s[i*3+1],M=s[i*3+2],y=s[a*3],w=s[a*3+1],T=s[a*3+2],G=x-c,F=f-m,S=M-p,U=y-c,J=w-m,Q=T-p,O=F*Q-S*J,E=S*U-G*Q,I=G*J-F*U,K=Math.sqrt(O*O+E*E+I*I)||1;for(const b of[r,i,a])e[b*3]+=O/K,e[b*3+1]+=E/K,e[b*3+2]+=I/K}for(let o=0;o<e.length;o+=3){const r=Math.sqrt(ve(e[o],2)+ve(e[o+1],2)+ve(e[o+2],2))||1;e[o]/=r,e[o+1]/=r,e[o+2]/=r}return e}function ot(s,t){const e=new u.Vector3().subVectors(t,s).normalize();let o=new u.Vector3().crossVectors(e,new u.Vector3(0,0,1)).normalize();return o.lengthSq()<.01&&(o=new u.Vector3().crossVectors(e,new u.Vector3(1,0,0)).normalize()),{start:s.clone(),end:t.clone(),normal:o}}function rt(s){const t=[];for(let e=0;e<s.length-1;e++)t.push(ot(s[e],s[e+1]));return t}const ze=new WeakMap;function st(s,t){if(!s.mesh||s.mesh.positions.length===0||s.mesh.indices.length===0)return new Float32Array(0);let e=ze.get(s);e||(e=new u.BufferGeometry,e.setAttribute("position",new u.BufferAttribute(s.mesh.positions,3)),e.setIndex(new u.BufferAttribute(s.mesh.indices,1)),e.boundsTree=new Me.MeshBVH(e),ze.set(s,e));const o=e.boundsTree,r=[],i=new u.Line3;return o.shapecast({intersectsBounds:a=>t.intersectsBox(a),intersectsTriangle:a=>(it(a,t,i)&&r.push(i.start.x,i.start.y,i.start.z,i.end.x,i.end.y,i.end.z),!1)}),new Float32Array(r)}function it(s,t,e){const o=t.distanceToPoint(s.a),r=t.distanceToPoint(s.b),i=t.distanceToPoint(s.c);if(o>0&&r>0&&i>0||o<0&&r<0&&i<0||o===0&&r===0&&i===0)return!1;const a=[];if(xe(s.a,s.b,o,r,a),xe(s.b,s.c,r,i,a),xe(s.c,s.a,i,o,a),a.length>=2){e.start.copy(a[0]);let c=0,m=1;for(let p=1;p<a.length;p++){const x=a[0].distanceToSquared(a[p]);x>c&&(c=x,m=p)}return e.end.copy(a[m]),c>=1e-10}return!1}function xe(s,t,e,o,r){if(e*o<0){const i=e/(e-o);r.push(new u.Vector3().copy(s).lerp(t,i))}else Math.abs(e)<1e-5&&(r.length===0||r[r.length-1].distanceTo(s)>1e-5)&&r.push(s.clone())}function at(s,t,e){const o=[],r=new u.Vector3().subVectors(e,t),i=r.lengthSq();if(i<1e-6)return[];const a=(c,m,p)=>{const x=c-t.x,f=m-t.y,M=p-t.z;return(x*r.x+f*r.y+M*r.z)/i};for(let c=0;c<s.length;c+=6){const m=s[c],p=s[c+1],x=s[c+2],f=s[c+3],M=s[c+4],y=s[c+5],w=a(m,p,x),T=a(f,M,y);if(w>=0&&w<=1&&T>=0&&T<=1){o.push(m,p,x,f,M,y);continue}if(w<0&&T<0||w>1&&T>1)continue;const G=Math.min(w,T),F=Math.max(w,T),S=w<T?{x:m,y:p,z:x}:{x:f,y:M,z:y},U=w<T?{x:f,y:M,z:y}:{x:m,y:p,z:x},J=Math.max(G,0),Q=Math.min(F,1);if(J<Q){const O=F-G,E=(J-G)/O,I=(Q-G)/O;o.push(S.x+(U.x-S.x)*E,S.y+(U.y-S.y)*E,S.z+(U.z-S.z)*E,S.x+(U.x-S.x)*I,S.y+(U.y-S.y)*I,S.z+(U.z-S.z)*I)}}return o}function lt(s,t){if(t.length<2)return{results:[],allPositions:new Float32Array(0)};const e=rt(t),o=[],r=[];for(const i of s){const a=i.node;if(!a.mesh||a.mesh.positions.length===0)continue;const c=[];for(const m of e){const p=new u.Plane(m.normal.clone(),-m.normal.dot(m.start)),x=st(a,p);if(x.length>0){const f=at(x,m.start,m.end);f.length>0&&c.push(...f)}}if(c.length>0){o.push(...c);const m=[];for(let p=0;p<c.length;p+=6)m.push({start:{x:c[p],y:c[p+1],z:c[p+2]},end:{x:c[p+3],y:c[p+4],z:c[p+5]}});r.push({nodeName:a.name,nodeColor:a.color,segments:m})}}return{results:r,allPositions:new Float32Array(o)}}const ct={class:"geo-dialog-box"},dt={class:"geo-dialog-header"},ut={key:0,class:"geo-highlight-tag"},mt={class:"geo-dialog-body"},ft={key:0,class:"geo-no-result"},pt=n.defineComponent({__name:"SectionDialog",props:{visible:{type:Boolean},results:{},startPoint:{},endPoint:{}},emits:["close"],setup(s,{emit:t}){const e=s,o=t,r=n.ref(),i=n.ref();let a=1100,c=600;const m=n.ref(!1),p=n.ref(""),x=n.ref({}),f=n.ref(null);function M(b){const N=parseInt(b.slice(1,3),16),d=parseInt(b.slice(3,5),16),L=parseInt(b.slice(5,7),16),A=.7,C=Math.round(N*A),B=Math.round(d*A),q=Math.round(L*A);return`#${C.toString(16).padStart(2,"0")}${B.toString(16).padStart(2,"0")}${q.toString(16).padStart(2,"0")}`}const y=["#d32f2f","#1565c0","#2e7d32","#e65100","#6a1b9a","#00838f","#c62828","#283593","#1b5e20","#bf360c"];function w(b,N){const d=parseInt(b.slice(1,3),16),L=parseInt(b.slice(3,5),16),A=parseInt(b.slice(5,7),16);return(d*299+L*587+A*114)/1e3>180?y[N%y.length]:M(b)}function T(){o("close"),f.value=null}function G(){const b=r.value;if(!b)return;const N=b.toDataURL("image/png"),d=document.createElement("a");d.download=`剖面结果_${new Date().toISOString().slice(0,10)}.png`,d.href=N,d.click()}const F=[];n.watch(()=>e.visible,b=>ge(null,null,function*(){b&&(f.value=null,yield n.nextTick(),S())}));function S(){const b=r.value,N=i.value;if(!b||!N)return;const d=b.getContext("2d");if(!d)return;const L=N.clientWidth;a=Math.max(L,600),c=Math.round(a*.5);const A=window.devicePixelRatio||1;if(b.width=a*A,b.height=c*A,b.style.width=a+"px",b.style.height=c+"px",d.scale(A,A),d.clearRect(0,0,a,c),e.results.length===0)return;const C=e.endPoint.x-e.startPoint.x,B=e.endPoint.y-e.startPoint.y,q=Math.sqrt(C*C+B*B);if(q<1e-6)return;const k=C/q,j=B/q,ee=[];let $=1/0,te=-1/0,ne=1/0,Y=-1/0;if(e.results.forEach((g,l)=>{const h="#"+g.nodeColor.toString(16).padStart(6,"0"),v=w(h,l);for(const _ of g.segments){const V=(_.start.x-e.startPoint.x)*k+(_.start.y-e.startPoint.y)*j,D=_.start.z,R=(_.end.x-e.startPoint.x)*k+(_.end.y-e.startPoint.y)*j,z=_.end.z;ee.push({x1:V,z1:D,x2:R,z2:z,color:v,name:g.nodeName}),$=Math.min($,V,R),te=Math.max(te,V,R),ne=Math.min(ne,D,z),Y=Math.max(Y,D,z)}}),ee.length===0)return;const fe=te-$||1,pe=Y-ne||1,oe=70,P=30,re=30,ue=50,me=a-oe-P,se=c-re-ue,we=me/fe,he=se/pe,X=g=>oe+(g-$)*we,Z=g=>c-ue-(g-ne)*he;d.fillStyle="#fafafa",d.fillRect(0,0,a,c),d.strokeStyle="#bbb",d.lineWidth=1,d.strokeRect(oe,re,me,se);const ie=K(fe),ae=K(pe);d.strokeStyle="#e8e8e8",d.lineWidth=.5;for(let g=Math.ceil($/ie)*ie;g<=te;g+=ie){const l=X(g);d.beginPath(),d.moveTo(l,re),d.lineTo(l,c-ue),d.stroke()}for(let g=Math.ceil(ne/ae)*ae;g<=Y;g+=ae){const l=Z(g);d.beginPath(),d.moveTo(oe,l),d.lineTo(a-P,l),d.stroke()}d.fillStyle="#444",d.font="11px monospace",d.textAlign="center";for(let g=Math.ceil($/ie)*ie;g<=te;g+=ie)d.fillText(g.toFixed(0),X(g),c-ue+16);d.textAlign="right";for(let g=Math.ceil(ne/ae)*ae;g<=Y;g+=ae)d.fillText(g.toFixed(0),oe-6,Z(g)+4);d.fillStyle="#222",d.font="bold 13px sans-serif",d.textAlign="center",d.fillText("水平距离 (m)",oe+me/2,c-4),d.save(),d.translate(14,re+se/2),d.rotate(-Math.PI/2),d.fillText("标高 Z (m)",0,0),d.restore(),d.save(),d.beginPath(),d.rect(oe,re,me,se),d.clip();const de=f.value;if(de){d.lineWidth=1.5,d.globalAlpha=.2;for(const g of ee)g.name!==de&&(d.strokeStyle=g.color,d.beginPath(),d.moveTo(X(g.x1),Z(g.z1)),d.lineTo(X(g.x2),Z(g.z2)),d.stroke());d.globalAlpha=1}d.lineWidth=de?4:1.5,d.lineCap="round";for(const g of ee)de&&g.name!==de||(d.strokeStyle=g.color,d.beginPath(),d.moveTo(X(g.x1),Z(g.z1)),d.lineTo(X(g.x2),Z(g.z2)),d.stroke());d.restore(),F.length=0;for(const g of ee)F.push({sx1:X(g.x1),sy1:Z(g.z1),sx2:X(g.x2),sy2:Z(g.z2),name:g.name,color:g.color})}function U(b,N,d,L,A,C){const B=A-d,q=C-L,k=B*B+q*q;if(k<1e-6)return Math.hypot(b-d,N-L);let j=((b-d)*B+(N-L)*q)/k;return j=Math.max(0,Math.min(1,j)),Math.hypot(b-(d+j*B),N-(L+j*q))}function J(b){const d=r.value.getBoundingClientRect();return{mx:(b.clientX-d.left)*(a/d.width),my:(b.clientY-d.top)*(c/d.height),rect:d}}function Q(b,N){let d=1/0,L="",A="";for(const C of F){const B=U(b,N,C.sx1,C.sy1,C.sx2,C.sy2);B<d&&(d=B,L=C.name,A=C.color)}return{bestDist:d,bestName:L,bestColor:A}}function O(b){if(!r.value||F.length===0)return;const{mx:N,my:d,rect:L}=J(b),{bestDist:A,bestName:C,bestColor:B}=Q(N,d);A<12?(m.value=!0,p.value=C,x.value={left:b.clientX-L.left+14+"px",top:b.clientY-L.top-8+"px",borderLeft:`4px solid ${B}`},r.value.style.cursor="pointer"):(m.value=!1,r.value.style.cursor="default")}function E(){m.value=!1}function I(b){if(!r.value||F.length===0)return;const{mx:N,my:d}=J(b),{bestDist:L,bestName:A}=Q(N,d);L<12?f.value=f.value===A?null:A:f.value=null,S()}function K(b){const N=b/8,d=Math.pow(10,Math.floor(Math.log10(N))),L=N/d;return L<1.5?d:L<3.5?2*d:L<7.5?5*d:10*d}return(b,N)=>s.visible?(n.openBlock(),n.createElementBlock("div",{key:0,class:"geo-dialog-overlay",onClick:n.withModifiers(T,["self"])},[n.createElementVNode("div",ct,[n.createElementVNode("div",dt,[N[0]||(N[0]=n.createElementVNode("span",{class:"geo-dialog-title"},"剖面结果",-1)),f.value?(n.openBlock(),n.createElementBlock("span",ut,n.toDisplayString(f.value),1)):n.createCommentVNode("",!0),n.createElementVNode("button",{class:"geo-export-btn",onClick:G,title:"导出图片"},"💾 导出图片"),n.createElementVNode("button",{class:"geo-dialog-close",onClick:T},"×")]),n.createElementVNode("div",mt,[n.createElementVNode("div",{class:"geo-canvas-wrap",ref_key:"canvasWrapRef",ref:i},[n.createElementVNode("canvas",{ref_key:"canvasRef",ref:r,onMousemove:O,onMouseleave:E,onClick:I},null,544),m.value?(n.openBlock(),n.createElementBlock("div",{key:0,class:"geo-canvas-tooltip",style:n.normalizeStyle(x.value)},n.toDisplayString(p.value),5)):n.createCommentVNode("",!0)],512),s.results.length===0?(n.openBlock(),n.createElementBlock("div",ft,"该剖切线未与任何模型相交")):n.createCommentVNode("",!0)])])])):n.createCommentVNode("",!0)}}),ht=Ee._export_sfc(pt,[["__scopeId","data-v-cf4a02c5"]]),vt={class:"lw-map-area"},gt={key:0,class:"lw-model-loading"},yt={key:1,class:"lw-section-hint"},wt={key:2,class:"lw-model-dropdown"},bt={key:0,class:"lw-model-panel"},kt=["checked"],xt=["onClick"],Et=["checked"],Mt={class:"lw-device-arrow"},_t={key:0,class:"lw-device-grid"},St=["onClick"],Nt={key:0,class:"lw-device-check"},Lt={class:"lw-device-name"},At=n.defineComponent({__name:"MonitoringMap",props:{mapScene:{},devices:{},mobileObjects:{},affectedAreas:{},currentWarning:{},warningAreaColor:{default:"#ff6600"},warningAreaFillOpacity:{default:.08},showModelToggle:{type:Boolean,default:!0},showDeviceToggle:{type:Boolean,default:!0},g3dFileUrl:{default:""},dtmModelUrl:{default:""},uavTileUrl:{default:""}},emits:["select-device","select-object","toggle-model"],setup(s,{expose:t,emit:e}){const o=s,r=e,i=n.ref(),a=n.ref(),c=n.ref(!1),m=n.ref(!1),p=n.ref(!1),x=n.ref(""),f=n.ref("none"),M=n.ref({x:0,y:0,z:0}),y=n.ref({x:0,y:0,z:0}),w=n.ref([]),T=n.ref(!1);let G={x:0,y:0};const F=[{key:"geological_model",label:"地质模型"},{key:"dtm_surface",label:"DTM面"},{key:"drone_map",label:"无人机地图"}],S=n.reactive(new Set(["drone_map"])),U=n.computed(()=>S.size===F.length);function J(l){S.has(l)?S.delete(l):S.add(l),b(),r("toggle-model")}function Q(){U.value?S.clear():F.forEach(l=>S.add(l.key)),b(),r("toggle-model")}let O=null,E=null,I=null;const K=n.computed(()=>S.has("geological_model")||S.has("dtm_surface"));function b(){return ge(this,null,function*(){if(S.has("geological_model")||S.has("dtm_surface")){if(!E&&a.value&&(yield n.nextTick(),E=new je(a.value)),S.has("geological_model")&&o.g3dFileUrl&&E)try{p.value=!0,x.value="加载地质模型...";const h=yield fetch(o.g3dFileUrl);if(!h.ok)throw new Error(`HTTP ${h.status}: ${h.statusText}`);x.value="读取模型数据...";const v=yield h.text();x.value="解析模型...";const _=Ye(v);yield E.loadDocument(_,V=>{x.value=V})}catch(h){console.error("[MonitoringMap] 加载地质模型失败:",h)}finally{p.value=!1}E&&ae()}else E&&E.removeAllDeviceMarkers(),k&&setTimeout(()=>k==null?void 0:k.invalidateSize(),100);if(S.has("drone_map")&&k){if(!I){const h=o.uavTileUrl||ne.satellite;I=H.L.tileLayer(h,{maxZoom:19,opacity:.85}).addTo(k)}}else I&&k&&(k.removeLayer(I),I=null)})}function N(){if(!E){alert("请先勾选「地质模型」加载 3D 模型后再进行剖面绘制");return}E.clearPickMarkers(),E.clearSectionResults(),f.value="start",T.value=!1,w.value=[],L()}function d(){f.value="none",E==null||E.clearPickMarkers(),A()}function L(){if(!E)return;const l=E.renderer.domElement;l.addEventListener("mousedown",C),l.addEventListener("mouseup",B)}function A(){if(!E)return;const l=E.renderer.domElement;l.removeEventListener("mousedown",C),l.removeEventListener("mouseup",B)}function C(l){G={x:l.clientX,y:l.clientY}}function B(l){if(!E||f.value==="none"||Math.hypot(l.clientX-G.x,l.clientY-G.y)>5)return;const h=E.pickPoint(l);if(h){if(f.value==="start")M.value={x:h.x,y:h.y,z:h.z},E.addPickMarker(h,65280),f.value="end";else if(f.value==="end"){y.value={x:h.x,y:h.y,z:h.z},E.addPickMarker(h,16711680),f.value="none",A();const v=new u.Vector3(M.value.x,M.value.y,M.value.z),_=new u.Vector3(y.value.x,y.value.y,y.value.z);E.addSectionPath([v,_]);const V=E.getVisibleMeshEntries(),{results:D,allPositions:R}=lt(V,[v,_]);w.value=D,R.length>0&&D.forEach(z=>{const W=z.nodeColor,le=[];for(const ce of z.segments)le.push(ce.start.x,ce.start.y,ce.start.z,ce.end.x,ce.end.y,ce.end.z);le.length>0&&E.addSectionLines(new Float32Array(le),W)}),T.value=!0}}}t({startSection:N});const q={mounted(l,h){l.__clickOutsideHandler=v=>{l.contains(v.target)||h.value()},document.addEventListener("click",l.__clickOutsideHandler)},unmounted(l){document.removeEventListener("click",l.__clickOutsideHandler)}};let k=null,j=null,ee=null,$=null,te=null;const ne={dark:"https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png",light:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",satellite:"https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}",gaode:"https://webrd0{s}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}",gaode_satellite:"https://webst0{s}.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}"},Y=[{type:"GNSS",label:"GNSS监测",icon:"📍",color:"#ff6b6b",category:"device"},{type:"inclinometer",label:"深部位移监测",icon:"⚓",color:"#3b82f6",category:"device"},{type:"radar",label:"雷达监测",icon:"📡",color:"#8b5cf6",category:"device"},{type:"crack_image",label:"裂缝写实",icon:"�",color:"#06b6d4",category:"device"},{type:"crack",label:"裂缝监测",icon:"📏",color:"#f97316",category:"device"},{type:"combustion",label:"煤自燃监测",icon:"🔥",color:"#ef4444",category:"device"},{type:"rain",label:"降雨监测",icon:"💧",color:"#0ea5e9",category:"device"},{type:"groundwater",label:"地下水监测",icon:"�",color:"#14b8a6",category:"device"},{type:"stress",label:"地下应力监测",icon:"📊",color:"#eab308",category:"device"},{type:"vibration",label:"爆破震动监测",icon:"💥",color:"#f59e0b",category:"device"},{type:"remote_sensing",label:"遥感监测",icon:"🛰️",color:"#64748b",category:"device"},{type:"person",label:"人员",icon:"👤",color:"#78909c",category:"object"},{type:"truck",label:"车辆",icon:"🚛",color:"#5d9b46",category:"object"},{type:"excavator",label:"挖掘设备",icon:"🏗️",color:"#e8a735",category:"object"},{type:"drone",label:"无人机",icon:"🛸",color:"#7e57c2",category:"object"}],fe=Y.reduce((l,h)=>(l[h.type]=h.icon,l),{}),pe={person:"👤",truck:"🚛",excavator:"🏗️",drone:"🛸"},oe={normal:"#52c41a",warning:"#ff4d4f",offline:"#999",abnormal:"#faad14",near_warning_area:"#ff6600",in_warning_area:"#ff0000",evacuated:"#999"},P=n.reactive(new Set(Y.map(l=>l.type))),re=n.computed(()=>P.size===Y.length);function ue(l){P.has(l)?P.delete(l):P.add(l)}function me(){re.value?P.clear():Y.forEach(l=>P.add(l.type))}const se=n.computed(()=>o.devices.filter(l=>P.has(l.deviceType)));function we(){var _,V,D;if(k||!i.value)return;const l=o.mapScene;k=H.L.map(i.value,{center:[(_=l.centerLat)!=null?_:45.3738,(V=l.centerLng)!=null?V:119.3838],zoom:(D=l.zoom)!=null?D:15,zoomControl:!1,attributionControl:!1});const h=ne[l.tileStyle||"dark"]||ne.dark,v=(l.tileStyle||"dark").startsWith("gaode")?"1234":"abc";H.L.tileLayer(h,{attribution:"",maxZoom:18,subdomains:v}).addTo(k),te=H.L.layerGroup().addTo(k),j=H.L.layerGroup().addTo(k),ee=H.L.layerGroup().addTo(k),$=H.L.layerGroup().addTo(k),he(),setTimeout(()=>k==null?void 0:k.invalidateSize(),100),setTimeout(()=>k==null?void 0:k.invalidateSize(),400),setTimeout(()=>k==null?void 0:k.invalidateSize(),1e3),i.value&&(O=new ResizeObserver(()=>{setTimeout(()=>k==null?void 0:k.invalidateSize(),50)}),O.observe(i.value))}function he(){Z(),ie(),de(),g()}const X=["#ff4d4f","#3b82f6","#22c55e","#f59e0b","#8b5cf6","#06b6d4","#ec4899","#14b8a6","#f97316","#6366f1"];function Z(){if(!te||!k)return;te.clearLayers();const l=new Map;se.value.forEach(v=>{const _=v.lineId;!_||!v.lat||!v.lng||(l.has(_)||l.set(_,[]),l.get(_).push({lat:v.lat,lng:v.lng}))});let h=0;l.forEach((v,_)=>{if(v.length<2)return;v.sort((z,W)=>z.lng-W.lng||z.lat-W.lat);const V=v.map(z=>[z.lat,z.lng]),D=X[h%X.length];h++;const R=H.L.polyline(V,{color:D,weight:3,opacity:.85,dashArray:""});R.bindTooltip(_,{sticky:!0,direction:"top"}),te.addLayer(R)})}function ie(){!j||!k||(j.clearLayers(),se.value.forEach(l=>{var le,ce;const h=(le=l.lat)!=null?le:0,v=(ce=l.lng)!=null?ce:0;if(!h||!v)return;const _=fe[l.deviceType]||"📍",V=oe[l.status]||"#52c41a",D=l.warningLevel&&l.warningLevel>0,R=H.L.divIcon({className:"lw-marker-icon",html:`<div class="lw-marker" style="border-color:${V}">
|
|
1
|
+
"use strict";var Be=Object.defineProperty;var _e=Object.getOwnPropertySymbols;var Ve=Object.prototype.hasOwnProperty,Re=Object.prototype.propertyIsEnumerable;var ve=Math.pow,Se=(s,t,e)=>t in s?Be(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e,ke=(s,t)=>{for(var e in t||(t={}))Ve.call(t,e)&&Se(s,e,t[e]);if(_e)for(var e of _e(t))Re.call(t,e)&&Se(s,e,t[e]);return s};var ge=(s,t,e)=>new Promise((o,r)=>{var i=m=>{try{c(e.next(m))}catch(p){r(p)}},a=m=>{try{c(e.throw(m))}catch(p){r(p)}},c=m=>m.done?o(m.value):Promise.resolve(m.value).then(i,a);c((e=e.apply(s,t)).next())});const n=require("vue"),Ee=require("./index-Cm7hGuPj.cjs"),H=require("./leaflet-src-DYGpvxW6.cjs");;/* empty css */const u=require("./three.module-CjayKmiG.cjs"),De=require("./OrbitControls-uuLGjaqy.cjs"),Ne=require("./CSS2DRenderer-nQ2DN9Uc.cjs"),Me=require("./ExtensionUtilities-ClTuwtC-.cjs"),Pe={class:"lw-filter-bar"},Fe=["value"],Ie={key:0,value:"",disabled:""},Ue=["value"],Oe=["value"],$e={class:"lw-time-btns"},Ge=["onClick"],We={class:"lw-date-range"},He=n.defineComponent({__name:"FilterBar",props:{filters:{},regions:{},lines:{},deviceNames:{}},emits:["update:filters","query","start-section"],setup(s,{emit:t}){const e=s,o=t,r=[{label:"一天内",value:"day"},{label:"一周内",value:"week"},{label:"一个月内",value:"month"}],i=n.reactive(ke({},e.filters)),a=n.computed(()=>{if(!i.regionId)return e.lines;const M=e.regions.find(y=>y.regionName===i.regionId);return M?e.lines.filter(y=>y.regionId===M.regionId):e.lines}),c=n.computed(()=>e.deviceNames);function m(){i.lineId&&!a.value.some(M=>M.lineName===i.lineId)&&(i.lineId=""),f()}function p(){f()}function x(M){i.quickRange=M,f()}function f(){o("update:filters",ke({},i))}return(M,y)=>(n.openBlock(),n.createElementBlock("div",Pe,[n.withDirectives(n.createElementVNode("select",{"onUpdate:modelValue":y[0]||(y[0]=w=>i.regionId=w),class:"lw-select",onChange:m},[y[6]||(y[6]=n.createElementVNode("option",{value:""},"全部区域",-1)),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s.regions,w=>(n.openBlock(),n.createElementBlock("option",{key:w.regionId,value:w.regionName},n.toDisplayString(w.regionName),9,Fe))),128))],544),[[n.vModelSelect,i.regionId]]),n.withDirectives(n.createElementVNode("select",{"onUpdate:modelValue":y[1]||(y[1]=w=>i.lineId=w),class:"lw-select",onChange:p},[y[7]||(y[7]=n.createElementVNode("option",{value:""},"全部监测线",-1)),a.value.length===0?(n.openBlock(),n.createElementBlock("option",Ie,"(该区域暂无监测线)")):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.value,w=>(n.openBlock(),n.createElementBlock("option",{key:w.lineId,value:w.lineName},n.toDisplayString(w.lineName),9,Ue))),128))],544),[[n.vModelSelect,i.lineId]]),n.withDirectives(n.createElementVNode("select",{"onUpdate:modelValue":y[2]||(y[2]=w=>i.deviceId=w),class:"lw-select",onChange:f},[y[8]||(y[8]=n.createElementVNode("option",{value:""},"全部监测点",-1)),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(c.value,w=>(n.openBlock(),n.createElementBlock("option",{key:w,value:w},n.toDisplayString(w),9,Oe))),128))],544),[[n.vModelSelect,i.deviceId]]),n.createElementVNode("div",$e,[(n.openBlock(),n.createElementBlock(n.Fragment,null,n.renderList(r,w=>n.createElementVNode("button",{key:w.value,class:n.normalizeClass(["lw-time-btn",{active:i.quickRange===w.value}]),onClick:T=>x(w.value)},n.toDisplayString(w.label),11,Ge)),64))]),n.createElementVNode("div",We,[n.withDirectives(n.createElementVNode("input",{type:"datetime-local","onUpdate:modelValue":y[3]||(y[3]=w=>i.startTime=w),class:"lw-date-input",onChange:f},null,544),[[n.vModelText,i.startTime]]),y[9]||(y[9]=n.createElementVNode("span",{class:"lw-date-sep"},"至",-1)),n.withDirectives(n.createElementVNode("input",{type:"datetime-local","onUpdate:modelValue":y[4]||(y[4]=w=>i.endTime=w),class:"lw-date-input",onChange:f},null,544),[[n.vModelText,i.endTime]])]),y[10]||(y[10]=n.createElementVNode("div",{class:"lw-spacer"},null,-1)),n.createElementVNode("button",{class:"lw-btn-section",onClick:y[5]||(y[5]=w=>o("start-section"))},"剖面图绘制")]))}}),qe=Ee._export_sfc(He,[["__scopeId","data-v-151e0d5e"]]);function Le(s,t){if(t==="cf"){const o=s.cf;return o<50?[0/255,170/255,255/255]:o<150?[255/255,230/255,0/255]:o<300?[255/255,145/255,0/255]:o<500?[240/255,70/255,40/255]:[180/255,0/255,0/255]}if(t==="av"){const o=s.av;return o<-.6?[0/255,80/255,220/255]:o<-.1?[0/255,170/255,255/255]:Math.abs(o)<.1?[0/255,220/255,120/255]:o<.6?[255/255,185/255,0/255]:[220/255,30/255,30/255]}const e=Math.abs(s.rr);return s.rr<0?e<5?[0/255,180/255,255/255]:e<20?[0/255,120/255,255/255]:e<60?[40/255,70/255,220/255]:[20/255,35/255,150/255]:e<5?[255/255,230/255,0/255]:e<20?[255/255,165/255,0/255]:e<60?[235/255,85/255,0/255]:[180/255,0/255,0/255]}u.Mesh.prototype.raycast=Me.acceleratedRaycast;class je{constructor(t){this.container=t,this.raycaster=new u.Raycaster,this.animFrameId=0,this.needsUpdate=!0,this.nodeEntries=new Map,this.resizeObserver=null,this.deviceMarkers=new Map,this.radarLayers=new Map,this.animate=()=>{if(this.animFrameId=requestAnimationFrame(this.animate),this.controls.update(),!this.needsUpdate)return;const o=this.camera.position.clone().sub(this.controls.target);this.dynamicLight.position.copy(o),this.renderer.render(this.scene,this.camera),this.labelRenderer.render(this.scene,this.camera),this.needsUpdate=!1},u.Object3D.DEFAULT_UP.set(0,0,1),this.scene=new u.Scene,this.camera=new u.PerspectiveCamera(50,t.clientWidth/Math.max(t.clientHeight,1),.1,1e5),this.camera.position.set(500,-500,500),this.camera.up.set(0,0,1),this.renderer=new u.WebGLRenderer({antialias:!0,alpha:!0}),this.renderer.setPixelRatio(window.devicePixelRatio),this.renderer.setSize(t.clientWidth,t.clientHeight),t.appendChild(this.renderer.domElement),this.labelRenderer=new Ne.CSS2DRenderer,this.labelRenderer.setSize(t.clientWidth,t.clientHeight),this.labelRenderer.domElement.style.position="absolute",this.labelRenderer.domElement.style.top="0",this.labelRenderer.domElement.style.left="0",this.labelRenderer.domElement.style.pointerEvents="none",this.labelRenderer.domElement.style.overflow="visible",t.appendChild(this.labelRenderer.domElement),this.controls=new De.OrbitControls(this.camera,this.renderer.domElement),this.controls.enableDamping=!1,this.controls.mouseButtons={LEFT:u.MOUSE.ROTATE,MIDDLE:u.MOUSE.PAN,RIGHT:u.MOUSE.PAN},this.controls.addEventListener("change",()=>{this.updateCameraNearFar(),this.needsUpdate=!0});const e=new u.AmbientLight(8947848,4);this.dynamicLight=new u.DirectionalLight(16777215,2),this.scene.add(e,this.dynamicLight),this.scene.add(new u.AxesHelper(250)),this.resizeObserver=new ResizeObserver(()=>this.resize()),this.resizeObserver.observe(t),this.animate()}loadDocument(t,e){return ge(this,null,function*(){this.clearModel();const o=this.flattenNodes(t.rootNode),r=o.filter(a=>a.mesh&&a.mesh.positions.length>0);e==null||e(`构建场景树 (${o.length} 节点)...`),this.buildGroupTree(t.rootNode,this.scene);let i=0;for(const a of r)this.createMeshForNode(a),i++,i%5===0&&(e==null||e(`创建网格 ${i}/${r.length}...`),yield new Promise(c=>setTimeout(c,0)));this.fitContent(),this.needsUpdate=!0})}flattenNodes(t){const e=[t];for(const o of t.children)e.push(...this.flattenNodes(o));return e}buildGroupTree(t,e){const o=new u.Group;o.name=t.name,o.visible=t.visible,e.add(o);const r={node:t,group:o};this.nodeEntries.set(t.id,r);for(const i of t.children)this.buildGroupTree(i,o)}createMeshForNode(t){var c,m;const e=this.nodeEntries.get(t.id);if(!e||!t.mesh)return;const{positions:o,indices:r,edgePositions:i}=t.mesh;if(o.length>0&&r.length>0){const p=new u.BufferGeometry;p.setAttribute("position",new u.BufferAttribute(o,3)),p.setIndex(new u.BufferAttribute(r,1)),p.computeVertexNormals(),p.computeBoundingBox(),p.boundsTree=new Me.MeshBVH(p);const x=new u.MeshLambertMaterial({color:new u.Color(t.color),side:u.DoubleSide,flatShading:!0}),f=new u.Mesh(p,x);f.name=t.name+"_mesh",e.group.add(f),e.meshObj=f}const a=(m=(c=t.raw)==null?void 0:c.displayMode)!=null?m:0;if(i.length>0&&a>0){const p=new u.BufferGeometry;p.setAttribute("position",new u.BufferAttribute(i,3)),p.computeBoundingBox();const x=new u.LineBasicMaterial({color:0,linewidth:1}),f=new u.LineSegments(p,x);f.name=t.name+"_edges",e.group.add(f),e.edgeObj=f}}setNodeVisible(t,e){const o=this.nodeEntries.get(t);o&&(this.setNodeVisibleRecursive(o.node,e),this.needsUpdate=!0)}setNodeVisibleRecursive(t,e){t.visible=e;const o=this.nodeEntries.get(t.id);o&&(o.group.visible=e);for(const r of t.children)this.setNodeVisibleRecursive(r,e)}fitContent(){try{this.scene.updateMatrixWorld(!0);const t=new u.Box3;if(this.scene.traverse(i=>{if(!(i instanceof u.AxesHelper)&&(i instanceof u.Mesh||i instanceof u.LineSegments)){const a=i.geometry;if(a&&a.attributes.position&&(a.computeBoundingBox(),a.boundingBox&&!a.boundingBox.isEmpty())){const c=a.boundingBox.clone();c.applyMatrix4(i.matrixWorld),t.union(c)}}}),t.isEmpty())return;const e=t.getCenter(new u.Vector3),o=t.getSize(new u.Vector3);console.log("[SceneManager] 模型包围盒 min:",t.min.toArray(),"max:",t.max.toArray(),"center:",e.toArray(),"size:",o.toArray());const r=Math.max(o.x,o.y,o.z);this.controls.target.copy(e),this.camera.position.set(e.x+r*.8,e.y-r*.8,e.z+r*.6),this.updateCameraNearFar(),this.controls.update(),this.needsUpdate=!0}catch(t){console.warn("[fitContent] error:",t)}}getVisibleMeshEntries(){const t=[];return this.nodeEntries.forEach(e=>{e.meshObj&&e.group.visible&&e.node.mesh&&t.push(e)}),t}addSectionLines(t,e){const o=new u.BufferGeometry;o.setAttribute("position",new u.BufferAttribute(t,3));const r=new u.LineBasicMaterial({color:e,linewidth:2,depthTest:!1}),i=new u.LineSegments(o,r);return i.renderOrder=999,i.name="__section_result__",this.scene.add(i),this.needsUpdate=!0,i}addSectionPath(t,e=16776960){const o=[];for(let c=0;c<t.length-1;c++)o.push(t[c].x,t[c].y,t[c].z),o.push(t[c+1].x,t[c+1].y,t[c+1].z);const r=new u.BufferGeometry;r.setAttribute("position",new u.BufferAttribute(new Float32Array(o),3));const i=new u.LineBasicMaterial({color:e,linewidth:3,depthTest:!1}),a=new u.LineSegments(r,i);return a.renderOrder=1e3,a.name="__section_path__",this.scene.add(a),this.needsUpdate=!0,a}clearSectionResults(){const t=[];this.scene.traverse(e=>{(e.name==="__section_result__"||e.name==="__section_path__")&&t.push(e)}),t.forEach(e=>{e.removeFromParent(),e.geometry&&e.geometry.dispose(),e.material&&e.material.dispose()}),this.needsUpdate=!0}setTransparency(t){this.nodeEntries.forEach(e=>{if(e.meshObj){const o=e.meshObj.material;o.transparent=t,o.opacity=t?.4:1,o.depthWrite=!t,o.needsUpdate=!0}}),this.needsUpdate=!0}pickPoint(t){const e=this.renderer.domElement.getBoundingClientRect(),o=new u.Vector2((t.clientX-e.left)/e.width*2-1,-((t.clientY-e.top)/e.height)*2+1);this.raycaster.setFromCamera(o,this.camera);const r=[];this.scene.traverse(a=>{a instanceof u.Mesh&&a.name.endsWith("_mesh")&&a.visible&&r.push(a)});const i=this.raycaster.intersectObjects(r,!1);return i.length>0?i[0].point.clone():null}addPickMarker(t,e=16711680){const o=new u.SphereGeometry(1,16,16),r=new u.MeshBasicMaterial({color:e,depthTest:!1}),i=new u.Mesh(o,r);i.position.copy(t),i.renderOrder=998,i.name="__pick_marker__";const a=this.camera.position.distanceTo(this.controls.target);return i.scale.setScalar(a*.008),this.scene.add(i),this.needsUpdate=!0,i}addPickLine(t,e){const o=new u.BufferGeometry;o.setAttribute("position",new u.BufferAttribute(new Float32Array([t.x,t.y,t.z,e.x,e.y,e.z]),3));const r=new u.LineBasicMaterial({color:16776960,linewidth:2,depthTest:!1}),i=new u.LineSegments(o,r);return i.renderOrder=998,i.name="__pick_line__",this.scene.add(i),this.needsUpdate=!0,i}clearPickMarkers(){const t=[];this.scene.traverse(e=>{(e.name==="__pick_marker__"||e.name==="__pick_line__")&&t.push(e)}),t.forEach(e=>{e.removeFromParent(),e.geometry&&e.geometry.dispose(),e.material&&e.material.dispose()}),this.needsUpdate=!0}addRadarLayer(t,e,o){if(this.removeRadarLayer(t),e.length===0)return;const r=new Float32Array(e.length*3),i=new Float32Array(e.length*3);for(let p=0;p<e.length;p++){const x=e[p],f=p*3;r[f]=x.e,r[f+1]=x.n,r[f+2]=x.rl;const M=Le(x,o);i[f]=M[0],i[f+1]=M[1],i[f+2]=M[2]}const a=new u.BufferGeometry;a.setAttribute("position",new u.BufferAttribute(r,3)),a.setAttribute("color",new u.BufferAttribute(i,3)),a.computeBoundingSphere();const c=new u.PointsMaterial({size:5,sizeAttenuation:!1,vertexColors:!0,depthWrite:!1,depthTest:!1,toneMapped:!1}),m=new u.Points(a,c);m.renderOrder=900,m.name=`__radar_layer_${t}__`,this.scene.add(m),this.radarLayers.set(t,{cloud:m,pointIndex:e}),this.needsUpdate=!0}setRadarLayerVisible(t,e){const o=this.radarLayers.get(t);o&&(o.cloud.visible=e,this.needsUpdate=!0)}updateRadarLayerColors(t,e,o){const r=this.radarLayers.get(t);if(!r)return;const i=r.cloud.geometry.getAttribute("color"),a=i.array;for(let c=0;c<e.length;c++){const m=Le(e[c],o),p=c*3;a[p]=m[0],a[p+1]=m[1],a[p+2]=m[2]}i.needsUpdate=!0,this.needsUpdate=!0}pickRadarPoint(t){const e=this.renderer.domElement.getBoundingClientRect(),o=new u.Vector2((t.clientX-e.left)/e.width*2-1,-((t.clientY-e.top)/e.height)*2+1),r=new u.Vector3;let i=.002,a=null;for(const[c,m]of this.radarLayers){if(!m.cloud.visible)continue;const x=m.cloud.geometry.getAttribute("position").array;for(let f=0;f<x.length;f+=3){if(r.set(x[f],x[f+1],x[f+2]).project(this.camera),r.z<-1||r.z>1)continue;const M=r.x-o.x,y=r.y-o.y,w=M*M+y*y;w<i&&(i=w,a={layerId:c,point:m.pointIndex[f/3]})}}return a}removeRadarLayer(t){const e=this.radarLayers.get(t);e&&(this.scene.remove(e.cloud),e.cloud.geometry.dispose(),e.cloud.material.dispose(),this.radarLayers.delete(t),this.needsUpdate=!0)}clearAllRadarLayers(){for(const[t]of this.radarLayers)this.removeRadarLayer(t)}addDeviceMarker(t,e,o){this.removeDeviceMarker(t);const r=new Ne.CSS2DObject(o);return r.position.set(e.e,e.n,e.rl),r.name=`__device_marker_${t}__`,this.scene.add(r),this.deviceMarkers.set(t,r),this.needsUpdate=!0,r}updateDeviceMarkerPosition(t,e){const o=this.deviceMarkers.get(t);o&&(o.position.set(e.e,e.n,e.rl),this.needsUpdate=!0)}removeDeviceMarker(t){const e=this.deviceMarkers.get(t);e&&(this.scene.remove(e),this.deviceMarkers.delete(t),this.needsUpdate=!0)}removeAllDeviceMarkers(){for(const[t]of this.deviceMarkers)this.removeDeviceMarker(t)}setDeviceMarkerVisible(t,e){const o=this.deviceMarkers.get(t);o&&(o.visible=e,this.needsUpdate=!0)}setDeviceMarkersVisible(t){for(const[,e]of this.deviceMarkers)e.visible=t;this.needsUpdate=!0}clearModel(){const t=[];this.scene.children.forEach(e=>{e instanceof u.Group&&t.push(e)}),t.forEach(e=>{e.traverse(o=>{if(o.geometry&&o.geometry.dispose(),o.material){const r=o.material;Array.isArray(r)?r.forEach(i=>i.dispose()):r.dispose()}}),e.removeFromParent()}),this.nodeEntries.clear(),this.clearSectionResults()}resize(){const t=this.container.clientWidth,e=this.container.clientHeight;e<1||(this.camera.aspect=t/e,this.camera.updateProjectionMatrix(),this.renderer.setSize(t,e),this.labelRenderer.setSize(t,e),this.needsUpdate=!0)}updateCameraNearFar(){const t=this.camera.position.distanceTo(this.controls.target);t<1?(this.camera.near=.001,this.camera.far=100):t<10?(this.camera.near=.01,this.camera.far=1e3):t<100?(this.camera.near=.1,this.camera.far=1e4):t<1e3?(this.camera.near=1,this.camera.far=1e5):t<1e4?(this.camera.near=10,this.camera.far=1e6):t<1e5?(this.camera.near=100,this.camera.far=1e7):(this.camera.near=1e3,this.camera.far=1e8),this.camera.updateProjectionMatrix()}requestUpdate(){this.needsUpdate=!0}dispose(){var t;cancelAnimationFrame(this.animFrameId),(t=this.resizeObserver)==null||t.disconnect(),this.clearModel(),this.clearAllRadarLayers(),this.removeAllDeviceMarkers(),this.controls.dispose(),this.renderer.dispose(),this.renderer.domElement.remove(),this.labelRenderer.domElement.remove()}}function Ye(s){const e=JSON.parse(s).properties,o=Xe(e.materials||[]),r=new Map;o.forEach(c=>r.set(c.id,c));const i=e.nodes,a=Ze(i,r);return{name:e.name||"Untitled",id:e.id||"",version:e.version||"",materials:o,rootNode:a}}function Xe(s){return s.map(t=>{var e,o,r;return{id:((e=t.properties)==null?void 0:e.id)||"",name:((o=t.properties)==null?void 0:o.name)||"",color:typeof((r=t.properties)==null?void 0:r.color)=="number"?t.properties.color:8947848}})}function Ze(s,t){var r;if(!s||s.length===0)return Ae("root");const e=new Map,o=[];for(const i of s){const a=Je(i,t);e.set(a.id,a),o.push({node:a,parentId:i.parentId})}for(const{node:i,parentId:a}of o)a&&e.has(a)&&e.get(a).children.push(i);return((r=o[0])==null?void 0:r.node)||Ae("root")}function Ae(s){return{id:"empty",name:s,classKey:"EmptyNode",visible:!0,color:8947848,children:[],raw:{}}}function Je(s,t){const e=s.properties||{},o=s.classKey||"";let r=8947848,i;if(e.materialId){i=e.materialId;const m=t.get(i);m&&(r=m.color)}else typeof e.color=="number"&&(r=e.color);const a={id:e.id||Math.random().toString(36).slice(2),name:e.name||o,classKey:o,visible:e.visible!==void 0?!!e.visible:!0,color:r,materialId:i,children:[],raw:e},c=Qe(o,e);return c&&(a.mesh=c),a}function Qe(s,t){if(s==="TriMeshNode"&&t.savedData)return Ke(t.savedData);if(s==="ShapeNode"||s==="MultiShapeNode")return et(t);if((s==="GeoPlineNode"||s==="PlineNode")&&t.points)return tt(t)}function Ke(s){try{const t=typeof s=="string"?JSON.parse(s):s;if(!t.pos||!t.idx)return;const e=new Float32Array(t.pos),o=new Uint32Array(t.idx),r=t.uv?new Float32Array(t.uv):new Float32Array(0),i=t.edgePos?new Float32Array(t.edgePos):new Float32Array(0),a=Ce(e,o);return{positions:e,indices:o,normals:a,uvs:r,edgePositions:i}}catch(t){return}}function et(s){const t=s.shape;if(!t)return;const e=t.properties||t,o=e.mesh||e._mesh;if(!o)return;const r=o.properties||o,i=r.faces||r._faces;if(!i)return;const a=i.properties||i;if(!a.position)return;const c=ye(a.position),m=nt(a.index),p=a.normal?ye(a.normal):Ce(c,m),x=a.uv?ye(a.uv):new Float32Array(0),f=r.edges||r._lines,M=(f==null?void 0:f.properties)||f,y=M!=null&&M.position?ye(M.position):new Float32Array(0);if(c.length!==0)return{positions:c,indices:m,normals:p,uvs:x,edgePositions:y}}function tt(s){const t=s.points;if(!t||!Array.isArray(t))return;const e=t.map(r=>r.properties?{x:r.properties.x||0,y:r.properties.y||0,z:r.properties.z||0}:{x:r.x||0,y:r.y||0,z:r.z||0});if(e.length<2)return;const o=[];for(let r=0;r<e.length-1;r++)o.push(e[r].x,e[r].y,e[r].z),o.push(e[r+1].x,e[r+1].y,e[r+1].z);return{positions:new Float32Array(0),indices:new Uint32Array(0),normals:new Float32Array(0),uvs:new Float32Array(0),edgePositions:new Float32Array(o)}}function ye(s){var t;return s instanceof Float32Array?s:(t=s==null?void 0:s.properties)!=null&&t.buffer?new Float32Array(s.properties.buffer):Array.isArray(s)?new Float32Array(s):new Float32Array(0)}function nt(s){var t;return s instanceof Uint32Array?s:(t=s==null?void 0:s.properties)!=null&&t.buffer?new Uint32Array(s.properties.buffer):Array.isArray(s)?new Uint32Array(s):new Uint32Array(0)}function Ce(s,t){if(s.length===0||t.length===0)return new Float32Array(0);const e=new Float32Array(s.length);for(let o=0;o<t.length;o+=3){const r=t[o],i=t[o+1],a=t[o+2],c=s[r*3],m=s[r*3+1],p=s[r*3+2],x=s[i*3],f=s[i*3+1],M=s[i*3+2],y=s[a*3],w=s[a*3+1],T=s[a*3+2],G=x-c,F=f-m,S=M-p,U=y-c,J=w-m,Q=T-p,O=F*Q-S*J,E=S*U-G*Q,I=G*J-F*U,K=Math.sqrt(O*O+E*E+I*I)||1;for(const b of[r,i,a])e[b*3]+=O/K,e[b*3+1]+=E/K,e[b*3+2]+=I/K}for(let o=0;o<e.length;o+=3){const r=Math.sqrt(ve(e[o],2)+ve(e[o+1],2)+ve(e[o+2],2))||1;e[o]/=r,e[o+1]/=r,e[o+2]/=r}return e}function ot(s,t){const e=new u.Vector3().subVectors(t,s).normalize();let o=new u.Vector3().crossVectors(e,new u.Vector3(0,0,1)).normalize();return o.lengthSq()<.01&&(o=new u.Vector3().crossVectors(e,new u.Vector3(1,0,0)).normalize()),{start:s.clone(),end:t.clone(),normal:o}}function rt(s){const t=[];for(let e=0;e<s.length-1;e++)t.push(ot(s[e],s[e+1]));return t}const ze=new WeakMap;function st(s,t){if(!s.mesh||s.mesh.positions.length===0||s.mesh.indices.length===0)return new Float32Array(0);let e=ze.get(s);e||(e=new u.BufferGeometry,e.setAttribute("position",new u.BufferAttribute(s.mesh.positions,3)),e.setIndex(new u.BufferAttribute(s.mesh.indices,1)),e.boundsTree=new Me.MeshBVH(e),ze.set(s,e));const o=e.boundsTree,r=[],i=new u.Line3;return o.shapecast({intersectsBounds:a=>t.intersectsBox(a),intersectsTriangle:a=>(it(a,t,i)&&r.push(i.start.x,i.start.y,i.start.z,i.end.x,i.end.y,i.end.z),!1)}),new Float32Array(r)}function it(s,t,e){const o=t.distanceToPoint(s.a),r=t.distanceToPoint(s.b),i=t.distanceToPoint(s.c);if(o>0&&r>0&&i>0||o<0&&r<0&&i<0||o===0&&r===0&&i===0)return!1;const a=[];if(xe(s.a,s.b,o,r,a),xe(s.b,s.c,r,i,a),xe(s.c,s.a,i,o,a),a.length>=2){e.start.copy(a[0]);let c=0,m=1;for(let p=1;p<a.length;p++){const x=a[0].distanceToSquared(a[p]);x>c&&(c=x,m=p)}return e.end.copy(a[m]),c>=1e-10}return!1}function xe(s,t,e,o,r){if(e*o<0){const i=e/(e-o);r.push(new u.Vector3().copy(s).lerp(t,i))}else Math.abs(e)<1e-5&&(r.length===0||r[r.length-1].distanceTo(s)>1e-5)&&r.push(s.clone())}function at(s,t,e){const o=[],r=new u.Vector3().subVectors(e,t),i=r.lengthSq();if(i<1e-6)return[];const a=(c,m,p)=>{const x=c-t.x,f=m-t.y,M=p-t.z;return(x*r.x+f*r.y+M*r.z)/i};for(let c=0;c<s.length;c+=6){const m=s[c],p=s[c+1],x=s[c+2],f=s[c+3],M=s[c+4],y=s[c+5],w=a(m,p,x),T=a(f,M,y);if(w>=0&&w<=1&&T>=0&&T<=1){o.push(m,p,x,f,M,y);continue}if(w<0&&T<0||w>1&&T>1)continue;const G=Math.min(w,T),F=Math.max(w,T),S=w<T?{x:m,y:p,z:x}:{x:f,y:M,z:y},U=w<T?{x:f,y:M,z:y}:{x:m,y:p,z:x},J=Math.max(G,0),Q=Math.min(F,1);if(J<Q){const O=F-G,E=(J-G)/O,I=(Q-G)/O;o.push(S.x+(U.x-S.x)*E,S.y+(U.y-S.y)*E,S.z+(U.z-S.z)*E,S.x+(U.x-S.x)*I,S.y+(U.y-S.y)*I,S.z+(U.z-S.z)*I)}}return o}function lt(s,t){if(t.length<2)return{results:[],allPositions:new Float32Array(0)};const e=rt(t),o=[],r=[];for(const i of s){const a=i.node;if(!a.mesh||a.mesh.positions.length===0)continue;const c=[];for(const m of e){const p=new u.Plane(m.normal.clone(),-m.normal.dot(m.start)),x=st(a,p);if(x.length>0){const f=at(x,m.start,m.end);f.length>0&&c.push(...f)}}if(c.length>0){o.push(...c);const m=[];for(let p=0;p<c.length;p+=6)m.push({start:{x:c[p],y:c[p+1],z:c[p+2]},end:{x:c[p+3],y:c[p+4],z:c[p+5]}});r.push({nodeName:a.name,nodeColor:a.color,segments:m})}}return{results:r,allPositions:new Float32Array(o)}}const ct={class:"geo-dialog-box"},dt={class:"geo-dialog-header"},ut={key:0,class:"geo-highlight-tag"},mt={class:"geo-dialog-body"},ft={key:0,class:"geo-no-result"},pt=n.defineComponent({__name:"SectionDialog",props:{visible:{type:Boolean},results:{},startPoint:{},endPoint:{}},emits:["close"],setup(s,{emit:t}){const e=s,o=t,r=n.ref(),i=n.ref();let a=1100,c=600;const m=n.ref(!1),p=n.ref(""),x=n.ref({}),f=n.ref(null);function M(b){const N=parseInt(b.slice(1,3),16),d=parseInt(b.slice(3,5),16),L=parseInt(b.slice(5,7),16),A=.7,C=Math.round(N*A),B=Math.round(d*A),q=Math.round(L*A);return`#${C.toString(16).padStart(2,"0")}${B.toString(16).padStart(2,"0")}${q.toString(16).padStart(2,"0")}`}const y=["#d32f2f","#1565c0","#2e7d32","#e65100","#6a1b9a","#00838f","#c62828","#283593","#1b5e20","#bf360c"];function w(b,N){const d=parseInt(b.slice(1,3),16),L=parseInt(b.slice(3,5),16),A=parseInt(b.slice(5,7),16);return(d*299+L*587+A*114)/1e3>180?y[N%y.length]:M(b)}function T(){o("close"),f.value=null}function G(){const b=r.value;if(!b)return;const N=b.toDataURL("image/png"),d=document.createElement("a");d.download=`剖面结果_${new Date().toISOString().slice(0,10)}.png`,d.href=N,d.click()}const F=[];n.watch(()=>e.visible,b=>ge(null,null,function*(){b&&(f.value=null,yield n.nextTick(),S())}));function S(){const b=r.value,N=i.value;if(!b||!N)return;const d=b.getContext("2d");if(!d)return;const L=N.clientWidth;a=Math.max(L,600),c=Math.round(a*.5);const A=window.devicePixelRatio||1;if(b.width=a*A,b.height=c*A,b.style.width=a+"px",b.style.height=c+"px",d.scale(A,A),d.clearRect(0,0,a,c),e.results.length===0)return;const C=e.endPoint.x-e.startPoint.x,B=e.endPoint.y-e.startPoint.y,q=Math.sqrt(C*C+B*B);if(q<1e-6)return;const k=C/q,j=B/q,ee=[];let $=1/0,te=-1/0,ne=1/0,Y=-1/0;if(e.results.forEach((g,l)=>{const h="#"+g.nodeColor.toString(16).padStart(6,"0"),v=w(h,l);for(const _ of g.segments){const V=(_.start.x-e.startPoint.x)*k+(_.start.y-e.startPoint.y)*j,D=_.start.z,R=(_.end.x-e.startPoint.x)*k+(_.end.y-e.startPoint.y)*j,z=_.end.z;ee.push({x1:V,z1:D,x2:R,z2:z,color:v,name:g.nodeName}),$=Math.min($,V,R),te=Math.max(te,V,R),ne=Math.min(ne,D,z),Y=Math.max(Y,D,z)}}),ee.length===0)return;const fe=te-$||1,pe=Y-ne||1,oe=70,P=30,re=30,ue=50,me=a-oe-P,se=c-re-ue,we=me/fe,he=se/pe,X=g=>oe+(g-$)*we,Z=g=>c-ue-(g-ne)*he;d.fillStyle="#fafafa",d.fillRect(0,0,a,c),d.strokeStyle="#bbb",d.lineWidth=1,d.strokeRect(oe,re,me,se);const ie=K(fe),ae=K(pe);d.strokeStyle="#e8e8e8",d.lineWidth=.5;for(let g=Math.ceil($/ie)*ie;g<=te;g+=ie){const l=X(g);d.beginPath(),d.moveTo(l,re),d.lineTo(l,c-ue),d.stroke()}for(let g=Math.ceil(ne/ae)*ae;g<=Y;g+=ae){const l=Z(g);d.beginPath(),d.moveTo(oe,l),d.lineTo(a-P,l),d.stroke()}d.fillStyle="#444",d.font="11px monospace",d.textAlign="center";for(let g=Math.ceil($/ie)*ie;g<=te;g+=ie)d.fillText(g.toFixed(0),X(g),c-ue+16);d.textAlign="right";for(let g=Math.ceil(ne/ae)*ae;g<=Y;g+=ae)d.fillText(g.toFixed(0),oe-6,Z(g)+4);d.fillStyle="#222",d.font="bold 13px sans-serif",d.textAlign="center",d.fillText("水平距离 (m)",oe+me/2,c-4),d.save(),d.translate(14,re+se/2),d.rotate(-Math.PI/2),d.fillText("标高 Z (m)",0,0),d.restore(),d.save(),d.beginPath(),d.rect(oe,re,me,se),d.clip();const de=f.value;if(de){d.lineWidth=1.5,d.globalAlpha=.2;for(const g of ee)g.name!==de&&(d.strokeStyle=g.color,d.beginPath(),d.moveTo(X(g.x1),Z(g.z1)),d.lineTo(X(g.x2),Z(g.z2)),d.stroke());d.globalAlpha=1}d.lineWidth=de?4:1.5,d.lineCap="round";for(const g of ee)de&&g.name!==de||(d.strokeStyle=g.color,d.beginPath(),d.moveTo(X(g.x1),Z(g.z1)),d.lineTo(X(g.x2),Z(g.z2)),d.stroke());d.restore(),F.length=0;for(const g of ee)F.push({sx1:X(g.x1),sy1:Z(g.z1),sx2:X(g.x2),sy2:Z(g.z2),name:g.name,color:g.color})}function U(b,N,d,L,A,C){const B=A-d,q=C-L,k=B*B+q*q;if(k<1e-6)return Math.hypot(b-d,N-L);let j=((b-d)*B+(N-L)*q)/k;return j=Math.max(0,Math.min(1,j)),Math.hypot(b-(d+j*B),N-(L+j*q))}function J(b){const d=r.value.getBoundingClientRect();return{mx:(b.clientX-d.left)*(a/d.width),my:(b.clientY-d.top)*(c/d.height),rect:d}}function Q(b,N){let d=1/0,L="",A="";for(const C of F){const B=U(b,N,C.sx1,C.sy1,C.sx2,C.sy2);B<d&&(d=B,L=C.name,A=C.color)}return{bestDist:d,bestName:L,bestColor:A}}function O(b){if(!r.value||F.length===0)return;const{mx:N,my:d,rect:L}=J(b),{bestDist:A,bestName:C,bestColor:B}=Q(N,d);A<12?(m.value=!0,p.value=C,x.value={left:b.clientX-L.left+14+"px",top:b.clientY-L.top-8+"px",borderLeft:`4px solid ${B}`},r.value.style.cursor="pointer"):(m.value=!1,r.value.style.cursor="default")}function E(){m.value=!1}function I(b){if(!r.value||F.length===0)return;const{mx:N,my:d}=J(b),{bestDist:L,bestName:A}=Q(N,d);L<12?f.value=f.value===A?null:A:f.value=null,S()}function K(b){const N=b/8,d=Math.pow(10,Math.floor(Math.log10(N))),L=N/d;return L<1.5?d:L<3.5?2*d:L<7.5?5*d:10*d}return(b,N)=>s.visible?(n.openBlock(),n.createElementBlock("div",{key:0,class:"geo-dialog-overlay",onClick:n.withModifiers(T,["self"])},[n.createElementVNode("div",ct,[n.createElementVNode("div",dt,[N[0]||(N[0]=n.createElementVNode("span",{class:"geo-dialog-title"},"剖面结果",-1)),f.value?(n.openBlock(),n.createElementBlock("span",ut,n.toDisplayString(f.value),1)):n.createCommentVNode("",!0),n.createElementVNode("button",{class:"geo-export-btn",onClick:G,title:"导出图片"},"💾 导出图片"),n.createElementVNode("button",{class:"geo-dialog-close",onClick:T},"×")]),n.createElementVNode("div",mt,[n.createElementVNode("div",{class:"geo-canvas-wrap",ref_key:"canvasWrapRef",ref:i},[n.createElementVNode("canvas",{ref_key:"canvasRef",ref:r,onMousemove:O,onMouseleave:E,onClick:I},null,544),m.value?(n.openBlock(),n.createElementBlock("div",{key:0,class:"geo-canvas-tooltip",style:n.normalizeStyle(x.value)},n.toDisplayString(p.value),5)):n.createCommentVNode("",!0)],512),s.results.length===0?(n.openBlock(),n.createElementBlock("div",ft,"该剖切线未与任何模型相交")):n.createCommentVNode("",!0)])])])):n.createCommentVNode("",!0)}}),ht=Ee._export_sfc(pt,[["__scopeId","data-v-cf4a02c5"]]),vt={class:"lw-map-area"},gt={key:0,class:"lw-model-loading"},yt={key:1,class:"lw-section-hint"},wt={key:2,class:"lw-model-dropdown"},bt={key:0,class:"lw-model-panel"},kt=["checked"],xt=["onClick"],Et=["checked"],Mt={class:"lw-device-arrow"},_t={key:0,class:"lw-device-grid"},St=["onClick"],Nt={key:0,class:"lw-device-check"},Lt={class:"lw-device-name"},At=n.defineComponent({__name:"MonitoringMap",props:{mapScene:{},devices:{},mobileObjects:{},affectedAreas:{},currentWarning:{},warningAreaColor:{default:"#ff6600"},warningAreaFillOpacity:{default:.08},showModelToggle:{type:Boolean,default:!0},showDeviceToggle:{type:Boolean,default:!0},g3dFileUrl:{default:""},dtmModelUrl:{default:""},uavTileUrl:{default:""}},emits:["select-device","select-object","toggle-model"],setup(s,{expose:t,emit:e}){const o=s,r=e,i=n.ref(),a=n.ref(),c=n.ref(!1),m=n.ref(!1),p=n.ref(!1),x=n.ref(""),f=n.ref("none"),M=n.ref({x:0,y:0,z:0}),y=n.ref({x:0,y:0,z:0}),w=n.ref([]),T=n.ref(!1);let G={x:0,y:0};const F=[{key:"geological_model",label:"地质模型"},{key:"dtm_surface",label:"DTM面"},{key:"drone_map",label:"无人机地图"}],S=n.reactive(new Set(["drone_map"])),U=n.computed(()=>S.size===F.length);function J(l){S.has(l)?S.delete(l):S.add(l),b(),r("toggle-model")}function Q(){U.value?S.clear():F.forEach(l=>S.add(l.key)),b(),r("toggle-model")}let O=null,E=null,I=null;const K=n.computed(()=>S.has("geological_model")||S.has("dtm_surface"));function b(){return ge(this,null,function*(){if(S.has("geological_model")||S.has("dtm_surface")){if(!E&&a.value&&(yield n.nextTick(),E=new je(a.value)),S.has("geological_model")&&o.g3dFileUrl&&E)try{p.value=!0,x.value="加载地质模型...";const h=yield fetch(o.g3dFileUrl);if(!h.ok)throw new Error(`HTTP ${h.status}: ${h.statusText}`);x.value="读取模型数据...";const v=yield h.text();x.value="解析模型...";const _=Ye(v);yield E.loadDocument(_,V=>{x.value=V})}catch(h){console.error("[MonitoringMap] 加载地质模型失败:",h)}finally{p.value=!1}E&&ae()}else E&&E.removeAllDeviceMarkers(),k&&setTimeout(()=>k==null?void 0:k.invalidateSize(),100);if(S.has("drone_map")&&k){if(!I){const h=o.uavTileUrl||ne.satellite;I=H.L.tileLayer(h,{maxZoom:19,opacity:.85}).addTo(k)}}else I&&k&&(k.removeLayer(I),I=null)})}function N(){if(!E){alert("请先勾选「地质模型」加载 3D 模型后再进行剖面绘制");return}E.clearPickMarkers(),E.clearSectionResults(),f.value="start",T.value=!1,w.value=[],L()}function d(){f.value="none",E==null||E.clearPickMarkers(),A()}function L(){if(!E)return;const l=E.renderer.domElement;l.addEventListener("mousedown",C),l.addEventListener("mouseup",B)}function A(){if(!E)return;const l=E.renderer.domElement;l.removeEventListener("mousedown",C),l.removeEventListener("mouseup",B)}function C(l){G={x:l.clientX,y:l.clientY}}function B(l){if(!E||f.value==="none"||Math.hypot(l.clientX-G.x,l.clientY-G.y)>5)return;const h=E.pickPoint(l);if(h){if(f.value==="start")M.value={x:h.x,y:h.y,z:h.z},E.addPickMarker(h,65280),f.value="end";else if(f.value==="end"){y.value={x:h.x,y:h.y,z:h.z},E.addPickMarker(h,16711680),f.value="none",A();const v=new u.Vector3(M.value.x,M.value.y,M.value.z),_=new u.Vector3(y.value.x,y.value.y,y.value.z);E.addSectionPath([v,_]);const V=E.getVisibleMeshEntries(),{results:D,allPositions:R}=lt(V,[v,_]);w.value=D,R.length>0&&D.forEach(z=>{const W=z.nodeColor,le=[];for(const ce of z.segments)le.push(ce.start.x,ce.start.y,ce.start.z,ce.end.x,ce.end.y,ce.end.z);le.length>0&&E.addSectionLines(new Float32Array(le),W)}),T.value=!0}}}t({startSection:N});const q={mounted(l,h){l.__clickOutsideHandler=v=>{l.contains(v.target)||h.value()},document.addEventListener("click",l.__clickOutsideHandler)},unmounted(l){document.removeEventListener("click",l.__clickOutsideHandler)}};let k=null,j=null,ee=null,$=null,te=null;const ne={dark:"https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png",light:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",satellite:"https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}",gaode:"https://webrd0{s}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}",gaode_satellite:"https://webst0{s}.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}"},Y=[{type:"GNSS",label:"GNSS监测",icon:"📍",color:"#ff6b6b",category:"device"},{type:"inclinometer",label:"深部位移监测",icon:"⚓",color:"#3b82f6",category:"device"},{type:"radar",label:"雷达监测",icon:"📡",color:"#8b5cf6",category:"device"},{type:"crack_image",label:"裂缝写实",icon:"�",color:"#06b6d4",category:"device"},{type:"crack",label:"裂缝监测",icon:"📏",color:"#f97316",category:"device"},{type:"combustion",label:"煤自燃监测",icon:"🔥",color:"#ef4444",category:"device"},{type:"rain",label:"降雨监测",icon:"💧",color:"#0ea5e9",category:"device"},{type:"groundwater",label:"地下水监测",icon:"�",color:"#14b8a6",category:"device"},{type:"stress",label:"地下应力监测",icon:"📊",color:"#eab308",category:"device"},{type:"vibration",label:"爆破震动监测",icon:"💥",color:"#f59e0b",category:"device"},{type:"remote_sensing",label:"遥感监测",icon:"🛰️",color:"#64748b",category:"device"},{type:"person",label:"人员",icon:"👤",color:"#78909c",category:"object"},{type:"truck",label:"车辆",icon:"🚛",color:"#5d9b46",category:"object"},{type:"excavator",label:"挖掘设备",icon:"🏗️",color:"#e8a735",category:"object"},{type:"drone",label:"无人机",icon:"🛸",color:"#7e57c2",category:"object"}],fe=Y.reduce((l,h)=>(l[h.type]=h.icon,l),{}),pe={person:"👤",truck:"🚛",excavator:"🏗️",drone:"🛸"},oe={normal:"#52c41a",warning:"#ff4d4f",offline:"#999",abnormal:"#faad14",near_warning_area:"#ff6600",in_warning_area:"#ff0000",evacuated:"#999"},P=n.reactive(new Set(Y.map(l=>l.type))),re=n.computed(()=>P.size===Y.length);function ue(l){P.has(l)?P.delete(l):P.add(l)}function me(){re.value?P.clear():Y.forEach(l=>P.add(l.type))}const se=n.computed(()=>o.devices.filter(l=>P.has(l.deviceType)));function we(){var _,V,D;if(k||!i.value)return;const l=o.mapScene;k=H.L.map(i.value,{center:[(_=l.centerLat)!=null?_:45.3738,(V=l.centerLng)!=null?V:119.3838],zoom:(D=l.zoom)!=null?D:15,zoomControl:!1,attributionControl:!1});const h=ne[l.tileStyle||"dark"]||ne.dark,v=(l.tileStyle||"dark").startsWith("gaode")?"1234":"abc";H.L.tileLayer(h,{attribution:"",maxZoom:18,subdomains:v}).addTo(k),te=H.L.layerGroup().addTo(k),j=H.L.layerGroup().addTo(k),ee=H.L.layerGroup().addTo(k),$=H.L.layerGroup().addTo(k),he(),setTimeout(()=>k==null?void 0:k.invalidateSize(),100),setTimeout(()=>k==null?void 0:k.invalidateSize(),400),setTimeout(()=>k==null?void 0:k.invalidateSize(),1e3),i.value&&(O=new ResizeObserver(()=>{setTimeout(()=>k==null?void 0:k.invalidateSize(),50)}),O.observe(i.value))}function he(){Z(),ie(),de(),g()}const X=["#ff4d4f","#3b82f6","#22c55e","#f59e0b","#8b5cf6","#06b6d4","#ec4899","#14b8a6","#f97316","#6366f1"];function Z(){if(!te||!k)return;te.clearLayers();const l=new Map;se.value.forEach(v=>{const _=v.lineId;!_||!v.lat||!v.lng||(l.has(_)||l.set(_,[]),l.get(_).push({lat:v.lat,lng:v.lng}))});let h=0;l.forEach((v,_)=>{if(v.length<2)return;v.sort((z,W)=>z.lng-W.lng||z.lat-W.lat);const V=v.map(z=>[z.lat,z.lng]),D=X[h%X.length];h++;const R=H.L.polyline(V,{color:D,weight:3,opacity:.85,dashArray:""});R.bindTooltip(_,{sticky:!0,direction:"top"}),te.addLayer(R)})}function ie(){!j||!k||(j.clearLayers(),se.value.forEach(l=>{var le,ce;const h=(le=l.lat)!=null?le:0,v=(ce=l.lng)!=null?ce:0;if(!h||!v)return;const _=fe[l.deviceType]||"📍",V=oe[l.status]||"#52c41a",D=l.warningLevel&&l.warningLevel>0,R=H.L.divIcon({className:"lw-marker-icon",html:`<div class="lw-marker" style="border-color:${V}">
|
|
2
2
|
<span class="lw-marker-emoji${D?" lw-pulse":""}">${_}</span>
|
|
3
3
|
<span class="lw-marker-label">${l.deviceName}</span>
|
|
4
4
|
</div>`,iconSize:[90,44],iconAnchor:[45,44]}),z=H.L.marker([h,v],{icon:R});z.on("click",()=>r("select-device",l)),z.bindTooltip(`<b>${l.deviceName}</b> (${l.deviceType})`,{direction:"top",offset:[0,-8]});const W=l.displayFields||[];if(W.length>0){const Te=W.map(be=>`<div class="lw-popup-row"><span class="lw-popup-label">${be.label}:</span> <span class="lw-popup-value">${be.value}</span> <span class="lw-popup-unit">${be.unit}</span></div>`).join("");z.bindPopup(`<div class="lw-popup-card"><div class="lw-popup-title">${l.deviceName}</div>${Te}</div>`,{className:"lw-device-popup",closeButton:!0,offset:[0,-10]})}j.addLayer(z)}))}function ae(){E&&(E.removeAllDeviceMarkers(),console.log("[3D markers] props.devices:",o.devices.length,"enabledTypes:",[...P],"visibleDevices:",se.value.length),console.log("[3D markers] devices detail:",o.devices.map(l=>({name:l.deviceName,type:l.deviceType,lng:l.lng,lat:l.lat,modelE:l.modelE,modelN:l.modelN,modelRL:l.modelRL}))),se.value.forEach(l=>{var z,W,le;const h=(z=l.modelE)!=null?z:0,v=(W=l.modelN)!=null?W:0,_=(le=l.modelRL)!=null?le:0;if(console.log(`[3D marker] ${l.deviceName}: E=${h}, N=${v}, RL=${_}`),!h&&!v)return;const V=fe[l.deviceType]||"📍",D=l.warningLevel&&l.warningLevel>0,R=document.createElement("div");R.className="lw-3d-marker",R.innerHTML=`
|