cnhis-design-vue 3.1.13-beta.0 → 3.1.13-beta.11
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/es/packages/big-table/src/BigTable.vue.d.ts +3 -16
- package/es/packages/big-table/src/BigTable.vue_vue_type_script_setup_true_lang.js +40 -21
- package/es/packages/big-table/src/bigTableEmits.js +2 -1
- package/es/packages/big-table/src/utils.js +2 -1
- package/es/packages/big-table/style/index.css +5 -0
- package/es/packages/bpmn-workflow/src/BpmnWorkflow.d.ts +5 -0
- package/es/packages/bpmn-workflow/types/BpmnViewer.d.ts +1 -0
- package/es/packages/bpmn-workflow/types/ModelingModule.d.ts +1 -0
- package/es/packages/bpmn-workflow/types/MoveCanvasModule.d.ts +1 -0
- package/es/packages/button-print/index.d.ts +15 -1
- package/es/packages/button-print/src/ButtonPrint.vue.d.ts +199 -185
- package/es/packages/button-print/src/ButtonPrint.vue_vue_type_script_setup_true_lang.js +39 -4
- package/es/packages/button-print/src/utils/print.d.ts +41 -0
- package/es/packages/button-print/src/utils/print.js +325 -0
- package/es/packages/fabric-chart/index.d.ts +3 -4
- package/es/packages/fabric-chart/src/FabricChart.vue.d.ts +3 -4
- package/es/packages/fabric-chart/src/FabricChart.vue_vue_type_script_setup_true_lang.js +24 -18
- package/es/packages/fabric-chart/src/hooks/useBottom.js +1 -2
- package/es/packages/fabric-chart/src/hooks/useCenter.js +89 -19
- package/es/packages/fabric-chart/src/hooks/useCumputedPoint.d.ts +2 -2
- package/es/packages/fabric-chart/src/hooks/useCumputedPoint.js +27 -13
- package/es/packages/fabric-chart/src/hooks/useDraw.d.ts +1 -1
- package/es/packages/fabric-chart/src/hooks/useDraw.js +64 -7
- package/es/packages/fabric-chart/src/hooks/useLeft.js +83 -22
- package/es/packages/fabric-chart/src/hooks/useOther.js +3 -2
- package/es/packages/fabric-chart/src/hooks/useShadow.js +1 -1
- package/es/packages/fabric-chart/src/hooks/useTop.js +6 -4
- package/es/packages/fabric-chart/src/interface.d.ts +2 -2
- package/es/packages/fabric-chart/src/utils/index.d.ts +6823 -2
- package/es/packages/form-render/index.d.ts +311 -0
- package/es/packages/form-render/src/FormRender.vue.d.ts +313 -2
- package/es/packages/form-render/src/FormRender.vue_vue_type_script_setup_true_lang.js +58 -27
- package/es/packages/form-render/src/components/renderer/cascader.d.ts +7 -1
- package/es/packages/form-render/src/components/renderer/cascader.js +65 -53
- package/es/packages/form-render/src/components/renderer/formItem.d.ts +8 -293
- package/es/packages/form-render/src/components/renderer/formItem.js +137 -2
- package/es/packages/form-render/src/components/renderer/input.js +3 -3
- package/es/packages/form-render/src/components/renderer/select.d.ts +7 -5
- package/es/packages/form-render/src/components/renderer/select.js +35 -40
- package/es/packages/form-render/src/components/renderer/simpleComponent.js +2 -15
- package/es/packages/form-render/src/constants/index.d.ts +2 -1
- package/es/packages/form-render/src/constants/index.js +2 -1
- package/es/packages/form-render/src/hooks/useFieldListAdaptor.js +4 -2
- package/es/packages/form-render/src/hooks/useFormContext.d.ts +2 -1
- package/es/packages/form-render/src/hooks/useFormContext.js +13 -2
- package/es/packages/form-render/src/types/fieldItem.d.ts +58 -7
- package/es/packages/form-render/src/types/index.d.ts +5 -0
- package/es/packages/form-render/src/utils/index.d.ts +13 -4
- package/es/packages/form-render/src/utils/index.js +44 -3
- package/es/packages/form-render/style/index.css +44 -6
- package/es/packages/form-table/src/hooks/useNuiThemeOverrides.d.ts +4 -0
- package/es/packages/form-table/src/hooks/useNuiThemeOverrides.js +18 -0
- package/es/packages/index.css +228 -8
- package/es/packages/index.d.ts +5 -1
- package/es/packages/index.js +12 -1
- package/es/packages/scale-view/src/hooks/scaleview-init.js +1 -5
- package/es/packages/scale-view/src/hooks/scaleview-submit.js +1 -6
- package/es/packages/scale-view/src/hooks/scaleview-validate.js +0 -3
- package/es/packages/shortcut-provider/index.d.ts +17 -0
- package/es/packages/shortcut-provider/index.js +13 -0
- package/es/packages/shortcut-provider/src/ShortcutProvider.js +4 -0
- package/es/packages/shortcut-provider/src/ShortcutProvider.vue.d.ts +15 -0
- package/es/packages/shortcut-provider/src/ShortcutProvider.vue_vue_type_script_setup_true_lang.js +32 -0
- package/es/packages/shortcut-provider/src/constants/index.d.ts +7 -0
- package/es/packages/shortcut-provider/src/constants/index.js +8 -0
- package/es/packages/shortcut-provider/src/hooks/index.d.ts +2 -0
- package/es/packages/shortcut-provider/src/hooks/index.js +2 -0
- package/es/packages/shortcut-provider/src/hooks/useShortcutSignature.d.ts +4 -0
- package/es/packages/shortcut-provider/src/hooks/useShortcutSignature.js +12 -0
- package/es/packages/shortcut-provider/src/hooks/useShortcuts.d.ts +30 -0
- package/es/packages/shortcut-provider/src/hooks/useShortcuts.js +157 -0
- package/es/packages/shortcut-provider/src/types/index.d.ts +30 -0
- package/es/packages/shortcut-provider/src/types/index.js +1 -0
- package/es/packages/shortcut-provider/src/utils/index.d.ts +7 -0
- package/es/packages/shortcut-provider/src/utils/index.js +49 -0
- package/es/packages/shortcut-provider/style/index.css +3 -0
- package/es/packages/shortcut-setter/constant/index.d.ts +4 -0
- package/es/packages/shortcut-setter/constant/index.js +7 -0
- package/es/packages/shortcut-setter/index.d.ts +4258 -0
- package/es/packages/shortcut-setter/index.js +11 -0
- package/es/packages/shortcut-setter/src/ShortcutSetter.js +4 -0
- package/es/packages/shortcut-setter/src/ShortcutSetter.vue.d.ts +4258 -0
- package/es/packages/shortcut-setter/src/ShortcutSetter.vue_vue_type_script_setup_true_lang.js +38 -0
- package/es/packages/shortcut-setter/src/ShortcutSetterItem.js +4 -0
- package/es/packages/shortcut-setter/src/ShortcutSetterItem.vue.d.ts +4238 -0
- package/es/packages/shortcut-setter/src/ShortcutSetterItem.vue_vue_type_script_setup_true_lang.js +125 -0
- package/es/packages/shortcut-setter/style/index.css +8 -0
- package/es/packages/steps-wheel/index.d.ts +548 -0
- package/es/packages/steps-wheel/index.js +11 -0
- package/es/packages/steps-wheel/src/StepsWheel.js +4 -0
- package/es/packages/steps-wheel/src/StepsWheel.vue.d.ts +547 -0
- package/es/packages/steps-wheel/src/StepsWheel.vue_vue_type_script_setup_true_lang.js +252 -0
- package/es/packages/steps-wheel/style/index.css +161 -0
- package/es/packages/time-line/index.d.ts +1 -0
- package/es/packages/time-line/src/TimeLine.vue.d.ts +1 -0
- package/es/packages/time-line/src/TimeLine.vue_vue_type_script_setup_true_lang.js +6 -1
- package/es/packages/time-line/style/index.css +7 -2
- package/es/src/types/index.d.ts +1 -0
- package/package.json +153 -153
- package/es/packages/button-print/src/utils/print.es.min.d.ts +0 -2
- package/es/packages/button-print/src/utils/print.es.min.js +0 -2532
- package/test.ts +0 -326
package/es/packages/index.css
CHANGED
|
@@ -249,6 +249,11 @@ body > .vxe-table--tooltip-wrapper {
|
|
|
249
249
|
height: 100%;
|
|
250
250
|
line-height: unset;
|
|
251
251
|
width: 100%;
|
|
252
|
+
display: inline-flex;
|
|
253
|
+
}
|
|
254
|
+
.custom-big-table .vxe-table .vxe-table--header .col--seq .vxe-cell--title,
|
|
255
|
+
.custom-big-table .vxe-table .vxe-table--header .col--checkbox .vxe-cell--title {
|
|
256
|
+
display: inline-block;
|
|
252
257
|
}
|
|
253
258
|
.custom-big-table .vxe-table .vxe-table--footer-wrapper.body--wrapper::-webkit-scrollbar,
|
|
254
259
|
.custom-big-table .vxe-table .vxe-table--body-wrapper::-webkit-scrollbar {
|
|
@@ -2474,11 +2479,13 @@ body > .vxe-table--tooltip-wrapper {
|
|
|
2474
2479
|
font-size: 14px;
|
|
2475
2480
|
margin-bottom: 10px;
|
|
2476
2481
|
}
|
|
2477
|
-
.c-time-line .content-name
|
|
2482
|
+
.c-time-line .content-name,
|
|
2483
|
+
.c-time-line .content-extra {
|
|
2478
2484
|
font-size: 16px;
|
|
2479
2485
|
font-weight: 600;
|
|
2480
2486
|
}
|
|
2481
|
-
.c-time-line .content-name + span
|
|
2487
|
+
.c-time-line .content-name + span,
|
|
2488
|
+
.c-time-line .content-extra + span {
|
|
2482
2489
|
color: #666;
|
|
2483
2490
|
}
|
|
2484
2491
|
.c-time-line .content p {
|
|
@@ -2486,6 +2493,9 @@ body > .vxe-table--tooltip-wrapper {
|
|
|
2486
2493
|
line-height: 20px;
|
|
2487
2494
|
text-align: left;
|
|
2488
2495
|
}
|
|
2496
|
+
.c-time-line .content-extra {
|
|
2497
|
+
margin-bottom: 8px !important;
|
|
2498
|
+
}
|
|
2489
2499
|
.clearfix:after {
|
|
2490
2500
|
visibility: hidden;
|
|
2491
2501
|
display: block;
|
|
@@ -2636,7 +2646,7 @@ body > .vxe-table--tooltip-wrapper {
|
|
|
2636
2646
|
.form-render__wrapper {
|
|
2637
2647
|
display: grid !important;
|
|
2638
2648
|
grid-template-columns: repeat(var(--column), minmax(0px, 1fr));
|
|
2639
|
-
gap: 0
|
|
2649
|
+
gap: 0 16px;
|
|
2640
2650
|
max-height: var(--form-height);
|
|
2641
2651
|
overflow-y: auto;
|
|
2642
2652
|
position: relative;
|
|
@@ -2647,23 +2657,52 @@ body > .vxe-table--tooltip-wrapper {
|
|
|
2647
2657
|
.form-render__formItem .n-date-picker {
|
|
2648
2658
|
width: 100%;
|
|
2649
2659
|
}
|
|
2660
|
+
.form-render__formItemLabel {
|
|
2661
|
+
position: relative;
|
|
2662
|
+
display: flex;
|
|
2663
|
+
align-items: center;
|
|
2664
|
+
}
|
|
2665
|
+
.form-render__formItemLabel--text.has-annotation {
|
|
2666
|
+
margin-right: 15px;
|
|
2667
|
+
}
|
|
2668
|
+
.form-render__formItemLabel--icon {
|
|
2669
|
+
display: inline-flex;
|
|
2670
|
+
align-items: center;
|
|
2671
|
+
}
|
|
2672
|
+
.form-render__formItemLabel--annotation {
|
|
2673
|
+
position: absolute;
|
|
2674
|
+
top: 50%;
|
|
2675
|
+
transform: translateY(-50%);
|
|
2676
|
+
right: calc(var(--icon-right) * 1px);
|
|
2677
|
+
cursor: pointer;
|
|
2678
|
+
color: #0067ee;
|
|
2679
|
+
font-size: 16px;
|
|
2680
|
+
user-select: none;
|
|
2681
|
+
display: inline-flex;
|
|
2682
|
+
align-items: center;
|
|
2683
|
+
}
|
|
2684
|
+
.form-render__formItemLabel--annotation.is-active {
|
|
2685
|
+
color: rgba(255, 152, 40);
|
|
2686
|
+
}
|
|
2650
2687
|
.form-render__linebar {
|
|
2651
2688
|
grid-column: span var(--column) / span var(--column);
|
|
2652
2689
|
}
|
|
2653
2690
|
.form-render__linebarHeader {
|
|
2654
2691
|
cursor: pointer;
|
|
2655
2692
|
display: flex;
|
|
2656
|
-
background: #
|
|
2657
|
-
height:
|
|
2693
|
+
background: #f2f2f2;
|
|
2694
|
+
height: 40px;
|
|
2695
|
+
font-size: 16px;
|
|
2696
|
+
font-weight: 500;
|
|
2658
2697
|
align-items: center;
|
|
2659
2698
|
padding: 0 16px;
|
|
2660
2699
|
margin-bottom: 8px;
|
|
2661
|
-
border:
|
|
2700
|
+
border-radius: 4px;
|
|
2662
2701
|
}
|
|
2663
2702
|
.form-render__linebarItem {
|
|
2664
2703
|
display: grid !important;
|
|
2665
2704
|
grid-template-columns: repeat(var(--column), minmax(0px, 1fr));
|
|
2666
|
-
gap: 0
|
|
2705
|
+
gap: 0 16px;
|
|
2667
2706
|
}
|
|
2668
2707
|
.form-render__inputGroup {
|
|
2669
2708
|
grid-column: span var(--column) / span var(--column);
|
|
@@ -2726,12 +2765,21 @@ body > .vxe-table--tooltip-wrapper {
|
|
|
2726
2765
|
.form-render__complexContent--grid {
|
|
2727
2766
|
display: grid !important;
|
|
2728
2767
|
grid-template-columns: repeat(var(--column), minmax(0px, 1fr));
|
|
2729
|
-
gap: 0
|
|
2768
|
+
gap: 0 16px;
|
|
2730
2769
|
}
|
|
2731
2770
|
.form-render__complexContent--flex {
|
|
2732
2771
|
display: flex !important;
|
|
2733
2772
|
gap: 0 8px;
|
|
2734
2773
|
}
|
|
2774
|
+
.form-render .n-form-item-label {
|
|
2775
|
+
display: inline-flex;
|
|
2776
|
+
}
|
|
2777
|
+
.form-render .n-form-item-label [form-item-hover-show='true'] {
|
|
2778
|
+
visibility: hidden;
|
|
2779
|
+
}
|
|
2780
|
+
.form-render .n-form-item-label:hover [form-item-hover-show='true'] {
|
|
2781
|
+
visibility: visible;
|
|
2782
|
+
}
|
|
2735
2783
|
.c-fabric-chart-popup-tip,
|
|
2736
2784
|
.c-fabric-chart-popup-menu {
|
|
2737
2785
|
position: absolute;
|
|
@@ -2775,3 +2823,175 @@ body > .vxe-table--tooltip-wrapper {
|
|
|
2775
2823
|
.c-fabric-chart-popup-menu > li.no-click:hover {
|
|
2776
2824
|
background: #fff;
|
|
2777
2825
|
}
|
|
2826
|
+
.shortcut-provider {
|
|
2827
|
+
outline: none;
|
|
2828
|
+
}
|
|
2829
|
+
.shortcut-setter-item__wrapper {
|
|
2830
|
+
display: flex;
|
|
2831
|
+
}
|
|
2832
|
+
.shortcut-setter-item__operation {
|
|
2833
|
+
margin-left: 12px;
|
|
2834
|
+
display: flex;
|
|
2835
|
+
gap: 12px;
|
|
2836
|
+
}
|
|
2837
|
+
.stepOut {
|
|
2838
|
+
width: 100%;
|
|
2839
|
+
height: 100%;
|
|
2840
|
+
display: flex;
|
|
2841
|
+
justify-content: center;
|
|
2842
|
+
font-size: 16px;
|
|
2843
|
+
font-weight: 500;
|
|
2844
|
+
font-family: PingFangSC-Medium, PingFang SC;
|
|
2845
|
+
}
|
|
2846
|
+
.stepOut .stepItem {
|
|
2847
|
+
width: 15%;
|
|
2848
|
+
min-width: 65px;
|
|
2849
|
+
height: 180px;
|
|
2850
|
+
float: left;
|
|
2851
|
+
font-family: SimSun;
|
|
2852
|
+
font-size: 16px;
|
|
2853
|
+
text-align: center;
|
|
2854
|
+
position: relative;
|
|
2855
|
+
top: 48px;
|
|
2856
|
+
}
|
|
2857
|
+
.stepOut .stepItem .lineCircleRight {
|
|
2858
|
+
left: 55%;
|
|
2859
|
+
top: 6px;
|
|
2860
|
+
position: absolute;
|
|
2861
|
+
display: block;
|
|
2862
|
+
border-left-color: white;
|
|
2863
|
+
border-left-width: 0px;
|
|
2864
|
+
width: 30%;
|
|
2865
|
+
border-color: white white white white;
|
|
2866
|
+
border-left-style: hidden;
|
|
2867
|
+
border-left: none;
|
|
2868
|
+
border-top: 1px dashed rgba(3, 2, 2, 0.4);
|
|
2869
|
+
border-right: 1px dashed rgba(3, 2, 2, 0.4);
|
|
2870
|
+
border-bottom: 1px dashed rgba(3, 2, 2, 0.4);
|
|
2871
|
+
border-left: 0px dashed rgba(3, 2, 2, 0.4) !important;
|
|
2872
|
+
height: 100%;
|
|
2873
|
+
border-radius: 0px 25px 25px 0px;
|
|
2874
|
+
}
|
|
2875
|
+
.stepOut .stepItem .lineCircleLeft {
|
|
2876
|
+
left: 15%;
|
|
2877
|
+
top: 6px;
|
|
2878
|
+
position: absolute;
|
|
2879
|
+
display: block;
|
|
2880
|
+
border-left-color: white;
|
|
2881
|
+
border-left-width: 0px;
|
|
2882
|
+
width: 30%;
|
|
2883
|
+
border-color: white white white white;
|
|
2884
|
+
border-left-style: hidden;
|
|
2885
|
+
border-left: none;
|
|
2886
|
+
border-top: 1px dashed rgba(3, 2, 2, 0.4);
|
|
2887
|
+
border-right: 0px dashed rgba(3, 2, 2, 0.4) !important;
|
|
2888
|
+
border-bottom: 1px dashed rgba(3, 2, 2, 0.4);
|
|
2889
|
+
border-left: 1px dashed rgba(3, 2, 2, 0.4);
|
|
2890
|
+
height: 100%;
|
|
2891
|
+
border-radius: 25px 0px 0px 25px;
|
|
2892
|
+
}
|
|
2893
|
+
.stepOut .stepItem .lineCircleActive {
|
|
2894
|
+
border-top: 1px solid #2563f4;
|
|
2895
|
+
border-right: 1px solid #2563f4;
|
|
2896
|
+
border-bottom: 1px solid #2563f4;
|
|
2897
|
+
border-left: 1px solid #2563f4;
|
|
2898
|
+
}
|
|
2899
|
+
.stepOut .stepItem .icon {
|
|
2900
|
+
width: 13px;
|
|
2901
|
+
height: 13px;
|
|
2902
|
+
border-radius: 50%;
|
|
2903
|
+
background: #969696;
|
|
2904
|
+
margin: 0 auto;
|
|
2905
|
+
position: relative;
|
|
2906
|
+
z-index: 888;
|
|
2907
|
+
}
|
|
2908
|
+
.stepOut .stepItem .active {
|
|
2909
|
+
background-color: #2563f4;
|
|
2910
|
+
}
|
|
2911
|
+
.stepOut .stepItem .finished {
|
|
2912
|
+
background-color: #5dc055 !important;
|
|
2913
|
+
color: #fff !important;
|
|
2914
|
+
border-color: #5dc055 !important;
|
|
2915
|
+
}
|
|
2916
|
+
.stepOut .stepItem .labelFinsh {
|
|
2917
|
+
color: #5dc055 !important;
|
|
2918
|
+
}
|
|
2919
|
+
.stepOut .stepItem .line {
|
|
2920
|
+
position: absolute;
|
|
2921
|
+
top: 6px;
|
|
2922
|
+
left: 55%;
|
|
2923
|
+
border-bottom: 1px dashed rgba(3, 2, 2, 0.4);
|
|
2924
|
+
width: 90%;
|
|
2925
|
+
z-index: 111;
|
|
2926
|
+
}
|
|
2927
|
+
.stepOut .stepItem .lineActive {
|
|
2928
|
+
border-bottom: 1px solid #2563f4;
|
|
2929
|
+
}
|
|
2930
|
+
.stepOut .stepItem .stepTopBox {
|
|
2931
|
+
position: absolute;
|
|
2932
|
+
top: -48px;
|
|
2933
|
+
left: 50%;
|
|
2934
|
+
transform: translateX(-50%);
|
|
2935
|
+
max-width: 70%;
|
|
2936
|
+
min-width: 65px;
|
|
2937
|
+
height: 40px;
|
|
2938
|
+
line-height: 40px;
|
|
2939
|
+
white-space: nowrap;
|
|
2940
|
+
text-overflow: ellipsis;
|
|
2941
|
+
overflow: hidden;
|
|
2942
|
+
background: rgba(110, 153, 255, 0.11);
|
|
2943
|
+
border-radius: 4px;
|
|
2944
|
+
color: #2563f4;
|
|
2945
|
+
padding: 0px 5px;
|
|
2946
|
+
cursor: pointer;
|
|
2947
|
+
}
|
|
2948
|
+
.stepOut .stepItem .stepBottomBox {
|
|
2949
|
+
cursor: pointer;
|
|
2950
|
+
width: 100%;
|
|
2951
|
+
min-width: 65px;
|
|
2952
|
+
display: flex;
|
|
2953
|
+
flex-direction: column;
|
|
2954
|
+
align-items: center;
|
|
2955
|
+
}
|
|
2956
|
+
.stepOut .stepItem .stepLabel {
|
|
2957
|
+
width: 100%;
|
|
2958
|
+
color: #212121;
|
|
2959
|
+
line-height: 36px;
|
|
2960
|
+
margin: 0;
|
|
2961
|
+
white-space: nowrap;
|
|
2962
|
+
text-overflow: ellipsis;
|
|
2963
|
+
overflow: hidden;
|
|
2964
|
+
}
|
|
2965
|
+
.stepOut .stepItem .stepExtra {
|
|
2966
|
+
width: 68px;
|
|
2967
|
+
height: 26px;
|
|
2968
|
+
border-radius: 4px;
|
|
2969
|
+
border: 1px solid #cacaca;
|
|
2970
|
+
margin: 0;
|
|
2971
|
+
white-space: nowrap;
|
|
2972
|
+
text-overflow: ellipsis;
|
|
2973
|
+
overflow: hidden;
|
|
2974
|
+
}
|
|
2975
|
+
.stepOut .stepItem .statusTime {
|
|
2976
|
+
color: rgba(0, 0, 0, 0.6);
|
|
2977
|
+
font-size: 14px;
|
|
2978
|
+
font-weight: 400;
|
|
2979
|
+
width: 89px;
|
|
2980
|
+
height: 34px;
|
|
2981
|
+
margin: 0;
|
|
2982
|
+
}
|
|
2983
|
+
.nodeTipContent {
|
|
2984
|
+
max-height: 200px;
|
|
2985
|
+
max-width: 400px;
|
|
2986
|
+
overflow: auto;
|
|
2987
|
+
text-align: center;
|
|
2988
|
+
padding: 0;
|
|
2989
|
+
margin: 0;
|
|
2990
|
+
}
|
|
2991
|
+
.nodeTipContent li {
|
|
2992
|
+
list-style: none;
|
|
2993
|
+
margin-bottom: 5px;
|
|
2994
|
+
}
|
|
2995
|
+
.nodeTipContent li p {
|
|
2996
|
+
margin: 0;
|
|
2997
|
+
}
|
package/es/packages/index.d.ts
CHANGED
|
@@ -13,12 +13,16 @@ import CFormTable from './form-table';
|
|
|
13
13
|
import CInfoHeader from './info-header';
|
|
14
14
|
import CTimeLine from './time-line';
|
|
15
15
|
import CBpmnWorkflow from './bpmn-workflow';
|
|
16
|
+
import CStepsWheel from './steps-wheel';
|
|
16
17
|
import Editor from './editor';
|
|
17
18
|
import CFormRender from './form-render';
|
|
18
19
|
import CFabricChart from './fabric-chart';
|
|
20
|
+
import CShortcutProvider from './shortcut-provider';
|
|
21
|
+
import CShortcutSetter from './shortcut-setter';
|
|
19
22
|
export * from './form-render';
|
|
23
|
+
export * from './shortcut-provider';
|
|
20
24
|
declare function install(app: App): void;
|
|
21
|
-
export { CGrid, CBigTable, CFieldSet, CDragLayout, CButtonPrint, CSelectPerson, CSelectLabel, CLabelFormContent, CScaleView, CMap, CVodChunkUpload, CRadio, CCheckbox, CSelect, CDatetime, CFormTable, CInfoHeader, CTimeLine, CBpmnWorkflow, Editor, CFormRender, CFabricChart };
|
|
25
|
+
export { CGrid, CBigTable, CFieldSet, CDragLayout, CButtonPrint, CSelectPerson, CSelectLabel, CLabelFormContent, CScaleView, CMap, CVodChunkUpload, CRadio, CCheckbox, CSelect, CDatetime, CFormTable, CInfoHeader, CTimeLine, CBpmnWorkflow, CStepsWheel, Editor, CFormRender, CFabricChart, CShortcutProvider, CShortcutSetter };
|
|
22
26
|
declare const _default: {
|
|
23
27
|
install: typeof install;
|
|
24
28
|
};
|
package/es/packages/index.js
CHANGED
|
@@ -26,12 +26,18 @@ import TimeLine from './time-line/index.js';
|
|
|
26
26
|
export { default as CTimeLine } from './time-line/index.js';
|
|
27
27
|
import BpmnWorkflow from './bpmn-workflow/index.js';
|
|
28
28
|
export { default as CBpmnWorkflow } from './bpmn-workflow/index.js';
|
|
29
|
+
import StepsWheel from './steps-wheel/index.js';
|
|
30
|
+
export { default as CStepsWheel } from './steps-wheel/index.js';
|
|
29
31
|
import Editor from './editor/index.js';
|
|
30
32
|
export { default as Editor } from './editor/index.js';
|
|
31
33
|
import FormRender from './form-render/index.js';
|
|
32
34
|
export { default as CFormRender } from './form-render/index.js';
|
|
33
35
|
import FabricChart from './fabric-chart/index.js';
|
|
34
36
|
export { default as CFabricChart } from './fabric-chart/index.js';
|
|
37
|
+
import ShortcutProvider from './shortcut-provider/index.js';
|
|
38
|
+
export { default as CShortcutProvider } from './shortcut-provider/index.js';
|
|
39
|
+
import ShortcutSetter from './shortcut-setter/index.js';
|
|
40
|
+
export { default as CShortcutSetter } from './shortcut-setter/index.js';
|
|
35
41
|
export { useFieldListAdaptor } from './form-render/src/hooks/useFieldListAdaptor.js';
|
|
36
42
|
export { useFormRequest } from './form-render/src/hooks/useFormRequest.js';
|
|
37
43
|
export { useCommonLog } from './form-render/src/hooks/useCommonLog.js';
|
|
@@ -46,6 +52,8 @@ export { FormItemDepsCollector, useFormItemDeps } from './form-render/src/hooks/
|
|
|
46
52
|
export { useInitialData } from './form-render/src/hooks/useInitialData.js';
|
|
47
53
|
export { useAnchor } from './form-render/src/hooks/useAnchor.js';
|
|
48
54
|
export { useFormContext } from './form-render/src/hooks/useFormContext.js';
|
|
55
|
+
export { ShortcutManager, useShortcuts } from './shortcut-provider/src/hooks/useShortcuts.js';
|
|
56
|
+
export { useShortcutSignature } from './shortcut-provider/src/hooks/useShortcutSignature.js';
|
|
49
57
|
|
|
50
58
|
const components = {
|
|
51
59
|
CGrid: Grid,
|
|
@@ -67,9 +75,12 @@ const components = {
|
|
|
67
75
|
CInfoHeader: InfoHeader,
|
|
68
76
|
CTimeLine: TimeLine,
|
|
69
77
|
CBpmnWorkflow: BpmnWorkflow,
|
|
78
|
+
CStepsWheel: StepsWheel,
|
|
70
79
|
Editor,
|
|
71
80
|
CFormRender: FormRender,
|
|
72
|
-
CFabricChart: FabricChart
|
|
81
|
+
CFabricChart: FabricChart,
|
|
82
|
+
CShortcutProvider: ShortcutProvider,
|
|
83
|
+
CShortcutSetter: ShortcutSetter
|
|
73
84
|
};
|
|
74
85
|
function install(app) {
|
|
75
86
|
Object.values(components).forEach((component) => {
|
|
@@ -303,14 +303,10 @@ const ScaleViewInit = (props, state, emit, config) => {
|
|
|
303
303
|
let i = 1;
|
|
304
304
|
const results = list.map((item) => {
|
|
305
305
|
const key = formKey(item);
|
|
306
|
-
|
|
306
|
+
(key || "").replace(/\n/g, "");
|
|
307
307
|
item.showTitle = item.title;
|
|
308
308
|
item.val_key = key;
|
|
309
309
|
item.renderCom = componentMap[item.type];
|
|
310
|
-
if (title.includes(".")) {
|
|
311
|
-
let newTitle = title.replace(/\./g, "~-~");
|
|
312
|
-
item.showTitle = newTitle;
|
|
313
|
-
}
|
|
314
310
|
item.isShow = true;
|
|
315
311
|
Object.keys(item).forEach((key2) => {
|
|
316
312
|
if (vexutils.isJSON(item[key2])) {
|
|
@@ -82,12 +82,7 @@ const ScaleViewSubmit = (props, state, emit, config) => {
|
|
|
82
82
|
if (itemTemp.setting && itemTemp.setting.dateType == "date" && tempObj[key])
|
|
83
83
|
tempObj[key] = moment(tempObj[key]).format("YYYY-MM-DD ") + moment().format("HH:mm:ss");
|
|
84
84
|
}
|
|
85
|
-
|
|
86
|
-
let newKey = keyTemp ? keyTemp.replace(/~-~/g, ".") : key.replace(/~-~/g, ".");
|
|
87
|
-
res[newKey] = tempObj[key];
|
|
88
|
-
} else {
|
|
89
|
-
res[keyTemp || key] = !tempObj[key] ? null : tempObj[key];
|
|
90
|
-
}
|
|
85
|
+
res[keyTemp || key] = !tempObj[key] ? null : tempObj[key];
|
|
91
86
|
if (isOnlyOptions(itemTemp.type)) {
|
|
92
87
|
let { options } = itemTemp;
|
|
93
88
|
let useKey = itemTemp.val_key;
|
|
@@ -117,9 +117,6 @@ const ScaleViewValidate = (props, state, config) => {
|
|
|
117
117
|
const rules = {};
|
|
118
118
|
formArray.forEach((item) => {
|
|
119
119
|
let newTitle = item.val_key;
|
|
120
|
-
if (newTitle.includes(".")) {
|
|
121
|
-
newTitle = newTitle.replace(/\./g, "~-~");
|
|
122
|
-
}
|
|
123
120
|
rules[newTitle] = [];
|
|
124
121
|
if (item.required && !filterArr.includes(item.type)) {
|
|
125
122
|
rules[newTitle].push({
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { SFCWithInstall } from '../../../es/src/types';
|
|
2
|
+
export * from './src/hooks';
|
|
3
|
+
export * from './src/types';
|
|
4
|
+
declare const ShortcutProvider: SFCWithInstall<import("vue").DefineComponent<{
|
|
5
|
+
cacheKey: StringConstructor;
|
|
6
|
+
}, {
|
|
7
|
+
shortcutWrapperRef: import("vue").Ref<HTMLElement | undefined>;
|
|
8
|
+
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
9
|
+
cacheKey: StringConstructor;
|
|
10
|
+
}>> & {
|
|
11
|
+
[x: `on${string}`]: ((...args: any[]) => any) | ((...args: unknown[]) => any) | undefined;
|
|
12
|
+
}>>;
|
|
13
|
+
manager: import("./src/hooks").ShortcutManager;
|
|
14
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
15
|
+
cacheKey: StringConstructor;
|
|
16
|
+
}>>, {}>>;
|
|
17
|
+
export default ShortcutProvider;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { COMPONENT_NAMESPACE } from '../../src/global/variable';
|
|
2
|
+
import { safeComponentRegister } from '../../src/utils';
|
|
3
|
+
import './src/ShortcutProvider.js';
|
|
4
|
+
import script from './src/ShortcutProvider.vue_vue_type_script_setup_true_lang.js';
|
|
5
|
+
export { ShortcutManager, useShortcuts } from './src/hooks/useShortcuts.js';
|
|
6
|
+
export { useShortcutSignature } from './src/hooks/useShortcutSignature.js';
|
|
7
|
+
|
|
8
|
+
const ShortcutProvider = script;
|
|
9
|
+
ShortcutProvider.install = function(app) {
|
|
10
|
+
safeComponentRegister(app, ShortcutProvider, COMPONENT_NAMESPACE + "ShortcutProvider");
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
export { ShortcutProvider as default };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ShortcutManager } from '../../../../es/packages/shortcut-provider';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
cacheKey: StringConstructor;
|
|
4
|
+
}, {
|
|
5
|
+
shortcutWrapperRef: import("vue").Ref<HTMLElement | undefined>;
|
|
6
|
+
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
7
|
+
cacheKey: StringConstructor;
|
|
8
|
+
}>> & {
|
|
9
|
+
[x: `on${string}`]: ((...args: any[]) => any) | ((...args: unknown[]) => any) | undefined;
|
|
10
|
+
}>>;
|
|
11
|
+
manager: ShortcutManager;
|
|
12
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
13
|
+
cacheKey: StringConstructor;
|
|
14
|
+
}>>, {}>;
|
|
15
|
+
export default _default;
|
package/es/packages/shortcut-provider/src/ShortcutProvider.vue_vue_type_script_setup_true_lang.js
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { defineComponent, ref, provide, onBeforeUnmount, openBlock, createElementBlock, renderSlot } from 'vue';
|
|
2
|
+
import { InjectionShortcutManager } from '../../../packages/shortcut-provider/src/constants';
|
|
3
|
+
import { ShortcutManager } from '../../../packages/shortcut-provider';
|
|
4
|
+
|
|
5
|
+
var script = /* @__PURE__ */ defineComponent({
|
|
6
|
+
__name: "ShortcutProvider",
|
|
7
|
+
props: {
|
|
8
|
+
cacheKey: String
|
|
9
|
+
},
|
|
10
|
+
setup(__props) {
|
|
11
|
+
const props = __props;
|
|
12
|
+
const shortcutWrapperRef = ref();
|
|
13
|
+
const manager = new ShortcutManager(shortcutWrapperRef, props.cacheKey).start();
|
|
14
|
+
provide(InjectionShortcutManager, manager);
|
|
15
|
+
onBeforeUnmount(() => {
|
|
16
|
+
manager.destroy();
|
|
17
|
+
});
|
|
18
|
+
return (_ctx, _cache) => {
|
|
19
|
+
return openBlock(), createElementBlock("section", {
|
|
20
|
+
ref_key: "shortcutWrapperRef",
|
|
21
|
+
ref: shortcutWrapperRef,
|
|
22
|
+
"is-shortcut-capture": "",
|
|
23
|
+
class: "shortcut-provider",
|
|
24
|
+
tabindex: -9999
|
|
25
|
+
}, [
|
|
26
|
+
renderSlot(_ctx.$slots, "default")
|
|
27
|
+
], 512);
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
export { script as default };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { InjectionKey } from 'vue';
|
|
2
|
+
import { ShortcutManager } from '../../../../../es/packages/shortcut-provider/src/hooks';
|
|
3
|
+
export declare enum ShortcutStatus {
|
|
4
|
+
INACTIVE = 0,
|
|
5
|
+
ACTIVE = 1
|
|
6
|
+
}
|
|
7
|
+
export declare const InjectionShortcutManager: InjectionKey<ShortcutManager>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
var ShortcutStatus = /* @__PURE__ */ ((ShortcutStatus2) => {
|
|
2
|
+
ShortcutStatus2[ShortcutStatus2["INACTIVE"] = 0] = "INACTIVE";
|
|
3
|
+
ShortcutStatus2[ShortcutStatus2["ACTIVE"] = 1] = "ACTIVE";
|
|
4
|
+
return ShortcutStatus2;
|
|
5
|
+
})(ShortcutStatus || {});
|
|
6
|
+
const InjectionShortcutManager = Symbol("InjectionShortcutManager");
|
|
7
|
+
|
|
8
|
+
export { InjectionShortcutManager, ShortcutStatus };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ref, computed } from 'vue';
|
|
2
|
+
import { transformKey2DisplaySignature } from '../../../../packages/shortcut-provider/src/utils';
|
|
3
|
+
|
|
4
|
+
function useShortcutSignature() {
|
|
5
|
+
const signatureRef = ref(() => "");
|
|
6
|
+
const shortcut = computed(() => {
|
|
7
|
+
return transformKey2DisplaySignature(signatureRef.value());
|
|
8
|
+
});
|
|
9
|
+
return { signatureRef, shortcut };
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export { useShortcutSignature };
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { ShortcutItem, ShortcutOption, ShortcutSignatureInfo } from '../../../../../es/packages/shortcut-provider/src/types';
|
|
2
|
+
import { MaybeRef } from '@vueuse/core';
|
|
3
|
+
export declare class ShortcutManager {
|
|
4
|
+
private readonly shortcutCallbackMap;
|
|
5
|
+
private readonly shortcutCache;
|
|
6
|
+
private readonly environmentEle;
|
|
7
|
+
private handle?;
|
|
8
|
+
static log(message: string, dryRun?: boolean): string;
|
|
9
|
+
constructor(environmentEle?: MaybeRef<HTMLElement | undefined>, cacheKey?: string);
|
|
10
|
+
get traverse(): unknown[];
|
|
11
|
+
query(key: string): any;
|
|
12
|
+
updateState(key: string, state?: boolean): void;
|
|
13
|
+
update(key: string, info: KeyboardEvent | Partial<ShortcutSignatureInfo>): void;
|
|
14
|
+
register(shortcutItem: ShortcutItem): {
|
|
15
|
+
stop: () => void;
|
|
16
|
+
signature: () => string;
|
|
17
|
+
};
|
|
18
|
+
start(): this;
|
|
19
|
+
destroy(): void;
|
|
20
|
+
}
|
|
21
|
+
export declare function useShortcuts(glob?: boolean): {
|
|
22
|
+
register: (shortcut: ShortcutOption) => {
|
|
23
|
+
stop: () => void;
|
|
24
|
+
signature: () => string;
|
|
25
|
+
};
|
|
26
|
+
traverse: () => unknown[];
|
|
27
|
+
query: (key: string) => any;
|
|
28
|
+
update: (key: string, info: KeyboardEvent | Partial<ShortcutSignatureInfo>) => void;
|
|
29
|
+
updateState: (key: string, state?: boolean) => void;
|
|
30
|
+
};
|