exploria-ui-mcp-server 2.1.4 → 2.2.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +169 -109
- package/dist/index.js +3346 -2933
- package/dist/knowledge/vector-db.json +120728 -0
- package/package.json +5 -5
- package/dist/README.md +0 -633
- package/dist/components/advanced/e_parallax_scrolling/Document.vue +0 -23
- package/dist/components/advanced/e_parallax_scrolling/Using.vue +0 -20
- package/dist/components/advanced/e_parallax_scrolling/img.png +0 -0
- package/dist/components/advanced/e_parallax_scrolling/img_1.png +0 -0
- package/dist/components/advanced/e_parallax_scrolling//350/247/206/345/267/256/346/273/232/345/212/250 +0 -0
- package/dist/components/advanced/e_rolling_follow/Document.vue +0 -21
- package/dist/components/advanced/e_rolling_follow/Using.vue +0 -54
- package/dist/components/advanced/e_virtual_list/ComprehensiveCase.vue +0 -209
- package/dist/components/advanced/e_virtual_list/Document.vue +0 -68
- package/dist/components/advanced/e_virtual_list/DynamicData.vue +0 -42
- package/dist/components/advanced/e_virtual_list/Using.vue +0 -32
- package/dist/components/advanced/e_virtual_list/iconfont/iconfont.css +0 -19
- package/dist/components/advanced/e_virtual_list/iconfont/iconfont.ttf +0 -0
- package/dist/components/advanced/e_virtual_list/iconfont/iconfont.woff +0 -0
- package/dist/components/advanced/e_virtual_list/iconfont/iconfont.woff2 +0 -0
- package/dist/components/advanced/e_virtual_list/img.png +0 -0
- package/dist/components/advanced/e_watermark/AutoSize.vue +0 -89
- package/dist/components/advanced/e_watermark/BasicUsing.vue +0 -9
- package/dist/components/advanced/e_watermark/CustomFont.vue +0 -73
- package/dist/components/advanced/e_watermark/CustomStyle.vue +0 -76
- package/dist/components/advanced/e_watermark/Dense.vue +0 -28
- package/dist/components/advanced/e_watermark/Document.vue +0 -197
- package/dist/components/advanced/e_watermark/HighZIndex.vue +0 -105
- package/dist/components/advanced/e_watermark/ImageWatermark.vue +0 -31
- package/dist/components/advanced/e_watermark/MultiLine.vue +0 -29
- package/dist/components/advanced/e_watermark/OpacityWatermark.vue +0 -73
- package/dist/components/ai/typing_effect/Document.vue +0 -47
- package/dist/components/ai/typing_effect/Using1.vue +0 -189
- package/dist/components/ai/typing_effect/Using2.vue +0 -167
- package/dist/components/basic/e_badge/BasicBadge.vue +0 -31
- package/dist/components/basic/e_badge/Document.vue +0 -137
- package/dist/components/basic/e_badge/DotBadge.vue +0 -35
- package/dist/components/basic/e_badge/MaxBadge.vue +0 -33
- package/dist/components/basic/e_badge/ShowZeroBadge.vue +0 -30
- package/dist/components/basic/e_badge/SizeBadge.vue +0 -29
- package/dist/components/basic/e_badge/TypeBadge.vue +0 -36
- package/dist/components/basic/e_button/CircleButtons.vue +0 -30
- package/dist/components/basic/e_button/DisabledButtons.vue +0 -30
- package/dist/components/basic/e_button/Document.vue +0 -171
- package/dist/components/basic/e_button/LoadingButtons.vue +0 -30
- package/dist/components/basic/e_button/NormalButtons.vue +0 -30
- package/dist/components/basic/e_button/PlainButtons.vue +0 -30
- package/dist/components/basic/e_button/RoundButtons.vue +0 -30
- package/dist/components/basic/e_button/RoundedRectangleButtons.vue +0 -35
- package/dist/components/basic/e_button/SizeButtons.vue +0 -19
- package/dist/components/basic/e_button/Using.vue +0 -89
- package/dist/components/basic/e_card/BasicCard.vue +0 -9
- package/dist/components/basic/e_card/BorderlessCard.vue +0 -8
- package/dist/components/basic/e_card/ComplexContentCard.vue +0 -92
- package/dist/components/basic/e_card/CustomHeaderCard.vue +0 -24
- package/dist/components/basic/e_card/Document.vue +0 -131
- package/dist/components/basic/e_card/FooterCard.vue +0 -12
- package/dist/components/basic/e_card/ShadowCard.vue +0 -30
- package/dist/components/basic/e_card/SizesCard.vue +0 -29
- package/dist/components/basic/e_svg_icon/Document.vue +0 -38
- package/dist/components/basic/e_svg_icon/Using.vue +0 -7
- package/dist/components/basic/e_underline/BaseUsing.vue +0 -13
- package/dist/components/basic/e_underline/Document.vue +0 -27
- package/dist/components/basic/e_underline/ImgUsing.vue +0 -36
- package/dist/components/data/e_calendar/Document.vue +0 -41
- package/dist/components/data/e_calendar/Using.vue +0 -9
- package/dist/components/data/e_calendar//346/227/245/345/216/206 +0 -0
- package/dist/components/data/e_carousel/Document.vue +0 -143
- package/dist/components/data/e_carousel/Using.vue +0 -20
- package/dist/components/data/e_carousel/Using1.vue +0 -23
- package/dist/components/data/e_carousel/Using2.vue +0 -17
- package/dist/components/data/e_carousel/Using3.vue +0 -17
- package/dist/components/data/e_collapse/Document.vue +0 -40
- package/dist/components/data/e_collapse/Using.vue +0 -9
- package/dist/components/data/e_collapse//346/212/230/345/217/240/351/235/242/346/235/277 +0 -0
- package/dist/components/data/e_image/Document.vue +0 -71
- package/dist/components/data/e_image/Using.vue +0 -21
- package/dist/components/data/e_image/img.png +0 -0
- package/dist/components/data/e_list/BasicUsage.vue +0 -18
- package/dist/components/data/e_list/CustomCheckboxUsage.vue +0 -22
- package/dist/components/data/e_list/CustomEmptyDataUsage.vue +0 -38
- package/dist/components/data/e_list/CustomRowUsage.vue +0 -64
- package/dist/components/data/e_list/DividerUsage.vue +0 -20
- package/dist/components/data/e_list/Document.vue +0 -261
- package/dist/components/data/e_list/EmptyDataUsage.vue +0 -3
- package/dist/components/data/e_list/EventUsage.vue +0 -23
- package/dist/components/data/e_list/MultipleSelectUsage.vue +0 -22
- package/dist/components/data/e_list/SingleSelectUsage.vue +0 -21
- package/dist/components/data/e_list/SizeUsage.vue +0 -35
- package/dist/components/data/e_media_viewer/Document.vue +0 -39
- package/dist/components/data/e_media_viewer/Using.vue +0 -30
- package/dist/components/data/e_media_viewer/img.png +0 -0
- package/dist/components/data/e_progress/BasicProgress.vue +0 -21
- package/dist/components/data/e_progress/CircleProgress.vue +0 -23
- package/dist/components/data/e_progress/CustomColorProgress.vue +0 -63
- package/dist/components/data/e_progress/Document.vue +0 -179
- package/dist/components/data/e_progress/IndeterminateProgress.vue +0 -49
- package/dist/components/data/e_progress/ProgressSize.vue +0 -50
- package/dist/components/data/e_progress/ProgressStatus.vue +0 -21
- package/dist/components/data/e_progress/ProgressText.vue +0 -52
- package/dist/components/data/e_rolling_pagination/Document.vue +0 -21
- package/dist/components/data/e_rolling_pagination/Using.vue +0 -33
- package/dist/components/data/e_rolling_pagination//346/273/232/345/212/250/345/210/206/351/241/265 +0 -0
- package/dist/components/data/e_skeleton/Document.vue +0 -26
- package/dist/components/data/e_skeleton/Using.vue +0 -18
- package/dist/components/data/e_skeleton//351/252/250/346/236/266 +0 -0
- package/dist/components/data/e_table/Document.vue +0 -85
- package/dist/components/data/e_table/Using.vue +0 -131
- package/dist/components/data/e_timeline/Document.vue +0 -90
- package/dist/components/data/e_timeline/Using.vue +0 -124
- package/dist/components/feedback/e_dialog/AsyncUsing.vue +0 -30
- package/dist/components/feedback/e_dialog/BaseUsing.vue +0 -15
- package/dist/components/feedback/e_dialog/Document.vue +0 -26
- package/dist/components/feedback/e_drawer/BaseUsing.vue +0 -35
- package/dist/components/feedback/e_drawer/DirectionUsing.vue +0 -93
- package/dist/components/feedback/e_drawer/Document.vue +0 -153
- package/dist/components/feedback/e_drawer/LargeSizeDrawer.vue +0 -29
- package/dist/components/feedback/e_drawer/MediumSizeDrawer.vue +0 -29
- package/dist/components/feedback/e_drawer/SizeUsing.vue +0 -67
- package/dist/components/feedback/e_drawer/SmallSizeDrawer.vue +0 -29
- package/dist/components/feedback/e_message/Document.vue +0 -18
- package/dist/components/feedback/e_message/Using.vue +0 -16
- package/dist/components/feedback/e_message_box/BaseUsing.vue +0 -11
- package/dist/components/feedback/e_message_box/Document.vue +0 -18
- package/dist/components/feedback/e_message_box/intro.md +0 -12
- package/dist/components/feedback/e_notification/AllPositionsNotification.vue +0 -35
- package/dist/components/feedback/e_notification/BasicTypesNotification.vue +0 -47
- package/dist/components/feedback/e_notification/ClickableNotification.vue +0 -18
- package/dist/components/feedback/e_notification/Document.vue +0 -147
- package/dist/components/feedback/e_notification/ManualCloseNotification.vue +0 -17
- package/dist/components/feedback/e_notification/Using.vue +0 -253
- package/dist/components/feedback/e_popover/BasicUsage.vue +0 -51
- package/dist/components/feedback/e_popover/ContextmenuTrigger.vue +0 -27
- package/dist/components/feedback/e_popover/CustomContent.vue +0 -43
- package/dist/components/feedback/e_popover/CustomTrigger.vue +0 -39
- package/dist/components/feedback/e_popover/Document.vue +0 -84
- package/dist/components/feedback/e_popover/HoverTrigger.vue +0 -29
- package/dist/components/feedback/e_popover/SizeVariants.vue +0 -36
- package/dist/components/feedback/e_popover/Using.vue +0 -177
- package/dist/components/feedback/e_tooltip/Document.vue +0 -42
- package/dist/components/feedback/e_tooltip/SizeUsing.vue +0 -28
- package/dist/components/feedback/e_tooltip/Using.vue +0 -44
- package/dist/components/form/e_checkbox/Document.vue +0 -88
- package/dist/components/form/e_checkbox/Using.vue +0 -10
- package/dist/components/form/e_color_picker/Document.vue +0 -55
- package/dist/components/form/e_color_picker/Using.vue +0 -10
- package/dist/components/form/e_condition_group/Document.vue +0 -52
- package/dist/components/form/e_condition_group/Using.vue +0 -165
- package/dist/components/form/e_file_selector/Document.vue +0 -50
- package/dist/components/form/e_file_selector/Using.vue +0 -44
- package/dist/components/form/e_form/BaseUsage.vue +0 -155
- package/dist/components/form/e_form/Document.vue +0 -93
- package/dist/components/form/e_form/LoginForm.vue +0 -150
- package/dist/components/form/e_form/RegisterForm.vue +0 -46
- package/dist/components/form/e_form/iconfont/iconfont.css +0 -67
- package/dist/components/form/e_form/iconfont/iconfont.ttf +0 -0
- package/dist/components/form/e_form/iconfont/iconfont.woff +0 -0
- package/dist/components/form/e_form/iconfont/iconfont.woff2 +0 -0
- package/dist/components/form/e_input/BaseUsage.vue +0 -16
- package/dist/components/form/e_input/Clearable.vue +0 -24
- package/dist/components/form/e_input/Document.vue +0 -111
- package/dist/components/form/e_input/Number.vue +0 -10
- package/dist/components/form/e_input/Password.vue +0 -52
- package/dist/components/form/e_input/iconfont/iconfont.css +0 -67
- package/dist/components/form/e_input/iconfont/iconfont.ttf +0 -0
- package/dist/components/form/e_input/iconfont/iconfont.woff +0 -0
- package/dist/components/form/e_input/iconfont/iconfont.woff2 +0 -0
- package/dist/components/form/e_radio/Document.vue +0 -88
- package/dist/components/form/e_radio/Using.vue +0 -14
- package/dist/components/form/e_select/Document.vue +0 -32
- package/dist/components/form/e_select/Using.vue +0 -24
- package/dist/components/form/e_select//351/200/211/351/241/271/346/241/206 +0 -0
- package/dist/components/form/e_slider/BaseUsage.vue +0 -10
- package/dist/components/form/e_slider/CustomRange.vue +0 -21
- package/dist/components/form/e_slider/Disabled.vue +0 -10
- package/dist/components/form/e_slider/Document.vue +0 -55
- package/dist/components/form/e_slider/ShowValue.vue +0 -10
- package/dist/components/form/e_slider/Sizes.vue +0 -47
- package/dist/components/form/e_time_picker/Document.vue +0 -58
- package/dist/components/form/e_time_picker/Using.vue +0 -13
- package/dist/components/geometry/css_3d/Document.vue +0 -17
- package/dist/components/geometry/css_3d/Using.vue +0 -9
- package/dist/components/layout/e_scroll_x/Document.vue +0 -39
- package/dist/components/layout/e_scroll_x/Using.vue +0 -38
- package/dist/components/navigation/e_dropdown/BasicUsage.vue +0 -64
- package/dist/components/navigation/e_dropdown/Contextmenu.vue +0 -41
- package/dist/components/navigation/e_dropdown/Document.vue +0 -72
- package/dist/components/navigation/e_dropdown/HoverTrigger.vue +0 -66
- package/dist/components/navigation/e_dropdown/NestedDropdown.vue +0 -143
- package/dist/components/navigation/e_tabs/Document.vue +0 -33
- package/dist/components/navigation/e_tabs/Using.vue +0 -40
- package/dist/directives/e_uuid_util/Document.vue +0 -15
- package/dist/directives/e_uuid_util/Using.vue +0 -13
- package/dist/other/advanced/gsap/BasicUsing.vue +0 -26
- package/dist/other/advanced/gsap/Document.vue +0 -45
- package/dist/other/advanced/gsap/GSAP/345/212/250/347/224/273 +0 -0
- package/dist/other/advanced/gsap/ScrollTrigger.vue +0 -195
- package/dist/other/advanced/gsap/ScrollX.vue +0 -81
- package/dist/other/advanced/gsap/Timeline.vue +0 -30
- package/dist/other/advanced/lottie/BasicUsing.vue +0 -33
- package/dist/other/advanced/lottie/Document.vue +0 -30
- package/dist/other/advanced/lottie/Lottie /345/212/250/347/224/273 +0 -0
- package/dist/other/advanced/rich_text_editor/Document.vue +0 -24
- package/dist/other/advanced/rich_text_editor/RichTextEditor.vue +0 -105
- package/dist/other/advanced/rich_text_editor/wangeditor_style.css +0 -684
- package/dist/other/advanced/sortablejs/Document.vue +0 -32
- package/dist/other/advanced/sortablejs/ShuttleFrame.vue +0 -181
- package/dist/other/advanced/sortablejs/Using.vue +0 -68
- package/dist/other/advanced/sortablejs/iconfont/iconfont.ttf +0 -0
- package/dist/other/advanced/sortablejs/iconfont/iconfont.woff +0 -0
- package/dist/other/advanced/sortablejs/iconfont/iconfont.woff2 +0 -0
- package/dist/other/advanced/spelling/Document.vue +0 -17
- package/dist/other/advanced/spelling/Using.vue +0 -104
- package/dist/other/advanced/svg/BasicUsing.vue +0 -12
- package/dist/other/advanced/svg/Document.vue +0 -24
- package/dist/other/advanced/svg/FeDisplacementMap/FeDisplacementMap.vue +0 -30
- package/dist/other/advanced/svg/FeDisplacementMap/example/Image.vue +0 -41
- package/dist/other/advanced/svg/FeDisplacementMap/example//346/225/205/351/232/234/346/263/242/347/272/271/346/225/210/346/236/234 +0 -0
- package/dist/other/advanced/svg/FeDisplacementMap//344/275/215/347/275/256/346/233/277/346/215/242/346/273/244/351/225/234 +0 -0
- package/dist/other/advanced/svg/FeTurbulence/FeTurbulence.vue +0 -28
- package/dist/other/advanced/svg/FeTurbulence/example/Image.vue +0 -41
- package/dist/other/advanced/svg/FeTurbulence/example//346/225/205/351/232/234/346/263/242/347/272/271/346/225/210/346/236/234 +0 -0
- package/dist/other/advanced/svg/FeTurbulence//346/271/215/346/265/201/346/273/244/351/225/234 +0 -0
- package/dist/other/canvas/base/Document.vue +0 -15
- package/dist/other/canvas/base/Using.vue +0 -125
- package/dist/other/canvas/burrow/Clip.vue +0 -66
- package/dist/other/canvas/burrow/Document.vue +0 -36
- package/dist/other/canvas/burrow/Erase.vue +0 -58
- package/dist/other/canvas/burrow/NonZeroSurroundRule.vue +0 -70
- package/dist/other/canvas/clip/Clip.vue +0 -58
- package/dist/other/canvas/clip/Document.vue +0 -26
- package/dist/other/canvas/definition/Document.vue +0 -26
- package/dist/other/canvas/definition/Using.vue +0 -60
- package/dist/other/echarts/basic/Document.vue +0 -36
- package/dist/other/echarts/basic/Label.vue +0 -98
- package/dist/other/echarts/data_zoom/Document.vue +0 -38
- package/dist/other/echarts/data_zoom/Using.vue +0 -119
- package/dist/other/echarts/data_zoom/img.svg +0 -33
- package/dist/other/echarts/gauge/Document.vue +0 -38
- package/dist/other/echarts/gauge/Gauge.vue +0 -340
- package/dist/other/echarts/gauge//344/273/252/350/241/250/347/233/230 +0 -0
- package/dist/other/echarts/liquidfill/Document.vue +0 -46
- package/dist/other/echarts/liquidfill/Using.vue +0 -239
- package/dist/other/git/sample_set/Document.vue +0 -43
- package/dist/other/git/sample_set/img/img.png +0 -0
- package/dist/other/git/sample_set/img/img_1.png +0 -0
- package/dist/other/git/sample_set/img/img_2.png +0 -0
- package/dist/other/layout/flex/Advanced.vue +0 -104
- package/dist/other/layout/flex/Advanced2.vue +0 -181
- package/dist/other/layout/flex/Base.vue +0 -48
- package/dist/other/layout/flex/Document.vue +0 -57
- package/dist/other/layout/flex/Grid.vue +0 -54
- package/dist/other/layout/flex/Height100.vue +0 -35
- package/dist/other/layout/flex/intro.md +0 -1
- package/dist/other/layout/grid/Base.vue +0 -29
- package/dist/other/layout/grid/Document.vue +0 -54
- package/dist/other/layout/grid/Grid.vue +0 -28
- package/dist/other/layout/grid/Height100.vue +0 -35
- package/dist/other/layout/grid/intro.md +0 -1
- package/dist/other/navigation/new_tab_page/Document.vue +0 -18
- package/dist/other/navigation/new_tab_page/OpenNewTabPage.vue +0 -7
- package/dist/other/navigation/new_tab_page/new-tab-page-demo.html +0 -450
- package/dist/other/network/sse/Document.vue +0 -21
- package/dist/other/network/sse/Using.vue +0 -24
- package/dist/other/network/sse/server/app.ts +0 -62
- package/dist/other/network/sse/server/static/text.md +0 -99
- package/dist/other/network/sse/server/utils/sleep.ts +0 -5
- package/dist/other/observer/mutation_observer/Document.vue +0 -15
- package/dist/other/observer/mutation_observer/Using.vue +0 -46
- package/dist/other/optimize/Document.vue +0 -19
- package/dist/other/optimize/HeavyComp.vue +0 -19
- package/dist/other/optimize/Using.vue +0 -14
- package/dist/other/optimize/useDefer.ts +0 -28
- package/dist/other/svg/base/BasicUsing.vue +0 -12
- package/dist/other/svg/base/Document.vue +0 -24
- package/dist/other/svg/base/FeDisplacementMap/FeDisplacementMap.vue +0 -30
- package/dist/other/svg/base/FeDisplacementMap/example/Image.vue +0 -41
- package/dist/other/svg/base/FeDisplacementMap/example//346/225/205/351/232/234/346/263/242/347/272/271/346/225/210/346/236/234 +0 -0
- package/dist/other/svg/base/FeDisplacementMap//344/275/215/347/275/256/346/233/277/346/215/242/346/273/244/351/225/234 +0 -0
- package/dist/other/svg/base/FeTurbulence/FeTurbulence.vue +0 -28
- package/dist/other/svg/base/FeTurbulence/example/Image.vue +0 -41
- package/dist/other/svg/base/FeTurbulence/example//346/225/205/351/232/234/346/263/242/347/272/271/346/225/210/346/236/234 +0 -0
- package/dist/other/svg/base/FeTurbulence//346/271/215/346/265/201/346/273/244/351/225/234 +0 -0
- package/dist/other/threejs/base/Document.vue +0 -17
- package/dist/other/threejs/base/Using.vue +0 -127
- package/dist/other/threejs/controller_sync/Document.vue +0 -15
- package/dist/other/threejs/controller_sync/Using.vue +0 -347
- package/dist/other/threejs/controller_sync/bone//345/217/214/350/204/232/345/206/205/344/276/247/350/270/242/347/220/203.fbx +0 -0
- package/dist/other/threejs/controller_sync/motion//345/217/214/350/204/232/345/206/205/344/276/247/350/270/242/347/220/203.fbx +0 -0
- package/dist/other/threejs/controller_sync/scene/EnvMapTexture.jpg +0 -0
- package/dist/other/threejs/controller_sync/scene//347/257/256/347/220/203/345/234/272.glb +0 -0
- package/dist/other/threejs/controller_sync/scene//347/276/275/346/257/233/347/220/203/345/234/272.glb +0 -0
- package/dist/other/threejs/phoenix/Document.vue +0 -17
- package/dist/other/threejs/phoenix/Using.vue +0 -79
- package/dist/other/vue/life_cycle/Child.vue +0 -43
- package/dist/other/vue/life_cycle/Document.vue +0 -15
- package/dist/other/vue/life_cycle/Using.vue +0 -16
- package/dist/utils/e_echarts_util/Document.vue +0 -14
- package/dist/utils/e_echarts_util/Using.vue +0 -81
- package/dist/utils/e_image_util/Document.vue +0 -15
- package/dist/utils/e_image_util/Using.vue +0 -24
- package/dist/utils/e_image_util/author_avatar.png +0 -0
- package/dist/utils/e_uuid_util/Document.vue +0 -15
- package/dist/utils/e_uuid_util/Using.vue +0 -13
- package/dist/utils/type_utils/Document.vue +0 -16
- package/dist/utils/type_utils/TupleType.vue +0 -16
- package/public/README.md +0 -633
- package/public/components/advanced/e_parallax_scrolling/Document.vue +0 -23
- package/public/components/advanced/e_parallax_scrolling/Using.vue +0 -20
- package/public/components/advanced/e_parallax_scrolling/img.png +0 -0
- package/public/components/advanced/e_parallax_scrolling/img_1.png +0 -0
- package/public/components/advanced/e_parallax_scrolling//350/247/206/345/267/256/346/273/232/345/212/250 +0 -0
- package/public/components/advanced/e_rolling_follow/Document.vue +0 -21
- package/public/components/advanced/e_rolling_follow/Using.vue +0 -54
- package/public/components/advanced/e_virtual_list/ComprehensiveCase.vue +0 -209
- package/public/components/advanced/e_virtual_list/Document.vue +0 -68
- package/public/components/advanced/e_virtual_list/DynamicData.vue +0 -42
- package/public/components/advanced/e_virtual_list/Using.vue +0 -32
- package/public/components/advanced/e_virtual_list/iconfont/iconfont.css +0 -19
- package/public/components/advanced/e_virtual_list/iconfont/iconfont.ttf +0 -0
- package/public/components/advanced/e_virtual_list/iconfont/iconfont.woff +0 -0
- package/public/components/advanced/e_virtual_list/iconfont/iconfont.woff2 +0 -0
- package/public/components/advanced/e_virtual_list/img.png +0 -0
- package/public/components/advanced/e_watermark/AutoSize.vue +0 -89
- package/public/components/advanced/e_watermark/BasicUsing.vue +0 -9
- package/public/components/advanced/e_watermark/CustomFont.vue +0 -73
- package/public/components/advanced/e_watermark/CustomStyle.vue +0 -76
- package/public/components/advanced/e_watermark/Dense.vue +0 -28
- package/public/components/advanced/e_watermark/Document.vue +0 -197
- package/public/components/advanced/e_watermark/HighZIndex.vue +0 -105
- package/public/components/advanced/e_watermark/ImageWatermark.vue +0 -31
- package/public/components/advanced/e_watermark/MultiLine.vue +0 -29
- package/public/components/advanced/e_watermark/OpacityWatermark.vue +0 -73
- package/public/components/ai/typing_effect/Document.vue +0 -47
- package/public/components/ai/typing_effect/Using1.vue +0 -189
- package/public/components/ai/typing_effect/Using2.vue +0 -167
- package/public/components/basic/e_badge/BasicBadge.vue +0 -31
- package/public/components/basic/e_badge/Document.vue +0 -137
- package/public/components/basic/e_badge/DotBadge.vue +0 -35
- package/public/components/basic/e_badge/MaxBadge.vue +0 -33
- package/public/components/basic/e_badge/ShowZeroBadge.vue +0 -30
- package/public/components/basic/e_badge/SizeBadge.vue +0 -29
- package/public/components/basic/e_badge/TypeBadge.vue +0 -36
- package/public/components/basic/e_button/CircleButtons.vue +0 -30
- package/public/components/basic/e_button/DisabledButtons.vue +0 -30
- package/public/components/basic/e_button/Document.vue +0 -171
- package/public/components/basic/e_button/LoadingButtons.vue +0 -30
- package/public/components/basic/e_button/NormalButtons.vue +0 -30
- package/public/components/basic/e_button/PlainButtons.vue +0 -30
- package/public/components/basic/e_button/RoundButtons.vue +0 -30
- package/public/components/basic/e_button/RoundedRectangleButtons.vue +0 -35
- package/public/components/basic/e_button/SizeButtons.vue +0 -19
- package/public/components/basic/e_button/Using.vue +0 -89
- package/public/components/basic/e_card/BasicCard.vue +0 -9
- package/public/components/basic/e_card/BorderlessCard.vue +0 -8
- package/public/components/basic/e_card/ComplexContentCard.vue +0 -92
- package/public/components/basic/e_card/CustomHeaderCard.vue +0 -24
- package/public/components/basic/e_card/Document.vue +0 -131
- package/public/components/basic/e_card/FooterCard.vue +0 -12
- package/public/components/basic/e_card/ShadowCard.vue +0 -30
- package/public/components/basic/e_card/SizesCard.vue +0 -29
- package/public/components/basic/e_svg_icon/Document.vue +0 -38
- package/public/components/basic/e_svg_icon/Using.vue +0 -7
- package/public/components/basic/e_underline/BaseUsing.vue +0 -13
- package/public/components/basic/e_underline/Document.vue +0 -27
- package/public/components/basic/e_underline/ImgUsing.vue +0 -36
- package/public/components/data/e_calendar/Document.vue +0 -41
- package/public/components/data/e_calendar/Using.vue +0 -9
- package/public/components/data/e_calendar//346/227/245/345/216/206 +0 -0
- package/public/components/data/e_carousel/Document.vue +0 -143
- package/public/components/data/e_carousel/Using.vue +0 -20
- package/public/components/data/e_carousel/Using1.vue +0 -23
- package/public/components/data/e_carousel/Using2.vue +0 -17
- package/public/components/data/e_carousel/Using3.vue +0 -17
- package/public/components/data/e_collapse/Document.vue +0 -40
- package/public/components/data/e_collapse/Using.vue +0 -9
- package/public/components/data/e_collapse//346/212/230/345/217/240/351/235/242/346/235/277 +0 -0
- package/public/components/data/e_image/Document.vue +0 -71
- package/public/components/data/e_image/Using.vue +0 -21
- package/public/components/data/e_image/img.png +0 -0
- package/public/components/data/e_list/BasicUsage.vue +0 -18
- package/public/components/data/e_list/CustomCheckboxUsage.vue +0 -22
- package/public/components/data/e_list/CustomEmptyDataUsage.vue +0 -38
- package/public/components/data/e_list/CustomRowUsage.vue +0 -64
- package/public/components/data/e_list/DividerUsage.vue +0 -20
- package/public/components/data/e_list/Document.vue +0 -261
- package/public/components/data/e_list/EmptyDataUsage.vue +0 -3
- package/public/components/data/e_list/EventUsage.vue +0 -23
- package/public/components/data/e_list/MultipleSelectUsage.vue +0 -22
- package/public/components/data/e_list/SingleSelectUsage.vue +0 -21
- package/public/components/data/e_list/SizeUsage.vue +0 -35
- package/public/components/data/e_media_viewer/Document.vue +0 -39
- package/public/components/data/e_media_viewer/Using.vue +0 -30
- package/public/components/data/e_media_viewer/img.png +0 -0
- package/public/components/data/e_progress/BasicProgress.vue +0 -21
- package/public/components/data/e_progress/CircleProgress.vue +0 -23
- package/public/components/data/e_progress/CustomColorProgress.vue +0 -63
- package/public/components/data/e_progress/Document.vue +0 -179
- package/public/components/data/e_progress/IndeterminateProgress.vue +0 -49
- package/public/components/data/e_progress/ProgressSize.vue +0 -50
- package/public/components/data/e_progress/ProgressStatus.vue +0 -21
- package/public/components/data/e_progress/ProgressText.vue +0 -52
- package/public/components/data/e_rolling_pagination/Document.vue +0 -21
- package/public/components/data/e_rolling_pagination/Using.vue +0 -33
- package/public/components/data/e_rolling_pagination//346/273/232/345/212/250/345/210/206/351/241/265 +0 -0
- package/public/components/data/e_skeleton/Document.vue +0 -26
- package/public/components/data/e_skeleton/Using.vue +0 -18
- package/public/components/data/e_skeleton//351/252/250/346/236/266 +0 -0
- package/public/components/data/e_table/Document.vue +0 -85
- package/public/components/data/e_table/Using.vue +0 -131
- package/public/components/data/e_timeline/Document.vue +0 -90
- package/public/components/data/e_timeline/Using.vue +0 -124
- package/public/components/feedback/e_dialog/AsyncUsing.vue +0 -30
- package/public/components/feedback/e_dialog/BaseUsing.vue +0 -15
- package/public/components/feedback/e_dialog/Document.vue +0 -26
- package/public/components/feedback/e_drawer/BaseUsing.vue +0 -35
- package/public/components/feedback/e_drawer/DirectionUsing.vue +0 -93
- package/public/components/feedback/e_drawer/Document.vue +0 -153
- package/public/components/feedback/e_drawer/LargeSizeDrawer.vue +0 -29
- package/public/components/feedback/e_drawer/MediumSizeDrawer.vue +0 -29
- package/public/components/feedback/e_drawer/SizeUsing.vue +0 -67
- package/public/components/feedback/e_drawer/SmallSizeDrawer.vue +0 -29
- package/public/components/feedback/e_message/Document.vue +0 -18
- package/public/components/feedback/e_message/Using.vue +0 -16
- package/public/components/feedback/e_message_box/BaseUsing.vue +0 -11
- package/public/components/feedback/e_message_box/Document.vue +0 -18
- package/public/components/feedback/e_message_box/intro.md +0 -12
- package/public/components/feedback/e_notification/AllPositionsNotification.vue +0 -35
- package/public/components/feedback/e_notification/BasicTypesNotification.vue +0 -47
- package/public/components/feedback/e_notification/ClickableNotification.vue +0 -18
- package/public/components/feedback/e_notification/Document.vue +0 -147
- package/public/components/feedback/e_notification/ManualCloseNotification.vue +0 -17
- package/public/components/feedback/e_notification/Using.vue +0 -253
- package/public/components/feedback/e_popover/BasicUsage.vue +0 -51
- package/public/components/feedback/e_popover/ContextmenuTrigger.vue +0 -27
- package/public/components/feedback/e_popover/CustomContent.vue +0 -43
- package/public/components/feedback/e_popover/CustomTrigger.vue +0 -39
- package/public/components/feedback/e_popover/Document.vue +0 -84
- package/public/components/feedback/e_popover/HoverTrigger.vue +0 -29
- package/public/components/feedback/e_popover/SizeVariants.vue +0 -36
- package/public/components/feedback/e_popover/Using.vue +0 -177
- package/public/components/feedback/e_tooltip/Document.vue +0 -42
- package/public/components/feedback/e_tooltip/SizeUsing.vue +0 -28
- package/public/components/feedback/e_tooltip/Using.vue +0 -44
- package/public/components/form/e_checkbox/Document.vue +0 -88
- package/public/components/form/e_checkbox/Using.vue +0 -10
- package/public/components/form/e_color_picker/Document.vue +0 -55
- package/public/components/form/e_color_picker/Using.vue +0 -10
- package/public/components/form/e_condition_group/Document.vue +0 -52
- package/public/components/form/e_condition_group/Using.vue +0 -165
- package/public/components/form/e_file_selector/Document.vue +0 -50
- package/public/components/form/e_file_selector/Using.vue +0 -44
- package/public/components/form/e_form/BaseUsage.vue +0 -155
- package/public/components/form/e_form/Document.vue +0 -93
- package/public/components/form/e_form/LoginForm.vue +0 -150
- package/public/components/form/e_form/RegisterForm.vue +0 -46
- package/public/components/form/e_form/iconfont/iconfont.css +0 -67
- package/public/components/form/e_form/iconfont/iconfont.ttf +0 -0
- package/public/components/form/e_form/iconfont/iconfont.woff +0 -0
- package/public/components/form/e_form/iconfont/iconfont.woff2 +0 -0
- package/public/components/form/e_input/BaseUsage.vue +0 -16
- package/public/components/form/e_input/Clearable.vue +0 -24
- package/public/components/form/e_input/Document.vue +0 -111
- package/public/components/form/e_input/Number.vue +0 -10
- package/public/components/form/e_input/Password.vue +0 -52
- package/public/components/form/e_input/iconfont/iconfont.css +0 -67
- package/public/components/form/e_input/iconfont/iconfont.ttf +0 -0
- package/public/components/form/e_input/iconfont/iconfont.woff +0 -0
- package/public/components/form/e_input/iconfont/iconfont.woff2 +0 -0
- package/public/components/form/e_radio/Document.vue +0 -88
- package/public/components/form/e_radio/Using.vue +0 -14
- package/public/components/form/e_select/Document.vue +0 -32
- package/public/components/form/e_select/Using.vue +0 -24
- package/public/components/form/e_select//351/200/211/351/241/271/346/241/206 +0 -0
- package/public/components/form/e_slider/BaseUsage.vue +0 -10
- package/public/components/form/e_slider/CustomRange.vue +0 -21
- package/public/components/form/e_slider/Disabled.vue +0 -10
- package/public/components/form/e_slider/Document.vue +0 -55
- package/public/components/form/e_slider/ShowValue.vue +0 -10
- package/public/components/form/e_slider/Sizes.vue +0 -47
- package/public/components/form/e_time_picker/Document.vue +0 -58
- package/public/components/form/e_time_picker/Using.vue +0 -13
- package/public/components/geometry/css_3d/Document.vue +0 -17
- package/public/components/geometry/css_3d/Using.vue +0 -9
- package/public/components/layout/e_scroll_x/Document.vue +0 -39
- package/public/components/layout/e_scroll_x/Using.vue +0 -38
- package/public/components/navigation/e_dropdown/BasicUsage.vue +0 -64
- package/public/components/navigation/e_dropdown/Contextmenu.vue +0 -41
- package/public/components/navigation/e_dropdown/Document.vue +0 -72
- package/public/components/navigation/e_dropdown/HoverTrigger.vue +0 -66
- package/public/components/navigation/e_dropdown/NestedDropdown.vue +0 -143
- package/public/components/navigation/e_tabs/Document.vue +0 -33
- package/public/components/navigation/e_tabs/Using.vue +0 -40
- package/public/directives/e_uuid_util/Document.vue +0 -15
- package/public/directives/e_uuid_util/Using.vue +0 -13
- package/public/other/advanced/gsap/BasicUsing.vue +0 -26
- package/public/other/advanced/gsap/Document.vue +0 -45
- package/public/other/advanced/gsap/GSAP/345/212/250/347/224/273 +0 -0
- package/public/other/advanced/gsap/ScrollTrigger.vue +0 -195
- package/public/other/advanced/gsap/ScrollX.vue +0 -81
- package/public/other/advanced/gsap/Timeline.vue +0 -30
- package/public/other/advanced/lottie/BasicUsing.vue +0 -33
- package/public/other/advanced/lottie/Document.vue +0 -30
- package/public/other/advanced/lottie/Lottie /345/212/250/347/224/273 +0 -0
- package/public/other/advanced/rich_text_editor/Document.vue +0 -24
- package/public/other/advanced/rich_text_editor/RichTextEditor.vue +0 -105
- package/public/other/advanced/rich_text_editor/wangeditor_style.css +0 -684
- package/public/other/advanced/sortablejs/Document.vue +0 -32
- package/public/other/advanced/sortablejs/ShuttleFrame.vue +0 -181
- package/public/other/advanced/sortablejs/Using.vue +0 -68
- package/public/other/advanced/sortablejs/iconfont/iconfont.ttf +0 -0
- package/public/other/advanced/sortablejs/iconfont/iconfont.woff +0 -0
- package/public/other/advanced/sortablejs/iconfont/iconfont.woff2 +0 -0
- package/public/other/advanced/spelling/Document.vue +0 -17
- package/public/other/advanced/spelling/Using.vue +0 -104
- package/public/other/advanced/svg/BasicUsing.vue +0 -12
- package/public/other/advanced/svg/Document.vue +0 -24
- package/public/other/advanced/svg/FeDisplacementMap/FeDisplacementMap.vue +0 -30
- package/public/other/advanced/svg/FeDisplacementMap/example/Image.vue +0 -41
- package/public/other/advanced/svg/FeDisplacementMap/example//346/225/205/351/232/234/346/263/242/347/272/271/346/225/210/346/236/234 +0 -0
- package/public/other/advanced/svg/FeDisplacementMap//344/275/215/347/275/256/346/233/277/346/215/242/346/273/244/351/225/234 +0 -0
- package/public/other/advanced/svg/FeTurbulence/FeTurbulence.vue +0 -28
- package/public/other/advanced/svg/FeTurbulence/example/Image.vue +0 -41
- package/public/other/advanced/svg/FeTurbulence/example//346/225/205/351/232/234/346/263/242/347/272/271/346/225/210/346/236/234 +0 -0
- package/public/other/advanced/svg/FeTurbulence//346/271/215/346/265/201/346/273/244/351/225/234 +0 -0
- package/public/other/canvas/base/Document.vue +0 -15
- package/public/other/canvas/base/Using.vue +0 -125
- package/public/other/canvas/burrow/Clip.vue +0 -66
- package/public/other/canvas/burrow/Document.vue +0 -36
- package/public/other/canvas/burrow/Erase.vue +0 -58
- package/public/other/canvas/burrow/NonZeroSurroundRule.vue +0 -70
- package/public/other/canvas/clip/Clip.vue +0 -58
- package/public/other/canvas/clip/Document.vue +0 -26
- package/public/other/canvas/definition/Document.vue +0 -26
- package/public/other/canvas/definition/Using.vue +0 -60
- package/public/other/echarts/basic/Document.vue +0 -36
- package/public/other/echarts/basic/Label.vue +0 -98
- package/public/other/echarts/data_zoom/Document.vue +0 -38
- package/public/other/echarts/data_zoom/Using.vue +0 -119
- package/public/other/echarts/data_zoom/img.svg +0 -33
- package/public/other/echarts/gauge/Document.vue +0 -38
- package/public/other/echarts/gauge/Gauge.vue +0 -340
- package/public/other/echarts/gauge//344/273/252/350/241/250/347/233/230 +0 -0
- package/public/other/echarts/liquidfill/Document.vue +0 -46
- package/public/other/echarts/liquidfill/Using.vue +0 -239
- package/public/other/git/sample_set/Document.vue +0 -43
- package/public/other/git/sample_set/img/img.png +0 -0
- package/public/other/git/sample_set/img/img_1.png +0 -0
- package/public/other/git/sample_set/img/img_2.png +0 -0
- package/public/other/layout/flex/Advanced.vue +0 -104
- package/public/other/layout/flex/Advanced2.vue +0 -181
- package/public/other/layout/flex/Base.vue +0 -48
- package/public/other/layout/flex/Document.vue +0 -57
- package/public/other/layout/flex/Grid.vue +0 -54
- package/public/other/layout/flex/Height100.vue +0 -35
- package/public/other/layout/flex/intro.md +0 -1
- package/public/other/layout/grid/Base.vue +0 -29
- package/public/other/layout/grid/Document.vue +0 -54
- package/public/other/layout/grid/Grid.vue +0 -28
- package/public/other/layout/grid/Height100.vue +0 -35
- package/public/other/layout/grid/intro.md +0 -1
- package/public/other/navigation/new_tab_page/Document.vue +0 -18
- package/public/other/navigation/new_tab_page/OpenNewTabPage.vue +0 -7
- package/public/other/navigation/new_tab_page/new-tab-page-demo.html +0 -450
- package/public/other/network/sse/Document.vue +0 -21
- package/public/other/network/sse/Using.vue +0 -24
- package/public/other/network/sse/server/app.ts +0 -62
- package/public/other/network/sse/server/static/text.md +0 -99
- package/public/other/network/sse/server/utils/sleep.ts +0 -5
- package/public/other/observer/mutation_observer/Document.vue +0 -15
- package/public/other/observer/mutation_observer/Using.vue +0 -46
- package/public/other/optimize/Document.vue +0 -19
- package/public/other/optimize/HeavyComp.vue +0 -19
- package/public/other/optimize/Using.vue +0 -14
- package/public/other/optimize/useDefer.ts +0 -28
- package/public/other/svg/base/BasicUsing.vue +0 -12
- package/public/other/svg/base/Document.vue +0 -24
- package/public/other/svg/base/FeDisplacementMap/FeDisplacementMap.vue +0 -30
- package/public/other/svg/base/FeDisplacementMap/example/Image.vue +0 -41
- package/public/other/svg/base/FeDisplacementMap/example//346/225/205/351/232/234/346/263/242/347/272/271/346/225/210/346/236/234 +0 -0
- package/public/other/svg/base/FeDisplacementMap//344/275/215/347/275/256/346/233/277/346/215/242/346/273/244/351/225/234 +0 -0
- package/public/other/svg/base/FeTurbulence/FeTurbulence.vue +0 -28
- package/public/other/svg/base/FeTurbulence/example/Image.vue +0 -41
- package/public/other/svg/base/FeTurbulence/example//346/225/205/351/232/234/346/263/242/347/272/271/346/225/210/346/236/234 +0 -0
- package/public/other/svg/base/FeTurbulence//346/271/215/346/265/201/346/273/244/351/225/234 +0 -0
- package/public/other/threejs/base/Document.vue +0 -17
- package/public/other/threejs/base/Using.vue +0 -127
- package/public/other/threejs/controller_sync/Document.vue +0 -15
- package/public/other/threejs/controller_sync/Using.vue +0 -347
- package/public/other/threejs/controller_sync/bone//345/217/214/350/204/232/345/206/205/344/276/247/350/270/242/347/220/203.fbx +0 -0
- package/public/other/threejs/controller_sync/motion//345/217/214/350/204/232/345/206/205/344/276/247/350/270/242/347/220/203.fbx +0 -0
- package/public/other/threejs/controller_sync/scene/EnvMapTexture.jpg +0 -0
- package/public/other/threejs/controller_sync/scene//347/257/256/347/220/203/345/234/272.glb +0 -0
- package/public/other/threejs/controller_sync/scene//347/276/275/346/257/233/347/220/203/345/234/272.glb +0 -0
- package/public/other/threejs/phoenix/Document.vue +0 -17
- package/public/other/threejs/phoenix/Using.vue +0 -79
- package/public/other/vue/life_cycle/Child.vue +0 -43
- package/public/other/vue/life_cycle/Document.vue +0 -15
- package/public/other/vue/life_cycle/Using.vue +0 -16
- package/public/utils/e_echarts_util/Document.vue +0 -14
- package/public/utils/e_echarts_util/Using.vue +0 -81
- package/public/utils/e_image_util/Document.vue +0 -15
- package/public/utils/e_image_util/Using.vue +0 -24
- package/public/utils/e_image_util/author_avatar.png +0 -0
- package/public/utils/e_uuid_util/Document.vue +0 -15
- package/public/utils/e_uuid_util/Using.vue +0 -13
- package/public/utils/type_utils/Document.vue +0 -16
- package/public/utils/type_utils/TupleType.vue +0 -16
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { onMounted, useTemplateRef } from 'vue';
|
|
3
|
-
|
|
4
|
-
const canvasRef = useTemplateRef<HTMLCanvasElement>('flag');
|
|
5
|
-
|
|
6
|
-
onMounted(() => {
|
|
7
|
-
const canvas = canvasRef.value!;
|
|
8
|
-
const cssWidth = canvas.offsetWidth;
|
|
9
|
-
const whR = 3 / 2;
|
|
10
|
-
|
|
11
|
-
canvas.width = cssWidth;
|
|
12
|
-
canvas.height = cssWidth / whR;
|
|
13
|
-
|
|
14
|
-
const ctx = canvas.getContext('2d')!;
|
|
15
|
-
|
|
16
|
-
// 红色旗面
|
|
17
|
-
ctx.fillStyle = '#DE2910';
|
|
18
|
-
ctx.fillRect(0, 0, canvas.width, canvas.height);
|
|
19
|
-
|
|
20
|
-
// 逻辑网格:
|
|
21
|
-
const logicW = 15;
|
|
22
|
-
const ceilWidth = canvas.width / 2 / logicW; // 每格像素
|
|
23
|
-
|
|
24
|
-
// // 显示网格
|
|
25
|
-
// ctx.strokeStyle = '#000';
|
|
26
|
-
// ctx.lineWidth = 1;
|
|
27
|
-
// for (let i = 1; i <= logicW / whR; i++) {
|
|
28
|
-
// ctx.beginPath();
|
|
29
|
-
// ctx.moveTo(0, i * ceilWidth);
|
|
30
|
-
// ctx.lineTo(canvas.width, i * ceilWidth);
|
|
31
|
-
// ctx.stroke();
|
|
32
|
-
// }
|
|
33
|
-
//
|
|
34
|
-
// for (let i = 1; i <= logicW; i++) {
|
|
35
|
-
// ctx.beginPath();
|
|
36
|
-
// ctx.moveTo(i * ceilWidth, 0);
|
|
37
|
-
// ctx.lineTo(i * ceilWidth, canvas.height);
|
|
38
|
-
// ctx.stroke();
|
|
39
|
-
// }
|
|
40
|
-
|
|
41
|
-
function logicToPixel(lx: number, ly: number) {
|
|
42
|
-
return { x: lx * ceilWidth, y: ly * ceilWidth };
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
// 画五角星(逻辑坐标)
|
|
46
|
-
function drawStar(lx: number, ly: number, lr: number, rotate: number) {
|
|
47
|
-
const { x, y } = logicToPixel(lx, ly);
|
|
48
|
-
const r = lr * ceilWidth;
|
|
49
|
-
ctx.save();
|
|
50
|
-
ctx.translate(x, y);
|
|
51
|
-
ctx.rotate(rotate);
|
|
52
|
-
ctx.beginPath();
|
|
53
|
-
const out = r;
|
|
54
|
-
const inn = r * 0.381966;
|
|
55
|
-
for (let i = 0; i < 5; i++) {
|
|
56
|
-
const outerAngle = (i * 2 * Math.PI) / 5 - Math.PI / 2;
|
|
57
|
-
const innerAngle = ((i + 0.5) * 2 * Math.PI) / 5 - Math.PI / 2;
|
|
58
|
-
const xo = out * Math.cos(outerAngle);
|
|
59
|
-
const yo = out * Math.sin(outerAngle);
|
|
60
|
-
const xi = inn * Math.cos(innerAngle);
|
|
61
|
-
const yi = inn * Math.sin(innerAngle);
|
|
62
|
-
if (i === 0) ctx.moveTo(xo, yo);
|
|
63
|
-
else ctx.lineTo(xo, yo);
|
|
64
|
-
ctx.lineTo(xi, yi);
|
|
65
|
-
}
|
|
66
|
-
ctx.closePath();
|
|
67
|
-
ctx.fillStyle = '#FFDE00';
|
|
68
|
-
ctx.fill();
|
|
69
|
-
ctx.restore();
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
// 大星
|
|
73
|
-
const bigX = 5;
|
|
74
|
-
const bigY = 5;
|
|
75
|
-
const bigR = 3;
|
|
76
|
-
drawStar(bigX, bigY, bigR, 0);
|
|
77
|
-
|
|
78
|
-
// 小星:坐标 + 旋转角(星尖指向大星中心)
|
|
79
|
-
const smallStars = [
|
|
80
|
-
{
|
|
81
|
-
x: 10,
|
|
82
|
-
y: 2,
|
|
83
|
-
r: 1,
|
|
84
|
-
ang: Math.atan2(bigY - 2, bigX - 10) + Math.PI / 2,
|
|
85
|
-
},
|
|
86
|
-
{
|
|
87
|
-
x: 12,
|
|
88
|
-
y: 4,
|
|
89
|
-
r: 1,
|
|
90
|
-
ang: Math.atan2(bigY - 4, bigX - 12) + Math.PI / 2,
|
|
91
|
-
},
|
|
92
|
-
{
|
|
93
|
-
x: 12,
|
|
94
|
-
y: 7,
|
|
95
|
-
r: 1,
|
|
96
|
-
ang: Math.atan2(bigY - 7, bigX - 12) + Math.PI / 2,
|
|
97
|
-
},
|
|
98
|
-
{
|
|
99
|
-
x: 10,
|
|
100
|
-
y: 9,
|
|
101
|
-
r: 1,
|
|
102
|
-
ang: Math.atan2(bigY - 9, bigX - 10) + Math.PI / 2,
|
|
103
|
-
},
|
|
104
|
-
];
|
|
105
|
-
|
|
106
|
-
for (const s of smallStars) {
|
|
107
|
-
drawStar(s.x, s.y, s.r, s.ang);
|
|
108
|
-
// 五角星之间的连线
|
|
109
|
-
// ctx.beginPath();
|
|
110
|
-
// ctx.moveTo(s.x * ceilWidth, s.y * ceilWidth);
|
|
111
|
-
// ctx.lineTo(5 * ceilWidth, 5 * ceilWidth);
|
|
112
|
-
// ctx.stroke();
|
|
113
|
-
}
|
|
114
|
-
});
|
|
115
|
-
</script>
|
|
116
|
-
|
|
117
|
-
<template>
|
|
118
|
-
<canvas ref="flag"></canvas>
|
|
119
|
-
</template>
|
|
120
|
-
|
|
121
|
-
<style scoped lang="scss">
|
|
122
|
-
canvas {
|
|
123
|
-
width: 100%;
|
|
124
|
-
}
|
|
125
|
-
</style>
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { onMounted, useTemplateRef } from 'vue';
|
|
3
|
-
|
|
4
|
-
const usingRef = useTemplateRef<HTMLCanvasElement>('using');
|
|
5
|
-
onMounted(() => {
|
|
6
|
-
const canvas = usingRef.value!.querySelector('canvas') as HTMLCanvasElement;
|
|
7
|
-
const ctx = canvas.getContext('2d')!;
|
|
8
|
-
/* 让 canvas 内部像素尺寸与 css 尺寸一致,避免拉伸 */
|
|
9
|
-
const { width, height } = canvas.getBoundingClientRect();
|
|
10
|
-
canvas.width = width;
|
|
11
|
-
canvas.height = height;
|
|
12
|
-
ctx.fillStyle = '#5a8bea';
|
|
13
|
-
ctx.fillRect(0, 0, width, height); // 整屏背景
|
|
14
|
-
// 1. 保存画布状态
|
|
15
|
-
ctx.save();
|
|
16
|
-
|
|
17
|
-
// 2. 创建圆形路径作为裁剪区域
|
|
18
|
-
ctx.beginPath();
|
|
19
|
-
ctx.arc(width / 2, height / 2, 160, 0, Math.PI * 2);
|
|
20
|
-
ctx.clip();
|
|
21
|
-
|
|
22
|
-
// 3. 清除这块区域(变成透明)
|
|
23
|
-
ctx.clearRect(0, 0, width, height);
|
|
24
|
-
|
|
25
|
-
// 4. 恢复状态,后续绘制不再受 clip 影响
|
|
26
|
-
ctx.restore();
|
|
27
|
-
});
|
|
28
|
-
</script>
|
|
29
|
-
|
|
30
|
-
<template>
|
|
31
|
-
<div class="using" ref="using">
|
|
32
|
-
我是 Canvas 下的元素(渐变背景)
|
|
33
|
-
<canvas />
|
|
34
|
-
</div>
|
|
35
|
-
</template>
|
|
36
|
-
|
|
37
|
-
<style scoped lang="scss">
|
|
38
|
-
.using {
|
|
39
|
-
height: 400px;
|
|
40
|
-
position: relative;
|
|
41
|
-
display: grid;
|
|
42
|
-
place-items: center;
|
|
43
|
-
background: linear-gradient(-45deg, #4d9eff, #ef58a9);
|
|
44
|
-
background-size: 200% 200%;
|
|
45
|
-
animation: background 3s linear infinite;
|
|
46
|
-
|
|
47
|
-
// 动画
|
|
48
|
-
@keyframes background {
|
|
49
|
-
0%,
|
|
50
|
-
100% {
|
|
51
|
-
background-position: 0 0;
|
|
52
|
-
}
|
|
53
|
-
50% {
|
|
54
|
-
background-position: 100% 100%;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
canvas {
|
|
59
|
-
position: absolute;
|
|
60
|
-
inset: 0;
|
|
61
|
-
width: 100%;
|
|
62
|
-
height: 100%;
|
|
63
|
-
filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.81));
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
</style>
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import DemoBox from '@/components/DemoBox/DemoBox.vue';
|
|
3
|
-
import EraseCode from './Erase.vue?raw';
|
|
4
|
-
import Erase from './Erase.vue';
|
|
5
|
-
import ClipCode from './Clip.vue?raw';
|
|
6
|
-
import Clip from './Clip.vue';
|
|
7
|
-
import NonZeroSurroundRuleCode from './NonZeroSurroundRule.vue?raw';
|
|
8
|
-
import NonZeroSurroundRule from './NonZeroSurroundRule.vue';
|
|
9
|
-
import PageLayout from '@/components/PageLayout.vue';
|
|
10
|
-
</script>
|
|
11
|
-
|
|
12
|
-
<template>
|
|
13
|
-
<PageLayout>
|
|
14
|
-
<DemoBox :libs="[]" title="介绍">
|
|
15
|
-
<template #introduce>
|
|
16
|
-
下面演示的是如何在 canvas 元素上打洞
|
|
17
|
-
</template>
|
|
18
|
-
</DemoBox>
|
|
19
|
-
<DemoBox
|
|
20
|
-
:code="NonZeroSurroundRuleCode"
|
|
21
|
-
:libs="[]"
|
|
22
|
-
title="非零环绕规则"
|
|
23
|
-
>
|
|
24
|
-
<NonZeroSurroundRule />
|
|
25
|
-
<template #description> Three.js 基础用法</template>
|
|
26
|
-
</DemoBox>
|
|
27
|
-
<DemoBox :code="EraseCode" :libs="[]" title="擦掉">
|
|
28
|
-
<Erase />
|
|
29
|
-
<template #description> Three.js 基础用法</template>
|
|
30
|
-
</DemoBox>
|
|
31
|
-
<DemoBox :code="ClipCode" :libs="[]" title="反向裁剪">
|
|
32
|
-
<Clip />
|
|
33
|
-
<template #description> Three.js 基础用法</template>
|
|
34
|
-
</DemoBox>
|
|
35
|
-
</PageLayout>
|
|
36
|
-
</template>
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { onMounted, useTemplateRef } from 'vue';
|
|
3
|
-
|
|
4
|
-
const usingRef = useTemplateRef<HTMLCanvasElement>('using');
|
|
5
|
-
onMounted(() => {
|
|
6
|
-
const canvas = usingRef.value!.querySelector('canvas') as HTMLCanvasElement;
|
|
7
|
-
const ctx = canvas.getContext('2d')!;
|
|
8
|
-
/* 让 canvas 内部像素尺寸与 css 尺寸一致,避免拉伸 */
|
|
9
|
-
const { width, height } = canvas.getBoundingClientRect();
|
|
10
|
-
canvas.width = width;
|
|
11
|
-
canvas.height = height;
|
|
12
|
-
ctx.fillStyle = '#5a8bea';
|
|
13
|
-
ctx.fillRect(0, 0, width, height); // 整屏背景
|
|
14
|
-
|
|
15
|
-
ctx.globalCompositeOperation = 'destination-out'; // 把接下来画的内容“抠掉”
|
|
16
|
-
ctx.beginPath();
|
|
17
|
-
ctx.arc(width / 2, height / 2, 160, 0, Math.PI * 2);
|
|
18
|
-
ctx.fill();
|
|
19
|
-
});
|
|
20
|
-
</script>
|
|
21
|
-
|
|
22
|
-
<template>
|
|
23
|
-
<div class="using" ref="using">
|
|
24
|
-
我是 Canvas 下的元素(渐变背景)
|
|
25
|
-
<canvas />
|
|
26
|
-
</div>
|
|
27
|
-
</template>
|
|
28
|
-
|
|
29
|
-
<style scoped lang="scss">
|
|
30
|
-
.using {
|
|
31
|
-
height: 400px;
|
|
32
|
-
position: relative;
|
|
33
|
-
display: grid;
|
|
34
|
-
place-items: center;
|
|
35
|
-
background: linear-gradient(-45deg, #4d9eff, #ef58a9);
|
|
36
|
-
background-size: 200% 200%;
|
|
37
|
-
animation: background 3s linear infinite;
|
|
38
|
-
|
|
39
|
-
// 动画
|
|
40
|
-
@keyframes background {
|
|
41
|
-
0%,
|
|
42
|
-
100% {
|
|
43
|
-
background-position: 0 0;
|
|
44
|
-
}
|
|
45
|
-
50% {
|
|
46
|
-
background-position: 100% 100%;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
canvas {
|
|
51
|
-
position: absolute;
|
|
52
|
-
inset: 0;
|
|
53
|
-
width: 100%;
|
|
54
|
-
height: 100%;
|
|
55
|
-
filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.81));
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
</style>
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { onMounted, useTemplateRef } from 'vue';
|
|
3
|
-
|
|
4
|
-
const usingRef = useTemplateRef<HTMLCanvasElement>('using');
|
|
5
|
-
onMounted(() => {
|
|
6
|
-
const canvas = usingRef.value!.querySelector('canvas') as HTMLCanvasElement;
|
|
7
|
-
const ctx = canvas.getContext('2d')!;
|
|
8
|
-
|
|
9
|
-
/* 让画布像素与 CSS 尺寸一致 */
|
|
10
|
-
const { width, height } = canvas.getBoundingClientRect();
|
|
11
|
-
canvas.width = width;
|
|
12
|
-
canvas.height = height;
|
|
13
|
-
|
|
14
|
-
/* 关键:清空画布,保持透明 */
|
|
15
|
-
ctx.clearRect(0, 0, width, height);
|
|
16
|
-
|
|
17
|
-
/* 1. 整屏矩形(顺时针) */
|
|
18
|
-
ctx.beginPath();
|
|
19
|
-
ctx.rect(0, 0, width, height);
|
|
20
|
-
|
|
21
|
-
/* 2. 中间圆(逆时针,与矩形方向相反即可触发 evenodd)*/
|
|
22
|
-
const cx = width / 2;
|
|
23
|
-
const cy = height / 2;
|
|
24
|
-
const r = 160;
|
|
25
|
-
ctx.arc(cx, cy, r, 0, Math.PI * 2);
|
|
26
|
-
|
|
27
|
-
/* 3. 填充颜色(任意色都行,中间会被挖空) */
|
|
28
|
-
ctx.fillStyle = 'rgb(153,190,246)'; // 半透明蓝色,仅作演示
|
|
29
|
-
ctx.fill('evenodd');
|
|
30
|
-
});
|
|
31
|
-
</script>
|
|
32
|
-
|
|
33
|
-
<template>
|
|
34
|
-
<div class="using" ref="using">
|
|
35
|
-
我是 Canvas 下的元素(渐变背景)
|
|
36
|
-
<canvas />
|
|
37
|
-
</div>
|
|
38
|
-
</template>
|
|
39
|
-
|
|
40
|
-
<style scoped lang="scss">
|
|
41
|
-
.using {
|
|
42
|
-
height: 400px;
|
|
43
|
-
position: relative;
|
|
44
|
-
display: grid;
|
|
45
|
-
place-items: center;
|
|
46
|
-
background: linear-gradient(-45deg, #4d9eff, #ef58a9);
|
|
47
|
-
background-size: 200% 200%;
|
|
48
|
-
animation: background 3s linear infinite;
|
|
49
|
-
|
|
50
|
-
// 动画
|
|
51
|
-
@keyframes background {
|
|
52
|
-
0%,
|
|
53
|
-
100% {
|
|
54
|
-
background-position: 0 0;
|
|
55
|
-
}
|
|
56
|
-
50% {
|
|
57
|
-
background-position: 100% 100%;
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
canvas {
|
|
62
|
-
position: absolute;
|
|
63
|
-
inset: 0;
|
|
64
|
-
width: 100%;
|
|
65
|
-
height: 100%;
|
|
66
|
-
pointer-events: none; /* 可选:让鼠标事件穿透 */
|
|
67
|
-
filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.81));
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
</style>
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { onMounted, useTemplateRef } from 'vue';
|
|
3
|
-
|
|
4
|
-
const usingRef = useTemplateRef<HTMLCanvasElement>('using');
|
|
5
|
-
onMounted(() => {
|
|
6
|
-
const canvas = usingRef.value!.querySelector('canvas') as HTMLCanvasElement;
|
|
7
|
-
|
|
8
|
-
/* 让 canvas 内部像素尺寸与 css 尺寸一致,避免拉伸 */
|
|
9
|
-
const { width, height } = canvas.getBoundingClientRect();
|
|
10
|
-
|
|
11
|
-
const canvas2 = document.createElement('canvas');
|
|
12
|
-
canvas2.width = width;
|
|
13
|
-
canvas2.height = height;
|
|
14
|
-
const ctx2 = canvas2.getContext('2d')!;
|
|
15
|
-
|
|
16
|
-
ctx2.fillStyle = '#c64b4b';
|
|
17
|
-
|
|
18
|
-
// 1. 保存画布状态
|
|
19
|
-
ctx2.fillRect(0, 0, width, height);
|
|
20
|
-
|
|
21
|
-
const ctx = canvas.getContext('2d')!;
|
|
22
|
-
canvas.width = width;
|
|
23
|
-
canvas.height = height;
|
|
24
|
-
|
|
25
|
-
ctx.drawImage(canvas2, 0 - width / 2, 0, width, height);
|
|
26
|
-
});
|
|
27
|
-
</script>
|
|
28
|
-
|
|
29
|
-
<template>
|
|
30
|
-
<div class="using" ref="using">
|
|
31
|
-
<canvas />
|
|
32
|
-
</div>
|
|
33
|
-
</template>
|
|
34
|
-
|
|
35
|
-
<style scoped lang="scss">
|
|
36
|
-
.using {
|
|
37
|
-
height: 400px;
|
|
38
|
-
background: linear-gradient(-45deg, #4d9eff, #ef58a9);
|
|
39
|
-
background-size: 200% 200%;
|
|
40
|
-
animation: background 3s linear infinite;
|
|
41
|
-
|
|
42
|
-
// 动画
|
|
43
|
-
@keyframes background {
|
|
44
|
-
0%,
|
|
45
|
-
100% {
|
|
46
|
-
background-position: 0 0;
|
|
47
|
-
}
|
|
48
|
-
50% {
|
|
49
|
-
background-position: 100% 100%;
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
canvas {
|
|
54
|
-
width: 300px;
|
|
55
|
-
height: 100%;
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
</style>
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import DemoBox from '@/components/DemoBox/DemoBox.vue';
|
|
3
|
-
import ClipCode from './Clip.vue?raw';
|
|
4
|
-
import Clip from './Clip.vue';
|
|
5
|
-
import PageLayout from '@/components/PageLayout.vue';
|
|
6
|
-
</script>
|
|
7
|
-
|
|
8
|
-
<template>
|
|
9
|
-
<PageLayout>
|
|
10
|
-
<DemoBox :libs="[]" title="介绍">
|
|
11
|
-
<p>下面演示的是如何在 canvas 元素上打洞</p>
|
|
12
|
-
</DemoBox>
|
|
13
|
-
|
|
14
|
-
<DemoBox :code="ClipCode" :libs="[]" title="反向裁剪">
|
|
15
|
-
<Clip />
|
|
16
|
-
<template #description> Three.js 基础用法</template>
|
|
17
|
-
</DemoBox>
|
|
18
|
-
</PageLayout>
|
|
19
|
-
</template>
|
|
20
|
-
|
|
21
|
-
<style lang="scss" scoped>
|
|
22
|
-
p {
|
|
23
|
-
padding: 10px;
|
|
24
|
-
color: #666666;
|
|
25
|
-
}
|
|
26
|
-
</style>
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import DemoBox from '@/components/DemoBox/DemoBox.vue';
|
|
3
|
-
import UsingCode from './Using.vue?raw';
|
|
4
|
-
import Using from './Using.vue';
|
|
5
|
-
import PageLayout from '@/components/PageLayout.vue';
|
|
6
|
-
</script>
|
|
7
|
-
|
|
8
|
-
<template>
|
|
9
|
-
<PageLayout>
|
|
10
|
-
<DemoBox :libs="[]" title="介绍">
|
|
11
|
-
<p>windows</p>
|
|
12
|
-
</DemoBox>
|
|
13
|
-
|
|
14
|
-
<DemoBox :code="UsingCode" :libs="[]" title="擦掉">
|
|
15
|
-
<Using />
|
|
16
|
-
<template #description> Three.js 基础用法</template>
|
|
17
|
-
</DemoBox>
|
|
18
|
-
</PageLayout>
|
|
19
|
-
</template>
|
|
20
|
-
|
|
21
|
-
<style lang="scss" scoped>
|
|
22
|
-
p {
|
|
23
|
-
padding: 10px;
|
|
24
|
-
color: #666666;
|
|
25
|
-
}
|
|
26
|
-
</style>
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { onMounted, onUnmounted, useTemplateRef } from 'vue';
|
|
3
|
-
|
|
4
|
-
const usingRef = useTemplateRef<HTMLCanvasElement>('using');
|
|
5
|
-
|
|
6
|
-
const ob = new ResizeObserver(() => {
|
|
7
|
-
const leftCanvas = usingRef.value!.querySelector(
|
|
8
|
-
'canvas.left'
|
|
9
|
-
) as HTMLCanvasElement;
|
|
10
|
-
leftCanvas.width = leftCanvas.clientWidth;
|
|
11
|
-
leftCanvas.height = leftCanvas.clientHeight;
|
|
12
|
-
const ctx = leftCanvas.getContext('2d')!;
|
|
13
|
-
ctx.clearRect(0, 0, leftCanvas.width, leftCanvas.height);
|
|
14
|
-
const fontSize = 20 * window.devicePixelRatio;
|
|
15
|
-
ctx.font = `${fontSize}px serif`;
|
|
16
|
-
ctx.fillStyle = 'red';
|
|
17
|
-
ctx.fillText('清晰度测试文字 (考虑dpi)', 0, 0);
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
onMounted(() => {
|
|
21
|
-
const leftCanvas = usingRef.value!.querySelector(
|
|
22
|
-
'canvas.left'
|
|
23
|
-
) as HTMLCanvasElement;
|
|
24
|
-
ob.observe(leftCanvas);
|
|
25
|
-
|
|
26
|
-
const rightCanvas = usingRef.value!.querySelector(
|
|
27
|
-
'canvas.right'
|
|
28
|
-
) as HTMLCanvasElement;
|
|
29
|
-
rightCanvas.width = rightCanvas.clientWidth;
|
|
30
|
-
rightCanvas.height = rightCanvas.clientHeight;
|
|
31
|
-
const ctx = rightCanvas.getContext('2d')!;
|
|
32
|
-
ctx.clearRect(0, 0, rightCanvas.width, rightCanvas.height);
|
|
33
|
-
ctx.font = '28px serif';
|
|
34
|
-
ctx.fillStyle = 'red';
|
|
35
|
-
ctx.fillText('清晰度测试文字 (不考虑dpi)', 0, 0);
|
|
36
|
-
});
|
|
37
|
-
onUnmounted(() => {
|
|
38
|
-
ob.disconnect();
|
|
39
|
-
});
|
|
40
|
-
</script>
|
|
41
|
-
|
|
42
|
-
<template>
|
|
43
|
-
<div class="using" ref="using">
|
|
44
|
-
<canvas class="left" />
|
|
45
|
-
<canvas class="right" />
|
|
46
|
-
</div>
|
|
47
|
-
</template>
|
|
48
|
-
|
|
49
|
-
<style scoped lang="scss">
|
|
50
|
-
.using {
|
|
51
|
-
height: 400px;
|
|
52
|
-
display: flex;
|
|
53
|
-
justify-content: space-between;
|
|
54
|
-
|
|
55
|
-
canvas {
|
|
56
|
-
border: 1px solid #ccc;
|
|
57
|
-
flex: 1;
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
</style>
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import DemoBox from '@/components/DemoBox/DemoBox.vue';
|
|
3
|
-
import LabelCode from './Label.vue?raw';
|
|
4
|
-
import Label from './Label.vue';
|
|
5
|
-
|
|
6
|
-
import PageLayout from '@/components/PageLayout.vue';
|
|
7
|
-
</script>
|
|
8
|
-
|
|
9
|
-
<template>
|
|
10
|
-
<PageLayout>
|
|
11
|
-
<DemoBox :code="LabelCode" :libs="['echarts']" title="开启两端刻度">
|
|
12
|
-
<Label />
|
|
13
|
-
<template #description>
|
|
14
|
-
按钮有五种类型:主按钮、次按钮、虚线按钮、文本按钮和链接按钮。主按钮在同一个操作区域最多出现一次。
|
|
15
|
-
</template>
|
|
16
|
-
</DemoBox>
|
|
17
|
-
</PageLayout>
|
|
18
|
-
</template>
|
|
19
|
-
|
|
20
|
-
<style scoped lang="scss">
|
|
21
|
-
.time-picker-demo {
|
|
22
|
-
display: flex;
|
|
23
|
-
flex-direction: row;
|
|
24
|
-
overflow: auto;
|
|
25
|
-
|
|
26
|
-
.left {
|
|
27
|
-
flex: 1;
|
|
28
|
-
overflow: auto;
|
|
29
|
-
padding: 30px;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
.right {
|
|
33
|
-
width: 260px;
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
</style>
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { onMounted, onUnmounted, useTemplateRef } from 'vue';
|
|
3
|
-
import * as echarts from 'echarts';
|
|
4
|
-
|
|
5
|
-
const boxRef = useTemplateRef<HTMLElement>('boxRef');
|
|
6
|
-
let chart1: echarts.ECharts;
|
|
7
|
-
const initChart1 = () => {
|
|
8
|
-
chart1?.dispose();
|
|
9
|
-
chart1 = echarts.init(boxRef.value!);
|
|
10
|
-
onUnmounted(() => {
|
|
11
|
-
chart1.dispose();
|
|
12
|
-
});
|
|
13
|
-
};
|
|
14
|
-
// 临时转成时间戳给 ECharts 用(不改 data 常量)
|
|
15
|
-
|
|
16
|
-
const updateChart = () => {
|
|
17
|
-
const data = [
|
|
18
|
-
['2000-06-05', 116],
|
|
19
|
-
['2000-06-06', 129],
|
|
20
|
-
['2000-06-07', 135],
|
|
21
|
-
['2000-06-08', 86],
|
|
22
|
-
['2000-06-09', 73],
|
|
23
|
-
['2000-06-10', 85],
|
|
24
|
-
['2000-06-11', 73],
|
|
25
|
-
['2000-06-12', 68],
|
|
26
|
-
['2000-06-13', 92],
|
|
27
|
-
['2000-06-14', 130],
|
|
28
|
-
['2000-06-15', 245],
|
|
29
|
-
['2000-06-16', 139],
|
|
30
|
-
['2000-06-17', 115],
|
|
31
|
-
['2000-06-18', 111],
|
|
32
|
-
['2000-06-19', 309],
|
|
33
|
-
['2000-06-20', 206],
|
|
34
|
-
['2000-06-21', 137],
|
|
35
|
-
['2000-06-22', 128],
|
|
36
|
-
['2000-06-23', 85],
|
|
37
|
-
['2000-06-24', 94],
|
|
38
|
-
['2000-06-25', 71],
|
|
39
|
-
['2000-06-26', 106],
|
|
40
|
-
['2000-06-27', 84],
|
|
41
|
-
['2000-06-28', 93],
|
|
42
|
-
['2000-06-30', 73],
|
|
43
|
-
['2000-07-01', 83],
|
|
44
|
-
['2000-07-02', 125],
|
|
45
|
-
['2000-07-03', 107],
|
|
46
|
-
['2000-07-07', 106],
|
|
47
|
-
['2000-07-08', 107],
|
|
48
|
-
] as [string, number][];
|
|
49
|
-
const option: echarts.EChartsOption = {
|
|
50
|
-
title: [
|
|
51
|
-
{
|
|
52
|
-
left: 'center',
|
|
53
|
-
text: 'Gradient along the y axis',
|
|
54
|
-
},
|
|
55
|
-
],
|
|
56
|
-
tooltip: {
|
|
57
|
-
trigger: 'axis',
|
|
58
|
-
},
|
|
59
|
-
dataZoom: [
|
|
60
|
-
{
|
|
61
|
-
type: 'inside',
|
|
62
|
-
},
|
|
63
|
-
],
|
|
64
|
-
grid: {
|
|
65
|
-
containLabel: true,
|
|
66
|
-
},
|
|
67
|
-
yAxis: {
|
|
68
|
-
type: 'value',
|
|
69
|
-
},
|
|
70
|
-
xAxis: {
|
|
71
|
-
type: 'category',
|
|
72
|
-
boundaryGap: false,
|
|
73
|
-
data: data.map((item) => item[0]),
|
|
74
|
-
axisLabel: {
|
|
75
|
-
showMinLabel: true,
|
|
76
|
-
showMaxLabel: true,
|
|
77
|
-
},
|
|
78
|
-
},
|
|
79
|
-
series: [{ type: 'line', data }],
|
|
80
|
-
};
|
|
81
|
-
chart1!.setOption(option);
|
|
82
|
-
};
|
|
83
|
-
|
|
84
|
-
onMounted(() => {
|
|
85
|
-
initChart1();
|
|
86
|
-
updateChart();
|
|
87
|
-
});
|
|
88
|
-
</script>
|
|
89
|
-
|
|
90
|
-
<template>
|
|
91
|
-
<div ref="boxRef" class="chart" />
|
|
92
|
-
</template>
|
|
93
|
-
|
|
94
|
-
<style lang="scss" scoped>
|
|
95
|
-
.chart {
|
|
96
|
-
height: 300px;
|
|
97
|
-
}
|
|
98
|
-
</style>
|