@vunk/plus 1.6.8 → 1.6.10
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/components/SendOutlined.mjs +8 -6
- package/components/SharedSystems.mjs +290 -72
- package/components/WebGLRenderer.mjs +32 -20
- package/components/WebGPURenderer.mjs +48 -10
- package/components/agent-chat-provider/index.d.ts +7 -0
- package/components/agent-chat-provider/index.mjs +6 -3
- package/components/agent-chat-provider/src/api.d.ts +3 -0
- package/components/agent-chat-provider/src/const-roles.d.ts +8 -0
- package/components/agent-chat-provider/src/const.d.ts +1 -0
- package/components/agent-chat-provider/src/index.vue.d.ts +22 -0
- package/components/agent-chat-provider/src/types.d.ts +50 -0
- package/components/agent-chat-provider/src/use.d.ts +5 -0
- package/components/avatar/index.d.ts +4 -0
- package/components/avatar/index.mjs +2 -2
- package/components/avatar/src/ctx.d.ts +6 -0
- package/components/avatar/src/index.vue.d.ts +180 -0
- package/components/avatar/src/types.d.ts +1 -0
- package/components/broadcasting-markdown/index.d.ts +7 -0
- package/components/broadcasting-markdown/index.mjs +78 -158
- package/components/broadcasting-markdown/src/const.d.ts +13 -0
- package/components/broadcasting-markdown/src/ctx.d.ts +129 -0
- package/components/broadcasting-markdown/src/howler-speech.vue.d.ts +104 -0
- package/components/broadcasting-markdown/src/index.vue.d.ts +439 -0
- package/components/broadcasting-markdown/src/paragraph.vue.d.ts +79 -0
- package/components/broadcasting-markdown/src/speech-error.vue.d.ts +67 -0
- package/components/broadcasting-markdown/src/types.d.ts +26 -0
- package/components/broadcasting-markdown/src/use.d.ts +21 -0
- package/components/browserAll.mjs +333 -562
- package/components/bubble-list/index.d.ts +5 -0
- package/components/bubble-list/index.mjs +91 -72
- package/components/bubble-list/src/ctx.d.ts +32 -0
- package/components/bubble-list/src/index.vue.d.ts +810 -0
- package/components/bubble-list/src/types.d.ts +4 -0
- package/components/bubble-templates/index.d.ts +4 -0
- package/components/bubble-templates/index.mjs +83 -68
- package/components/bubble-templates/src/index.vue.d.ts +595 -0
- package/components/bubble-templates/src/types.d.ts +40 -0
- package/components/chat-independent/index.d.ts +4 -0
- package/components/chat-independent/index.mjs +136 -115
- package/components/chat-independent/src/const.d.ts +13 -0
- package/components/chat-independent/src/ctx.d.ts +21 -0
- package/components/chat-independent/src/index.vue.d.ts +2429 -0
- package/components/chat-independent/src/types.d.ts +13 -0
- package/components/colorToUniform.mjs +2 -0
- package/components/index.d.ts +0 -0
- package/components/index2.mjs +11896 -8381
- package/components/init.mjs +1724 -998
- package/components/lottie-animation/index.d.ts +4 -0
- package/components/lottie-animation/index.mjs +2 -2
- package/components/lottie-animation/src/ctx.d.ts +10 -0
- package/components/lottie-animation/src/index.vue.d.ts +21 -0
- package/components/lottie-animation/src/types.d.ts +4 -0
- package/components/metahuman-broadcasting/index.d.ts +5 -0
- package/components/metahuman-broadcasting/index.mjs +57 -40
- package/components/metahuman-broadcasting/src/ctx.d.ts +57 -0
- package/components/metahuman-broadcasting/src/index.vue.d.ts +885 -0
- package/components/metahuman-broadcasting/src/types.d.ts +1 -0
- package/components/monaco-editor/index.d.ts +5 -0
- package/components/monaco-editor/index.mjs +2 -2
- package/components/monaco-editor/src/ctx.d.ts +23 -0
- package/components/monaco-editor/src/index.vue.d.ts +40 -0
- package/components/monaco-editor/src/types.d.ts +1 -0
- package/components/monaco-environment/index.d.ts +4 -0
- package/components/monaco-environment/index.mjs +1 -1
- package/components/monaco-environment/src/ctx.d.ts +8 -0
- package/components/monaco-environment/src/index.vue.d.ts +2 -0
- package/components/monaco-environment/src/types.d.ts +1 -0
- package/components/pixi-frame/index.d.ts +11 -0
- package/components/pixi-frame/index.mjs +2 -2
- package/components/pixi-frame/src/apng.vue.d.ts +161 -0
- package/components/pixi-frame/src/bitmap.vue.d.ts +158 -0
- package/components/pixi-frame/src/core.vue.d.ts +173 -0
- package/components/pixi-frame/src/ctx.d.ts +55 -0
- package/components/pixi-frame/src/index.vue.d.ts +591 -0
- package/components/pixi-frame/src/provider.vue.d.ts +2 -0
- package/components/pixi-frame/src/types.d.ts +17 -0
- package/components/pixi-frame/src/use.d.ts +16 -0
- package/components/pixi-frame/src/useSprite.d.ts +12 -0
- package/components/pixi-frame/src/video.vue.d.ts +159 -0
- package/components/pixi-frame/src/view.vue.d.ts +29 -0
- package/components/recorder-button/index.d.ts +4 -0
- package/components/recorder-button/index.mjs +2 -2
- package/components/recorder-button/src/ctx.d.ts +41 -0
- package/components/recorder-button/src/index.vue.d.ts +333 -0
- package/components/recorder-button/src/speech-to-text.d.ts +1 -0
- package/components/recorder-button/src/types.d.ts +7 -0
- package/components/routes-menu-content/index.d.ts +4 -0
- package/components/routes-menu-content/index.mjs +5 -5
- package/components/routes-menu-content/src/ctx.d.ts +17 -0
- package/components/routes-menu-content/src/index.vue.d.ts +350 -0
- package/components/routes-menu-content/src/item/core/ctx.d.ts +18 -0
- package/components/routes-menu-content/src/item/core/index.vue.d.ts +185 -0
- package/components/routes-menu-content/src/item/ctx.d.ts +14 -0
- package/components/routes-menu-content/src/item/index.vue.d.ts +316 -0
- package/components/routes-menu-content/src/types.d.ts +1 -0
- package/components/sender/index.d.ts +4 -0
- package/components/sender/index.mjs +180 -86
- package/components/sender/src/SenderHeader.vue.d.ts +270 -0
- package/components/sender/src/ctx.d.ts +64 -0
- package/components/sender/src/index.vue.d.ts +779 -0
- package/components/sender/src/types.d.ts +1 -0
- package/components/speech-button/index.d.ts +4 -0
- package/components/speech-button/index.mjs +13 -6
- package/components/speech-button/src/LoadingIcon.vue.d.ts +2 -0
- package/components/speech-button/src/RecordingIcon.vue.d.ts +2 -0
- package/components/speech-button/src/ctx.d.ts +10 -0
- package/components/speech-button/src/index.vue.d.ts +22 -0
- package/components/speech-button/src/types.d.ts +1 -0
- package/components/table-columns/index.d.ts +5 -0
- package/components/table-columns/index.mjs +6 -3
- package/components/table-columns/src/ctx.d.ts +59 -0
- package/components/table-columns/src/el-ctx.d.ts +57 -0
- package/components/table-columns/src/index.vue.d.ts +266 -0
- package/components/table-columns/src/types.d.ts +21 -0
- package/components/tables-v1/index.d.ts +5 -0
- package/components/tables-v1/index.mjs +3 -3
- package/components/tables-v1/src/ctx.d.ts +280 -0
- package/components/tables-v1/src/el-ctx.d.ts +262 -0
- package/components/tables-v1/src/index.vue.d.ts +3054 -0
- package/components/tables-v1/src/types.d.ts +3 -0
- package/components/tables-v1-checkbox/index.d.ts +5 -0
- package/components/tables-v1-checkbox/index.mjs +33 -269
- package/components/tables-v1-checkbox/src/ctx.d.ts +313 -0
- package/components/tables-v1-checkbox/src/index.vue.d.ts +3831 -0
- package/components/tables-v1-checkbox/src/types.d.ts +1 -0
- package/components/text/index.d.ts +4 -0
- package/components/text/index.mjs +52 -42
- package/components/text/src/ctx.d.ts +341 -0
- package/components/text/src/index.vue.d.ts +4593 -0
- package/components/text/src/types.d.ts +1 -0
- package/components/typing-markdown/index.d.ts +4 -0
- package/components/typing-markdown/index.mjs +2 -2
- package/components/typing-markdown/src/core.d.ts +2 -0
- package/components/typing-markdown/src/ctx.d.ts +41 -0
- package/components/typing-markdown/src/index.vue.d.ts +75 -0
- package/components/typing-markdown/src/types.d.ts +1 -0
- package/components/vditor/index.d.ts +5 -0
- package/components/vditor/index.mjs +9 -5
- package/components/vditor/src/ctx.d.ts +38 -0
- package/components/vditor/src/handle-fullscreen.vue.d.ts +18 -0
- package/components/vditor/src/handle-value.vue.d.ts +18 -0
- package/components/vditor/src/index.vue.d.ts +143 -0
- package/components/vditor/src/types.d.ts +9 -0
- package/components/vditor/src/use.d.ts +4 -0
- package/components/webworkerAll.mjs +1 -1
- package/composables/el-breakpoints/index.d.ts +5 -5
- package/composables/recorder/index.mjs +191 -288
- package/icons/end/index.mjs +3 -3
- package/icons/end/src/avatar.d.ts +2 -11
- package/icons/end/src/icon.d.ts +2 -56
- package/icons/keyboard/index.mjs +3 -3
- package/icons/keyboard/src/avatar.d.ts +2 -11
- package/icons/keyboard/src/icon.d.ts +2 -56
- package/icons/start/index.mjs +3 -3
- package/icons/start/src/avatar.d.ts +2 -11
- package/icons/start/src/icon.d.ts +2 -56
- package/icons/voice/index.mjs +2 -2
- package/icons/voice/src/avatar.d.ts +2 -11
- package/icons/voice/src/icon.d.ts +2 -56
- package/package.json +1 -1
- package/shared/audioToFrames/index.mjs +10 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { computed, ref, watch, inject, isVNode, Comment, Fragment, shallowRef, watchEffect, provide, onBeforeUnmount, onBeforeMount, toRef, defineComponent, h, createVNode, resolveComponent,
|
|
1
|
+
import { computed, ref, watch, inject, isVNode, Comment, Fragment, shallowRef, watchEffect, provide, onBeforeUnmount, onBeforeMount, toRef, defineComponent, h, createVNode, resolveComponent, openBlock, createBlock, withCtx, mergeProps, toHandlers } from 'vue';
|
|
2
2
|
import { _VkTabelsV1Ctx, VkTablesV1 } from '@vunk/plus/components/tables-v1';
|
|
3
3
|
import { VkCheckRecordLogicProvider, VkCheckRecordLogic } from '@vunk/core';
|
|
4
4
|
import { noop } from '@vunk/shared/function';
|
|
@@ -617,203 +617,31 @@ function createKey(prefix, suffix) {
|
|
|
617
617
|
return prefix + (suffix === 'default' ? '' : suffix.replace(/^[a-z]/, startChar => startChar.toUpperCase()));
|
|
618
618
|
}
|
|
619
619
|
|
|
620
|
-
// src: https://www.w3schools.com/colors/colors_names.asp
|
|
621
620
|
var colors = {
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
cornflowerblue: "#6495ED",
|
|
640
|
-
cornsilk: "#FFF8DC",
|
|
641
|
-
crimson: "#DC143C",
|
|
642
|
-
cyan: "#0FF",
|
|
643
|
-
darkblue: "#00008B",
|
|
644
|
-
darkcyan: "#008B8B",
|
|
645
|
-
darkgoldenrod: "#B8860B",
|
|
646
|
-
darkgray: "#A9A9A9",
|
|
647
|
-
darkgrey: "#A9A9A9",
|
|
648
|
-
darkgreen: "#006400",
|
|
649
|
-
darkkhaki: "#BDB76B",
|
|
650
|
-
darkmagenta: "#8B008B",
|
|
651
|
-
darkolivegreen: "#556B2F",
|
|
652
|
-
darkorange: "#FF8C00",
|
|
653
|
-
darkorchid: "#9932CC",
|
|
654
|
-
darkred: "#8B0000",
|
|
655
|
-
darksalmon: "#E9967A",
|
|
656
|
-
darkseagreen: "#8FBC8F",
|
|
657
|
-
darkslateblue: "#483D8B",
|
|
658
|
-
darkslategray: "#2F4F4F",
|
|
659
|
-
darkslategrey: "#2F4F4F",
|
|
660
|
-
darkturquoise: "#00CED1",
|
|
661
|
-
darkviolet: "#9400D3",
|
|
662
|
-
deeppink: "#FF1493",
|
|
663
|
-
deepskyblue: "#00BFFF",
|
|
664
|
-
dimgray: "#696969",
|
|
665
|
-
dimgrey: "#696969",
|
|
666
|
-
dodgerblue: "#1E90FF",
|
|
667
|
-
firebrick: "#B22222",
|
|
668
|
-
floralwhite: "#FFFAF0",
|
|
669
|
-
forestgreen: "#228B22",
|
|
670
|
-
fuchsia: "#F0F",
|
|
671
|
-
gainsboro: "#DCDCDC",
|
|
672
|
-
ghostwhite: "#F8F8FF",
|
|
673
|
-
gold: "#FFD700",
|
|
674
|
-
goldenrod: "#DAA520",
|
|
675
|
-
gray: "#808080",
|
|
676
|
-
grey: "#808080",
|
|
677
|
-
green: "#008000",
|
|
678
|
-
greenyellow: "#ADFF2F",
|
|
679
|
-
honeydew: "#F0FFF0",
|
|
680
|
-
hotpink: "#FF69B4",
|
|
681
|
-
indianred: "#CD5C5C",
|
|
682
|
-
indigo: "#4B0082",
|
|
683
|
-
ivory: "#FFFFF0",
|
|
684
|
-
khaki: "#F0E68C",
|
|
685
|
-
lavender: "#E6E6FA",
|
|
686
|
-
lavenderblush: "#FFF0F5",
|
|
687
|
-
lawngreen: "#7CFC00",
|
|
688
|
-
lemonchiffon: "#FFFACD",
|
|
689
|
-
lightblue: "#ADD8E6",
|
|
690
|
-
lightcoral: "#F08080",
|
|
691
|
-
lightcyan: "#E0FFFF",
|
|
692
|
-
lightgoldenrodyellow: "#FAFAD2",
|
|
693
|
-
lightgray: "#D3D3D3",
|
|
694
|
-
lightgrey: "#D3D3D3",
|
|
695
|
-
lightgreen: "#90EE90",
|
|
696
|
-
lightpink: "#FFB6C1",
|
|
697
|
-
lightsalmon: "#FFA07A",
|
|
698
|
-
lightseagreen: "#20B2AA",
|
|
699
|
-
lightskyblue: "#87CEFA",
|
|
700
|
-
lightslategray: "#778899",
|
|
701
|
-
lightslategrey: "#778899",
|
|
702
|
-
lightsteelblue: "#B0C4DE",
|
|
703
|
-
lightyellow: "#FFFFE0",
|
|
704
|
-
lime: "#0F0",
|
|
705
|
-
limegreen: "#32CD32",
|
|
706
|
-
linen: "#FAF0E6",
|
|
707
|
-
magenta: "#F0F",
|
|
708
|
-
maroon: "#800000",
|
|
709
|
-
mediumaquamarine: "#66CDAA",
|
|
710
|
-
mediumblue: "#0000CD",
|
|
711
|
-
mediumorchid: "#BA55D3",
|
|
712
|
-
mediumpurple: "#9370DB",
|
|
713
|
-
mediumseagreen: "#3CB371",
|
|
714
|
-
mediumslateblue: "#7B68EE",
|
|
715
|
-
mediumspringgreen: "#00FA9A",
|
|
716
|
-
mediumturquoise: "#48D1CC",
|
|
717
|
-
mediumvioletred: "#C71585",
|
|
718
|
-
midnightblue: "#191970",
|
|
719
|
-
mintcream: "#F5FFFA",
|
|
720
|
-
mistyrose: "#FFE4E1",
|
|
721
|
-
moccasin: "#FFE4B5",
|
|
722
|
-
navajowhite: "#FFDEAD",
|
|
723
|
-
navy: "#000080",
|
|
724
|
-
oldlace: "#FDF5E6",
|
|
725
|
-
olive: "#808000",
|
|
726
|
-
olivedrab: "#6B8E23",
|
|
727
|
-
orange: "#FFA500",
|
|
728
|
-
orangered: "#FF4500",
|
|
729
|
-
orchid: "#DA70D6",
|
|
730
|
-
palegoldenrod: "#EEE8AA",
|
|
731
|
-
palegreen: "#98FB98",
|
|
732
|
-
paleturquoise: "#AFEEEE",
|
|
733
|
-
palevioletred: "#DB7093",
|
|
734
|
-
papayawhip: "#FFEFD5",
|
|
735
|
-
peachpuff: "#FFDAB9",
|
|
736
|
-
peru: "#CD853F",
|
|
737
|
-
pink: "#FFC0CB",
|
|
738
|
-
plum: "#DDA0DD",
|
|
739
|
-
powderblue: "#B0E0E6",
|
|
740
|
-
purple: "#800080",
|
|
741
|
-
rebeccapurple: "#663399",
|
|
742
|
-
red: "#F00",
|
|
743
|
-
rosybrown: "#BC8F8F",
|
|
744
|
-
royalblue: "#4169E1",
|
|
745
|
-
saddlebrown: "#8B4513",
|
|
746
|
-
salmon: "#FA8072",
|
|
747
|
-
sandybrown: "#F4A460",
|
|
748
|
-
seagreen: "#2E8B57",
|
|
749
|
-
seashell: "#FFF5EE",
|
|
750
|
-
sienna: "#A0522D",
|
|
751
|
-
silver: "#C0C0C0",
|
|
752
|
-
skyblue: "#87CEEB",
|
|
753
|
-
slateblue: "#6A5ACD",
|
|
754
|
-
slategray: "#708090",
|
|
755
|
-
slategrey: "#708090",
|
|
756
|
-
snow: "#FFFAFA",
|
|
757
|
-
springgreen: "#00FF7F",
|
|
758
|
-
steelblue: "#4682B4",
|
|
759
|
-
tan: "#D2B48C",
|
|
760
|
-
teal: "#008080",
|
|
761
|
-
thistle: "#D8BFD8",
|
|
762
|
-
tomato: "#FF6347",
|
|
763
|
-
turquoise: "#40E0D0",
|
|
764
|
-
violet: "#EE82EE",
|
|
765
|
-
wheat: "#F5DEB3",
|
|
766
|
-
white: "#FFF",
|
|
767
|
-
whitesmoke: "#F5F5F5",
|
|
768
|
-
yellow: "#FF0",
|
|
769
|
-
yellowgreen: "#9ACD32",
|
|
770
|
-
transparent: "#0000"
|
|
621
|
+
black: '#000',
|
|
622
|
+
silver: '#C0C0C0',
|
|
623
|
+
gray: '#808080',
|
|
624
|
+
white: '#FFF',
|
|
625
|
+
maroon: '#800000',
|
|
626
|
+
red: '#F00',
|
|
627
|
+
purple: '#800080',
|
|
628
|
+
fuchsia: '#F0F',
|
|
629
|
+
green: '#008000',
|
|
630
|
+
lime: '#0F0',
|
|
631
|
+
olive: '#808000',
|
|
632
|
+
yellow: '#FF0',
|
|
633
|
+
navy: '#000080',
|
|
634
|
+
blue: '#00F',
|
|
635
|
+
teal: '#008080',
|
|
636
|
+
aqua: '#0FF',
|
|
637
|
+
transparent: '#0000'
|
|
771
638
|
};
|
|
772
639
|
|
|
773
|
-
// All the algorithms credit to https://stackoverflow.com/questions/36721830/convert-hsl-to-rgb-and-hex/54014428#54014428
|
|
774
|
-
// original author: Kamil Kiełczewski
|
|
775
|
-
/**
|
|
776
|
-
* @param h 360
|
|
777
|
-
* @param s 100
|
|
778
|
-
* @param l 100
|
|
779
|
-
* @returns [h, s, v] 360, 100, 100
|
|
780
|
-
*/
|
|
781
|
-
/**
|
|
782
|
-
* @param h 360
|
|
783
|
-
* @param s 100
|
|
784
|
-
* @param v 100
|
|
785
|
-
* @returns [r, g, b] 255, 255, 255
|
|
786
|
-
*/
|
|
787
|
-
function hsv2rgb(h, s, v) {
|
|
788
|
-
s /= 100;
|
|
789
|
-
v /= 100;
|
|
790
|
-
let f = (n, k = (n + h / 60) % 6) => v - v * s * Math.max(Math.min(k, 4 - k, 1), 0);
|
|
791
|
-
return [f(5) * 255, f(3) * 255, f(1) * 255];
|
|
792
|
-
}
|
|
793
|
-
/**
|
|
794
|
-
* @param h 360
|
|
795
|
-
* @param s 100
|
|
796
|
-
* @param l 100
|
|
797
|
-
* @returns [255, 255, 255]
|
|
798
|
-
*/
|
|
799
|
-
function hsl2rgb(h, s, l) {
|
|
800
|
-
s /= 100;
|
|
801
|
-
l /= 100;
|
|
802
|
-
let a = s * Math.min(l, 1 - l);
|
|
803
|
-
let f = (n, k = (n + h / 30) % 12) => l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1);
|
|
804
|
-
return [f(0) * 255, f(8) * 255, f(4) * 255];
|
|
805
|
-
}
|
|
806
|
-
|
|
807
640
|
const prefix = '^\\s*';
|
|
808
641
|
const suffix = '\\s*$';
|
|
809
|
-
const percent = '\\s*((\\.\\d+)|(\\d+(\\.\\d*)?))%\\s*'; // 4 offset
|
|
810
642
|
const float = '\\s*((\\.\\d+)|(\\d+(\\.\\d*)?))\\s*'; // 4 offset
|
|
811
643
|
const hex = '([0-9A-Fa-f])';
|
|
812
644
|
const dhex = '([0-9A-Fa-f]{2})';
|
|
813
|
-
const hslRegex = new RegExp(`${prefix}hsl\\s*\\(${float},${percent},${percent}\\)${suffix}`);
|
|
814
|
-
const hsvRegex = new RegExp(`${prefix}hsv\\s*\\(${float},${percent},${percent}\\)${suffix}`);
|
|
815
|
-
const hslaRegex = new RegExp(`${prefix}hsla\\s*\\(${float},${percent},${percent},${float}\\)${suffix}`);
|
|
816
|
-
const hsvaRegex = new RegExp(`${prefix}hsva\\s*\\(${float},${percent},${percent},${float}\\)${suffix}`);
|
|
817
645
|
const rgbRegex = new RegExp(`${prefix}rgb\\s*\\(${float},${float},${float}\\)${suffix}`);
|
|
818
646
|
const rgbaRegex = new RegExp(`${prefix}rgba\\s*\\(${float},${float},${float},${float}\\)${suffix}`);
|
|
819
647
|
const sHexRegex = new RegExp(`${prefix}#${hex}${hex}${hex}${suffix}`);
|
|
@@ -823,61 +651,9 @@ const hexaRegex = new RegExp(`${prefix}#${dhex}${dhex}${dhex}${dhex}${suffix}`);
|
|
|
823
651
|
function parseHex(value) {
|
|
824
652
|
return parseInt(value, 16);
|
|
825
653
|
}
|
|
826
|
-
/**
|
|
827
|
-
* Convert color string to hsla array
|
|
828
|
-
* @param color format like hsl(180, 100%, 100%), hsla(180, 100%, 100%, 1)
|
|
829
|
-
* @returns
|
|
830
|
-
*/
|
|
831
|
-
function hsla(color) {
|
|
832
|
-
try {
|
|
833
|
-
let i;
|
|
834
|
-
if ((i = hslaRegex.exec(color))) {
|
|
835
|
-
return [
|
|
836
|
-
roundDeg(i[1]),
|
|
837
|
-
roundPercent(i[5]),
|
|
838
|
-
roundPercent(i[9]),
|
|
839
|
-
roundAlpha(i[13])
|
|
840
|
-
];
|
|
841
|
-
}
|
|
842
|
-
else if ((i = hslRegex.exec(color))) {
|
|
843
|
-
return [roundDeg(i[1]), roundPercent(i[5]), roundPercent(i[9]), 1];
|
|
844
|
-
}
|
|
845
|
-
throw new Error(`[seemly/hsla]: Invalid color value ${color}.`);
|
|
846
|
-
}
|
|
847
|
-
catch (e) {
|
|
848
|
-
throw e;
|
|
849
|
-
}
|
|
850
|
-
}
|
|
851
|
-
/**
|
|
852
|
-
* Convert color string to hsva array
|
|
853
|
-
* @param color format like hsv(180, 100%, 100%), hsva(180, 100%, 100%, 1)
|
|
854
|
-
* @returns
|
|
855
|
-
*/
|
|
856
|
-
function hsva(color) {
|
|
857
|
-
try {
|
|
858
|
-
let i;
|
|
859
|
-
if ((i = hsvaRegex.exec(color))) {
|
|
860
|
-
return [
|
|
861
|
-
roundDeg(i[1]),
|
|
862
|
-
roundPercent(i[5]),
|
|
863
|
-
roundPercent(i[9]),
|
|
864
|
-
roundAlpha(i[13])
|
|
865
|
-
];
|
|
866
|
-
}
|
|
867
|
-
else if ((i = hsvRegex.exec(color))) {
|
|
868
|
-
return [roundDeg(i[1]), roundPercent(i[5]), roundPercent(i[9]), 1];
|
|
869
|
-
}
|
|
870
|
-
throw new Error(`[seemly/hsva]: Invalid color value ${color}.`);
|
|
871
|
-
}
|
|
872
|
-
catch (e) {
|
|
873
|
-
throw e;
|
|
874
|
-
}
|
|
875
|
-
}
|
|
876
654
|
/**
|
|
877
655
|
* Convert color string to rgba array.
|
|
878
|
-
* @param color format like #000[0], #000000[00], rgb(0, 0, 0),
|
|
879
|
-
* rgba(0, 0, 0, 0), hsl(a) color, hsv(a) color and color keywords and
|
|
880
|
-
* transparent
|
|
656
|
+
* @param color format like #000[0], #000000[00], rgb(0, 0, 0), rgba(0, 0, 0, 0) and basic color keywords https://www.w3.org/TR/css-color-3/#html4 and transparent
|
|
881
657
|
* @returns
|
|
882
658
|
*/
|
|
883
659
|
function rgba(color) {
|
|
@@ -924,14 +700,6 @@ function rgba(color) {
|
|
|
924
700
|
else if (color in colors) {
|
|
925
701
|
return rgba(colors[color]);
|
|
926
702
|
}
|
|
927
|
-
else if (hslRegex.test(color) || hslaRegex.test(color)) {
|
|
928
|
-
const [h, s, l, a] = hsla(color);
|
|
929
|
-
return [...hsl2rgb(h, s, l), a];
|
|
930
|
-
}
|
|
931
|
-
else if (hsvRegex.test(color) || hsvaRegex.test(color)) {
|
|
932
|
-
const [h, s, v, a] = hsva(color);
|
|
933
|
-
return [...hsv2rgb(h, s, v), a];
|
|
934
|
-
}
|
|
935
703
|
throw new Error(`[seemly/rgba]: Invalid color value ${color}.`);
|
|
936
704
|
}
|
|
937
705
|
catch (e) {
|
|
@@ -959,7 +727,7 @@ function composite(background, overlay) {
|
|
|
959
727
|
}
|
|
960
728
|
function changeColor(base, options) {
|
|
961
729
|
const [r, g, b, a = 1] = Array.isArray(base) ? base : rgba(base);
|
|
962
|
-
if (
|
|
730
|
+
if (options.alpha) {
|
|
963
731
|
return stringifyRgba(r, g, b, options.alpha);
|
|
964
732
|
}
|
|
965
733
|
return stringifyRgba(r, g, b, a);
|
|
@@ -977,14 +745,6 @@ function roundAlpha(value) {
|
|
|
977
745
|
return 0;
|
|
978
746
|
return v;
|
|
979
747
|
}
|
|
980
|
-
function roundDeg(value) {
|
|
981
|
-
const v = Math.round(Number(value));
|
|
982
|
-
if (v >= 360)
|
|
983
|
-
return 0;
|
|
984
|
-
if (v < 0)
|
|
985
|
-
return 0;
|
|
986
|
-
return v;
|
|
987
|
-
}
|
|
988
748
|
function roundChannel(value) {
|
|
989
749
|
const v = Math.round(Number(value));
|
|
990
750
|
if (v > 255)
|
|
@@ -993,14 +753,6 @@ function roundChannel(value) {
|
|
|
993
753
|
return 0;
|
|
994
754
|
return v;
|
|
995
755
|
}
|
|
996
|
-
function roundPercent(value) {
|
|
997
|
-
const v = Math.round(Number(value));
|
|
998
|
-
if (v > 100)
|
|
999
|
-
return 100;
|
|
1000
|
-
if (v < 0)
|
|
1001
|
-
return 0;
|
|
1002
|
-
return v;
|
|
1003
|
-
}
|
|
1004
756
|
function toRgbaString(base) {
|
|
1005
757
|
const [r, g, b] = base;
|
|
1006
758
|
if (3 in base) {
|
|
@@ -3564,11 +3316,22 @@ const base = {
|
|
|
3564
3316
|
// disabled placeholder
|
|
3565
3317
|
alphaClose: '0.6',
|
|
3566
3318
|
alphaDisabled: '0.5',
|
|
3319
|
+
alphaDisabledInput: '0.02',
|
|
3320
|
+
alphaPending: '0.05',
|
|
3321
|
+
alphaTablePending: '0.02',
|
|
3322
|
+
alphaPressed: '0.07',
|
|
3567
3323
|
alphaAvatar: '0.2',
|
|
3324
|
+
alphaRail: '0.14',
|
|
3568
3325
|
alphaProgressRail: '.08',
|
|
3326
|
+
alphaBorder: '0.12',
|
|
3327
|
+
alphaDivider: '0.06',
|
|
3569
3328
|
alphaInput: '0',
|
|
3329
|
+
alphaAction: '0.02',
|
|
3330
|
+
alphaTab: '0.04',
|
|
3570
3331
|
alphaScrollbar: '0.25',
|
|
3571
3332
|
alphaScrollbarHover: '0.4',
|
|
3333
|
+
alphaCode: '0.05',
|
|
3334
|
+
alphaTag: '0.02',
|
|
3572
3335
|
// primary
|
|
3573
3336
|
primaryHover: '#36ad6a',
|
|
3574
3337
|
primaryDefault: '#18a058',
|
|
@@ -3777,6 +3540,7 @@ function self$1(vars) {
|
|
|
3777
3540
|
});
|
|
3778
3541
|
}
|
|
3779
3542
|
const radioLight = {
|
|
3543
|
+
name: 'Radio',
|
|
3780
3544
|
common: derived,
|
|
3781
3545
|
self: self$1
|
|
3782
3546
|
};
|
|
@@ -4370,7 +4134,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
4370
4134
|
/* STABLE */
|
|
4371
4135
|
}, 8, ["model-value", "oid-field"]);
|
|
4372
4136
|
}
|
|
4373
|
-
var VkTablesV1Checkbox = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
4137
|
+
var VkTablesV1Checkbox = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__file", "/home/runner/work/vunk-plus/vunk-plus/packages/components/tables-v1-checkbox/src/index.vue"]]);
|
|
4374
4138
|
|
|
4375
4139
|
var types = /*#__PURE__*/Object.freeze({
|
|
4376
4140
|
__proto__: null
|