@cloud-app-dev/vidc 4.0.14 → 4.0.17
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/.dumirc.ts +2 -18
- package/.fatherrc.ts +0 -1
- package/.prettierrc.js +1 -1
- package/package.json +41 -33
- package/release-build.sh +1 -2
- package/es/AppContext/Sync.d.ts +0 -8
- package/es/AppContext/Sync.js +0 -44
- package/es/AppContext/index.d.ts +0 -10
- package/es/AppContext/index.js +0 -144
- package/es/AppContext/interface.d.ts +0 -41
- package/es/AppContext/static.d.ts +0 -8
- package/es/AppContext/static.js +0 -9
- package/es/Auth/index.d.ts +0 -8
- package/es/Auth/index.js +0 -18
- package/es/AutoExit/index.d.ts +0 -6
- package/es/AutoExit/index.js +0 -23
- package/es/CheckGroupFixed/demo.d.ts +0 -3
- package/es/CheckGroupFixed/demo.js +0 -25
- package/es/CheckGroupFixed/index.d.ts +0 -18
- package/es/CheckGroupFixed/index.js +0 -150
- package/es/CheckGroupFixed/index.less +0 -53
- package/es/Config/index.d.ts +0 -4
- package/es/Config/index.js +0 -77
- package/es/Config/interface.d.ts +0 -65
- package/es/Config/utils.d.ts +0 -4
- package/es/Config/utils.js +0 -33
- package/es/ConfigContext/index.d.ts +0 -22
- package/es/ConfigContext/index.js +0 -25
- package/es/CustomRenderSelect/index.d.ts +0 -12
- package/es/CustomRenderSelect/index.js +0 -83
- package/es/CustomRenderSelect/index.less +0 -25
- package/es/DBTools/index.d.ts +0 -25
- package/es/DBTools/index.js +0 -337
- package/es/DisableMark/index.d.ts +0 -9
- package/es/DisableMark/index.js +0 -22
- package/es/DisableMark/index.less +0 -9
- package/es/DomMove/demo.d.ts +0 -2
- package/es/DomMove/demo.js +0 -20
- package/es/DomMove/index.d.ts +0 -16
- package/es/DomMove/index.js +0 -149
- package/es/DomMove/utils.d.ts +0 -8
- package/es/DomMove/utils.js +0 -33
- package/es/Drag/DragAndDropItem.d.ts +0 -4
- package/es/Drag/DragAndDropItem.js +0 -133
- package/es/Drag/DropItem.d.ts +0 -4
- package/es/Drag/DropItem.js +0 -50
- package/es/Drag/index.d.ts +0 -7
- package/es/Drag/index.js +0 -7
- package/es/Drag/interface.d.ts +0 -16
- package/es/DynamicGridList/Demo.d.ts +0 -3
- package/es/DynamicGridList/Demo.js +0 -86
- package/es/DynamicGridList/index.d.ts +0 -27
- package/es/DynamicGridList/index.js +0 -71
- package/es/DynamicList/demo.d.ts +0 -2
- package/es/DynamicList/demo.js +0 -50
- package/es/DynamicList/index.d.ts +0 -31
- package/es/DynamicList/index.js +0 -96
- package/es/DynamicList/index.less +0 -17
- package/es/DynamicList/interface.d.ts +0 -19
- package/es/DynamicList/utils.d.ts +0 -4
- package/es/DynamicList/utils.js +0 -6
- package/es/ErrorFallback/index.d.ts +0 -9
- package/es/ErrorFallback/index.js +0 -38
- package/es/ErrorFallback/inerface.d.ts +0 -48
- package/es/EventTools/index.d.ts +0 -3
- package/es/EventTools/index.js +0 -12
- package/es/FrontendPlayer/index.d.ts +0 -4
- package/es/FrontendPlayer/index.js +0 -2
- package/es/FullScreen/index.d.ts +0 -22
- package/es/FullScreen/index.js +0 -36
- package/es/FullScreen/index.less +0 -18
- package/es/GridList/Demo.d.ts +0 -3
- package/es/GridList/Demo.js +0 -89
- package/es/GridList/data.d.ts +0 -16
- package/es/GridList/data.js +0 -609
- package/es/GridList/hook.d.ts +0 -13
- package/es/GridList/hook.js +0 -270
- package/es/GridList/index.d.ts +0 -15
- package/es/GridList/index.js +0 -48
- package/es/GridList/index.less +0 -8
- package/es/GridList/interface.d.ts +0 -59
- package/es/GridList/utils.d.ts +0 -9
- package/es/GridList/utils.js +0 -42
- package/es/HightLevel/index.d.ts +0 -9
- package/es/HightLevel/index.js +0 -21
- package/es/HightLevel/index.less +0 -3
- package/es/IconFont/index.d.ts +0 -12
- package/es/IconFont/index.js +0 -63
- package/es/ImageView/index.d.ts +0 -17
- package/es/ImageView/index.js +0 -58
- package/es/ImageView/index.less +0 -11
- package/es/InstanceHistory/index.d.ts +0 -3
- package/es/InstanceHistory/index.js +0 -7
- package/es/LabelPlayer/111.png +0 -0
- package/es/LabelPlayer/demo.d.ts +0 -2
- package/es/LabelPlayer/demo.js +0 -123
- package/es/LabelPlayer/index.d.ts +0 -21
- package/es/LabelPlayer/index.js +0 -169
- package/es/LabelPlayer/index.less +0 -24
- package/es/LabelValue/index.d.ts +0 -15
- package/es/LabelValue/index.js +0 -32
- package/es/LabelValue/index.less +0 -23
- package/es/List/demo.d.ts +0 -3
- package/es/List/demo.js +0 -26
- package/es/List/index.d.ts +0 -28
- package/es/List/index.js +0 -30
- package/es/List/index.less +0 -13
- package/es/ListWithSizeAnimate/demo.d.ts +0 -2
- package/es/ListWithSizeAnimate/demo.js +0 -128
- package/es/ListWithSizeAnimate/index.d.ts +0 -14
- package/es/ListWithSizeAnimate/index.js +0 -97
- package/es/ListWithSizeAnimate/index.less +0 -23
- package/es/LoaderScript/index.d.ts +0 -47
- package/es/LoaderScript/index.js +0 -38
- package/es/LoaderScript/utils.d.ts +0 -13
- package/es/LoaderScript/utils.js +0 -179
- package/es/Map/AMap.d.ts +0 -7109
- package/es/Map/BasicMap/AMapInstance.d.ts +0 -19
- package/es/Map/BasicMap/AMapInstance.js +0 -98
- package/es/Map/BasicMap/LeafletInstance.d.ts +0 -18
- package/es/Map/BasicMap/LeafletInstance.js +0 -111
- package/es/Map/BasicMap/index.d.ts +0 -9
- package/es/Map/BasicMap/index.js +0 -98
- package/es/Map/BasicMap/index.less +0 -29
- package/es/Map/ClusterLayer/demo.d.ts +0 -3
- package/es/Map/ClusterLayer/demo.js +0 -22
- package/es/Map/ClusterLayer/hook.d.ts +0 -5
- package/es/Map/ClusterLayer/hook.js +0 -124
- package/es/Map/ClusterLayer/index.d.ts +0 -6
- package/es/Map/ClusterLayer/index.js +0 -32
- package/es/Map/ClusterLayer/index.less +0 -29
- package/es/Map/ClusterLayer/props.d.ts +0 -8
- package/es/Map/Config/index.d.ts +0 -9
- package/es/Map/Config/index.js +0 -52
- package/es/Map/Config/utils.d.ts +0 -2
- package/es/Map/Config/utils.js +0 -65
- package/es/Map/Context/index.d.ts +0 -11
- package/es/Map/Context/index.js +0 -56
- package/es/Map/FindPio/index.d.ts +0 -4
- package/es/Map/FindPio/index.js +0 -14
- package/es/Map/FindPio/index.less +0 -7
- package/es/Map/InfoWindow/MakerLikeWindow.d.ts +0 -4
- package/es/Map/InfoWindow/MakerLikeWindow.js +0 -113
- package/es/Map/InfoWindow/demo.d.ts +0 -3
- package/es/Map/InfoWindow/demo.js +0 -76
- package/es/Map/InfoWindow/index.d.ts +0 -11
- package/es/Map/InfoWindow/index.js +0 -67
- package/es/Map/LevelCenter/DragMarker/index.d.ts +0 -10
- package/es/Map/LevelCenter/DragMarker/index.js +0 -44
- package/es/Map/LevelCenter/demo.d.ts +0 -3
- package/es/Map/LevelCenter/demo.js +0 -46
- package/es/Map/LevelCenter/index.d.ts +0 -15
- package/es/Map/LevelCenter/index.js +0 -71
- package/es/Map/LoaderMap/index.d.ts +0 -12
- package/es/Map/LoaderMap/index.js +0 -71
- package/es/Map/MapDrawSelect/demo.d.ts +0 -3
- package/es/Map/MapDrawSelect/demo.js +0 -79
- package/es/Map/MapDrawSelect/index.d.ts +0 -15
- package/es/Map/MapDrawSelect/index.js +0 -62
- package/es/Map/MouseTool/index.d.ts +0 -10
- package/es/Map/MouseTool/index.js +0 -44
- package/es/Map/MouseTool/useMouseTools.d.ts +0 -7
- package/es/Map/MouseTool/useMouseTools.js +0 -83
- package/es/Map/ResetTools/index.d.ts +0 -10
- package/es/Map/ResetTools/index.js +0 -67
- package/es/Map/ResetTools/index.less +0 -39
- package/es/Map/SinglePoint/demo.d.ts +0 -3
- package/es/Map/SinglePoint/demo.js +0 -16
- package/es/Map/SinglePoint/index.d.ts +0 -27
- package/es/Map/SinglePoint/index.js +0 -57
- package/es/Map/SinglePoint/index.less +0 -41
- package/es/Map/hook/useMapEvent.d.ts +0 -2
- package/es/Map/hook/useMapEvent.js +0 -19
- package/es/Map/hook/useMapType.d.ts +0 -4
- package/es/Map/hook/useMapType.js +0 -12
- package/es/Map/icon.d.ts +0 -2
- package/es/Map/icon.js +0 -10
- package/es/Map/index.d.ts +0 -24
- package/es/Map/index.js +0 -25
- package/es/Map/interface.d.ts +0 -74
- package/es/Map/points.d.ts +0 -74
- package/es/Map/points.js +0 -1
- package/es/Map/useMarker/index.d.ts +0 -10
- package/es/Map/useMarker/index.js +0 -71
- package/es/Map/withMap/index.d.ts +0 -3
- package/es/Map/withMap/index.js +0 -18
- package/es/Map3D/demo.d.ts +0 -3
- package/es/Map3D/demo.js +0 -13
- package/es/Map3D/index.d.ts +0 -4
- package/es/Map3D/index.js +0 -84
- package/es/Map3D/index.less +0 -4
- package/es/Picture/component/DefaultRects/RectInfo.d.ts +0 -8
- package/es/Picture/component/DefaultRects/RectInfo.js +0 -88
- package/es/Picture/component/DefaultRects/index.d.ts +0 -13
- package/es/Picture/component/DefaultRects/index.js +0 -58
- package/es/Picture/component/DefaultRects/index.less +0 -211
- package/es/Picture/component/DefaultRects/utils.d.ts +0 -2
- package/es/Picture/component/DefaultRects/utils.js +0 -11
- package/es/Picture/component/DrawRect/index.d.ts +0 -13
- package/es/Picture/component/DrawRect/index.js +0 -51
- package/es/Picture/component/DrawRect/index.less +0 -8
- package/es/Picture/component/RectMenu/index.d.ts +0 -12
- package/es/Picture/component/RectMenu/index.js +0 -79
- package/es/Picture/component/RectMenu/index.less +0 -36
- package/es/Picture/component/RectMenu/utils.d.ts +0 -12
- package/es/Picture/component/RectMenu/utils.js +0 -19
- package/es/Picture/component/Tools/index.d.ts +0 -12
- package/es/Picture/component/Tools/index.js +0 -93
- package/es/Picture/component/Tools/index.less +0 -49
- package/es/Picture/component/WheelScale/index.d.ts +0 -7
- package/es/Picture/component/WheelScale/index.js +0 -29
- package/es/Picture/demo.d.ts +0 -2
- package/es/Picture/demo.js +0 -113
- package/es/Picture/index.d.ts +0 -19
- package/es/Picture/index.js +0 -354
- package/es/Picture/index.less +0 -20
- package/es/Picture/interface.d.ts +0 -196
- package/es/Picture/loadCaptureRectImage.d.ts +0 -3
- package/es/Picture/loadCaptureRectImage.js +0 -99
- package/es/Picture/useDraw.d.ts +0 -1
- package/es/Picture/useDraw.js +0 -103
- package/es/Picture/utils.d.ts +0 -26
- package/es/Picture/utils.js +0 -143
- package/es/Player/api/index.d.ts +0 -68
- package/es/Player/api/index.js +0 -283
- package/es/Player/context.d.ts +0 -21
- package/es/Player/context.js +0 -25
- package/es/Player/contraller_bar/bar.d.ts +0 -8
- package/es/Player/contraller_bar/bar.js +0 -28
- package/es/Player/contraller_bar/contraller_event.d.ts +0 -6
- package/es/Player/contraller_bar/contraller_event.js +0 -53
- package/es/Player/contraller_bar/index.d.ts +0 -14
- package/es/Player/contraller_bar/index.js +0 -33
- package/es/Player/contraller_bar/left_bar.d.ts +0 -10
- package/es/Player/contraller_bar/left_bar.js +0 -88
- package/es/Player/contraller_bar/right_bar.d.ts +0 -8
- package/es/Player/contraller_bar/right_bar.js +0 -37
- package/es/Player/contraller_bar/time.d.ts +0 -3
- package/es/Player/contraller_bar/time.js +0 -21
- package/es/Player/contraller_bar/useBarStatus.d.ts +0 -2
- package/es/Player/contraller_bar/useBarStatus.js +0 -43
- package/es/Player/contraller_bar/volume.d.ts +0 -9
- package/es/Player/contraller_bar/volume.js +0 -65
- package/es/Player/demo.d.ts +0 -3
- package/es/Player/demo.js +0 -277
- package/es/Player/empty.d.ts +0 -2
- package/es/Player/empty.js +0 -6
- package/es/Player/event/errorEvent.d.ts +0 -14
- package/es/Player/event/errorEvent.js +0 -88
- package/es/Player/event/eventName.d.ts +0 -18
- package/es/Player/event/eventName.js +0 -30
- package/es/Player/event/index.d.ts +0 -24
- package/es/Player/event/index.js +0 -204
- package/es/Player/fps_play.d.ts +0 -11
- package/es/Player/fps_play.js +0 -84
- package/es/Player/frontend_player.d.ts +0 -8
- package/es/Player/frontend_player.js +0 -72
- package/es/Player/frontend_timeline.d.ts +0 -10
- package/es/Player/frontend_timeline.js +0 -145
- package/es/Player/iconfont.d.ts +0 -5
- package/es/Player/iconfont.js +0 -22
- package/es/Player/index.d.ts +0 -2
- package/es/Player/index.js +0 -2
- package/es/Player/live_heart.d.ts +0 -8
- package/es/Player/live_heart.js +0 -46
- package/es/Player/message.d.ts +0 -5
- package/es/Player/message.js +0 -138
- package/es/Player/player.d.ts +0 -231
- package/es/Player/segment_player.d.ts +0 -9
- package/es/Player/segment_player.js +0 -230
- package/es/Player/segment_timeline.d.ts +0 -12
- package/es/Player/segment_timeline.js +0 -190
- package/es/Player/single_player.d.ts +0 -5
- package/es/Player/single_player.js +0 -290
- package/es/Player/style/bar.less +0 -43
- package/es/Player/style/iconfont.js +0 -43
- package/es/Player/style/index.less +0 -34
- package/es/Player/style/message.less +0 -56
- package/es/Player/style/slider.less +0 -106
- package/es/Player/style/timeline.less +0 -116
- package/es/Player/style/volume.less +0 -24
- package/es/Player/timeline.d.ts +0 -5
- package/es/Player/timeline.js +0 -98
- package/es/Player/util.d.ts +0 -42
- package/es/Player/util.js +0 -172
- package/es/PlayerExt/demo.d.ts +0 -3
- package/es/PlayerExt/demo.js +0 -170
- package/es/PlayerExt/index.d.ts +0 -48
- package/es/PlayerExt/index.js +0 -207
- package/es/PlayerExt/index.less +0 -10
- package/es/Progress/index.d.ts +0 -12
- package/es/Progress/index.js +0 -56
- package/es/Progress/index.less +0 -21
- package/es/ROI/demo.d.ts +0 -3
- package/es/ROI/demo.js +0 -18
- package/es/ROI/index.d.ts +0 -33
- package/es/ROI/index.js +0 -57
- package/es/ROI/index.less +0 -33
- package/es/RefDrawer/Footer.d.ts +0 -9
- package/es/RefDrawer/Footer.js +0 -27
- package/es/RefDrawer/demo.d.ts +0 -3
- package/es/RefDrawer/demo.js +0 -32
- package/es/RefDrawer/index.d.ts +0 -26
- package/es/RefDrawer/index.js +0 -73
- package/es/RefModal/demo.d.ts +0 -3
- package/es/RefModal/demo.js +0 -32
- package/es/RefModal/index.d.ts +0 -17
- package/es/RefModal/index.js +0 -71
- package/es/ScreenPlayer/Live.d.ts +0 -10
- package/es/ScreenPlayer/Live.js +0 -220
- package/es/ScreenPlayer/LiveTools.d.ts +0 -29
- package/es/ScreenPlayer/LiveTools.js +0 -167
- package/es/ScreenPlayer/PlayerWithExt.d.ts +0 -34
- package/es/ScreenPlayer/PlayerWithExt.js +0 -240
- package/es/ScreenPlayer/RatePick.d.ts +0 -8
- package/es/ScreenPlayer/RatePick.js +0 -30
- package/es/ScreenPlayer/Record.d.ts +0 -10
- package/es/ScreenPlayer/Record.js +0 -447
- package/es/ScreenPlayer/RecordTools.d.ts +0 -38
- package/es/ScreenPlayer/RecordTools.js +0 -216
- package/es/ScreenPlayer/ScreenSelect.d.ts +0 -7
- package/es/ScreenPlayer/ScreenSelect.js +0 -51
- package/es/ScreenPlayer/SegmentTimeLine.d.ts +0 -17
- package/es/ScreenPlayer/SegmentTimeLine.js +0 -38
- package/es/ScreenPlayer/TimeMode.d.ts +0 -7
- package/es/ScreenPlayer/TimeMode.js +0 -30
- package/es/ScreenPlayer/TimeSelect.d.ts +0 -7
- package/es/ScreenPlayer/TimeSelect.js +0 -94
- package/es/ScreenPlayer/demo.d.ts +0 -2
- package/es/ScreenPlayer/demo.js +0 -24
- package/es/ScreenPlayer/demo2.d.ts +0 -2
- package/es/ScreenPlayer/demo2.js +0 -200
- package/es/ScreenPlayer/index.d.ts +0 -6
- package/es/ScreenPlayer/index.js +0 -9
- package/es/ScreenPlayer/index.less +0 -335
- package/es/ScreenPlayer/interface.d.ts +0 -216
- package/es/ScreenPlayer/useTimeSlider.d.ts +0 -25
- package/es/ScreenPlayer/useTimeSlider.js +0 -450
- package/es/ScreenPlayer/useVideoFit.d.ts +0 -5
- package/es/ScreenPlayer/useVideoFit.js +0 -35
- package/es/ScreenPlayer/utils.d.ts +0 -17
- package/es/ScreenPlayer/utils.js +0 -85
- package/es/SegmentPlayer/index.d.ts +0 -2
- package/es/SegmentPlayer/index.js +0 -2
- package/es/Service/http.d.ts +0 -6
- package/es/Service/http.js +0 -125
- package/es/Service/index.d.ts +0 -3
- package/es/Service/index.js +0 -10
- package/es/Service/interface.d.ts +0 -22
- package/es/Service/middleware.d.ts +0 -5
- package/es/Service/middleware.js +0 -15
- package/es/SocketEmitter/eventEmitter.d.ts +0 -27
- package/es/SocketEmitter/eventEmitter.js +0 -88
- package/es/SocketEmitter/index.d.ts +0 -24
- package/es/SocketEmitter/index.js +0 -125
- package/es/SocketEmitter/interface.d.ts +0 -4
- package/es/TableLayout/index.d.ts +0 -10
- package/es/TableLayout/index.js +0 -29
- package/es/TableLayout/index.less +0 -4
- package/es/ThemeAntd/demo.d.ts +0 -4
- package/es/ThemeAntd/demo.js +0 -129
- package/es/ThemeAntd/demo.less +0 -20
- package/es/ThemeAntd/index.d.ts +0 -7
- package/es/ThemeAntd/index.js +0 -23
- package/es/ThemeAntd/index.less +0 -4
- package/es/Timeout/index.d.ts +0 -32
- package/es/Timeout/index.js +0 -70
- package/es/VList/index.d.ts +0 -11
- package/es/VList/index.js +0 -42
- package/es/VList/index.less +0 -6
- package/es/VList/utils.d.ts +0 -14
- package/es/VList/utils.js +0 -17
- package/es/bigNumberTransformCN/index.d.ts +0 -5
- package/es/bigNumberTransformCN/index.js +0 -60
- package/es/cache/index.d.ts +0 -34
- package/es/cache/index.js +0 -94
- package/es/copy/index.d.ts +0 -1
- package/es/copy/index.js +0 -9
- package/es/core.d.ts +0 -0
- package/es/getThemeStyle/index.d.ts +0 -2
- package/es/getThemeStyle/index.js +0 -5
- package/es/index.d.ts +0 -61
- package/es/index.js +0 -61
- package/es/logger/index.d.ts +0 -7
- package/es/logger/index.js +0 -30
- package/es/nextTick/index.d.ts +0 -1
- package/es/nextTick/index.js +0 -7
- package/es/submidstr/index.d.ts +0 -5
- package/es/submidstr/index.js +0 -14
- package/es/treeHelper/index.d.ts +0 -11
- package/es/treeHelper/index.js +0 -189
- package/es/typings.d.ts +0 -2
- package/es/useDrawROI/index.d.ts +0 -16
- package/es/useDrawROI/index.js +0 -322
- package/es/useEventEmitterHandle/index.d.ts +0 -2
- package/es/useEventEmitterHandle/index.js +0 -17
- package/es/useFullscreen/demo.d.ts +0 -2
- package/es/useFullscreen/demo.js +0 -48
- package/es/useFullscreen/index.d.ts +0 -12
- package/es/useFullscreen/index.js +0 -76
- package/es/useHistory/index.d.ts +0 -3
- package/es/useHistory/index.js +0 -9
- package/es/useHistory/interface.d.ts +0 -3
- package/es/useInfiniteScroll/index.d.ts +0 -16
- package/es/useInfiniteScroll/index.js +0 -101
- package/es/useRafInterval/index.d.ts +0 -5
- package/es/useRafInterval/index.js +0 -70
- package/es/useSimpleState/index.d.ts +0 -3
- package/es/useSimpleState/index.js +0 -36
- package/es/useVirtualList/index.d.ts +0 -13
- package/es/useVirtualList/index.js +0 -139
- package/es/utils.d.ts +0 -14
- package/es/utils.js +0 -75
- package/es/uuid/index.d.ts +0 -4
- package/es/uuid/index.js +0 -15
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
2
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
4
|
-
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
5
|
-
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
6
|
-
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
7
|
-
import React, { useCallback, useMemo } from 'react';
|
|
8
|
-
import RectMenu from "../RectMenu";
|
|
9
|
-
import "./index.less";
|
|
10
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
11
|
-
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
12
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
|
-
function DrawRect(_ref) {
|
|
14
|
-
var _ref$rect = _ref.rect,
|
|
15
|
-
rect = _ref$rect === void 0 ? [] : _ref$rect,
|
|
16
|
-
canRenderMenu = _ref.canRenderMenu,
|
|
17
|
-
containerDom = _ref.containerDom,
|
|
18
|
-
onMenuClick = _ref.onMenuClick,
|
|
19
|
-
menus = _ref.menus,
|
|
20
|
-
getRectImage = _ref.getRectImage;
|
|
21
|
-
var x = useMemo(function () {
|
|
22
|
-
return rect[0] + rect[2];
|
|
23
|
-
}, [rect]);
|
|
24
|
-
var y = useMemo(function () {
|
|
25
|
-
return rect[1] + rect[3];
|
|
26
|
-
}, [rect]);
|
|
27
|
-
var onMenuClickAction = useCallback(function (item) {
|
|
28
|
-
var _getRectImage;
|
|
29
|
-
onMenuClick === null || onMenuClick === void 0 ? void 0 : onMenuClick(_objectSpread(_objectSpread({}, item), {}, {
|
|
30
|
-
base64: (_getRectImage = getRectImage(rect)) !== null && _getRectImage !== void 0 ? _getRectImage : ''
|
|
31
|
-
}));
|
|
32
|
-
}, [getRectImage, onMenuClick, rect]);
|
|
33
|
-
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
34
|
-
children: [/*#__PURE__*/_jsx("div", {
|
|
35
|
-
className: "select-rect-layout",
|
|
36
|
-
style: {
|
|
37
|
-
left: rect[0],
|
|
38
|
-
top: rect[1],
|
|
39
|
-
width: rect[2],
|
|
40
|
-
height: rect[3]
|
|
41
|
-
}
|
|
42
|
-
}), canRenderMenu && /*#__PURE__*/_jsx(RectMenu, {
|
|
43
|
-
x: x,
|
|
44
|
-
y: y,
|
|
45
|
-
containerDom: containerDom,
|
|
46
|
-
onMenuClick: onMenuClickAction,
|
|
47
|
-
menus: menus
|
|
48
|
-
})]
|
|
49
|
-
});
|
|
50
|
-
}
|
|
51
|
-
export default DrawRect;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
.select-rect-layout {
|
|
2
|
-
position: absolute;
|
|
3
|
-
border: 1px solid;
|
|
4
|
-
box-shadow: 0 0 0 9999em rgb(0 0 0 / 40%);
|
|
5
|
-
border-image-source: url('data:image/gif;base64,R0lGODlhCgAKAJECAAAAAP///////wAAACH/C05FVFNDQVBFMi4wAwEAAAAh/wtYTVAgRGF0YVhNUDw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMy1jMDExIDY2LjE0NTY2MSwgMjAxMi8wMi8wNi0xNDo1NjoyNyAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6OEI5RDc5MTFDNkE2MTFFM0JCMDZEODI2QTI4MzJBOTIiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6OEI5RDc5MTBDNkE2MTFFM0JCMDZEODI2QTI4MzJBOTIiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNiAoTWFjaW50b3NoKSI+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuZGlkOjAyODAxMTc0MDcyMDY4MTE4MDgzQzNDMjA5MzREQ0ZDIiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjAyODAxMTc0MDcyMDY4MTE4MDgzQzNDMjA5MzREQ0ZDIi8+IDwvcmRmOkRlc2NyaXB0aW9uPiA8L3JkZjpSREY+IDwveDp4bXBtZXRhPiA8P3hwYWNrZXQgZW5kPSJyIj8+Af/+/fz7+vn49/b19PPy8fDv7u3s6+rp6Ofm5eTj4uHg397d3Nva2djX1tXU09LR0M/OzczLysnIx8bFxMPCwcC/vr28u7q5uLe2tbSzsrGwr66trKuqqainpqWko6KhoJ+enZybmpmYl5aVlJOSkZCPjo2Mi4qJiIeGhYSDgoGAf359fHt6eXh3dnV0c3JxcG9ubWxramloZ2ZlZGNiYWBfXl1cW1pZWFdWVVRTUlFQT05NTEtKSUhHRkVEQ0JBQD8+PTw7Ojk4NzY1NDMyMTAvLi0sKyopKCcmJSQjIiEgHx4dHBsaGRgXFhUUExIREA8ODQwLCgkIBwYFBAMCAQAAIfkEBQoAAgAsAAAAAAoACgAAAhWEERkn7W3ei7KlagMWF/dKgYeyGAUAIfkEBQoAAgAsAAAAAAoACgAAAg+UYwLJ7RnQm7QmsCyVKhUAIfkEBQoAAgAsAAAAAAoACgAAAhCUYgLJHdiinNSAVfOEKoUCACH5BAUKAAIALAAAAAAKAAoAAAIRVISAdusPo3RAzYtjaMIaUQAAIfkEBQoAAgAsAAAAAAoACgAAAg+MDiem7Q8bSLFaG5il6xQAIfkEBQoAAgAsAAAAAAoACgAAAg+UYRLJ7QnQm7SmsCyVKhUAIfkEBQoAAgAsAAAAAAoACgAAAhCUYBLJDdiinNSEVfOEKoECACH5BAUKAAIALAAAAAAKAAoAAAIRFISBdusPo3RBzYsjaMIaUQAAOw==');
|
|
6
|
-
border-image-repeat: repeat;
|
|
7
|
-
border-image-slice: 1;
|
|
8
|
-
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { MenuRectType } from '../../../Picture/interface';
|
|
3
|
-
import './index.less';
|
|
4
|
-
interface IRectMenuProps {
|
|
5
|
-
x: number;
|
|
6
|
-
y: number;
|
|
7
|
-
menus: MenuRectType[];
|
|
8
|
-
containerDom: HTMLDivElement;
|
|
9
|
-
onMenuClick: (options: MenuRectType) => void;
|
|
10
|
-
}
|
|
11
|
-
declare function RectMenu({ x, y, menus, containerDom, onMenuClick }: IRectMenuProps): JSX.Element;
|
|
12
|
-
export default RectMenu;
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
import React, { useCallback, useMemo, useRef, useEffect } from 'react';
|
|
2
|
-
import IconFont from "../../../IconFont";
|
|
3
|
-
import { computedMenuPosition } from "./utils";
|
|
4
|
-
import "./index.less";
|
|
5
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
6
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
7
|
-
var MENU_WIDTH = 110;
|
|
8
|
-
var MENU_HEIGHT = 30;
|
|
9
|
-
function RectMenu(_ref) {
|
|
10
|
-
var x = _ref.x,
|
|
11
|
-
y = _ref.y,
|
|
12
|
-
menus = _ref.menus,
|
|
13
|
-
containerDom = _ref.containerDom,
|
|
14
|
-
onMenuClick = _ref.onMenuClick;
|
|
15
|
-
var _useMemo = useMemo(function () {
|
|
16
|
-
return containerDom.getBoundingClientRect();
|
|
17
|
-
}, [containerDom]),
|
|
18
|
-
width = _useMemo.width,
|
|
19
|
-
height = _useMemo.height;
|
|
20
|
-
var size = useMemo(function () {
|
|
21
|
-
return {
|
|
22
|
-
w: MENU_WIDTH,
|
|
23
|
-
h: MENU_HEIGHT * menus.length
|
|
24
|
-
};
|
|
25
|
-
}, [menus.length]);
|
|
26
|
-
var position = useMemo(function () {
|
|
27
|
-
return computedMenuPosition({
|
|
28
|
-
width: width,
|
|
29
|
-
height: height,
|
|
30
|
-
size: size,
|
|
31
|
-
position: [x, y]
|
|
32
|
-
});
|
|
33
|
-
}, [height, size, width, x, y]);
|
|
34
|
-
var domRef = useRef(null);
|
|
35
|
-
var handleCancelB = useCallback(function (e) {
|
|
36
|
-
return e.stopPropagation();
|
|
37
|
-
}, []);
|
|
38
|
-
|
|
39
|
-
//防止click事件冒泡到查看器
|
|
40
|
-
useEffect(function () {
|
|
41
|
-
var dom = domRef.current;
|
|
42
|
-
if (dom) {
|
|
43
|
-
dom.addEventListener('mousedown', handleCancelB, false);
|
|
44
|
-
dom.addEventListener('mousemove', handleCancelB, false);
|
|
45
|
-
dom.addEventListener('mouseup', handleCancelB, false);
|
|
46
|
-
}
|
|
47
|
-
return function () {
|
|
48
|
-
if (dom) {
|
|
49
|
-
dom.removeEventListener('mousedown', handleCancelB, false);
|
|
50
|
-
dom.removeEventListener('mousemove', handleCancelB, false);
|
|
51
|
-
dom.removeEventListener('mouseup', handleCancelB, false);
|
|
52
|
-
}
|
|
53
|
-
};
|
|
54
|
-
}, [handleCancelB]);
|
|
55
|
-
var onClickMenu = useCallback(function (e, item) {
|
|
56
|
-
e.stopPropagation();
|
|
57
|
-
onMenuClick === null || onMenuClick === void 0 ? void 0 : onMenuClick(item);
|
|
58
|
-
}, [onMenuClick]);
|
|
59
|
-
return /*#__PURE__*/_jsx("div", {
|
|
60
|
-
className: "select-rect-menu-layout",
|
|
61
|
-
style: {
|
|
62
|
-
left: position.x,
|
|
63
|
-
top: position.y
|
|
64
|
-
},
|
|
65
|
-
ref: domRef,
|
|
66
|
-
children: menus.map(function (v) {
|
|
67
|
-
return /*#__PURE__*/_jsxs("div", {
|
|
68
|
-
className: "menu-action-item",
|
|
69
|
-
onClick: function onClick(e) {
|
|
70
|
-
return onClickMenu(e, v);
|
|
71
|
-
},
|
|
72
|
-
children: [/*#__PURE__*/_jsx(IconFont, {
|
|
73
|
-
type: v.icon
|
|
74
|
-
}), v.title]
|
|
75
|
-
}, v.pathname);
|
|
76
|
-
})
|
|
77
|
-
});
|
|
78
|
-
}
|
|
79
|
-
export default RectMenu;
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
.select-rect-menu-layout {
|
|
2
|
-
position: absolute;
|
|
3
|
-
width: 105px;
|
|
4
|
-
overflow: hidden;
|
|
5
|
-
font-size: var(--fs-small);
|
|
6
|
-
|
|
7
|
-
.menu-action-item {
|
|
8
|
-
padding: 4px 10px;
|
|
9
|
-
margin-bottom: 4px;
|
|
10
|
-
color: rgb(0 0 0 / 65%);
|
|
11
|
-
white-space: nowrap;
|
|
12
|
-
background: #fff;
|
|
13
|
-
border-radius: 15px;
|
|
14
|
-
box-shadow: 0 0 2px rgb(0 0 0 / 20%);
|
|
15
|
-
|
|
16
|
-
.anticon {
|
|
17
|
-
padding-right: 2px;
|
|
18
|
-
font-size: 16px;
|
|
19
|
-
color: #89b;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
&:hover {
|
|
23
|
-
color: #fff;
|
|
24
|
-
cursor: pointer;
|
|
25
|
-
background: #fa0;
|
|
26
|
-
|
|
27
|
-
.anticon {
|
|
28
|
-
color: #fff;
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
&:last-child {
|
|
33
|
-
margin-bottom: 0;
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
export function computedMenuPosition(_ref) {
|
|
2
|
-
var width = _ref.width,
|
|
3
|
-
height = _ref.height,
|
|
4
|
-
position = _ref.position,
|
|
5
|
-
size = _ref.size;
|
|
6
|
-
var x, y;
|
|
7
|
-
x = position[0];
|
|
8
|
-
y = position[1];
|
|
9
|
-
if (width - x < size.w) {
|
|
10
|
-
x = width - size.w;
|
|
11
|
-
}
|
|
12
|
-
if (height - y < size.h) {
|
|
13
|
-
y = height - size.h;
|
|
14
|
-
}
|
|
15
|
-
return {
|
|
16
|
-
x: x,
|
|
17
|
-
y: y
|
|
18
|
-
};
|
|
19
|
-
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import './index.less';
|
|
3
|
-
interface IToolsProps {
|
|
4
|
-
scale: number;
|
|
5
|
-
imgDownload?: () => void;
|
|
6
|
-
setScale: (scale: number) => void;
|
|
7
|
-
setRotate: (rotate: number) => void;
|
|
8
|
-
containerEle: HTMLDivElement;
|
|
9
|
-
resetPicture: (event: React.MouseEvent) => void;
|
|
10
|
-
}
|
|
11
|
-
declare function Tools({ scale, imgDownload, setScale, setRotate, containerEle, resetPicture }: IToolsProps): JSX.Element;
|
|
12
|
-
export default Tools;
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
import { Tooltip } from 'antd';
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import FullScreen from "../../../FullScreen";
|
|
4
|
-
import IconFont from "../../../Player/iconfont";
|
|
5
|
-
import "./index.less";
|
|
6
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
8
|
-
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
9
|
-
function Tools(_ref) {
|
|
10
|
-
var scale = _ref.scale,
|
|
11
|
-
imgDownload = _ref.imgDownload,
|
|
12
|
-
setScale = _ref.setScale,
|
|
13
|
-
setRotate = _ref.setRotate,
|
|
14
|
-
containerEle = _ref.containerEle,
|
|
15
|
-
resetPicture = _ref.resetPicture;
|
|
16
|
-
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
17
|
-
children: [/*#__PURE__*/_jsxs("div", {
|
|
18
|
-
className: "picture-tools",
|
|
19
|
-
children: [/*#__PURE__*/_jsx(Tooltip, {
|
|
20
|
-
placement: "left",
|
|
21
|
-
title: "\u590D\u4F4D",
|
|
22
|
-
children: /*#__PURE__*/_jsx("div", {
|
|
23
|
-
onClick: resetPicture,
|
|
24
|
-
children: /*#__PURE__*/_jsx(IconFont, {
|
|
25
|
-
type: "lm-player-S_View_RotateMiddle"
|
|
26
|
-
})
|
|
27
|
-
})
|
|
28
|
-
}), /*#__PURE__*/_jsx(Tooltip, {
|
|
29
|
-
placement: "left",
|
|
30
|
-
title: "\u653E\u5927",
|
|
31
|
-
children: /*#__PURE__*/_jsx("div", {
|
|
32
|
-
onClick: function onClick() {
|
|
33
|
-
return setScale(0.2);
|
|
34
|
-
},
|
|
35
|
-
className: scale === 3 ? 'disabled' : '',
|
|
36
|
-
children: /*#__PURE__*/_jsx(IconFont, {
|
|
37
|
-
type: "lm-player-S_View_ZoomIn"
|
|
38
|
-
})
|
|
39
|
-
})
|
|
40
|
-
}), /*#__PURE__*/_jsx(Tooltip, {
|
|
41
|
-
placement: "left",
|
|
42
|
-
title: "\u7F29\u5C0F",
|
|
43
|
-
children: /*#__PURE__*/_jsx("div", {
|
|
44
|
-
onClick: function onClick() {
|
|
45
|
-
return setScale(-0.2);
|
|
46
|
-
},
|
|
47
|
-
className: scale === 1 ? 'disabled' : '',
|
|
48
|
-
children: /*#__PURE__*/_jsx(IconFont, {
|
|
49
|
-
type: "lm-player-S_View_ZoomOut"
|
|
50
|
-
})
|
|
51
|
-
})
|
|
52
|
-
}), /*#__PURE__*/_jsx(Tooltip, {
|
|
53
|
-
placement: "left",
|
|
54
|
-
title: "\u5411\u5DE6",
|
|
55
|
-
children: /*#__PURE__*/_jsx("div", {
|
|
56
|
-
onClick: function onClick() {
|
|
57
|
-
return setRotate(-90);
|
|
58
|
-
},
|
|
59
|
-
children: /*#__PURE__*/_jsx(IconFont, {
|
|
60
|
-
type: "lm-player-S_View_RotateLeft"
|
|
61
|
-
})
|
|
62
|
-
})
|
|
63
|
-
}), /*#__PURE__*/_jsx(Tooltip, {
|
|
64
|
-
placement: "left",
|
|
65
|
-
title: "\u5411\u53F3",
|
|
66
|
-
children: /*#__PURE__*/_jsx("div", {
|
|
67
|
-
onClick: function onClick() {
|
|
68
|
-
return setRotate(90);
|
|
69
|
-
},
|
|
70
|
-
children: /*#__PURE__*/_jsx(IconFont, {
|
|
71
|
-
type: "lm-player-S_View_RotateRight"
|
|
72
|
-
})
|
|
73
|
-
})
|
|
74
|
-
})]
|
|
75
|
-
}), /*#__PURE__*/_jsxs("div", {
|
|
76
|
-
className: "picture-actions",
|
|
77
|
-
children: [imgDownload && /*#__PURE__*/_jsx("div", {
|
|
78
|
-
onClick: imgDownload,
|
|
79
|
-
children: /*#__PURE__*/_jsx(IconFont, {
|
|
80
|
-
type: "lm-player-S_Edit_LoadDown"
|
|
81
|
-
})
|
|
82
|
-
}), /*#__PURE__*/_jsx("div", {
|
|
83
|
-
children: /*#__PURE__*/_jsx(FullScreen, {
|
|
84
|
-
className: "footer_window",
|
|
85
|
-
getContainer: function getContainer() {
|
|
86
|
-
return containerEle;
|
|
87
|
-
}
|
|
88
|
-
})
|
|
89
|
-
})]
|
|
90
|
-
})]
|
|
91
|
-
});
|
|
92
|
-
}
|
|
93
|
-
export default Tools;
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
.picture-tools {
|
|
2
|
-
position: absolute;
|
|
3
|
-
right: 10px;
|
|
4
|
-
bottom: 10px;
|
|
5
|
-
background: #fff;
|
|
6
|
-
box-shadow: 0 2px 5px 0 rgb(0 0 0 / 30%);
|
|
7
|
-
|
|
8
|
-
&.actions-change-rotate {
|
|
9
|
-
bottom: 150px;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
& > div {
|
|
13
|
-
width: 30px;
|
|
14
|
-
height: 25px;
|
|
15
|
-
line-height: 25px;
|
|
16
|
-
text-align: center;
|
|
17
|
-
cursor: pointer;
|
|
18
|
-
|
|
19
|
-
&.disabled {
|
|
20
|
-
color: #999;
|
|
21
|
-
cursor: not-allowed;
|
|
22
|
-
|
|
23
|
-
.anticon {
|
|
24
|
-
color: #999;
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.picture-actions {
|
|
31
|
-
position: absolute;
|
|
32
|
-
top: 8px;
|
|
33
|
-
right: 8px;
|
|
34
|
-
|
|
35
|
-
& > div {
|
|
36
|
-
float: left;
|
|
37
|
-
width: 28px;
|
|
38
|
-
height: 28px;
|
|
39
|
-
margin-left: 4px;
|
|
40
|
-
line-height: 28px;
|
|
41
|
-
text-align: center;
|
|
42
|
-
cursor: pointer;
|
|
43
|
-
background: #fff;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.tools-screen-layer .anticon {
|
|
47
|
-
padding-right: 0;
|
|
48
|
-
}
|
|
49
|
-
}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import React, { useCallback, useEffect } from 'react';
|
|
2
|
-
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
3
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
4
|
-
function WheelScale(_ref) {
|
|
5
|
-
var dom = _ref.dom,
|
|
6
|
-
setScale = _ref.setScale;
|
|
7
|
-
var onWheel = useCallback(function (e) {
|
|
8
|
-
if (e.ctrlKey || e.metaKey) {
|
|
9
|
-
e.preventDefault();
|
|
10
|
-
e.stopPropagation();
|
|
11
|
-
setScale(e.deltaY > 0 ? -0.2 : 0.2);
|
|
12
|
-
}
|
|
13
|
-
}, [setScale]);
|
|
14
|
-
|
|
15
|
-
//滚轮缩放
|
|
16
|
-
useEffect(function () {
|
|
17
|
-
if (!dom) {
|
|
18
|
-
return undefined;
|
|
19
|
-
}
|
|
20
|
-
dom.addEventListener('wheel', onWheel, {
|
|
21
|
-
passive: false
|
|
22
|
-
});
|
|
23
|
-
return function () {
|
|
24
|
-
return dom.removeEventListener('wheel', onWheel);
|
|
25
|
-
};
|
|
26
|
-
}, [dom, onWheel]);
|
|
27
|
-
return /*#__PURE__*/_jsx(_Fragment, {});
|
|
28
|
-
}
|
|
29
|
-
export default WheelScale;
|
package/es/Picture/demo.d.ts
DELETED
package/es/Picture/demo.js
DELETED
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
2
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
3
|
-
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
4
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
5
|
-
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
6
|
-
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
7
|
-
import { Button, ConfigProvider, Modal } from 'antd';
|
|
8
|
-
import React from 'react';
|
|
9
|
-
import Picture from '.';
|
|
10
|
-
import { useSimpleState } from '..';
|
|
11
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
12
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
|
-
export default function App() {
|
|
14
|
-
var _useSimpleState = useSimpleState({
|
|
15
|
-
open: false,
|
|
16
|
-
open2: false
|
|
17
|
-
}),
|
|
18
|
-
_useSimpleState2 = _slicedToArray(_useSimpleState, 2),
|
|
19
|
-
state = _useSimpleState2[0],
|
|
20
|
-
updateState = _useSimpleState2[1];
|
|
21
|
-
return /*#__PURE__*/_jsxs(ConfigProvider, {
|
|
22
|
-
prefixCls: "cloudapp",
|
|
23
|
-
children: [/*#__PURE__*/_jsx("div", {
|
|
24
|
-
style: {
|
|
25
|
-
width: 600,
|
|
26
|
-
height: 300,
|
|
27
|
-
background: '#000'
|
|
28
|
-
},
|
|
29
|
-
children: /*#__PURE__*/_jsx(Picture, {
|
|
30
|
-
onClickRect: console.log,
|
|
31
|
-
onMenuClick: console.log,
|
|
32
|
-
menus: [{
|
|
33
|
-
title: '菜单1',
|
|
34
|
-
pathname: '/',
|
|
35
|
-
icon: ''
|
|
36
|
-
}]
|
|
37
|
-
// imagePath="http://192.168.100.246:5463/oss/v1/100004008/objects/638da35805f5f0a8101021f9?client_token=100004008_0_1670313176_9a47a8459c120d977904c9feb2354a7e"
|
|
38
|
-
,
|
|
39
|
-
isOpenSelect: state.open,
|
|
40
|
-
imagePath: "https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fc-ssl.duitang.com%2Fuploads%2Fitem%2F201503%2F16%2F20150316082631_YZ28f.jpeg&refer=http%3A%2F%2Fc-ssl.duitang.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1674876231&t=0824d5e8365bc9bcbe0484b5dbffff03"
|
|
41
|
-
// imagePath="https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fpic1.win4000.com%2Fwallpaper%2F2018-08-07%2F5b69694c2e398.jpg&refer=http%3A%2F%2Fpic1.win4000.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1674875813&t=f1f2c44a50e5f3ddae91ba223f5eb99b"
|
|
42
|
-
,
|
|
43
|
-
rects: [{
|
|
44
|
-
type: 'face',
|
|
45
|
-
rect: [920.0, 843.0, 96.0, 94.0],
|
|
46
|
-
needExpand: true
|
|
47
|
-
}],
|
|
48
|
-
children: function children() {
|
|
49
|
-
return /*#__PURE__*/_jsx(Button, {
|
|
50
|
-
onClick: function onClick() {
|
|
51
|
-
return updateState({
|
|
52
|
-
open: true
|
|
53
|
-
});
|
|
54
|
-
},
|
|
55
|
-
children: "\u622A\u56FE"
|
|
56
|
-
});
|
|
57
|
-
}
|
|
58
|
-
})
|
|
59
|
-
}), /*#__PURE__*/_jsxs("div", {
|
|
60
|
-
style: {
|
|
61
|
-
width: 800,
|
|
62
|
-
height: 600,
|
|
63
|
-
background: '#000',
|
|
64
|
-
marginTop: 40
|
|
65
|
-
},
|
|
66
|
-
children: [/*#__PURE__*/_jsx(Button, {
|
|
67
|
-
onClick: function onClick() {
|
|
68
|
-
return updateState({
|
|
69
|
-
open2: true
|
|
70
|
-
});
|
|
71
|
-
},
|
|
72
|
-
children: "\u6253\u5F00"
|
|
73
|
-
}), /*#__PURE__*/_jsx(Modal, {
|
|
74
|
-
title: "modal",
|
|
75
|
-
open: state.open2,
|
|
76
|
-
onCancel: function onCancel() {
|
|
77
|
-
return updateState({
|
|
78
|
-
open2: false
|
|
79
|
-
});
|
|
80
|
-
},
|
|
81
|
-
width: 844,
|
|
82
|
-
children: /*#__PURE__*/_jsx("div", {
|
|
83
|
-
style: {
|
|
84
|
-
width: 800,
|
|
85
|
-
height: 600,
|
|
86
|
-
backgroundColor: '#000'
|
|
87
|
-
},
|
|
88
|
-
children: /*#__PURE__*/_jsx(Picture, {
|
|
89
|
-
imagePath: "https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fc-ssl.duitang.com%2Fuploads%2Fblog%2F202106%2F09%2F20210609081952_51ef5.thumb.1000_0.jpg&refer=http%3A%2F%2Fc-ssl.duitang.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1673661389&t=906e24291130712565842eb7cf21e277",
|
|
90
|
-
isOpenSelect: false,
|
|
91
|
-
rects: [{
|
|
92
|
-
type: 'face',
|
|
93
|
-
rect: [698, 274, 23, 23],
|
|
94
|
-
needExpand: true
|
|
95
|
-
}, {
|
|
96
|
-
type: 'face',
|
|
97
|
-
rect: [754.0, 268.0, 23.0, 23.0],
|
|
98
|
-
needExpand: true
|
|
99
|
-
}, {
|
|
100
|
-
type: 'face',
|
|
101
|
-
rect: [430.0, 421.0, 49.0, 49.0],
|
|
102
|
-
needExpand: true
|
|
103
|
-
}, {
|
|
104
|
-
type: 'face',
|
|
105
|
-
rect: [240.0, 468.0, 41.0, 36.0],
|
|
106
|
-
needExpand: true
|
|
107
|
-
}]
|
|
108
|
-
})
|
|
109
|
-
})
|
|
110
|
-
})]
|
|
111
|
-
})]
|
|
112
|
-
});
|
|
113
|
-
}
|
package/es/Picture/index.d.ts
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import type { IPictureProps } from './interface';
|
|
3
|
-
import './index.less';
|
|
4
|
-
declare function Picture({ className, width, height, minHeight, disabledDrag, imagePath, rects, isOpenSelect, disabledDrawMenu, menus, hasTool, fullScreenEle, ...props }: IPictureProps): JSX.Element;
|
|
5
|
-
declare namespace Picture {
|
|
6
|
-
var defaultProps: {
|
|
7
|
-
width: string;
|
|
8
|
-
height: string;
|
|
9
|
-
className: string;
|
|
10
|
-
minHeight: number;
|
|
11
|
-
disabledDrag: boolean;
|
|
12
|
-
isOpenSelect: boolean;
|
|
13
|
-
disabledDrawMenu: boolean;
|
|
14
|
-
menus: never[];
|
|
15
|
-
rects: never[];
|
|
16
|
-
hasTool: boolean;
|
|
17
|
-
};
|
|
18
|
-
}
|
|
19
|
-
export default Picture;
|