@whitesev/pops 2.4.4 → 2.4.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 +117 -111
- package/dist/index.amd.js +687 -733
- package/dist/index.amd.js.map +1 -1
- package/dist/index.cjs.js +687 -733
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +687 -733
- package/dist/index.esm.js.map +1 -1
- package/dist/index.iife.js +687 -733
- package/dist/index.iife.js.map +1 -1
- package/dist/index.system.js +687 -733
- package/dist/index.system.js.map +1 -1
- package/dist/index.umd.js +687 -733
- package/dist/index.umd.js.map +1 -1
- package/dist/types/src/Pops.d.ts +9 -10
- package/dist/types/src/components/panel/types/components-common.d.ts +26 -26
- package/dist/types/src/components/panel/types/index.d.ts +2 -2
- package/dist/types/src/components/rightClickMenu/index.d.ts +3 -4
- package/dist/types/src/components/searchSuggestion/index.d.ts +2 -2
- package/dist/types/src/components/searchSuggestion/types/index.d.ts +2 -2
- package/dist/types/src/handler/PopsHandler.d.ts +3 -3
- package/dist/types/src/types/PopsDOMUtilsEventType.d.ts +141 -145
- package/dist/types/src/types/animation.d.ts +15 -15
- package/dist/types/src/types/button.d.ts +141 -141
- package/dist/types/src/types/components.d.ts +175 -178
- package/dist/types/src/types/event.d.ts +44 -44
- package/dist/types/src/types/global.d.ts +18 -13
- package/dist/types/src/types/icon.d.ts +28 -28
- package/dist/types/src/types/inst.d.ts +14 -14
- package/dist/types/src/types/main.d.ts +46 -49
- package/dist/types/src/types/mask.d.ts +36 -36
- package/dist/types/src/types/position.d.ts +46 -46
- package/dist/types/src/utils/PopsDOMUtils.d.ts +1 -1
- package/dist/types/src/utils/PopsInstanceUtils.d.ts +1 -1
- package/dist/types/src/utils/PopsUtils.d.ts +16 -16
- package/package.json +17 -8
package/dist/index.system.js
CHANGED
|
@@ -17,12 +17,12 @@ System.register('pops', [], (function (exports) {
|
|
|
17
17
|
* 获取全局配置
|
|
18
18
|
*/
|
|
19
19
|
getGlobalConfig() {
|
|
20
|
-
|
|
20
|
+
const result = {};
|
|
21
21
|
Object.keys(GlobalConfig.config).forEach((keyName) => {
|
|
22
|
-
|
|
22
|
+
const configValue = Reflect.get(GlobalConfig.config, keyName);
|
|
23
23
|
if (keyName === "style") {
|
|
24
24
|
// 设置style属性
|
|
25
|
-
|
|
25
|
+
const style = configValue == null ? "" : typeof configValue === "function" ? configValue() : configValue;
|
|
26
26
|
if (typeof style === "string") {
|
|
27
27
|
result.style = style;
|
|
28
28
|
}
|
|
@@ -31,7 +31,7 @@ System.register('pops', [], (function (exports) {
|
|
|
31
31
|
// 设置zIndex属性
|
|
32
32
|
let zIndex = configValue == null ? "" : typeof configValue === "function" ? configValue() : configValue;
|
|
33
33
|
if (typeof zIndex === "string") {
|
|
34
|
-
|
|
34
|
+
const newIndex = (zIndex = Number(zIndex));
|
|
35
35
|
if (!isNaN(newIndex)) {
|
|
36
36
|
result.zIndex = newIndex;
|
|
37
37
|
}
|
|
@@ -43,7 +43,7 @@ System.register('pops', [], (function (exports) {
|
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
else if (keyName === "mask") {
|
|
46
|
-
|
|
46
|
+
const mask = GlobalConfig.config.mask == null ? {} : GlobalConfig.config.mask;
|
|
47
47
|
if (typeof mask === "object" && mask != null) {
|
|
48
48
|
result.mask = mask;
|
|
49
49
|
}
|
|
@@ -555,7 +555,7 @@ System.register('pops', [], (function (exports) {
|
|
|
555
555
|
}
|
|
556
556
|
}
|
|
557
557
|
assign(target = {}, source = {}, isAdd = false) {
|
|
558
|
-
|
|
558
|
+
const UtilsContext = this;
|
|
559
559
|
if (source == null) {
|
|
560
560
|
return target;
|
|
561
561
|
}
|
|
@@ -563,7 +563,7 @@ System.register('pops', [], (function (exports) {
|
|
|
563
563
|
target = {};
|
|
564
564
|
}
|
|
565
565
|
if (Array.isArray(source)) {
|
|
566
|
-
|
|
566
|
+
const canTraverse = source.filter((item) => {
|
|
567
567
|
return typeof item === "object";
|
|
568
568
|
});
|
|
569
569
|
if (!canTraverse.length) {
|
|
@@ -573,8 +573,8 @@ System.register('pops', [], (function (exports) {
|
|
|
573
573
|
if (isAdd) {
|
|
574
574
|
for (const sourceKeyName in source) {
|
|
575
575
|
const targetKeyName = sourceKeyName;
|
|
576
|
-
|
|
577
|
-
|
|
576
|
+
const targetValue = target[targetKeyName];
|
|
577
|
+
const sourceValue = source[sourceKeyName];
|
|
578
578
|
if (typeof sourceValue === "object" &&
|
|
579
579
|
sourceValue != null &&
|
|
580
580
|
sourceKeyName in target &&
|
|
@@ -589,22 +589,19 @@ System.register('pops', [], (function (exports) {
|
|
|
589
589
|
else {
|
|
590
590
|
for (const targetKeyName in target) {
|
|
591
591
|
if (targetKeyName in source) {
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
// @ts-ignore
|
|
595
|
-
let sourceValue = source[targetKeyName];
|
|
592
|
+
const targetValue = Reflect.get(target, targetKeyName);
|
|
593
|
+
const sourceValue = Reflect.get(source, targetKeyName);
|
|
596
594
|
if (typeof sourceValue === "object" &&
|
|
597
595
|
sourceValue != null &&
|
|
598
596
|
!UtilsContext.isDOM(sourceValue) &&
|
|
599
597
|
Object.keys(sourceValue).length) {
|
|
600
598
|
/* 源端的值是object类型,且不是元素节点 */
|
|
601
|
-
|
|
602
|
-
|
|
599
|
+
const childObjectValue = UtilsContext.assign(targetValue, sourceValue, isAdd);
|
|
600
|
+
Reflect.set(target, targetKeyName, childObjectValue);
|
|
603
601
|
continue;
|
|
604
602
|
}
|
|
605
603
|
/* 直接赋值 */
|
|
606
|
-
|
|
607
|
-
target[targetKeyName] = sourceValue;
|
|
604
|
+
Reflect.set(target, targetKeyName, sourceValue);
|
|
608
605
|
}
|
|
609
606
|
}
|
|
610
607
|
}
|
|
@@ -619,15 +616,16 @@ System.register('pops', [], (function (exports) {
|
|
|
619
616
|
}
|
|
620
617
|
else {
|
|
621
618
|
return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function (charStr) {
|
|
622
|
-
|
|
619
|
+
const randomValue = (Math.random() * 16) | 0, randomCharValue = charStr === "x" ? randomValue : (randomValue & 0x3) | 0x8;
|
|
623
620
|
return randomCharValue.toString(16);
|
|
624
621
|
});
|
|
625
622
|
}
|
|
626
623
|
}
|
|
627
|
-
contains(
|
|
628
|
-
|
|
624
|
+
contains(...args) {
|
|
625
|
+
const [context, target] = args;
|
|
626
|
+
if (args.length === 1) {
|
|
629
627
|
// 只判断该页面是否存在该元素
|
|
630
|
-
return this.contains(PopsCore.document.body || PopsCore.document.documentElement,
|
|
628
|
+
return this.contains(PopsCore.document.body || PopsCore.document.documentElement, args[0]);
|
|
631
629
|
}
|
|
632
630
|
else {
|
|
633
631
|
if (target == null) {
|
|
@@ -650,7 +648,7 @@ System.register('pops', [], (function (exports) {
|
|
|
650
648
|
}
|
|
651
649
|
}
|
|
652
650
|
formatTime(text = new Date(), formatType = "yyyy-MM-dd HH:mm:ss") {
|
|
653
|
-
|
|
651
|
+
const time = text == null ? new Date() : new Date(text);
|
|
654
652
|
/**
|
|
655
653
|
* 校验时间补0
|
|
656
654
|
* @param timeNum
|
|
@@ -669,7 +667,7 @@ System.register('pops', [], (function (exports) {
|
|
|
669
667
|
function timeSystemChange(hourNum) {
|
|
670
668
|
return hourNum > 12 ? hourNum - 12 : hourNum;
|
|
671
669
|
}
|
|
672
|
-
|
|
670
|
+
const timeRegexp = {
|
|
673
671
|
yyyy: time.getFullYear(),
|
|
674
672
|
/* 年 */
|
|
675
673
|
MM: checkTime(time.getMonth() + 1),
|
|
@@ -686,7 +684,7 @@ System.register('pops', [], (function (exports) {
|
|
|
686
684
|
/* 秒 */
|
|
687
685
|
};
|
|
688
686
|
Object.keys(timeRegexp).forEach(function (key) {
|
|
689
|
-
|
|
687
|
+
const replaecRegexp = new RegExp(key, "g");
|
|
690
688
|
formatType = formatType.replace(replaecRegexp, timeRegexp[key]);
|
|
691
689
|
});
|
|
692
690
|
return formatType;
|
|
@@ -698,7 +696,7 @@ System.register('pops', [], (function (exports) {
|
|
|
698
696
|
}
|
|
699
697
|
let result = 0;
|
|
700
698
|
let resultType = "KB";
|
|
701
|
-
|
|
699
|
+
const sizeData = {};
|
|
702
700
|
sizeData.B = 1;
|
|
703
701
|
sizeData.KB = 1024;
|
|
704
702
|
sizeData.MB = sizeData.KB * sizeData.KB;
|
|
@@ -711,7 +709,7 @@ System.register('pops', [], (function (exports) {
|
|
|
711
709
|
sizeData.BB = sizeData.YB * sizeData.KB;
|
|
712
710
|
sizeData.NB = sizeData.BB * sizeData.KB;
|
|
713
711
|
sizeData.DB = sizeData.NB * sizeData.KB;
|
|
714
|
-
for (
|
|
712
|
+
for (const key in sizeData) {
|
|
715
713
|
result = byteSize / sizeData[key];
|
|
716
714
|
resultType = key;
|
|
717
715
|
if (sizeData.KB >= result) {
|
|
@@ -739,7 +737,7 @@ System.register('pops', [], (function (exports) {
|
|
|
739
737
|
try {
|
|
740
738
|
return setTimeout$1(callback, timeout);
|
|
741
739
|
}
|
|
742
|
-
catch
|
|
740
|
+
catch {
|
|
743
741
|
return PopsCore.setTimeout(callback, timeout);
|
|
744
742
|
}
|
|
745
743
|
}
|
|
@@ -752,7 +750,8 @@ System.register('pops', [], (function (exports) {
|
|
|
752
750
|
clearTimeout$1(timeId);
|
|
753
751
|
}
|
|
754
752
|
}
|
|
755
|
-
catch
|
|
753
|
+
catch {
|
|
754
|
+
// TODO
|
|
756
755
|
}
|
|
757
756
|
finally {
|
|
758
757
|
PopsCore.clearTimeout(timeId);
|
|
@@ -765,7 +764,7 @@ System.register('pops', [], (function (exports) {
|
|
|
765
764
|
try {
|
|
766
765
|
return setInterval$1(callback, timeout);
|
|
767
766
|
}
|
|
768
|
-
catch
|
|
767
|
+
catch {
|
|
769
768
|
return PopsCore.setInterval(callback, timeout);
|
|
770
769
|
}
|
|
771
770
|
}
|
|
@@ -778,7 +777,8 @@ System.register('pops', [], (function (exports) {
|
|
|
778
777
|
clearInterval$1(timeId);
|
|
779
778
|
}
|
|
780
779
|
}
|
|
781
|
-
catch
|
|
780
|
+
catch {
|
|
781
|
+
// 忽略
|
|
782
782
|
}
|
|
783
783
|
finally {
|
|
784
784
|
PopsCore.clearInterval(timeId);
|
|
@@ -792,10 +792,8 @@ System.register('pops', [], (function (exports) {
|
|
|
792
792
|
* 获取安全的html
|
|
793
793
|
*/
|
|
794
794
|
getSafeHTML(text) {
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
// @ts-ignore
|
|
798
|
-
const policy = globalThis.trustedTypes.createPolicy("safe-innerHTML", {
|
|
795
|
+
if (window.trustedTypes) {
|
|
796
|
+
const policy = window.trustedTypes.createPolicy("safe-innerHTML", {
|
|
799
797
|
createHTML: (html) => html,
|
|
800
798
|
});
|
|
801
799
|
return policy.createHTML(text);
|
|
@@ -833,7 +831,7 @@ System.register('pops', [], (function (exports) {
|
|
|
833
831
|
* @param option
|
|
834
832
|
*/
|
|
835
833
|
function getOption(args, startIndex, option) {
|
|
836
|
-
|
|
834
|
+
const currentParam = args[startIndex];
|
|
837
835
|
if (typeof currentParam === "boolean") {
|
|
838
836
|
option.capture = currentParam;
|
|
839
837
|
if (typeof args[startIndex + 1] === "boolean") {
|
|
@@ -855,8 +853,9 @@ System.register('pops', [], (function (exports) {
|
|
|
855
853
|
}
|
|
856
854
|
return option;
|
|
857
855
|
}
|
|
858
|
-
|
|
859
|
-
|
|
856
|
+
const DOMUtilsContext = this;
|
|
857
|
+
// eslint-disable-next-line prefer-rest-params
|
|
858
|
+
const args = arguments;
|
|
860
859
|
if (typeof element === "string") {
|
|
861
860
|
element = DOMUtilsContext.selectorAll(element);
|
|
862
861
|
}
|
|
@@ -932,14 +931,14 @@ System.register('pops', [], (function (exports) {
|
|
|
932
931
|
totalParent = PopsCore.document.documentElement;
|
|
933
932
|
}
|
|
934
933
|
}
|
|
935
|
-
|
|
934
|
+
const findValue = selectorList.find((selectorItem) => {
|
|
936
935
|
// 判断目标元素是否匹配选择器
|
|
937
936
|
if (DOMUtilsContext.matches(eventTarget, selectorItem)) {
|
|
938
937
|
/* 当前目标可以被selector所匹配到 */
|
|
939
938
|
return true;
|
|
940
939
|
}
|
|
941
940
|
/* 在上层与主元素之间寻找可以被selector所匹配到的 */
|
|
942
|
-
|
|
941
|
+
const $closestMatches = DOMUtilsContext.closest(eventTarget, selectorItem);
|
|
943
942
|
if ($closestMatches && totalParent?.contains($closestMatches)) {
|
|
944
943
|
eventTarget = $closestMatches;
|
|
945
944
|
return true;
|
|
@@ -955,7 +954,9 @@ System.register('pops', [], (function (exports) {
|
|
|
955
954
|
},
|
|
956
955
|
});
|
|
957
956
|
}
|
|
958
|
-
catch
|
|
957
|
+
catch {
|
|
958
|
+
// 忽略
|
|
959
|
+
}
|
|
959
960
|
listenerCallBack.call(eventTarget, event, eventTarget);
|
|
960
961
|
checkOptionOnceToRemoveEventListener();
|
|
961
962
|
}
|
|
@@ -970,7 +971,7 @@ System.register('pops', [], (function (exports) {
|
|
|
970
971
|
eventTypeList.forEach((eventName) => {
|
|
971
972
|
elementItem.addEventListener(eventName, domUtilsEventCallBack, listenerOption);
|
|
972
973
|
/* 获取对象上的事件 */
|
|
973
|
-
|
|
974
|
+
const elementEvents = Reflect.get(elementItem, SymbolEvents) || {};
|
|
974
975
|
/* 初始化对象上的xx事件 */
|
|
975
976
|
elementEvents[eventName] = elementEvents[eventName] || [];
|
|
976
977
|
elementEvents[eventName].push({
|
|
@@ -992,7 +993,7 @@ System.register('pops', [], (function (exports) {
|
|
|
992
993
|
* @param option
|
|
993
994
|
*/
|
|
994
995
|
function getOption(args1, startIndex, option) {
|
|
995
|
-
|
|
996
|
+
const currentParam = args1[startIndex];
|
|
996
997
|
if (typeof currentParam === "boolean") {
|
|
997
998
|
option.capture = currentParam;
|
|
998
999
|
}
|
|
@@ -1001,8 +1002,9 @@ System.register('pops', [], (function (exports) {
|
|
|
1001
1002
|
}
|
|
1002
1003
|
return option;
|
|
1003
1004
|
}
|
|
1004
|
-
|
|
1005
|
-
|
|
1005
|
+
const DOMUtilsContext = this;
|
|
1006
|
+
// eslint-disable-next-line prefer-rest-params
|
|
1007
|
+
const args = arguments;
|
|
1006
1008
|
if (typeof element === "string") {
|
|
1007
1009
|
element = DOMUtilsContext.selectorAll(element);
|
|
1008
1010
|
}
|
|
@@ -1064,14 +1066,14 @@ System.register('pops', [], (function (exports) {
|
|
|
1064
1066
|
}
|
|
1065
1067
|
elementList.forEach((elementItem) => {
|
|
1066
1068
|
/* 获取对象上的事件 */
|
|
1067
|
-
|
|
1069
|
+
const elementEvents = Reflect.get(elementItem, SymbolEvents) || {};
|
|
1068
1070
|
eventTypeList.forEach((eventName) => {
|
|
1069
1071
|
let handlers = elementEvents[eventName] || [];
|
|
1070
1072
|
if (typeof filter === "function") {
|
|
1071
1073
|
handlers = handlers.filter(filter);
|
|
1072
1074
|
}
|
|
1073
1075
|
for (let index = 0; index < handlers.length; index++) {
|
|
1074
|
-
|
|
1076
|
+
const handler = handlers[index];
|
|
1075
1077
|
let flag = true;
|
|
1076
1078
|
if (flag && listenerCallBack && handler.originCallBack !== listenerCallBack) {
|
|
1077
1079
|
// callback不同
|
|
@@ -1131,10 +1133,10 @@ System.register('pops', [], (function (exports) {
|
|
|
1131
1133
|
if (!__symbolEvents.toString().startsWith("Symbol(events_")) {
|
|
1132
1134
|
return;
|
|
1133
1135
|
}
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
+
const elementEvents = elementItem[__symbolEvents] || {};
|
|
1137
|
+
const iterEventNameList = eventTypeList.length ? eventTypeList : Object.keys(elementEvents);
|
|
1136
1138
|
iterEventNameList.forEach((eventName) => {
|
|
1137
|
-
|
|
1139
|
+
const handlers = elementEvents[eventName];
|
|
1138
1140
|
if (!handlers) {
|
|
1139
1141
|
return;
|
|
1140
1142
|
}
|
|
@@ -1174,7 +1176,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1174
1176
|
return false;
|
|
1175
1177
|
}
|
|
1176
1178
|
}
|
|
1177
|
-
catch
|
|
1179
|
+
catch {
|
|
1178
1180
|
return false;
|
|
1179
1181
|
}
|
|
1180
1182
|
}
|
|
@@ -1185,7 +1187,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1185
1187
|
removeDomReadyListener();
|
|
1186
1188
|
callback();
|
|
1187
1189
|
}
|
|
1188
|
-
|
|
1190
|
+
const targetList = [
|
|
1189
1191
|
{
|
|
1190
1192
|
target: PopsCore.document,
|
|
1191
1193
|
eventType: "DOMContentLoaded",
|
|
@@ -1202,7 +1204,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1202
1204
|
*/
|
|
1203
1205
|
function addDomReadyListener() {
|
|
1204
1206
|
for (let index = 0; index < targetList.length; index++) {
|
|
1205
|
-
|
|
1207
|
+
const item = targetList[index];
|
|
1206
1208
|
that.on(item.target, item.eventType, item.callback);
|
|
1207
1209
|
}
|
|
1208
1210
|
}
|
|
@@ -1211,7 +1213,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1211
1213
|
*/
|
|
1212
1214
|
function removeDomReadyListener() {
|
|
1213
1215
|
for (let index = 0; index < targetList.length; index++) {
|
|
1214
|
-
|
|
1216
|
+
const item = targetList[index];
|
|
1215
1217
|
that.off(item.target, item.eventType, item.callback);
|
|
1216
1218
|
}
|
|
1217
1219
|
}
|
|
@@ -1262,7 +1264,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1262
1264
|
}
|
|
1263
1265
|
elementList.forEach((elementItem) => {
|
|
1264
1266
|
/* 获取对象上的事件 */
|
|
1265
|
-
|
|
1267
|
+
const events = elementItem[SymbolEvents] || {};
|
|
1266
1268
|
eventTypeList.forEach((_eventType_) => {
|
|
1267
1269
|
let event = null;
|
|
1268
1270
|
if (details && details instanceof Event) {
|
|
@@ -1302,7 +1304,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1302
1304
|
* })
|
|
1303
1305
|
* */
|
|
1304
1306
|
click(element, handler, details, useDispatchToTriggerEvent) {
|
|
1305
|
-
|
|
1307
|
+
const DOMUtilsContext = this;
|
|
1306
1308
|
if (typeof element === "string") {
|
|
1307
1309
|
element = PopsCore.document.querySelector(element);
|
|
1308
1310
|
}
|
|
@@ -1331,7 +1333,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1331
1333
|
* })
|
|
1332
1334
|
* */
|
|
1333
1335
|
blur(element, handler, details, useDispatchToTriggerEvent) {
|
|
1334
|
-
|
|
1336
|
+
const DOMUtilsContext = this;
|
|
1335
1337
|
if (typeof element === "string") {
|
|
1336
1338
|
element = PopsCore.document.querySelector(element);
|
|
1337
1339
|
}
|
|
@@ -1360,7 +1362,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1360
1362
|
* })
|
|
1361
1363
|
* */
|
|
1362
1364
|
focus(element, handler, details, useDispatchToTriggerEvent) {
|
|
1363
|
-
|
|
1365
|
+
const DOMUtilsContext = this;
|
|
1364
1366
|
if (typeof element === "string") {
|
|
1365
1367
|
element = PopsCore.document.querySelector(element);
|
|
1366
1368
|
}
|
|
@@ -1389,7 +1391,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1389
1391
|
* })
|
|
1390
1392
|
*/
|
|
1391
1393
|
hover(element, handler, option) {
|
|
1392
|
-
|
|
1394
|
+
const DOMUtilsContext = this;
|
|
1393
1395
|
if (typeof element === "string") {
|
|
1394
1396
|
element = PopsCore.document.querySelector(element);
|
|
1395
1397
|
}
|
|
@@ -1415,7 +1417,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1415
1417
|
* })
|
|
1416
1418
|
*/
|
|
1417
1419
|
keyup(target, handler, option) {
|
|
1418
|
-
|
|
1420
|
+
const DOMUtilsContext = this;
|
|
1419
1421
|
if (target == null) {
|
|
1420
1422
|
return;
|
|
1421
1423
|
}
|
|
@@ -1440,7 +1442,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1440
1442
|
* })
|
|
1441
1443
|
*/
|
|
1442
1444
|
keydown(target, handler, option) {
|
|
1443
|
-
|
|
1445
|
+
const DOMUtilsContext = this;
|
|
1444
1446
|
if (target == null) {
|
|
1445
1447
|
return;
|
|
1446
1448
|
}
|
|
@@ -1465,7 +1467,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1465
1467
|
* })
|
|
1466
1468
|
*/
|
|
1467
1469
|
keypress(target, handler, option) {
|
|
1468
|
-
|
|
1470
|
+
const DOMUtilsContext = this;
|
|
1469
1471
|
if (target == null) {
|
|
1470
1472
|
return;
|
|
1471
1473
|
}
|
|
@@ -1486,6 +1488,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1486
1488
|
}
|
|
1487
1489
|
if (arguments.length === 1) {
|
|
1488
1490
|
/* 直接阻止事件 */
|
|
1491
|
+
// eslint-disable-next-line prefer-rest-params
|
|
1489
1492
|
return stopEvent(arguments[0]);
|
|
1490
1493
|
}
|
|
1491
1494
|
else {
|
|
@@ -1510,32 +1513,28 @@ System.register('pops', [], (function (exports) {
|
|
|
1510
1513
|
return $ele?.innerHTML?.trim() === "";
|
|
1511
1514
|
});
|
|
1512
1515
|
}
|
|
1513
|
-
else if (selector.match(/[^\s]{1}:contains\("(.*)"\)$/i) ||
|
|
1514
|
-
selector.match(/[^\s]{1}:contains\('(.*)'\)$/i)) {
|
|
1516
|
+
else if (selector.match(/[^\s]{1}:contains\("(.*)"\)$/i) || selector.match(/[^\s]{1}:contains\('(.*)'\)$/i)) {
|
|
1515
1517
|
// contains 语法
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
+
const textMatch = selector.match(/:contains\(("|')(.*)("|')\)$/i);
|
|
1519
|
+
const text = textMatch[2];
|
|
1518
1520
|
selector = selector.replace(/:contains\(("|')(.*)("|')\)$/gi, "");
|
|
1519
1521
|
return Array.from(PopsCore.document.querySelectorAll(selector)).filter(($ele) => {
|
|
1520
|
-
// @ts-ignore
|
|
1521
1522
|
return ($ele?.textContent || $ele?.innerText)?.includes(text);
|
|
1522
1523
|
});
|
|
1523
1524
|
}
|
|
1524
|
-
else if (selector.match(/[^\s]{1}:regexp\("(.*)"\)$/i) ||
|
|
1525
|
-
selector.match(/[^\s]{1}:regexp\('(.*)'\)$/i)) {
|
|
1525
|
+
else if (selector.match(/[^\s]{1}:regexp\("(.*)"\)$/i) || selector.match(/[^\s]{1}:regexp\('(.*)'\)$/i)) {
|
|
1526
1526
|
// regexp 语法
|
|
1527
|
-
|
|
1527
|
+
const textMatch = selector.match(/:regexp\(("|')(.*)("|')\)$/i);
|
|
1528
1528
|
let pattern = textMatch[2];
|
|
1529
|
-
|
|
1529
|
+
const flagMatch = pattern.match(/("|'),[\s]*("|')([igm]{0,3})$/i);
|
|
1530
1530
|
let flags = "";
|
|
1531
1531
|
if (flagMatch) {
|
|
1532
1532
|
pattern = pattern.replace(/("|'),[\s]*("|')([igm]{0,3})$/gi, "");
|
|
1533
1533
|
flags = flagMatch[3];
|
|
1534
1534
|
}
|
|
1535
|
-
|
|
1535
|
+
const regexp = new RegExp(pattern, flags);
|
|
1536
1536
|
selector = selector.replace(/:regexp\(("|')(.*)("|')\)$/gi, "");
|
|
1537
1537
|
return Array.from(PopsCore.document.querySelectorAll(selector)).filter(($ele) => {
|
|
1538
|
-
// @ts-ignore
|
|
1539
1538
|
return Boolean(($ele?.textContent || $ele?.innerText)?.match(regexp));
|
|
1540
1539
|
});
|
|
1541
1540
|
}
|
|
@@ -1575,33 +1574,29 @@ System.register('pops', [], (function (exports) {
|
|
|
1575
1574
|
selector = selector.replace(/:empty$/gi, "");
|
|
1576
1575
|
return $el.matches(selector) && $el?.innerHTML?.trim() === "";
|
|
1577
1576
|
}
|
|
1578
|
-
else if (selector.match(/[^\s]{1}:contains\("(.*)"\)$/i) ||
|
|
1579
|
-
selector.match(/[^\s]{1}:contains\('(.*)'\)$/i)) {
|
|
1577
|
+
else if (selector.match(/[^\s]{1}:contains\("(.*)"\)$/i) || selector.match(/[^\s]{1}:contains\('(.*)'\)$/i)) {
|
|
1580
1578
|
// contains 语法
|
|
1581
|
-
|
|
1582
|
-
|
|
1579
|
+
const textMatch = selector.match(/:contains\(("|')(.*)("|')\)$/i);
|
|
1580
|
+
const text = textMatch[2];
|
|
1583
1581
|
selector = selector.replace(/:contains\(("|')(.*)("|')\)$/gi, "");
|
|
1584
|
-
// @ts-ignore
|
|
1585
1582
|
let content = $el?.textContent || $el?.innerText;
|
|
1586
1583
|
if (typeof content !== "string") {
|
|
1587
1584
|
content = "";
|
|
1588
1585
|
}
|
|
1589
1586
|
return $el.matches(selector) && content?.includes(text);
|
|
1590
1587
|
}
|
|
1591
|
-
else if (selector.match(/[^\s]{1}:regexp\("(.*)"\)$/i) ||
|
|
1592
|
-
selector.match(/[^\s]{1}:regexp\('(.*)'\)$/i)) {
|
|
1588
|
+
else if (selector.match(/[^\s]{1}:regexp\("(.*)"\)$/i) || selector.match(/[^\s]{1}:regexp\('(.*)'\)$/i)) {
|
|
1593
1589
|
// regexp 语法
|
|
1594
|
-
|
|
1590
|
+
const textMatch = selector.match(/:regexp\(("|')(.*)("|')\)$/i);
|
|
1595
1591
|
let pattern = textMatch[2];
|
|
1596
|
-
|
|
1592
|
+
const flagMatch = pattern.match(/("|'),[\s]*("|')([igm]{0,3})$/i);
|
|
1597
1593
|
let flags = "";
|
|
1598
1594
|
if (flagMatch) {
|
|
1599
1595
|
pattern = pattern.replace(/("|'),[\s]*("|')([igm]{0,3})$/gi, "");
|
|
1600
1596
|
flags = flagMatch[3];
|
|
1601
1597
|
}
|
|
1602
|
-
|
|
1598
|
+
const regexp = new RegExp(pattern, flags);
|
|
1603
1599
|
selector = selector.replace(/:regexp\(("|')(.*)("|')\)$/gi, "");
|
|
1604
|
-
// @ts-ignore
|
|
1605
1600
|
let content = $el?.textContent || $el?.innerText;
|
|
1606
1601
|
if (typeof content !== "string") {
|
|
1607
1602
|
content = "";
|
|
@@ -1618,45 +1613,41 @@ System.register('pops', [], (function (exports) {
|
|
|
1618
1613
|
if (selector.match(/[^\s]{1}:empty$/gi)) {
|
|
1619
1614
|
// empty 语法
|
|
1620
1615
|
selector = selector.replace(/:empty$/gi, "");
|
|
1621
|
-
|
|
1616
|
+
const $closest = $el?.closest(selector);
|
|
1622
1617
|
if ($closest && $closest?.innerHTML?.trim() === "") {
|
|
1623
1618
|
return $closest;
|
|
1624
1619
|
}
|
|
1625
1620
|
return null;
|
|
1626
1621
|
}
|
|
1627
|
-
else if (selector.match(/[^\s]{1}:contains\("(.*)"\)$/i) ||
|
|
1628
|
-
selector.match(/[^\s]{1}:contains\('(.*)'\)$/i)) {
|
|
1622
|
+
else if (selector.match(/[^\s]{1}:contains\("(.*)"\)$/i) || selector.match(/[^\s]{1}:contains\('(.*)'\)$/i)) {
|
|
1629
1623
|
// contains 语法
|
|
1630
|
-
|
|
1631
|
-
|
|
1624
|
+
const textMatch = selector.match(/:contains\(("|')(.*)("|')\)$/i);
|
|
1625
|
+
const text = textMatch[2];
|
|
1632
1626
|
selector = selector.replace(/:contains\(("|')(.*)("|')\)$/gi, "");
|
|
1633
|
-
|
|
1627
|
+
const $closest = $el?.closest(selector);
|
|
1634
1628
|
if ($closest) {
|
|
1635
|
-
|
|
1636
|
-
let content = $el?.textContent || $el?.innerText;
|
|
1629
|
+
const content = $el?.textContent || $el?.innerText;
|
|
1637
1630
|
if (typeof content === "string" && content.includes(text)) {
|
|
1638
1631
|
return $closest;
|
|
1639
1632
|
}
|
|
1640
1633
|
}
|
|
1641
1634
|
return null;
|
|
1642
1635
|
}
|
|
1643
|
-
else if (selector.match(/[^\s]{1}:regexp\("(.*)"\)$/i) ||
|
|
1644
|
-
selector.match(/[^\s]{1}:regexp\('(.*)'\)$/i)) {
|
|
1636
|
+
else if (selector.match(/[^\s]{1}:regexp\("(.*)"\)$/i) || selector.match(/[^\s]{1}:regexp\('(.*)'\)$/i)) {
|
|
1645
1637
|
// regexp 语法
|
|
1646
|
-
|
|
1638
|
+
const textMatch = selector.match(/:regexp\(("|')(.*)("|')\)$/i);
|
|
1647
1639
|
let pattern = textMatch[2];
|
|
1648
|
-
|
|
1640
|
+
const flagMatch = pattern.match(/("|'),[\s]*("|')([igm]{0,3})$/i);
|
|
1649
1641
|
let flags = "";
|
|
1650
1642
|
if (flagMatch) {
|
|
1651
1643
|
pattern = pattern.replace(/("|'),[\s]*("|')([igm]{0,3})$/gi, "");
|
|
1652
1644
|
flags = flagMatch[3];
|
|
1653
1645
|
}
|
|
1654
|
-
|
|
1646
|
+
const regexp = new RegExp(pattern, flags);
|
|
1655
1647
|
selector = selector.replace(/:regexp\(("|')(.*)("|')\)$/gi, "");
|
|
1656
|
-
|
|
1648
|
+
const $closest = $el?.closest(selector);
|
|
1657
1649
|
if ($closest) {
|
|
1658
|
-
|
|
1659
|
-
let content = $el?.textContent || $el?.innerText;
|
|
1650
|
+
const content = $el?.textContent || $el?.innerText;
|
|
1660
1651
|
if (typeof content === "string" && content.match(regexp)) {
|
|
1661
1652
|
return $closest;
|
|
1662
1653
|
}
|
|
@@ -1665,7 +1656,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1665
1656
|
}
|
|
1666
1657
|
else {
|
|
1667
1658
|
// 普通语法
|
|
1668
|
-
|
|
1659
|
+
const $closest = $el?.closest(selector);
|
|
1669
1660
|
return $closest;
|
|
1670
1661
|
}
|
|
1671
1662
|
}
|
|
@@ -1685,13 +1676,13 @@ System.register('pops', [], (function (exports) {
|
|
|
1685
1676
|
* @param calcScroll 计算滚动距离
|
|
1686
1677
|
*/
|
|
1687
1678
|
offset(element, calcScroll = true) {
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1679
|
+
const rect = element.getBoundingClientRect();
|
|
1680
|
+
const win = element.ownerDocument.defaultView;
|
|
1681
|
+
const resultRect = new DOMRect(calcScroll ? parseFloat((rect.left + (win?.pageXOffset || 0)).toString()) : rect.left, calcScroll ? parseFloat((rect.top + (win?.pageYOffset || 0)).toString()) : rect.top, rect.width, rect.height);
|
|
1691
1682
|
return resultRect;
|
|
1692
1683
|
}
|
|
1693
1684
|
width(element, isShow = false, parent) {
|
|
1694
|
-
|
|
1685
|
+
const DOMUtilsContext = this;
|
|
1695
1686
|
if (typeof element === "string") {
|
|
1696
1687
|
element = PopsCore.document.querySelector(element);
|
|
1697
1688
|
}
|
|
@@ -1716,11 +1707,11 @@ System.register('pops', [], (function (exports) {
|
|
|
1716
1707
|
}
|
|
1717
1708
|
/* 如果从css里获取到的值不是大于0 可能是auto 则通过offsetWidth来进行计算 */
|
|
1718
1709
|
if (element.offsetWidth > 0) {
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1710
|
+
const borderLeftWidth = popsDOMUtils.getStyleValue(element, "borderLeftWidth");
|
|
1711
|
+
const borderRightWidth = popsDOMUtils.getStyleValue(element, "borderRightWidth");
|
|
1712
|
+
const paddingLeft = popsDOMUtils.getStyleValue(element, "paddingLeft");
|
|
1713
|
+
const paddingRight = popsDOMUtils.getStyleValue(element, "paddingRight");
|
|
1714
|
+
const backHeight = parseFloat(element.offsetWidth.toString()) -
|
|
1724
1715
|
parseFloat(borderLeftWidth.toString()) -
|
|
1725
1716
|
parseFloat(borderRightWidth.toString()) -
|
|
1726
1717
|
parseFloat(paddingLeft.toString()) -
|
|
@@ -1732,14 +1723,14 @@ System.register('pops', [], (function (exports) {
|
|
|
1732
1723
|
else {
|
|
1733
1724
|
/* 未显示 */
|
|
1734
1725
|
element = element;
|
|
1735
|
-
|
|
1736
|
-
|
|
1726
|
+
const { cloneNode, recovery } = popsDOMUtils.showElement(element, parent);
|
|
1727
|
+
const width = DOMUtilsContext.width(cloneNode, true, parent);
|
|
1737
1728
|
recovery();
|
|
1738
1729
|
return width;
|
|
1739
1730
|
}
|
|
1740
1731
|
}
|
|
1741
1732
|
height(element, isShow = false, parent) {
|
|
1742
|
-
|
|
1733
|
+
const DOMUtilsContext = this;
|
|
1743
1734
|
if (popsUtils.isWin(element)) {
|
|
1744
1735
|
return PopsCore.window.document.documentElement.clientHeight;
|
|
1745
1736
|
}
|
|
@@ -1764,11 +1755,11 @@ System.register('pops', [], (function (exports) {
|
|
|
1764
1755
|
}
|
|
1765
1756
|
/* 如果从css里获取到的值不是大于0 可能是auto 则通过offsetHeight来进行计算 */
|
|
1766
1757
|
if (element.offsetHeight > 0) {
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1758
|
+
const borderTopWidth = popsDOMUtils.getStyleValue(element, "borderTopWidth");
|
|
1759
|
+
const borderBottomWidth = popsDOMUtils.getStyleValue(element, "borderBottomWidth");
|
|
1760
|
+
const paddingTop = popsDOMUtils.getStyleValue(element, "paddingTop");
|
|
1761
|
+
const paddingBottom = popsDOMUtils.getStyleValue(element, "paddingBottom");
|
|
1762
|
+
const backHeight = parseFloat(element.offsetHeight.toString()) -
|
|
1772
1763
|
parseFloat(borderTopWidth.toString()) -
|
|
1773
1764
|
parseFloat(borderBottomWidth.toString()) -
|
|
1774
1765
|
parseFloat(paddingTop.toString()) -
|
|
@@ -1780,14 +1771,14 @@ System.register('pops', [], (function (exports) {
|
|
|
1780
1771
|
else {
|
|
1781
1772
|
/* 未显示 */
|
|
1782
1773
|
element = element;
|
|
1783
|
-
|
|
1784
|
-
|
|
1774
|
+
const { cloneNode, recovery } = popsDOMUtils.showElement(element, parent);
|
|
1775
|
+
const height = DOMUtilsContext.height(cloneNode, true, parent);
|
|
1785
1776
|
recovery();
|
|
1786
1777
|
return height;
|
|
1787
1778
|
}
|
|
1788
1779
|
}
|
|
1789
1780
|
outerWidth(element, isShow = false, parent) {
|
|
1790
|
-
|
|
1781
|
+
const DOMUtilsContext = this;
|
|
1791
1782
|
if (popsUtils.isWin(element)) {
|
|
1792
1783
|
return PopsCore.window.innerWidth;
|
|
1793
1784
|
}
|
|
@@ -1799,40 +1790,36 @@ System.register('pops', [], (function (exports) {
|
|
|
1799
1790
|
}
|
|
1800
1791
|
element = element;
|
|
1801
1792
|
if (isShow || (!isShow && popsDOMUtils.isShow(element))) {
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1793
|
+
const style = getComputedStyle(element, null);
|
|
1794
|
+
const marginLeft = popsDOMUtils.getStyleValue(style, "marginLeft");
|
|
1795
|
+
const marginRight = popsDOMUtils.getStyleValue(style, "marginRight");
|
|
1805
1796
|
return element.offsetWidth + marginLeft + marginRight;
|
|
1806
1797
|
}
|
|
1807
1798
|
else {
|
|
1808
|
-
|
|
1809
|
-
|
|
1799
|
+
const { cloneNode, recovery } = popsDOMUtils.showElement(element, parent);
|
|
1800
|
+
const outerWidth = DOMUtilsContext.outerWidth(cloneNode, true, parent);
|
|
1810
1801
|
recovery();
|
|
1811
1802
|
return outerWidth;
|
|
1812
1803
|
}
|
|
1813
1804
|
}
|
|
1814
1805
|
outerHeight(element, isShow = false, parent) {
|
|
1815
|
-
|
|
1806
|
+
const DOMUtilsContext = this;
|
|
1816
1807
|
if (popsUtils.isWin(element)) {
|
|
1817
1808
|
return PopsCore.window.innerHeight;
|
|
1818
1809
|
}
|
|
1819
1810
|
if (typeof element === "string") {
|
|
1820
1811
|
element = PopsCore.document.querySelector(element);
|
|
1821
1812
|
}
|
|
1822
|
-
if (element == null) {
|
|
1823
|
-
// @ts-ignore
|
|
1824
|
-
return;
|
|
1825
|
-
}
|
|
1826
1813
|
element = element;
|
|
1827
1814
|
if (isShow || (!isShow && popsDOMUtils.isShow(element))) {
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1815
|
+
const style = getComputedStyle(element, null);
|
|
1816
|
+
const marginTop = popsDOMUtils.getStyleValue(style, "marginTop");
|
|
1817
|
+
const marginBottom = popsDOMUtils.getStyleValue(style, "marginBottom");
|
|
1831
1818
|
return element.offsetHeight + marginTop + marginBottom;
|
|
1832
1819
|
}
|
|
1833
1820
|
else {
|
|
1834
|
-
|
|
1835
|
-
|
|
1821
|
+
const { cloneNode, recovery } = popsDOMUtils.showElement(element, parent);
|
|
1822
|
+
const outerHeight = DOMUtilsContext.outerHeight(cloneNode, true, parent);
|
|
1836
1823
|
recovery();
|
|
1837
1824
|
return outerHeight;
|
|
1838
1825
|
}
|
|
@@ -1895,13 +1882,11 @@ System.register('pops', [], (function (exports) {
|
|
|
1895
1882
|
* 把纯数字没有px的加上
|
|
1896
1883
|
*/
|
|
1897
1884
|
function handlePixe(propertyName, propertyValue) {
|
|
1898
|
-
|
|
1885
|
+
const allowAddPixe = ["width", "height", "top", "left", "right", "bottom", "font-size"];
|
|
1899
1886
|
if (typeof propertyValue === "number") {
|
|
1900
1887
|
propertyValue = propertyValue.toString();
|
|
1901
1888
|
}
|
|
1902
|
-
if (typeof propertyValue === "string" &&
|
|
1903
|
-
allowAddPixe.includes(propertyName) &&
|
|
1904
|
-
propertyValue.match(/[0-9]$/gi)) {
|
|
1889
|
+
if (typeof propertyValue === "string" && allowAddPixe.includes(propertyName) && propertyValue.match(/[0-9]$/gi)) {
|
|
1905
1890
|
propertyValue = propertyValue + "px";
|
|
1906
1891
|
}
|
|
1907
1892
|
return propertyValue;
|
|
@@ -1912,7 +1897,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1912
1897
|
if (element == null) {
|
|
1913
1898
|
return;
|
|
1914
1899
|
}
|
|
1915
|
-
|
|
1900
|
+
const setStyleProperty = (propertyName, propertyValue) => {
|
|
1916
1901
|
if (typeof propertyValue === "string" && propertyValue.trim().endsWith("!important")) {
|
|
1917
1902
|
propertyValue = propertyValue
|
|
1918
1903
|
.trim()
|
|
@@ -1934,8 +1919,8 @@ System.register('pops', [], (function (exports) {
|
|
|
1934
1919
|
}
|
|
1935
1920
|
}
|
|
1936
1921
|
else if (typeof property === "object") {
|
|
1937
|
-
for (
|
|
1938
|
-
|
|
1922
|
+
for (const prop in property) {
|
|
1923
|
+
const value = property[prop];
|
|
1939
1924
|
setStyleProperty(prop, value);
|
|
1940
1925
|
}
|
|
1941
1926
|
}
|
|
@@ -1965,7 +1950,7 @@ System.register('pops', [], (function (exports) {
|
|
|
1965
1950
|
property,
|
|
1966
1951
|
/** 自定义属性 */
|
|
1967
1952
|
attributes) {
|
|
1968
|
-
|
|
1953
|
+
const tempElement = PopsCore.document.createElement(tagName);
|
|
1969
1954
|
if (typeof property === "string") {
|
|
1970
1955
|
PopsSafeUtils.setSafeHTML(tempElement, property);
|
|
1971
1956
|
return tempElement;
|
|
@@ -1977,13 +1962,12 @@ System.register('pops', [], (function (exports) {
|
|
|
1977
1962
|
attributes = {};
|
|
1978
1963
|
}
|
|
1979
1964
|
Object.keys(property).forEach((key) => {
|
|
1980
|
-
|
|
1965
|
+
const value = property[key];
|
|
1981
1966
|
if (key === "innerHTML") {
|
|
1982
1967
|
PopsSafeUtils.setSafeHTML(tempElement, value);
|
|
1983
1968
|
return;
|
|
1984
1969
|
}
|
|
1985
|
-
|
|
1986
|
-
tempElement[key] = value;
|
|
1970
|
+
Reflect.set(tempElement, key, value);
|
|
1987
1971
|
});
|
|
1988
1972
|
Object.keys(attributes).forEach((key) => {
|
|
1989
1973
|
let value = attributes[key];
|
|
@@ -2007,7 +1991,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2007
1991
|
parseTextToDOM(elementString) {
|
|
2008
1992
|
/* 去除前后的换行和空格 */
|
|
2009
1993
|
elementString = elementString.replace(/^[\n|\s]*/g, "").replace(/[\n|\s]*$/g, "");
|
|
2010
|
-
|
|
1994
|
+
const targetElement = this.createElement("div", {
|
|
2011
1995
|
innerHTML: elementString,
|
|
2012
1996
|
});
|
|
2013
1997
|
return targetElement.firstChild;
|
|
@@ -2045,16 +2029,21 @@ System.register('pops', [], (function (exports) {
|
|
|
2045
2029
|
selectionEnd = Math.min(input.value.length, selectionEnd);
|
|
2046
2030
|
// If available (thus IE), use the createTextRange method
|
|
2047
2031
|
if (typeof input.createTextRange == "function") {
|
|
2048
|
-
|
|
2032
|
+
const range = input.createTextRange();
|
|
2049
2033
|
range.collapse(true);
|
|
2050
2034
|
range.moveStart("character", selectionStart);
|
|
2051
2035
|
range.moveEnd("character", selectionEnd - selectionStart);
|
|
2052
2036
|
return range.getBoundingClientRect();
|
|
2053
2037
|
}
|
|
2054
2038
|
// createTextRange is not supported, create a fake text range
|
|
2055
|
-
|
|
2039
|
+
const offset = getInputOffset();
|
|
2040
|
+
let topPos = offset.top;
|
|
2041
|
+
let leftPos = offset.left;
|
|
2042
|
+
const width = getInputCSS("width", true);
|
|
2043
|
+
const height = getInputCSS("height", true);
|
|
2056
2044
|
// Styles to simulate a node in an input field
|
|
2057
|
-
|
|
2045
|
+
let cssDefaultStyles = "white-space:pre;padding:0;margin:0;";
|
|
2046
|
+
const listOfModifiers = [
|
|
2058
2047
|
"direction",
|
|
2059
2048
|
"font-family",
|
|
2060
2049
|
"font-size",
|
|
@@ -2070,26 +2059,21 @@ System.register('pops', [], (function (exports) {
|
|
|
2070
2059
|
"word-wrap",
|
|
2071
2060
|
"word-spacing",
|
|
2072
2061
|
];
|
|
2073
|
-
// @ts-ignore
|
|
2074
2062
|
topPos += getInputCSS("padding-top", true);
|
|
2075
|
-
// @ts-ignore
|
|
2076
2063
|
topPos += getInputCSS("border-top-width", true);
|
|
2077
|
-
// @ts-ignore
|
|
2078
2064
|
leftPos += getInputCSS("padding-left", true);
|
|
2079
|
-
// @ts-ignore
|
|
2080
2065
|
leftPos += getInputCSS("border-left-width", true);
|
|
2081
2066
|
leftPos += 1; //Seems to be necessary
|
|
2082
|
-
for (
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
cssDefaultStyles += property + ":" + getInputCSS(property) + ";";
|
|
2067
|
+
for (let i = 0; i < listOfModifiers.length; i++) {
|
|
2068
|
+
const property = listOfModifiers[i];
|
|
2069
|
+
cssDefaultStyles += property + ":" + getInputCSS(property, false) + ";";
|
|
2086
2070
|
}
|
|
2087
2071
|
// End of CSS variable checks
|
|
2088
2072
|
// 不能为空,不然获取不到高度
|
|
2089
|
-
|
|
2073
|
+
const text = input.value || "G", textLen = text.length, fakeClone = document.createElement("div");
|
|
2090
2074
|
if (selectionStart > 0)
|
|
2091
2075
|
appendPart(0, selectionStart);
|
|
2092
|
-
|
|
2076
|
+
const fakeRange = appendPart(selectionStart, selectionEnd);
|
|
2093
2077
|
if (textLen > selectionEnd)
|
|
2094
2078
|
appendPart(selectionEnd, textLen);
|
|
2095
2079
|
// Styles to inherit the font styles of the element
|
|
@@ -2101,7 +2085,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2101
2085
|
fakeClone.style.width = width + "px";
|
|
2102
2086
|
fakeClone.style.height = height + "px";
|
|
2103
2087
|
PopsCore.document.body.appendChild(fakeClone);
|
|
2104
|
-
|
|
2088
|
+
const returnValue = fakeRange.getBoundingClientRect(); //Get rect
|
|
2105
2089
|
if (!debug)
|
|
2106
2090
|
fakeClone.parentNode.removeChild(fakeClone); //Remove temp
|
|
2107
2091
|
return returnValue;
|
|
@@ -2112,7 +2096,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2112
2096
|
* @param end
|
|
2113
2097
|
*/
|
|
2114
2098
|
function appendPart(start, end) {
|
|
2115
|
-
|
|
2099
|
+
const span = document.createElement("span");
|
|
2116
2100
|
span.style.cssText = cssDefaultStyles; //Force styles to prevent unexpected results
|
|
2117
2101
|
span.textContent = text.substring(start, end);
|
|
2118
2102
|
fakeClone.appendChild(span);
|
|
@@ -2120,35 +2104,31 @@ System.register('pops', [], (function (exports) {
|
|
|
2120
2104
|
}
|
|
2121
2105
|
// Computing offset position
|
|
2122
2106
|
function getInputOffset() {
|
|
2123
|
-
|
|
2107
|
+
const body = document.body, win = document.defaultView, docElem = document.documentElement, box = document.createElement("div");
|
|
2124
2108
|
box.style.paddingLeft = box.style.width = "1px";
|
|
2125
2109
|
body.appendChild(box);
|
|
2126
|
-
|
|
2110
|
+
const isBoxModel = box.offsetWidth == 2;
|
|
2127
2111
|
body.removeChild(box);
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
var clientTop = docElem.clientTop || body.clientTop || 0, clientLeft = docElem.clientLeft || body.clientLeft || 0, scrollTop =
|
|
2131
|
-
// @ts-ignore
|
|
2132
|
-
win.pageYOffset || (isBoxModel && docElem.scrollTop) || body.scrollTop, scrollLeft =
|
|
2133
|
-
// @ts-ignore
|
|
2134
|
-
win.pageXOffset || (isBoxModel && docElem.scrollLeft) || body.scrollLeft;
|
|
2112
|
+
const boxRect = input.getBoundingClientRect();
|
|
2113
|
+
const clientTop = docElem.clientTop || body.clientTop || 0, clientLeft = docElem.clientLeft || body.clientLeft || 0, scrollTop = win?.pageYOffset || (isBoxModel && docElem.scrollTop) || body.scrollTop, scrollLeft = win?.pageXOffset || (isBoxModel && docElem.scrollLeft) || body.scrollLeft;
|
|
2135
2114
|
return {
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
// @ts-ignore
|
|
2139
|
-
left: box.left + scrollLeft - clientLeft,
|
|
2115
|
+
top: boxRect.top + scrollTop - clientTop,
|
|
2116
|
+
left: boxRect.left + scrollLeft - clientLeft,
|
|
2140
2117
|
};
|
|
2141
2118
|
}
|
|
2142
2119
|
/**
|
|
2143
2120
|
*
|
|
2144
2121
|
* @param prop
|
|
2145
2122
|
* @param isnumber
|
|
2146
|
-
* @returns
|
|
2147
2123
|
*/
|
|
2148
2124
|
function getInputCSS(prop, isnumber) {
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2125
|
+
const val = PopsCore.document.defaultView.getComputedStyle(input, null).getPropertyValue(prop);
|
|
2126
|
+
if (isnumber) {
|
|
2127
|
+
return parseFloat(val);
|
|
2128
|
+
}
|
|
2129
|
+
else {
|
|
2130
|
+
return val;
|
|
2131
|
+
}
|
|
2152
2132
|
}
|
|
2153
2133
|
}
|
|
2154
2134
|
/**
|
|
@@ -2180,7 +2160,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2180
2160
|
}
|
|
2181
2161
|
parseHTML(html, useParser = false, isComplete = false) {
|
|
2182
2162
|
function parseHTMLByDOMParser() {
|
|
2183
|
-
|
|
2163
|
+
const parser = new DOMParser();
|
|
2184
2164
|
if (isComplete) {
|
|
2185
2165
|
return parser.parseFromString(html, "text/html");
|
|
2186
2166
|
}
|
|
@@ -2189,7 +2169,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2189
2169
|
}
|
|
2190
2170
|
}
|
|
2191
2171
|
function parseHTMLByCreateDom() {
|
|
2192
|
-
|
|
2172
|
+
const tempDIV = PopsCore.document.createElement("div");
|
|
2193
2173
|
PopsSafeUtils.setSafeHTML(tempDIV, html);
|
|
2194
2174
|
if (isComplete) {
|
|
2195
2175
|
return tempDIV;
|
|
@@ -2231,7 +2211,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2231
2211
|
}
|
|
2232
2212
|
if (Array.isArray(content) || content instanceof NodeList) {
|
|
2233
2213
|
/* 数组 */
|
|
2234
|
-
|
|
2214
|
+
const fragment = PopsCore.document.createDocumentFragment();
|
|
2235
2215
|
content.forEach((ele) => {
|
|
2236
2216
|
if (typeof ele === "string") {
|
|
2237
2217
|
ele = this.parseHTML(ele, true, false);
|
|
@@ -2281,11 +2261,11 @@ System.register('pops', [], (function (exports) {
|
|
|
2281
2261
|
*/
|
|
2282
2262
|
showElement($ele, ownParent) {
|
|
2283
2263
|
/** 克隆元素 */
|
|
2284
|
-
|
|
2264
|
+
const $cloneNode = $ele.cloneNode(true);
|
|
2285
2265
|
$cloneNode.setAttribute("style", "visibility: hidden !important;display:block !important;");
|
|
2286
2266
|
let $parent = PopsCore.document.documentElement;
|
|
2287
2267
|
// 这里需要的是先获取元素的父节点,把元素同样添加到父节点中
|
|
2288
|
-
|
|
2268
|
+
const $root = $ele.getRootNode();
|
|
2289
2269
|
if (ownParent == null) {
|
|
2290
2270
|
if ($root == $ele) {
|
|
2291
2271
|
// 未添加到任意节点中,那么直接添加到页面中去
|
|
@@ -2333,7 +2313,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2333
2313
|
}
|
|
2334
2314
|
styles = view.getComputedStyle(element);
|
|
2335
2315
|
}
|
|
2336
|
-
|
|
2316
|
+
const value = parseFloat(styles[styleName]);
|
|
2337
2317
|
if (isNaN(value)) {
|
|
2338
2318
|
return 0;
|
|
2339
2319
|
}
|
|
@@ -2393,10 +2373,9 @@ System.register('pops', [], (function (exports) {
|
|
|
2393
2373
|
* @returns
|
|
2394
2374
|
*/
|
|
2395
2375
|
getKeyFrames(sheet) {
|
|
2396
|
-
|
|
2376
|
+
const result = {};
|
|
2397
2377
|
Object.keys(sheet.cssRules).forEach((key) => {
|
|
2398
|
-
if (sheet.cssRules[key].type === 7 &&
|
|
2399
|
-
sheet.cssRules[key].name.startsWith("pops-anim-")) {
|
|
2378
|
+
if (sheet.cssRules[key].type === 7 && sheet.cssRules[key].name.startsWith("pops-anim-")) {
|
|
2400
2379
|
result[sheet.cssRules[key].name] = sheet.cssRules[key];
|
|
2401
2380
|
}
|
|
2402
2381
|
});
|
|
@@ -2420,7 +2399,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2420
2399
|
*/
|
|
2421
2400
|
str) => {
|
|
2422
2401
|
let hexs = "";
|
|
2423
|
-
|
|
2402
|
+
const reg = /^#(?:[0-9A-Fa-f]{3}|[0-9A-Fa-f]{6}|[0-9A-Fa-f]{8})$/;
|
|
2424
2403
|
if (!reg.test(str)) {
|
|
2425
2404
|
console.warn("输入错误的hex");
|
|
2426
2405
|
return "";
|
|
@@ -2447,12 +2426,12 @@ System.register('pops', [], (function (exports) {
|
|
|
2447
2426
|
* 蓝色
|
|
2448
2427
|
*/
|
|
2449
2428
|
b) => {
|
|
2450
|
-
|
|
2429
|
+
const reg = /^\d{1,3}$/;
|
|
2451
2430
|
if (!reg.test(r) || !reg.test(g) || !reg.test(b)) {
|
|
2452
2431
|
console.warn("输入错误的rgb颜色值");
|
|
2453
2432
|
return "";
|
|
2454
2433
|
}
|
|
2455
|
-
|
|
2434
|
+
const hexs = [r.toString(16), g.toString(16), b.toString(16)];
|
|
2456
2435
|
for (let i = 0; i < 3; i++)
|
|
2457
2436
|
if (hexs[i].length == 1)
|
|
2458
2437
|
hexs[i] = `0${hexs[i]}`;
|
|
@@ -2470,12 +2449,12 @@ System.register('pops', [], (function (exports) {
|
|
|
2470
2449
|
* 加深的程度,限0-1之间
|
|
2471
2450
|
*/
|
|
2472
2451
|
level) => {
|
|
2473
|
-
|
|
2452
|
+
const reg = /^#(?:[0-9A-Fa-f]{3}|[0-9A-Fa-f]{6}|[0-9A-Fa-f]{8})$/;
|
|
2474
2453
|
if (!reg.test(color)) {
|
|
2475
2454
|
console.warn("输入错误的hex颜色值");
|
|
2476
2455
|
return "";
|
|
2477
2456
|
}
|
|
2478
|
-
|
|
2457
|
+
const rgb = useChangeColor().hexToRgb(color);
|
|
2479
2458
|
for (let i = 0; i < 3; i++)
|
|
2480
2459
|
rgb[i] = Math.floor(rgb[i] * (1 - level));
|
|
2481
2460
|
return useChangeColor().rgbToHex(rgb[0], rgb[1], rgb[2]);
|
|
@@ -2492,12 +2471,12 @@ System.register('pops', [], (function (exports) {
|
|
|
2492
2471
|
* 加深的程度,限0-1之间
|
|
2493
2472
|
*/
|
|
2494
2473
|
level) => {
|
|
2495
|
-
|
|
2474
|
+
const reg = /^#(?:[0-9A-Fa-f]{3}|[0-9A-Fa-f]{6}|[0-9A-Fa-f]{8})$/;
|
|
2496
2475
|
if (!reg.test(color)) {
|
|
2497
2476
|
console.warn("输入错误的hex颜色值");
|
|
2498
2477
|
return "";
|
|
2499
2478
|
}
|
|
2500
|
-
|
|
2479
|
+
const rgb = useChangeColor().hexToRgb(color);
|
|
2501
2480
|
for (let i = 0; i < 3; i++)
|
|
2502
2481
|
rgb[i] = Math.floor((255 - rgb[i]) * level + rgb[i]);
|
|
2503
2482
|
return useChangeColor().rgbToHex(rgb[0], rgb[1], rgb[2]);
|
|
@@ -2518,9 +2497,11 @@ System.register('pops', [], (function (exports) {
|
|
|
2518
2497
|
getTransform(element) {
|
|
2519
2498
|
let transform_left = 0;
|
|
2520
2499
|
let transform_top = 0;
|
|
2521
|
-
|
|
2500
|
+
const elementTransform = PopsCore.globalThis.getComputedStyle(element).transform;
|
|
2522
2501
|
if (elementTransform !== "none" && elementTransform != null && elementTransform !== "") {
|
|
2523
|
-
|
|
2502
|
+
const elementTransformMatch = elementTransform.match(/\((.+)\)/);
|
|
2503
|
+
// eslint-disable-next-line @typescript-eslint/no-non-null-asserted-optional-chain
|
|
2504
|
+
const elementTransformSplit = elementTransformMatch?.[1]?.split?.(",");
|
|
2524
2505
|
transform_left = Math.abs(parseInt(elementTransformSplit[4]));
|
|
2525
2506
|
transform_top = Math.abs(parseInt(elementTransformSplit[5]));
|
|
2526
2507
|
}
|
|
@@ -2534,15 +2515,15 @@ System.register('pops', [], (function (exports) {
|
|
|
2534
2515
|
*/
|
|
2535
2516
|
onInput($el, callback, option) {
|
|
2536
2517
|
let isComposite = false;
|
|
2537
|
-
|
|
2518
|
+
const __callback = async (event) => {
|
|
2538
2519
|
if (isComposite)
|
|
2539
2520
|
return;
|
|
2540
2521
|
await callback(event);
|
|
2541
2522
|
};
|
|
2542
|
-
|
|
2523
|
+
const __composition_start_callback = () => {
|
|
2543
2524
|
isComposite = true;
|
|
2544
2525
|
};
|
|
2545
|
-
|
|
2526
|
+
const __composition_end_callback = () => {
|
|
2546
2527
|
isComposite = false;
|
|
2547
2528
|
this.trigger($el, "input", {
|
|
2548
2529
|
isComposite,
|
|
@@ -2586,10 +2567,10 @@ System.register('pops', [], (function (exports) {
|
|
|
2586
2567
|
* @param zIndex
|
|
2587
2568
|
*/
|
|
2588
2569
|
createAnim(guid, type, config, html = "", bottomBtnHTML = "", zIndex) {
|
|
2589
|
-
|
|
2570
|
+
const __config = config;
|
|
2590
2571
|
let popsAnimStyle = "";
|
|
2591
2572
|
let popsStyle = "";
|
|
2592
|
-
|
|
2573
|
+
const popsPosition = __config.position || "";
|
|
2593
2574
|
if (config.zIndex != null) {
|
|
2594
2575
|
popsAnimStyle += `z-index: ${zIndex};`;
|
|
2595
2576
|
popsStyle += `z-index: ${zIndex};`;
|
|
@@ -2600,7 +2581,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2600
2581
|
if (__config.height != null) {
|
|
2601
2582
|
popsStyle += `height: ${__config.height};`;
|
|
2602
2583
|
}
|
|
2603
|
-
|
|
2584
|
+
const hasBottomBtn = bottomBtnHTML.trim() === "" ? false : true;
|
|
2604
2585
|
return /*html*/ `
|
|
2605
2586
|
<div class="pops-anim" anim="${__config.animation || ""}" style="${popsAnimStyle}" data-guid="${guid}">${config.style != null ? `<style tyle="text/css">${config.style}</style>` : ""}
|
|
2606
2587
|
<div class="pops ${config.class || ""}" data-bottom-btn="${hasBottomBtn}" type-value="${type}" style="${popsStyle}" position="${popsPosition}" data-guid="${guid}">${html}</div>
|
|
@@ -2615,14 +2596,14 @@ System.register('pops', [], (function (exports) {
|
|
|
2615
2596
|
if (!config.btn) {
|
|
2616
2597
|
return "";
|
|
2617
2598
|
}
|
|
2618
|
-
|
|
2599
|
+
const confirm_config = config;
|
|
2619
2600
|
if (type !== "iframe" && !confirm_config.btn?.close?.enable) {
|
|
2620
2601
|
return "";
|
|
2621
2602
|
}
|
|
2622
2603
|
let resultHTML = "";
|
|
2623
2604
|
// let btnStyle = "";
|
|
2624
2605
|
let closeHTML = "";
|
|
2625
|
-
|
|
2606
|
+
const iframe_config = config;
|
|
2626
2607
|
if (type === "iframe" && iframe_config.topRightButton?.trim() !== "") {
|
|
2627
2608
|
/* iframe的 */
|
|
2628
2609
|
let topRightButtonHTML = "";
|
|
@@ -2672,7 +2653,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2672
2653
|
// 未设置btn参数
|
|
2673
2654
|
return "";
|
|
2674
2655
|
}
|
|
2675
|
-
|
|
2656
|
+
const confirm_config = config;
|
|
2676
2657
|
if (!(config.btn?.ok?.enable || confirm_config.btn?.cancel?.enable || confirm_config.btn?.other?.enable)) {
|
|
2677
2658
|
// 确定、取消、其它按钮都未启用直接返回
|
|
2678
2659
|
return "";
|
|
@@ -2698,7 +2679,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2698
2679
|
okButtonSizeClassName = "pops-button-" + config.btn.ok.size;
|
|
2699
2680
|
}
|
|
2700
2681
|
let okIconHTML = "";
|
|
2701
|
-
|
|
2682
|
+
const okIcon = confirm_config.btn.ok.icon;
|
|
2702
2683
|
if (okIcon !== "") {
|
|
2703
2684
|
// 判断图标是否是svg库内的
|
|
2704
2685
|
let iconHTML = "";
|
|
@@ -2731,7 +2712,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2731
2712
|
cancelButtonSizeClassName = "pops-button-" + confirm_config.btn.cancel.size;
|
|
2732
2713
|
}
|
|
2733
2714
|
let cancelIconHTML = "";
|
|
2734
|
-
|
|
2715
|
+
const cancelIcon = confirm_config.btn.cancel.icon;
|
|
2735
2716
|
if (cancelIcon !== "") {
|
|
2736
2717
|
let iconHTML = "";
|
|
2737
2718
|
// 判断图标是否是svg库内的
|
|
@@ -2764,7 +2745,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2764
2745
|
otherButtonSizeClassName = "pops-button-" + confirm_config.btn.other.size;
|
|
2765
2746
|
}
|
|
2766
2747
|
let otherIconHTML = "";
|
|
2767
|
-
|
|
2748
|
+
const otherIcon = confirm_config.btn.other.icon;
|
|
2768
2749
|
if (otherIcon !== "") {
|
|
2769
2750
|
let iconHTML = "";
|
|
2770
2751
|
// 判断图标是否是svg库内的
|
|
@@ -2824,37 +2805,37 @@ System.register('pops', [], (function (exports) {
|
|
|
2824
2805
|
},
|
|
2825
2806
|
};
|
|
2826
2807
|
|
|
2827
|
-
var indexCSS = "@charset \"utf-8\";\n.pops * {\n
|
|
2808
|
+
var indexCSS = "@charset \"utf-8\";\n.pops * {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n -webkit-tap-highlight-color: transparent;\n /* 代替::-webkit-scrollbar */\n scrollbar-width: thin;\n}\n.pops {\n --pops-bg-opacity: 1;\n --pops-bd-opacity: 1;\n --pops-font-size: 16px;\n interpolate-size: allow-keywords;\n --pops-color: #000000;\n --pops-bg-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n --pops-bd-color: rgb(235, 238, 245, var(--pops-bd-opacity));\n --pops-box-shadow-color: rgba(0, 0, 0, 0.12);\n --pops-title-color: #000000;\n --pops-title-border-color: var(--pops-bd-color);\n --pops-content-color: #000000;\n --pops-bottom-btn-controls-border-color: var(--pops-bd-color);\n --pops-components-is-disabled-text-color: #a8abb2;\n --pops-components-is-disabled-bg-color: #f5f7fa;\n}\n@media (prefers-color-scheme: dark) {\n .pops {\n --pops-mask-bg-opacity: 0.8;\n --pops-color: #ffffff;\n --pops-bg-color: rgb(17, 17, 17, var(--pops-bg-opacity));\n --pops-bd-color: rgb(55, 55, 55, var(--pops-bd-opacity));\n --pops-box-shadow-color: rgba(81, 81, 81, 0.12);\n --pops-title-color: #e8e8e8;\n --pops-title-border-color: var(--pops-bd-color);\n --pops-content-color: #e5e5e5;\n --pops-components-is-disabled-text-color: #a8abb2;\n --pops-components-is-disabled-bg-color: #262727;\n }\n}\n.pops {\n color: var(--pops-color);\n background-color: var(--pops-bg-color);\n border: 1px solid var(--pops-bd-color);\n border-radius: 4px;\n font-size: var(--pops-font-size);\n line-height: normal;\n box-shadow: 0 0 12px var(--pops-box-shadow-color);\n box-sizing: border-box;\n overflow: hidden;\n transition: all 0.35s;\n display: flex;\n flex-direction: column;\n}\n.pops-anim {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n width: 100%;\n height: 100%;\n}\n.pops-anim[anim=\"\"] {\n top: unset;\n right: unset;\n bottom: unset;\n left: unset;\n width: unset;\n height: unset;\n transition: none;\n}\n/* 底部图标动画和样式 */\n.pops i.pops-bottom-icon[is-loading=\"true\"] {\n animation: rotating 2s linear infinite;\n}\n.pops i.pops-bottom-icon {\n height: 1em;\n width: 1em;\n line-height: normal;\n display: inline-flex;\n justify-content: center;\n align-items: center;\n position: relative;\n fill: currentColor;\n color: inherit;\n font-size: inherit;\n}\n\n/* 遮罩层样式 */\n.pops-mask {\n --pops-mask-bg-opacity: 0.4;\n --pops-mask-bg-color: rgba(0, 0, 0, var(--pops-mask-bg-opacity));\n}\n.pops-mask {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n width: 100%;\n height: 100%;\n border: 0;\n border-radius: 0;\n background-color: var(--pops-mask-bg-color);\n box-shadow: none;\n transition: none;\n}\n\n.pops-header-controls button.pops-header-control[type][data-header] {\n float: right;\n margin: 0 0;\n outline: 0;\n border: 0;\n border-color: rgb(136, 136, 136, var(--pops-bd-opacity));\n background-color: transparent;\n color: #888;\n cursor: pointer;\n}\n.pops-header-controls button.pops-header-control[data-type=\"max\"],\n.pops-header-controls button.pops-header-control[data-type=\"mise\"],\n.pops-header-controls button.pops-header-control[data-type=\"min\"] {\n outline: 0 !important;\n border: 0;\n border-color: rgb(136, 136, 136, var(--pops-bd-opacity));\n background-color: transparent;\n color: rgb(136, 136, 136);\n cursor: pointer;\n transition: all 0.3s ease-in-out;\n}\nbutton.pops-header-control i {\n color: rgb(144, 147, 153);\n font-size: inherit;\n display: inline-flex;\n justify-content: center;\n align-items: center;\n position: relative;\n fill: currentColor;\n}\nbutton.pops-header-control svg {\n height: 1.25em;\n width: 1.25em;\n}\nbutton.pops-header-control {\n right: 15px;\n padding: 0;\n border: none;\n outline: 0;\n background: 0 0;\n cursor: pointer;\n position: unset;\n line-height: normal;\n}\nbutton.pops-header-control i:hover {\n color: rgb(64, 158, 255);\n}\n.pops-header-controls[data-margin] button.pops-header-control {\n margin: 0 6px;\n display: flex;\n align-items: center;\n}\n.pops[type-value] .pops-header-controls {\n display: flex;\n gap: 6px;\n}\n\n/* 代码块 <code> */\n.pops code {\n font-family: Menlo, Monaco, Consolas, \"Courier New\", monospace;\n font-size: 0.85em;\n color: #000;\n background-color: #f0f0f0;\n border-radius: 3px;\n border: 0;\n padding: 0.2em 0;\n white-space: normal;\n background: #f5f5f5;\n text-wrap: wrap;\n text-align: left;\n word-spacing: normal;\n word-break: normal;\n word-wrap: normal;\n line-height: 1.4;\n -moz-tab-size: 8;\n -o-tab-size: 8;\n tab-size: 8;\n -webkit-hyphens: none;\n -moz-hyphens: none;\n -ms-hyphens: none;\n hyphens: none;\n direction: ltr;\n}\n\n.pops code::before,\n.pops code::after {\n letter-spacing: -0.2em;\n content: \"\\00a0\";\n}\n\n/* 标题 */\n.pops .pops-title {\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n display: flex;\n align-items: center;\n justify-content: space-between;\n border-bottom: 1px solid var(--pops-title-border-color);\n width: 100%;\n height: var(--container-title-height);\n}\n/* 标题-普通文本 */\n.pops .pops-title p[pops] {\n color: var(--pops-title-color);\n width: 100%;\n overflow: hidden;\n text-indent: 15px;\n text-overflow: ellipsis;\n white-space: nowrap;\n font-weight: 500;\n line-height: normal;\n}\n\n/* 内容 */\n.pops .pops-content {\n width: 100%;\n /*height: calc(\n\t\t100% - var(--container-title-height) - var(--container-bottom-btn-height)\n\t);*/\n flex: 1;\n overflow: auto;\n word-break: break-word;\n}\n/* 内容-普通文本 */\n.pops .pops-content p[pops] {\n color: var(--pops-content-color);\n padding: 5px 10px;\n text-indent: 15px;\n}\n\n/* 底部-按钮组 */\n.pops .pops-botttom-btn-controls {\n display: flex;\n padding: 10px 10px 10px 10px;\n width: 100%;\n height: var(--container-bottom-btn-height);\n max-height: var(--container-bottom-btn-height);\n line-height: normal;\n border-top: 1px solid var(--pops-bottom-btn-controls-border-color);\n text-align: right;\n align-items: center;\n}\n";
|
|
2828
2809
|
|
|
2829
|
-
var ninePalaceGridPositionCSS = ".pops[position=\"top_left\"] {\n
|
|
2810
|
+
var ninePalaceGridPositionCSS = ".pops[position=\"top_left\"] {\n position: fixed;\n top: 0;\n left: 0;\n}\n.pops[position=\"top\"] {\n position: fixed;\n top: 0;\n left: 50%;\n transform: translateX(-50%);\n}\n.pops[position=\"top_right\"] {\n position: fixed;\n top: 0;\n right: 0;\n}\n.pops[position=\"center_left\"] {\n position: fixed;\n top: 50%;\n left: 0;\n transform: translateY(-50%);\n}\n.pops[position=\"center\"] {\n position: fixed;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n}\n.pops[position=\"center_right\"] {\n position: fixed;\n top: 50%;\n right: 0;\n transform: translateY(-50%);\n}\n.pops[position=\"bottom_left\"] {\n position: fixed;\n bottom: 0;\n left: 0;\n}\n.pops[position=\"bottom\"] {\n position: fixed;\n bottom: 0;\n left: 50%;\n transform: translate(-50%, 0);\n}\n.pops[position=\"bottom_right\"] {\n position: fixed;\n right: 0;\n bottom: 0;\n}\n";
|
|
2830
2811
|
|
|
2831
|
-
var scrollbarCSS = "/* ::-webkit-scrollbar 是非标准的css */\n/* https://caniuse.com/?search=%20%3A%3A-webkit-scrollbar */\n.pops ::-webkit-scrollbar {\n
|
|
2812
|
+
var scrollbarCSS = "/* ::-webkit-scrollbar 是非标准的css */\n/* https://caniuse.com/?search=%20%3A%3A-webkit-scrollbar */\n.pops ::-webkit-scrollbar {\n width: 6px;\n height: 0;\n}\n\n/* 滚动条轨道 */\n.pops ::-webkit-scrollbar-track {\n width: 0;\n}\n/* 滚动条滑块 */\n.pops ::-webkit-scrollbar-thumb {\n min-height: 28px;\n border-radius: 2em;\n background: rgb(204, 204, 204, var(--pops-bg-opacity, 1));\n background-clip: padding-box;\n}\n/* 滚动条滑块 */\n.pops ::-webkit-scrollbar-thumb:hover {\n background: rgb(178, 178, 178, var(--pops-bg-opacity, 1));\n}\n";
|
|
2832
2813
|
|
|
2833
|
-
var buttonCSS = ".pops {\n\t--button-font-size: 14px;\n\t--button-height: 32px;\n\t--button-color: rgb(51, 51, 51);\n\t--button-bd-color: rgb(220, 223, 230, var(--pops-bd-opacity));\n\t--button-bg-color: rgb(220, 223, 230, var(--pops-bg-opacity));\n\t--button-margin-top: 0px;\n\t--button-margin-bottom: 0px;\n\t--button-margin-left: 5px;\n\t--button-margin-right: 5px;\n\t--button-padding-top: 6px;\n\t--button-padding-bottom: 6px;\n\t--button-padding-left: 12px;\n\t--button-padding-right: 12px;\n\t--button-radius: 4px;\n\n\t--container-title-height: 55px;\n\t--container-bottom-btn-height: 55px;\n\n\t/* default按钮 */\n\t--button-default-color: #333333;\n\t--button-default-bd-color: #dcdfe6;\n\t--button-default-bg-color: #ffffff;\n\t--button-default-active-color: #409eff;\n\t--button-default-active-bd-color: #409eff;\n\t--button-default-active-bg-color: #ecf5ff;\n\t--button-default-hover-color: #409eff;\n\t--button-default-hover-bd-color: #c6e2ff;\n\t--button-default-hover-bg-color: #ecf5ff;\n\t--button-default-focus-visible-outline-color: #a0cfff;\n\t--button-default-focus-visible-outline: 2px solid var(--button-default-focus-visible-outline-color);\n\t--button-default-focus-visible-outline-offset: 1px;\n\t--button-default-disabled-color: #a8abb2;\n\t--button-default-disabled-bd-color: #ffffff;\n\t--button-default-disabled-bg-color: #e4e7ed;\n\n\t/* primary按钮 */\n\t--button-primary-color: #ffffff;\n\t--button-primary-bd-color: #409eff;\n\t--button-primary-bg-color: #409eff;\n\t--button-primary-active-color: #ffffff;\n\t--button-primary-active-bd-color: #337ecc;\n\t--button-primary-active-bg-color: #337ecc;\n\t--button-primary-hover-color: #ffffff;\n\t--button-primary-hover-bd-color: #79bbff;\n\t--button-primary-hover-bg-color: #79bbff;\n\t--button-primary-focus-visible-outline-color: #a0cfff;\n\t--button-primary-focus-visible-outline: 2px solid var(--button-primary-focus-visible-outline-color);\n\t--button-primary-focus-visible-outline-offset: 1px;\n\t--button-primary-disabled-color: #ffffff80;\n\t--button-primary-disabled-bd-color: #a0cfff;\n\t--button-primary-disabled-bg-color: #a0cfff;\n\n\t/* success按钮 */\n\t--button-success-color: #ffffff;\n\t--button-success-bd-color: #4cae4c;\n\t--button-success-bg-color: #5cb85c;\n\t--button-success-active-color: #ffffff;\n\t--button-success-active-bd-color: #529b2e;\n\t--button-success-active-bg-color: #529b2e;\n\t--button-success-hover-color: #ffffff;\n\t--button-success-hover-bd-color: #95d475;\n\t--button-success-hover-bg-color: #95d475;\n\t--button-success-focus-visible-outline-color: #b3e19d;\n\t--button-success-focus-visible-outline: 2px solid var(--button-success-focus-visible-outline-color);\n\t--button-success-focus-visible-outline-offset: 1px;\n\t--button-success-disabled-color: #ffffff80;\n\t--button-success-disabled-bd-color: #b3e19d;\n\t--button-success-disabled-bg-color: #b3e19d;\n\n\t/* info按钮 */\n\t--button-info-color: #ffffff;\n\t--button-info-bd-color: #909399;\n\t--button-info-bg-color: #909399;\n\t--button-info-active-color: #ffffff;\n\t--button-info-active-bd-color: #73767a;\n\t--button-info-active-bg-color: #73767a;\n\t--button-info-hover-color: #ffffff;\n\t--button-info-hover-bd-color: #b1b3b8;\n\t--button-info-hover-bg-color: #b1b3b8;\n\t--button-info-focus-visible-outline-color: #c8c9cc;\n\t--button-info-focus-visible-outline: 2px solid var(--button-info-focus-visible-outline-color);\n\t--button-info-focus-visible-outline-offset: 1px;\n\t--button-info-disabled-color: #ffffff80;\n\t--button-info-disabled-bd-color: #c8c9cc;\n\t--button-info-disabled-bg-color: #c8c9cc;\n\n\t/* warning按钮 */\n\t--button-warning-color: #ffffff;\n\t--button-warning-bd-color: #e6a23c;\n\t--button-warning-bg-color: #e6a23c;\n\t--button-warning-active-color: #ffffff;\n\t--button-warning-active-bd-color: #b88230;\n\t--button-warning-active-bg-color: #b88230;\n\t--button-warning-hover-color: #ffffff80;\n\t--button-warning-hover-bd-color: #eebe77;\n\t--button-warning-hover-bg-color: #eebe77;\n\t--button-warning-focus-visible-outline-color: #f3d19e;\n\t--button-warning-focus-visible-outline: 2px solid var(--button-warning-focus-visible-outline-color);\n\t--button-warning-focus-visible-outline-offset: 1px;\n\t--button-warning-disabled-color: #ffffff80;\n\t--button-warning-disabled-bd-color: #f3d19e;\n\t--button-warning-disabled-bg-color: #f3d19e;\n\n\t/* danger按钮 */\n\t--button-danger-color: #ffffff;\n\t--button-danger-bd-color: #f56c6c;\n\t--button-danger-bg-color: #f56c6c;\n\t--button-danger-active-color: #ffffff;\n\t--button-danger-active-bd-color: #c45656;\n\t--button-danger-active-bg-color: #c45656;\n\t--button-danger-hover-color: #ffffff;\n\t--button-danger-hover-bd-color: #f89898;\n\t--button-danger-hover-bg-color: #f89898;\n\t--button-danger-focus-visible-outline-color: #fab6b6;\n\t--button-danger-focus-visible-outline: 2px solid var(--button-danger-focus-visible-outline-color);\n\t--button-danger-focus-visible-outline-offset: 1px;\n\t--button-danger-disabled-color: #ffffff80;\n\t--button-danger-disabled-bd-color: #fab6b6;\n\t--button-danger-disabled-bg-color: #fab6b6;\n\n\t/* xiaomi-primary按钮 */\n\t--button-xiaomi-primary-color: #ffffff;\n\t--button-xiaomi-primary-bd-color: #ff5c00;\n\t--button-xiaomi-primary-bg-color: #ff5c00;\n\t--button-xiaomi-primary-active-color: #ffffff;\n\t--button-xiaomi-primary-active-bd-color: #da4f00;\n\t--button-xiaomi-primary-active-bg-color: #da4f00;\n\t--button-xiaomi-primary-hover-color: #ffffff;\n\t--button-xiaomi-primary-hover-bd-color: #ff7e29;\n\t--button-xiaomi-primary-hover-bg-color: #ff7e29;\n\t--button-xiaomi-primary-focus-visible-outline-color: #ffa061;\n\t--button-xiaomi-primary-focus-visible-outline: 2px solid\n\t\tvar(--button-xiaomi-primary-focus-visible-outline-color);\n\t--button-xiaomi-primary-focus-visible-outline-offset: 1px;\n\t--button-xiaomi-primary-disabled-color: #ffffff80;\n\t--button-xiaomi-primary-disabled-bd-color: #fad5b6;\n\t--button-xiaomi-primary-disabled-bg-color: #fad5b6;\n\n\t/* violet按钮 */\n\t--button-violet-color: #ffffff;\n\t--button-violet-bd-color: #626aef;\n\t--button-violet-bg-color: #626aef;\n\t--button-violet-active-color: #ffffff;\n\t--button-violet-active-bd-color: #8188f2;\n\t--button-violet-active-bg-color: #8188f2;\n\t--button-violet-hover-color: #ffffff;\n\t--button-violet-hover-bd-color: #4b50ad;\n\t--button-violet-hover-bg-color: #4b50ad;\n\t--button-violet-focus-visible-outline-color: #2a598a;\n\t--button-violet-focus-visible-outline: 2px solid var(--button-violet-focus-visible-outline-color);\n\t--button-violet-focus-visible-outline-offset: 1px;\n\t--button-violet-disabled-color: #ffffff80;\n\t--button-violet-disabled-bd-color: #3b3f82;\n\t--button-violet-disabled-bg-color: #3b3f82;\n}\n\n@media (prefers-color-scheme: dark) {\n\t.pops {\n\t\t/* default按钮 */\n\t\t--button-default-color: #cfd3dc;\n\t\t--button-default-bd-color: #4c4d4f;\n\t\t--button-default-bg-color: transparent;\n\t\t--button-default-active-color: #409eff;\n\t\t--button-default-active-bd-color: #409eff;\n\t\t--button-default-active-bg-color: #18222c;\n\t\t--button-default-hover-color: #409eff;\n\t\t--button-default-hover-bd-color: #213d5b;\n\t\t--button-default-hover-bg-color: #18222c;\n\t\t--button-default-focus-visible-outline-color: #2a598a;\n\t\t--button-default-focus-visible-outline: 2px solid var(--button-default-focus-visible-outline-color);\n\t\t--button-default-focus-visible-outline-offset: 1px;\n\t\t--button-default-disabled-color: #ffffff80;\n\t\t--button-default-disabled-bd-color: #414243;\n\t\t--button-default-disabled-bg-color: transparent;\n\n\t\t/* primary按钮 */\n\t\t--button-primary-color: #ffffff;\n\t\t--button-primary-bd-color: #409eff;\n\t\t--button-primary-bg-color: #409eff;\n\t\t--button-primary-active-color: #ffffff;\n\t\t--button-primary-active-bd-color: #66b1ff;\n\t\t--button-primary-active-bg-color: #66b1ff;\n\t\t--button-primary-hover-color: #ffffff;\n\t\t--button-primary-hover-bd-color: #3375b9;\n\t\t--button-primary-hover-bg-color: #3375b9;\n\t\t--button-primary-focus-visible-outline-color: #2a598a;\n\t\t--button-primary-focus-visible-outline: 2px solid var(--button-primary-focus-visible-outline-color);\n\t\t--button-primary-focus-visible-outline-offset: 1px;\n\t\t--button-primary-disabled-color: #ffffff80;\n\t\t--button-primary-disabled-bd-color: #2a598a;\n\t\t--button-primary-disabled-bg-color: #2a598a;\n\n\t\t/* success按钮 */\n\t\t--button-success-color: #ffffff;\n\t\t--button-success-bd-color: #67c23a;\n\t\t--button-success-bg-color: #67c23a;\n\t\t--button-success-active-color: #ffffff;\n\t\t--button-success-active-bd-color: #85ce61;\n\t\t--button-success-active-bg-color: #85ce61;\n\t\t--button-success-hover-color: #ffffff;\n\t\t--button-success-hover-bd-color: #4e8e2f;\n\t\t--button-success-hover-bg-color: #4e8e2f;\n\t\t--button-success-focus-visible-outline-color: #3e6b27;\n\t\t--button-success-focus-visible-outline: 2px solid var(--button-success-focus-visible-outline-color);\n\t\t--button-success-focus-visible-outline-offset: 1px;\n\t\t--button-success-disabled-color: #ffffff80;\n\t\t--button-success-disabled-bd-color: #3e6b27;\n\t\t--button-success-disabled-bg-color: #3e6b27;\n\n\t\t/* info按钮 */\n\t\t--button-info-color: #ffffff;\n\t\t--button-info-bd-color: #909399;\n\t\t--button-info-bg-color: #909399;\n\t\t--button-info-active-color: #ffffff;\n\t\t--button-info-active-bd-color: #a6a9ad;\n\t\t--button-info-active-bg-color: #a6a9ad;\n\t\t--button-info-hover-color: #ffffff;\n\t\t--button-info-hover-bd-color: #6b6d71;\n\t\t--button-info-hover-bg-color: #6b6d71;\n\t\t--button-info-focus-visible-outline-color: #525457;\n\t\t--button-info-focus-visible-outline: 2px solid var(--button-info-focus-visible-outline-color);\n\t\t--button-info-focus-visible-outline-offset: 1px;\n\t\t--button-info-disabled-color: #ffffff80;\n\t\t--button-info-disabled-bd-color: #525457;\n\t\t--button-info-disabled-bg-color: #525457;\n\n\t\t/* warning按钮 */\n\t\t--button-warning-color: #ffffff;\n\t\t--button-warning-bd-color: #e6a23c;\n\t\t--button-warning-bg-color: #e6a23c;\n\t\t--button-warning-active-color: #ffffff;\n\t\t--button-warning-active-bd-color: #ebb563;\n\t\t--button-warning-active-bg-color: #ebb563;\n\t\t--button-warning-hover-color: #ffffff80;\n\t\t--button-warning-hover-bd-color: #a77730;\n\t\t--button-warning-hover-bg-color: #a77730;\n\t\t--button-warning-focus-visible-outline-color: #7d5b28;\n\t\t--button-warning-focus-visible-outline: 2px solid var(--button-warning-focus-visible-outline-color);\n\t\t--button-warning-focus-visible-outline-offset: 1px;\n\t\t--button-warning-disabled-color: #ffffff80;\n\t\t--button-warning-disabled-bd-color: #7d5b28;\n\t\t--button-warning-disabled-bg-color: #7d5b28;\n\n\t\t/* danger按钮 */\n\t\t--button-danger-color: #ffffff;\n\t\t--button-danger-bd-color: #f56c6c;\n\t\t--button-danger-bg-color: #f56c6c;\n\t\t--button-danger-active-color: #ffffff;\n\t\t--button-danger-active-bd-color: #f78989;\n\t\t--button-danger-active-bg-color: #f78989;\n\t\t--button-danger-hover-color: #ffffff;\n\t\t--button-danger-hover-bd-color: #b25252;\n\t\t--button-danger-hover-bg-color: #b25252;\n\t\t--button-danger-focus-visible-outline-color: #854040;\n\t\t--button-danger-focus-visible-outline: 2px solid var(--button-danger-focus-visible-outline-color);\n\t\t--button-danger-focus-visible-outline-offset: 1px;\n\t\t--button-danger-disabled-color: #ffffff80;\n\t\t--button-danger-disabled-bd-color: #854040;\n\t\t--button-danger-disabled-bg-color: #854040;\n\t}\n}\n.pops[data-bottom-btn=\"false\"] {\n\t--container-bottom-btn-height: 0px;\n}\n.pops button {\n\twhite-space: nowrap;\n\tfloat: right;\n\tdisplay: inline-block;\n\tmargin: var(--button-margin-top) var(--button-margin-right) var(--button-margin-bottom)\n\t\tvar(--button-margin-left);\n\tpadding: var(--button-padding-top) var(--button-padding-right) var(--button-padding-bottom)\n\t\tvar(--button-padding-left);\n\toutline: 0;\n}\n.pops button[data-has-icon=\"false\"] .pops-bottom-icon {\n\tdisplay: none;\n}\n.pops button {\n\tborder-radius: var(--button-radius);\n\tbox-shadow: none;\n\tfont-weight: 400;\n\tfont-size: var(--button-font-size);\n\tcursor: pointer;\n\ttransition: all 0.3s ease-in-out;\n}\n.pops button {\n\tdisplay: flex;\n\talign-items: center;\n\theight: var(--button-height);\n\tline-height: normal;\n\tbox-sizing: border-box;\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-moz-user-select: none;\n\t-ms-user-select: none;\n\tborder: 1px solid var(--button-bd-color);\n}\n.pops button {\n\tcolor: var(--button-color);\n\tborder-color: var(--button-bd-color);\n\tbackground-color: var(--button-bg-color);\n}\n.pops button:active {\n\tcolor: var(--button-color);\n\tborder-color: var(--button-bd-color);\n\tbackground-color: var(--button-bg-color);\n\toutline: 0;\n}\n.pops button:hover {\n\tcolor: var(--button-color);\n\tborder-color: var(--button-bd-color);\n\tbackground-color: var(--button-bg-color);\n}\n.pops button:focus-visible {\n\tcolor: var(--button-color);\n\tborder-color: var(--button-bd-color);\n\tbackground-color: var(--button-bg-color);\n}\n.pops button:disabled {\n\tcursor: not-allowed;\n\tcolor: var(--button-color);\n\tborder-color: var(--button-bd-color);\n\tbackground-color: var(--button-bg-color);\n}\n.pops button.pops-button-large {\n\t--button-height: 32px;\n\t--button-padding-top: 12px;\n\t--button-padding-bottom: 12px;\n\t--button-padding-left: 19px;\n\t--button-padding-right: 19px;\n\t--button-font-size: 14px;\n\t--button-border-radius: 4px;\n}\n\n.pops button.pops-button-small {\n\t--button-height: 24px;\n\t--button-padding-top: 5px;\n\t--button-padding-bottom: 5px;\n\t--button-padding-left: 11px;\n\t--button-padding-right: 11px;\n\t--button-font-size: 12px;\n\t--button-border-radius: 4px;\n}\n.pops-panel-button-no-icon .pops-panel-button_inner i {\n\tdisplay: none;\n}\n.pops-panel-button-right-icon .pops-panel-button_inner {\n\tflex-direction: row-reverse;\n}\n.pops-panel-button .pops-panel-button_inner i:has(svg),\n.pops-panel-button-right-icon .pops-panel-button-text {\n\tmargin-right: 6px;\n}\n\n.pops button[data-type=\"default\"] {\n\t--button-color: var(--button-default-color);\n\t--button-bd-color: var(--button-default-bd-color);\n\t--button-bg-color: var(--button-default-bg-color);\n}\n.pops button[data-type=\"default\"]:active {\n\t--button-color: var(--button-default-active-color);\n\t--button-bd-color: var(--button-default-active-bd-color);\n\t--button-bg-color: var(--button-default-active-bg-color);\n}\n.pops button[data-type=\"default\"]:hover {\n\t--button-color: var(--button-default-hover-color);\n\t--button-bd-color: var(--button-default-hover-bd-color);\n\t--button-bg-color: var(--button-default-hover-bg-color);\n}\n.pops button[data-type=\"default\"]:focus-visible {\n\toutline: var(--button-default-focus-visible-outline);\n\toutline-offset: var(--button-default-focus-visible-outline-offset);\n}\n.pops button[data-type=\"default\"]:disabled {\n\t--button-color: var(--button-default-disabled-color);\n\t--button-bd-color: var(--button-default-disabled-bd-color);\n\t--button-bg-color: var(--button-default-disabled-bg-color);\n}\n\n.pops button[data-type=\"primary\"] {\n\t--button-color: var(--button-primary-color);\n\t--button-bd-color: var(--button-primary-bd-color);\n\t--button-bg-color: var(--button-primary-bg-color);\n}\n.pops button[data-type=\"primary\"]:active {\n\t--button-color: var(--button-primary-active-color);\n\t--button-bd-color: var(--button-primary-active-bd-color);\n\t--button-bg-color: var(--button-primary-active-bg-color);\n}\n.pops button[data-type=\"primary\"]:hover {\n\t--button-color: var(--button-primary-hover-color);\n\t--button-bd-color: var(--button-primary-hover-bd-color);\n\t--button-bg-color: var(--button-primary-hover-bg-color);\n}\n.pops button[data-type=\"primary\"]:focus-visible {\n\toutline: var(--button-primary-focus-visible-outline);\n\toutline-offset: var(--button-primary-focus-visible-outline-offset);\n}\n.pops button[data-type=\"primary\"]:disabled {\n\t--button-color: var(--button-primary-disabled-color);\n\t--button-bd-color: var(--button-primary-disabled-bd-color);\n\t--button-bg-color: var(--button-primary-disabled-bg-color);\n}\n\n.pops button[data-type=\"success\"] {\n\t--button-color: var(--button-success-color);\n\t--button-bd-color: var(--button-success-bd-color);\n\t--button-bg-color: var(--button-success-bg-color);\n}\n.pops button[data-type=\"success\"]:active {\n\t--button-color: var(--button-success-active-color);\n\t--button-bd-color: var(--button-success-active-bd-color);\n\t--button-bg-color: var(--button-success-active-bg-color);\n}\n.pops button[data-type=\"success\"]:hover {\n\t--button-color: var(--button-success-hover-color);\n\t--button-bd-color: var(--button-success-hover-bd-color);\n\t--button-bg-color: var(--button-success-hover-bg-color);\n}\n.pops button[data-type=\"success\"]:focus-visible {\n\toutline: var(--button-success-focus-visible-outline);\n\toutline-offset: var(--button-success-focus-visible-outline-offset);\n}\n.pops button[data-type=\"success\"]:disabled {\n\t--button-color: var(--button-success-disabled-color);\n\t--button-bd-color: var(--button-success-disabled-bd-color);\n\t--button-bg-color: var(--button-success-disabled-bg-color);\n}\n\n.pops button[data-type=\"info\"] {\n\t--button-color: var(--button-info-color);\n\t--button-bd-color: var(--button-info-bd-color);\n\t--button-bg-color: var(--button-info-bg-color);\n}\n.pops button[data-type=\"info\"]:active {\n\t--button-color: var(--button-info-active-color);\n\t--button-bd-color: var(--button-info-active-bd-color);\n\t--button-bg-color: var(--button-info-active-bg-color);\n}\n.pops button[data-type=\"info\"]:hover {\n\t--button-color: var(--button-info-hover-color);\n\t--button-bd-color: var(--button-info-hover-bd-color);\n\t--button-bg-color: var(--button-info-hover-bg-color);\n}\n.pops button[data-type=\"info\"]:focus-visible {\n\toutline: var(--button-info-focus-visible-outline);\n\toutline-offset: var(--button-info-focus-visible-outline-offset);\n}\n.pops button[data-type=\"info\"]:disabled {\n\t--button-color: var(--button-info-disabled-color);\n\t--button-bd-color: var(--button-info-disabled-bd-color);\n\t--button-bg-color: var(--button-info-disabled-bg-color);\n}\n\n.pops button[data-type=\"warning\"] {\n\t--button-color: var(--button-warning-color);\n\t--button-bd-color: var(--button-warning-bd-color);\n\t--button-bg-color: var(--button-warning-bg-color);\n}\n.pops button[data-type=\"warning\"]:active {\n\t--button-color: var(--button-warning-active-color);\n\t--button-bd-color: var(--button-warning-active-bd-color);\n\t--button-bg-color: var(--button-warning-active-bg-color);\n}\n.pops button[data-type=\"warning\"]:hover {\n\t--button-color: var(--button-warning-hover-color);\n\t--button-bd-color: var(--button-warning-hover-bd-color);\n\t--button-bg-color: var(--button-warning-hover-bg-color);\n}\n.pops button[data-type=\"warning\"]:focus-visible {\n\toutline: var(--button-warning-focus-visible-outline);\n\toutline-offset: var(--button-warning-focus-visible-outline-offset);\n}\n.pops button[data-type=\"warning\"]:disabled {\n\t--button-color: var(--button-warning-disabled-color);\n\t--button-bd-color: var(--button-warning-disabled-bd-color);\n\t--button-bg-color: var(--button-warning-disabled-bg-color);\n}\n\n.pops button[data-type=\"danger\"] {\n\t--button-color: var(--button-danger-color);\n\t--button-bd-color: var(--button-danger-bd-color);\n\t--button-bg-color: var(--button-danger-bg-color);\n}\n.pops button[data-type=\"danger\"]:active {\n\t--button-color: var(--button-danger-active-color);\n\t--button-bd-color: var(--button-danger-active-bd-color);\n\t--button-bg-color: var(--button-danger-active-bg-color);\n}\n.pops button[data-type=\"danger\"]:hover {\n\t--button-color: var(--button-danger-hover-color);\n\t--button-bd-color: var(--button-danger-hover-bd-color);\n\t--button-bg-color: var(--button-danger-hover-bg-color);\n}\n.pops button[data-type=\"danger\"]:focus-visible {\n\toutline: var(--button-danger-focus-visible-outline);\n\toutline-offset: var(--button-danger-focus-visible-outline-offset);\n}\n.pops button[data-type=\"danger\"]:disabled {\n\t--button-color: var(--button-danger-disabled-color);\n\t--button-bd-color: var(--button-danger-disabled-bd-color);\n\t--button-bg-color: var(--button-danger-disabled-bg-color);\n}\n\n.pops button[data-type=\"xiaomi-primary\"] {\n\t--button-color: var(--button-xiaomi-primary-color);\n\t--button-bd-color: var(--button-xiaomi-primary-bd-color);\n\t--button-bg-color: var(--button-xiaomi-primary-bg-color);\n}\n.pops button[data-type=\"xiaomi-primary\"]:active {\n\t--button-color: var(--button-xiaomi-primary-active-color);\n\t--button-bd-color: var(--button-xiaomi-primary-active-bd-color);\n\t--button-bg-color: var(--button-xiaomi-primary-active-bg-color);\n}\n.pops button[data-type=\"xiaomi-primary\"]:hover {\n\t--button-color: var(--button-xiaomi-primary-hover-color);\n\t--button-bd-color: var(--button-xiaomi-primary-hover-bd-color);\n\t--button-bg-color: var(--button-xiaomi-primary-hover-bg-color);\n}\n.pops button[data-type=\"xiaomi-primary\"]:focus-visible {\n\toutline: var(--button-xiaomi-primary-focus-visible-outline);\n\toutline-offset: var(--button-xiaomi-primary-focus-visible-outline-offset);\n}\n.pops button[data-type=\"xiaomi-primary\"]:disabled {\n\t--button-color: var(--button-xiaomi-primary-disabled-color);\n\t--button-bd-color: var(--button-xiaomi-primary-disabled-bd-color);\n\t--button-bg-color: var(--button-xiaomi-primary-disabled-bg-color);\n}\n\n.pops button[data-type=\"violet\"] {\n\t--button-color: var(--button-violet-color);\n\t--button-bd-color: var(--button-violet-bd-color);\n\t--button-bg-color: var(--button-violet-bg-color);\n}\n.pops button[data-type=\"violet\"]:active {\n\t--button-color: var(--button-violet-active-color);\n\t--button-bd-color: var(--button-violet-active-bd-color);\n\t--button-bg-color: var(--button-violet-active-bg-color);\n}\n.pops button[data-type=\"violet\"]:hover {\n\t--button-color: var(--button-violet-hover-color);\n\t--button-bd-color: var(--button-violet-hover-bd-color);\n\t--button-bg-color: var(--button-violet-hover-bg-color);\n}\n.pops button[data-type=\"violet\"]:focus-visible {\n\toutline: var(--button-violet-focus-visible-outline);\n\toutline-offset: var(--button-violet-focus-visible-outline-offset);\n}\n.pops button[data-type=\"violet\"]:disabled {\n\t--button-color: var(--button-violet-disabled-color);\n\t--button-bd-color: var(--button-violet-disabled-bd-color);\n\t--button-bg-color: var(--button-violet-disabled-bg-color);\n}\n";
|
|
2814
|
+
var buttonCSS = ".pops {\n --button-font-size: 14px;\n --button-height: 32px;\n --button-color: rgb(51, 51, 51);\n --button-bd-color: rgb(220, 223, 230, var(--pops-bd-opacity));\n --button-bg-color: rgb(220, 223, 230, var(--pops-bg-opacity));\n --button-margin-top: 0px;\n --button-margin-bottom: 0px;\n --button-margin-left: 5px;\n --button-margin-right: 5px;\n --button-padding-top: 6px;\n --button-padding-bottom: 6px;\n --button-padding-left: 12px;\n --button-padding-right: 12px;\n --button-radius: 4px;\n\n --container-title-height: 55px;\n --container-bottom-btn-height: 55px;\n\n /* default按钮 */\n --button-default-color: #333333;\n --button-default-bd-color: #dcdfe6;\n --button-default-bg-color: #ffffff;\n --button-default-active-color: #409eff;\n --button-default-active-bd-color: #409eff;\n --button-default-active-bg-color: #ecf5ff;\n --button-default-hover-color: #409eff;\n --button-default-hover-bd-color: #c6e2ff;\n --button-default-hover-bg-color: #ecf5ff;\n --button-default-focus-visible-outline-color: #a0cfff;\n --button-default-focus-visible-outline: 2px solid var(--button-default-focus-visible-outline-color);\n --button-default-focus-visible-outline-offset: 1px;\n --button-default-disabled-color: #a8abb2;\n --button-default-disabled-bd-color: #ffffff;\n --button-default-disabled-bg-color: #e4e7ed;\n\n /* primary按钮 */\n --button-primary-color: #ffffff;\n --button-primary-bd-color: #409eff;\n --button-primary-bg-color: #409eff;\n --button-primary-active-color: #ffffff;\n --button-primary-active-bd-color: #337ecc;\n --button-primary-active-bg-color: #337ecc;\n --button-primary-hover-color: #ffffff;\n --button-primary-hover-bd-color: #79bbff;\n --button-primary-hover-bg-color: #79bbff;\n --button-primary-focus-visible-outline-color: #a0cfff;\n --button-primary-focus-visible-outline: 2px solid var(--button-primary-focus-visible-outline-color);\n --button-primary-focus-visible-outline-offset: 1px;\n --button-primary-disabled-color: #ffffff80;\n --button-primary-disabled-bd-color: #a0cfff;\n --button-primary-disabled-bg-color: #a0cfff;\n\n /* success按钮 */\n --button-success-color: #ffffff;\n --button-success-bd-color: #4cae4c;\n --button-success-bg-color: #5cb85c;\n --button-success-active-color: #ffffff;\n --button-success-active-bd-color: #529b2e;\n --button-success-active-bg-color: #529b2e;\n --button-success-hover-color: #ffffff;\n --button-success-hover-bd-color: #95d475;\n --button-success-hover-bg-color: #95d475;\n --button-success-focus-visible-outline-color: #b3e19d;\n --button-success-focus-visible-outline: 2px solid var(--button-success-focus-visible-outline-color);\n --button-success-focus-visible-outline-offset: 1px;\n --button-success-disabled-color: #ffffff80;\n --button-success-disabled-bd-color: #b3e19d;\n --button-success-disabled-bg-color: #b3e19d;\n\n /* info按钮 */\n --button-info-color: #ffffff;\n --button-info-bd-color: #909399;\n --button-info-bg-color: #909399;\n --button-info-active-color: #ffffff;\n --button-info-active-bd-color: #73767a;\n --button-info-active-bg-color: #73767a;\n --button-info-hover-color: #ffffff;\n --button-info-hover-bd-color: #b1b3b8;\n --button-info-hover-bg-color: #b1b3b8;\n --button-info-focus-visible-outline-color: #c8c9cc;\n --button-info-focus-visible-outline: 2px solid var(--button-info-focus-visible-outline-color);\n --button-info-focus-visible-outline-offset: 1px;\n --button-info-disabled-color: #ffffff80;\n --button-info-disabled-bd-color: #c8c9cc;\n --button-info-disabled-bg-color: #c8c9cc;\n\n /* warning按钮 */\n --button-warning-color: #ffffff;\n --button-warning-bd-color: #e6a23c;\n --button-warning-bg-color: #e6a23c;\n --button-warning-active-color: #ffffff;\n --button-warning-active-bd-color: #b88230;\n --button-warning-active-bg-color: #b88230;\n --button-warning-hover-color: #ffffff80;\n --button-warning-hover-bd-color: #eebe77;\n --button-warning-hover-bg-color: #eebe77;\n --button-warning-focus-visible-outline-color: #f3d19e;\n --button-warning-focus-visible-outline: 2px solid var(--button-warning-focus-visible-outline-color);\n --button-warning-focus-visible-outline-offset: 1px;\n --button-warning-disabled-color: #ffffff80;\n --button-warning-disabled-bd-color: #f3d19e;\n --button-warning-disabled-bg-color: #f3d19e;\n\n /* danger按钮 */\n --button-danger-color: #ffffff;\n --button-danger-bd-color: #f56c6c;\n --button-danger-bg-color: #f56c6c;\n --button-danger-active-color: #ffffff;\n --button-danger-active-bd-color: #c45656;\n --button-danger-active-bg-color: #c45656;\n --button-danger-hover-color: #ffffff;\n --button-danger-hover-bd-color: #f89898;\n --button-danger-hover-bg-color: #f89898;\n --button-danger-focus-visible-outline-color: #fab6b6;\n --button-danger-focus-visible-outline: 2px solid var(--button-danger-focus-visible-outline-color);\n --button-danger-focus-visible-outline-offset: 1px;\n --button-danger-disabled-color: #ffffff80;\n --button-danger-disabled-bd-color: #fab6b6;\n --button-danger-disabled-bg-color: #fab6b6;\n\n /* xiaomi-primary按钮 */\n --button-xiaomi-primary-color: #ffffff;\n --button-xiaomi-primary-bd-color: #ff5c00;\n --button-xiaomi-primary-bg-color: #ff5c00;\n --button-xiaomi-primary-active-color: #ffffff;\n --button-xiaomi-primary-active-bd-color: #da4f00;\n --button-xiaomi-primary-active-bg-color: #da4f00;\n --button-xiaomi-primary-hover-color: #ffffff;\n --button-xiaomi-primary-hover-bd-color: #ff7e29;\n --button-xiaomi-primary-hover-bg-color: #ff7e29;\n --button-xiaomi-primary-focus-visible-outline-color: #ffa061;\n --button-xiaomi-primary-focus-visible-outline: 2px solid var(--button-xiaomi-primary-focus-visible-outline-color);\n --button-xiaomi-primary-focus-visible-outline-offset: 1px;\n --button-xiaomi-primary-disabled-color: #ffffff80;\n --button-xiaomi-primary-disabled-bd-color: #fad5b6;\n --button-xiaomi-primary-disabled-bg-color: #fad5b6;\n\n /* violet按钮 */\n --button-violet-color: #ffffff;\n --button-violet-bd-color: #626aef;\n --button-violet-bg-color: #626aef;\n --button-violet-active-color: #ffffff;\n --button-violet-active-bd-color: #8188f2;\n --button-violet-active-bg-color: #8188f2;\n --button-violet-hover-color: #ffffff;\n --button-violet-hover-bd-color: #4b50ad;\n --button-violet-hover-bg-color: #4b50ad;\n --button-violet-focus-visible-outline-color: #2a598a;\n --button-violet-focus-visible-outline: 2px solid var(--button-violet-focus-visible-outline-color);\n --button-violet-focus-visible-outline-offset: 1px;\n --button-violet-disabled-color: #ffffff80;\n --button-violet-disabled-bd-color: #3b3f82;\n --button-violet-disabled-bg-color: #3b3f82;\n}\n\n@media (prefers-color-scheme: dark) {\n .pops {\n /* default按钮 */\n --button-default-color: #cfd3dc;\n --button-default-bd-color: #4c4d4f;\n --button-default-bg-color: transparent;\n --button-default-active-color: #409eff;\n --button-default-active-bd-color: #409eff;\n --button-default-active-bg-color: #18222c;\n --button-default-hover-color: #409eff;\n --button-default-hover-bd-color: #213d5b;\n --button-default-hover-bg-color: #18222c;\n --button-default-focus-visible-outline-color: #2a598a;\n --button-default-focus-visible-outline: 2px solid var(--button-default-focus-visible-outline-color);\n --button-default-focus-visible-outline-offset: 1px;\n --button-default-disabled-color: #ffffff80;\n --button-default-disabled-bd-color: #414243;\n --button-default-disabled-bg-color: transparent;\n\n /* primary按钮 */\n --button-primary-color: #ffffff;\n --button-primary-bd-color: #409eff;\n --button-primary-bg-color: #409eff;\n --button-primary-active-color: #ffffff;\n --button-primary-active-bd-color: #66b1ff;\n --button-primary-active-bg-color: #66b1ff;\n --button-primary-hover-color: #ffffff;\n --button-primary-hover-bd-color: #3375b9;\n --button-primary-hover-bg-color: #3375b9;\n --button-primary-focus-visible-outline-color: #2a598a;\n --button-primary-focus-visible-outline: 2px solid var(--button-primary-focus-visible-outline-color);\n --button-primary-focus-visible-outline-offset: 1px;\n --button-primary-disabled-color: #ffffff80;\n --button-primary-disabled-bd-color: #2a598a;\n --button-primary-disabled-bg-color: #2a598a;\n\n /* success按钮 */\n --button-success-color: #ffffff;\n --button-success-bd-color: #67c23a;\n --button-success-bg-color: #67c23a;\n --button-success-active-color: #ffffff;\n --button-success-active-bd-color: #85ce61;\n --button-success-active-bg-color: #85ce61;\n --button-success-hover-color: #ffffff;\n --button-success-hover-bd-color: #4e8e2f;\n --button-success-hover-bg-color: #4e8e2f;\n --button-success-focus-visible-outline-color: #3e6b27;\n --button-success-focus-visible-outline: 2px solid var(--button-success-focus-visible-outline-color);\n --button-success-focus-visible-outline-offset: 1px;\n --button-success-disabled-color: #ffffff80;\n --button-success-disabled-bd-color: #3e6b27;\n --button-success-disabled-bg-color: #3e6b27;\n\n /* info按钮 */\n --button-info-color: #ffffff;\n --button-info-bd-color: #909399;\n --button-info-bg-color: #909399;\n --button-info-active-color: #ffffff;\n --button-info-active-bd-color: #a6a9ad;\n --button-info-active-bg-color: #a6a9ad;\n --button-info-hover-color: #ffffff;\n --button-info-hover-bd-color: #6b6d71;\n --button-info-hover-bg-color: #6b6d71;\n --button-info-focus-visible-outline-color: #525457;\n --button-info-focus-visible-outline: 2px solid var(--button-info-focus-visible-outline-color);\n --button-info-focus-visible-outline-offset: 1px;\n --button-info-disabled-color: #ffffff80;\n --button-info-disabled-bd-color: #525457;\n --button-info-disabled-bg-color: #525457;\n\n /* warning按钮 */\n --button-warning-color: #ffffff;\n --button-warning-bd-color: #e6a23c;\n --button-warning-bg-color: #e6a23c;\n --button-warning-active-color: #ffffff;\n --button-warning-active-bd-color: #ebb563;\n --button-warning-active-bg-color: #ebb563;\n --button-warning-hover-color: #ffffff80;\n --button-warning-hover-bd-color: #a77730;\n --button-warning-hover-bg-color: #a77730;\n --button-warning-focus-visible-outline-color: #7d5b28;\n --button-warning-focus-visible-outline: 2px solid var(--button-warning-focus-visible-outline-color);\n --button-warning-focus-visible-outline-offset: 1px;\n --button-warning-disabled-color: #ffffff80;\n --button-warning-disabled-bd-color: #7d5b28;\n --button-warning-disabled-bg-color: #7d5b28;\n\n /* danger按钮 */\n --button-danger-color: #ffffff;\n --button-danger-bd-color: #f56c6c;\n --button-danger-bg-color: #f56c6c;\n --button-danger-active-color: #ffffff;\n --button-danger-active-bd-color: #f78989;\n --button-danger-active-bg-color: #f78989;\n --button-danger-hover-color: #ffffff;\n --button-danger-hover-bd-color: #b25252;\n --button-danger-hover-bg-color: #b25252;\n --button-danger-focus-visible-outline-color: #854040;\n --button-danger-focus-visible-outline: 2px solid var(--button-danger-focus-visible-outline-color);\n --button-danger-focus-visible-outline-offset: 1px;\n --button-danger-disabled-color: #ffffff80;\n --button-danger-disabled-bd-color: #854040;\n --button-danger-disabled-bg-color: #854040;\n }\n}\n.pops[data-bottom-btn=\"false\"] {\n --container-bottom-btn-height: 0px;\n}\n.pops button {\n white-space: nowrap;\n float: right;\n display: inline-block;\n margin: var(--button-margin-top) var(--button-margin-right) var(--button-margin-bottom) var(--button-margin-left);\n padding: var(--button-padding-top) var(--button-padding-right) var(--button-padding-bottom) var(--button-padding-left);\n outline: 0;\n}\n.pops button[data-has-icon=\"false\"] .pops-bottom-icon {\n display: none;\n}\n.pops button {\n border-radius: var(--button-radius);\n box-shadow: none;\n font-weight: 400;\n font-size: var(--button-font-size);\n cursor: pointer;\n transition: all 0.3s ease-in-out;\n}\n.pops button {\n display: flex;\n align-items: center;\n height: var(--button-height);\n line-height: normal;\n box-sizing: border-box;\n border: 1px solid var(--button-bd-color);\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n.pops button {\n color: var(--button-color);\n border-color: var(--button-bd-color);\n background-color: var(--button-bg-color);\n}\n.pops button:active {\n color: var(--button-color);\n border-color: var(--button-bd-color);\n background-color: var(--button-bg-color);\n outline: 0;\n}\n.pops button:hover {\n color: var(--button-color);\n border-color: var(--button-bd-color);\n background-color: var(--button-bg-color);\n}\n.pops button:focus-visible {\n color: var(--button-color);\n border-color: var(--button-bd-color);\n background-color: var(--button-bg-color);\n}\n.pops button:disabled {\n cursor: not-allowed;\n color: var(--button-color);\n border-color: var(--button-bd-color);\n background-color: var(--button-bg-color);\n}\n.pops button.pops-button-large {\n --button-height: 32px;\n --button-padding-top: 12px;\n --button-padding-bottom: 12px;\n --button-padding-left: 19px;\n --button-padding-right: 19px;\n --button-font-size: 14px;\n --button-border-radius: 4px;\n}\n\n.pops button.pops-button-small {\n --button-height: 24px;\n --button-padding-top: 5px;\n --button-padding-bottom: 5px;\n --button-padding-left: 11px;\n --button-padding-right: 11px;\n --button-font-size: 12px;\n --button-border-radius: 4px;\n}\n.pops-panel-button-no-icon .pops-panel-button_inner i {\n display: none;\n}\n.pops-panel-button-right-icon .pops-panel-button_inner {\n flex-direction: row-reverse;\n}\n.pops-panel-button .pops-panel-button_inner i:has(svg),\n.pops-panel-button-right-icon .pops-panel-button-text {\n margin-right: 6px;\n}\n\n.pops button[data-type=\"default\"] {\n --button-color: var(--button-default-color);\n --button-bd-color: var(--button-default-bd-color);\n --button-bg-color: var(--button-default-bg-color);\n}\n.pops button[data-type=\"default\"]:active {\n --button-color: var(--button-default-active-color);\n --button-bd-color: var(--button-default-active-bd-color);\n --button-bg-color: var(--button-default-active-bg-color);\n}\n.pops button[data-type=\"default\"]:hover {\n --button-color: var(--button-default-hover-color);\n --button-bd-color: var(--button-default-hover-bd-color);\n --button-bg-color: var(--button-default-hover-bg-color);\n}\n.pops button[data-type=\"default\"]:focus-visible {\n outline: var(--button-default-focus-visible-outline);\n outline-offset: var(--button-default-focus-visible-outline-offset);\n}\n.pops button[data-type=\"default\"]:disabled {\n --button-color: var(--button-default-disabled-color);\n --button-bd-color: var(--button-default-disabled-bd-color);\n --button-bg-color: var(--button-default-disabled-bg-color);\n}\n\n.pops button[data-type=\"primary\"] {\n --button-color: var(--button-primary-color);\n --button-bd-color: var(--button-primary-bd-color);\n --button-bg-color: var(--button-primary-bg-color);\n}\n.pops button[data-type=\"primary\"]:active {\n --button-color: var(--button-primary-active-color);\n --button-bd-color: var(--button-primary-active-bd-color);\n --button-bg-color: var(--button-primary-active-bg-color);\n}\n.pops button[data-type=\"primary\"]:hover {\n --button-color: var(--button-primary-hover-color);\n --button-bd-color: var(--button-primary-hover-bd-color);\n --button-bg-color: var(--button-primary-hover-bg-color);\n}\n.pops button[data-type=\"primary\"]:focus-visible {\n outline: var(--button-primary-focus-visible-outline);\n outline-offset: var(--button-primary-focus-visible-outline-offset);\n}\n.pops button[data-type=\"primary\"]:disabled {\n --button-color: var(--button-primary-disabled-color);\n --button-bd-color: var(--button-primary-disabled-bd-color);\n --button-bg-color: var(--button-primary-disabled-bg-color);\n}\n\n.pops button[data-type=\"success\"] {\n --button-color: var(--button-success-color);\n --button-bd-color: var(--button-success-bd-color);\n --button-bg-color: var(--button-success-bg-color);\n}\n.pops button[data-type=\"success\"]:active {\n --button-color: var(--button-success-active-color);\n --button-bd-color: var(--button-success-active-bd-color);\n --button-bg-color: var(--button-success-active-bg-color);\n}\n.pops button[data-type=\"success\"]:hover {\n --button-color: var(--button-success-hover-color);\n --button-bd-color: var(--button-success-hover-bd-color);\n --button-bg-color: var(--button-success-hover-bg-color);\n}\n.pops button[data-type=\"success\"]:focus-visible {\n outline: var(--button-success-focus-visible-outline);\n outline-offset: var(--button-success-focus-visible-outline-offset);\n}\n.pops button[data-type=\"success\"]:disabled {\n --button-color: var(--button-success-disabled-color);\n --button-bd-color: var(--button-success-disabled-bd-color);\n --button-bg-color: var(--button-success-disabled-bg-color);\n}\n\n.pops button[data-type=\"info\"] {\n --button-color: var(--button-info-color);\n --button-bd-color: var(--button-info-bd-color);\n --button-bg-color: var(--button-info-bg-color);\n}\n.pops button[data-type=\"info\"]:active {\n --button-color: var(--button-info-active-color);\n --button-bd-color: var(--button-info-active-bd-color);\n --button-bg-color: var(--button-info-active-bg-color);\n}\n.pops button[data-type=\"info\"]:hover {\n --button-color: var(--button-info-hover-color);\n --button-bd-color: var(--button-info-hover-bd-color);\n --button-bg-color: var(--button-info-hover-bg-color);\n}\n.pops button[data-type=\"info\"]:focus-visible {\n outline: var(--button-info-focus-visible-outline);\n outline-offset: var(--button-info-focus-visible-outline-offset);\n}\n.pops button[data-type=\"info\"]:disabled {\n --button-color: var(--button-info-disabled-color);\n --button-bd-color: var(--button-info-disabled-bd-color);\n --button-bg-color: var(--button-info-disabled-bg-color);\n}\n\n.pops button[data-type=\"warning\"] {\n --button-color: var(--button-warning-color);\n --button-bd-color: var(--button-warning-bd-color);\n --button-bg-color: var(--button-warning-bg-color);\n}\n.pops button[data-type=\"warning\"]:active {\n --button-color: var(--button-warning-active-color);\n --button-bd-color: var(--button-warning-active-bd-color);\n --button-bg-color: var(--button-warning-active-bg-color);\n}\n.pops button[data-type=\"warning\"]:hover {\n --button-color: var(--button-warning-hover-color);\n --button-bd-color: var(--button-warning-hover-bd-color);\n --button-bg-color: var(--button-warning-hover-bg-color);\n}\n.pops button[data-type=\"warning\"]:focus-visible {\n outline: var(--button-warning-focus-visible-outline);\n outline-offset: var(--button-warning-focus-visible-outline-offset);\n}\n.pops button[data-type=\"warning\"]:disabled {\n --button-color: var(--button-warning-disabled-color);\n --button-bd-color: var(--button-warning-disabled-bd-color);\n --button-bg-color: var(--button-warning-disabled-bg-color);\n}\n\n.pops button[data-type=\"danger\"] {\n --button-color: var(--button-danger-color);\n --button-bd-color: var(--button-danger-bd-color);\n --button-bg-color: var(--button-danger-bg-color);\n}\n.pops button[data-type=\"danger\"]:active {\n --button-color: var(--button-danger-active-color);\n --button-bd-color: var(--button-danger-active-bd-color);\n --button-bg-color: var(--button-danger-active-bg-color);\n}\n.pops button[data-type=\"danger\"]:hover {\n --button-color: var(--button-danger-hover-color);\n --button-bd-color: var(--button-danger-hover-bd-color);\n --button-bg-color: var(--button-danger-hover-bg-color);\n}\n.pops button[data-type=\"danger\"]:focus-visible {\n outline: var(--button-danger-focus-visible-outline);\n outline-offset: var(--button-danger-focus-visible-outline-offset);\n}\n.pops button[data-type=\"danger\"]:disabled {\n --button-color: var(--button-danger-disabled-color);\n --button-bd-color: var(--button-danger-disabled-bd-color);\n --button-bg-color: var(--button-danger-disabled-bg-color);\n}\n\n.pops button[data-type=\"xiaomi-primary\"] {\n --button-color: var(--button-xiaomi-primary-color);\n --button-bd-color: var(--button-xiaomi-primary-bd-color);\n --button-bg-color: var(--button-xiaomi-primary-bg-color);\n}\n.pops button[data-type=\"xiaomi-primary\"]:active {\n --button-color: var(--button-xiaomi-primary-active-color);\n --button-bd-color: var(--button-xiaomi-primary-active-bd-color);\n --button-bg-color: var(--button-xiaomi-primary-active-bg-color);\n}\n.pops button[data-type=\"xiaomi-primary\"]:hover {\n --button-color: var(--button-xiaomi-primary-hover-color);\n --button-bd-color: var(--button-xiaomi-primary-hover-bd-color);\n --button-bg-color: var(--button-xiaomi-primary-hover-bg-color);\n}\n.pops button[data-type=\"xiaomi-primary\"]:focus-visible {\n outline: var(--button-xiaomi-primary-focus-visible-outline);\n outline-offset: var(--button-xiaomi-primary-focus-visible-outline-offset);\n}\n.pops button[data-type=\"xiaomi-primary\"]:disabled {\n --button-color: var(--button-xiaomi-primary-disabled-color);\n --button-bd-color: var(--button-xiaomi-primary-disabled-bd-color);\n --button-bg-color: var(--button-xiaomi-primary-disabled-bg-color);\n}\n\n.pops button[data-type=\"violet\"] {\n --button-color: var(--button-violet-color);\n --button-bd-color: var(--button-violet-bd-color);\n --button-bg-color: var(--button-violet-bg-color);\n}\n.pops button[data-type=\"violet\"]:active {\n --button-color: var(--button-violet-active-color);\n --button-bd-color: var(--button-violet-active-bd-color);\n --button-bg-color: var(--button-violet-active-bg-color);\n}\n.pops button[data-type=\"violet\"]:hover {\n --button-color: var(--button-violet-hover-color);\n --button-bd-color: var(--button-violet-hover-bd-color);\n --button-bg-color: var(--button-violet-hover-bg-color);\n}\n.pops button[data-type=\"violet\"]:focus-visible {\n outline: var(--button-violet-focus-visible-outline);\n outline-offset: var(--button-violet-focus-visible-outline-offset);\n}\n.pops button[data-type=\"violet\"]:disabled {\n --button-color: var(--button-violet-disabled-color);\n --button-bd-color: var(--button-violet-disabled-bd-color);\n --button-bg-color: var(--button-violet-disabled-bg-color);\n}\n";
|
|
2834
2815
|
|
|
2835
|
-
var commonCSS = ".pops-flex-items-center {\n
|
|
2816
|
+
var commonCSS = ".pops-flex-items-center {\n display: flex;\n align-items: center;\n}\n.pops-flex-y-center {\n display: flex;\n justify-content: space-between;\n}\n.pops-flex-x-center {\n display: flex;\n align-content: center;\n}\n.pops-hide {\n display: none;\n}\n.pops-hide-important {\n display: none !important;\n}\n.pops-no-border {\n border: 0;\n}\n.pops-no-border-important {\n border: 0 !important;\n}\n.pops-user-select-none {\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n.pops-line-height-center {\n line-height: normal;\n align-content: center;\n}\n.pops-width-fill {\n width: -webkit-fill-available;\n width: -moz-available;\n}\n.pops-text-is-disabled {\n --pops-text-is-disabled-color: #a8abb2;\n color: var(--pops-text-is-disabled-color);\n --pops-panel-forms-container-item-left-desc-text-color: var(--pops-text-is-disabled-color);\n}\n.pops-text-is-disabled-important {\n --pops-text-is-disabled-color: #a8abb2;\n color: var(--pops-text-is-disabled-color) !important;\n --pops-panel-forms-container-item-left-desc-text-color: var(--pops-text-is-disabled-color) !important;\n}\n";
|
|
2836
2817
|
|
|
2837
|
-
var animCSS = "@keyframes rotating {\n\t0% {\n\t\ttransform: rotate(0);\n\t}\n\tto {\n\t\ttransform: rotate(360deg);\n\t}\n}\n@keyframes iframeLoadingChange_85 {\n\t0% {\n\t\tbackground: linear-gradient(to right, #4995dd, #fff, rgb(202 224 246));\n\t}\n\t20% {\n\t\tbackground: linear-gradient(to right, #4995dd, #ead0d0, rgb(123 185 246));\n\t}\n\t40% {\n\t\tbackground: linear-gradient(to right, #4995dd, #f4b7b7, rgb(112 178 244));\n\t}\n\t60% {\n\t\tbackground: linear-gradient(to right, #4995dd, #ec9393, rgb(80 163 246));\n\t}\n\t80% {\n\t\tbackground: linear-gradient(to right, #4995dd, #e87f7f, rgb(25 139 253));\n\t}\n\t100% {\n\t\tbackground: linear-gradient(to right, #4995dd, #ee2c2c, rgb(0 124 247));\n\t}\n\tfrom {\n\t\twidth: 75%;\n\t}\n\tto {\n\t\twidth: 100%;\n\t}\n}\n@keyframes iframeLoadingChange {\n\t0% {\n\t\tbackground: linear-gradient(to right, #4995dd, #fff, rgb(202 224 246));\n\t}\n\t20% {\n\t\tbackground: linear-gradient(to right, #4995dd, #ead0d0, rgb(123 185 246));\n\t}\n\t40% {\n\t\tbackground: linear-gradient(to right, #4995dd, #f4b7b7, rgb(112 178 244));\n\t}\n\t60% {\n\t\tbackground: linear-gradient(to right, #4995dd, #ec9393, rgb(80 163 246));\n\t}\n\t80% {\n\t\tbackground: linear-gradient(to right, #4995dd, #e87f7f, rgb(25 139 253));\n\t}\n\t100% {\n\t\tbackground: linear-gradient(to right, #4995dd, #ee2c2c, rgb(0 124 247));\n\t}\n\tfrom {\n\t\twidth: 0;\n\t}\n\tto {\n\t\twidth: 75%;\n\t}\n}\n\n@keyframes searchSelectFalIn {\n\tfrom {\n\t\topacity: 0;\n\t\tdisplay: none;\n\t}\n\tto {\n\t\tdisplay: block;\n\t\topacity: 1;\n\t}\n}\n@keyframes searchSelectFalOut {\n\tfrom {\n\t\tdisplay: block;\n\t\topacity: 1;\n\t}\n\tto {\n\t\topacity: 0;\n\t\tdisplay: none;\n\t}\n}\n\n@keyframes pops-anim-wait-rotate {\n\tform {\n\t\ttransform: rotate(0);\n\t}\n\tto {\n\t\ttransform: rotate(360deg);\n\t}\n}\n@keyframes pops-anim-spread {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: scaleX(0);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: scaleX(1);\n\t}\n}\n@keyframes pops-anim-shake {\n\t0%,\n\t100% {\n\t\ttransform: translateX(0);\n\t}\n\t10%,\n\t30%,\n\t50%,\n\t70%,\n\t90% {\n\t\ttransform: translateX(-10px);\n\t}\n\t20%,\n\t40%,\n\t60%,\n\t80% {\n\t\ttransform: translateX(10px);\n\t}\n}\n@keyframes pops-anim-rolling-left {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: translateX(-100%) rotate(-120deg);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: translateX(0) rotate(0);\n\t}\n}\n@keyframes pops-anim-rolling-right {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: translateX(100%) rotate(120deg);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: translateX(0) rotate(0);\n\t}\n}\n@keyframes pops-anim-slide-top {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: translateY(-200%);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: translateY(0);\n\t}\n}\n@keyframes pops-anim-slide-bottom {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: translateY(200%);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: translateY(0);\n\t}\n}\n@keyframes pops-anim-slide-left {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: translateX(-200%);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: translateX(0);\n\t}\n}\n@keyframes pops-anim-slide-right {\n\t0% {\n\t\ttransform: translateX(200%);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: translateX(0);\n\t}\n}\n@keyframes pops-anim-fadein {\n\t0% {\n\t\topacity: 0;\n\t}\n\t100% {\n\t\topacity: 1;\n\t}\n}\n@keyframes pops-anim-fadein-zoom {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: scale(0.5);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: scale(1);\n\t}\n}\n@keyframes pops-anim-fadein-alert {\n\t0% {\n\t\ttransform: scale(0.5);\n\t}\n\t45% {\n\t\ttransform: scale(1.05);\n\t}\n\t80% {\n\t\ttransform: scale(0.95);\n\t}\n\t100% {\n\t\ttransform: scale(1);\n\t}\n}\n@keyframes pops-anim-don {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: matrix3d(0.7, 0, 0, 0, 0, 0.7, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t2.08333% {\n\t\ttransform: matrix3d(0.75266, 0, 0, 0, 0, 0.76342, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t4.16667% {\n\t\ttransform: matrix3d(0.81071, 0, 0, 0, 0, 0.84545, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t6.25% {\n\t\ttransform: matrix3d(0.86808, 0, 0, 0, 0, 0.9286, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t8.33333% {\n\t\ttransform: matrix3d(0.92038, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t10.4167% {\n\t\ttransform: matrix3d(0.96482, 0, 0, 0, 0, 1.05202, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t12.5% {\n\t\ttransform: matrix3d(1, 0, 0, 0, 0, 1.08204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t14.5833% {\n\t\ttransform: matrix3d(1.02563, 0, 0, 0, 0, 1.09149, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t16.6667% {\n\t\ttransform: matrix3d(1.04227, 0, 0, 0, 0, 1.08453, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t18.75% {\n\t\ttransform: matrix3d(1.05102, 0, 0, 0, 0, 1.06666, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t20.8333% {\n\t\ttransform: matrix3d(1.05334, 0, 0, 0, 0, 1.04355, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t22.9167% {\n\t\ttransform: matrix3d(1.05078, 0, 0, 0, 0, 1.02012, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t25% {\n\t\ttransform: matrix3d(1.04487, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t27.0833% {\n\t\ttransform: matrix3d(1.03699, 0, 0, 0, 0, 0.98534, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t29.1667% {\n\t\ttransform: matrix3d(1.02831, 0, 0, 0, 0, 0.97688, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t31.25% {\n\t\ttransform: matrix3d(1.01973, 0, 0, 0, 0, 0.97422, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t33.3333% {\n\t\ttransform: matrix3d(1.01191, 0, 0, 0, 0, 0.97618, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t35.4167% {\n\t\ttransform: matrix3d(1.00526, 0, 0, 0, 0, 0.98122, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t37.5% {\n\t\ttransform: matrix3d(1, 0, 0, 0, 0, 0.98773, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t39.5833% {\n\t\ttransform: matrix3d(0.99617, 0, 0, 0, 0, 0.99433, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t41.6667% {\n\t\ttransform: matrix3d(0.99368, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t43.75% {\n\t\ttransform: matrix3d(0.99237, 0, 0, 0, 0, 1.00413, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t45.8333% {\n\t\ttransform: matrix3d(0.99202, 0, 0, 0, 0, 1.00651, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t47.9167% {\n\t\ttransform: matrix3d(0.99241, 0, 0, 0, 0, 1.00726, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t50% {\n\t\topacity: 1;\n\t\ttransform: matrix3d(0.99329, 0, 0, 0, 0, 1.00671, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t52.0833% {\n\t\ttransform: matrix3d(0.99447, 0, 0, 0, 0, 1.00529, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t54.1667% {\n\t\ttransform: matrix3d(0.99577, 0, 0, 0, 0, 1.00346, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t56.25% {\n\t\ttransform: matrix3d(0.99705, 0, 0, 0, 0, 1.0016, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t58.3333% {\n\t\ttransform: matrix3d(0.99822, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t60.4167% {\n\t\ttransform: matrix3d(0.99921, 0, 0, 0, 0, 0.99884, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t62.5% {\n\t\ttransform: matrix3d(1, 0, 0, 0, 0, 0.99816, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t64.5833% {\n\t\ttransform: matrix3d(1.00057, 0, 0, 0, 0, 0.99795, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t66.6667% {\n\t\ttransform: matrix3d(1.00095, 0, 0, 0, 0, 0.99811, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t68.75% {\n\t\ttransform: matrix3d(1.00114, 0, 0, 0, 0, 0.99851, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t70.8333% {\n\t\ttransform: matrix3d(1.00119, 0, 0, 0, 0, 0.99903, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t72.9167% {\n\t\ttransform: matrix3d(1.00114, 0, 0, 0, 0, 0.99955, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t75% {\n\t\ttransform: matrix3d(1.001, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t77.0833% {\n\t\ttransform: matrix3d(1.00083, 0, 0, 0, 0, 1.00033, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t79.1667% {\n\t\ttransform: matrix3d(1.00063, 0, 0, 0, 0, 1.00052, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t81.25% {\n\t\ttransform: matrix3d(1.00044, 0, 0, 0, 0, 1.00058, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t83.3333% {\n\t\ttransform: matrix3d(1.00027, 0, 0, 0, 0, 1.00053, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t85.4167% {\n\t\ttransform: matrix3d(1.00012, 0, 0, 0, 0, 1.00042, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t87.5% {\n\t\ttransform: matrix3d(1, 0, 0, 0, 0, 1.00027, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t89.5833% {\n\t\ttransform: matrix3d(0.99991, 0, 0, 0, 0, 1.00013, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t91.6667% {\n\t\ttransform: matrix3d(0.99986, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t93.75% {\n\t\ttransform: matrix3d(0.99983, 0, 0, 0, 0, 0.99991, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t95.8333% {\n\t\ttransform: matrix3d(0.99982, 0, 0, 0, 0, 0.99985, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t97.9167% {\n\t\ttransform: matrix3d(0.99983, 0, 0, 0, 0, 0.99984, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n}\n@keyframes pops-anim-roll {\n\t0% {\n\t\ttransform: perspective(1000px) rotate3d(1, 0, 0, 90deg);\n\t}\n\t100% {\n\t\ttransform: perspective(1000px) rotate3d(1, 0, 0, 0deg);\n\t}\n}\n@keyframes pops-anim-sandra {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: scale3d(1.1, 1.1, 1);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: scale3d(1, 1, 1);\n\t}\n}\n@keyframes pops-anim-gather {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: scale(5, 0);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: scale(1, 1);\n\t}\n}\n@keyframes pops-anim-spread-reverse {\n\t0% {\n\t\topacity: 1;\n\t\ttransform: scaleX(1);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\ttransform: scaleX(0);\n\t}\n}\n@keyframes pops-anim-shake-reverse {\n\t0%,\n\t100% {\n\t\ttransform: translateX(10px);\n\t}\n\t10%,\n\t30%,\n\t50%,\n\t70%,\n\t90% {\n\t\ttransform: translateX(-10px);\n\t}\n\t20%,\n\t40%,\n\t60%,\n\t80% {\n\t\ttransform: translateX(0);\n\t}\n}\n@keyframes pops-anim-rolling-left-reverse {\n\t0% {\n\t\topacity: 1;\n\t\ttransform: translateX(0) rotate(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\ttransform: translateX(-100%) rotate(-120deg);\n\t}\n}\n@keyframes pops-anim-rolling-right-reverse {\n\t0% {\n\t\topacity: 1;\n\t\ttransform: translateX(0) rotate(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\ttransform: translateX(100%) rotate(120deg);\n\t}\n}\n@keyframes pops-anim-slide-top-reverse {\n\t0% {\n\t\topacity: 1;\n\t\ttransform: translateY(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\ttransform: translateY(-200%);\n\t}\n}\n@keyframes pops-anim-slide-bottom-reverse {\n\t0% {\n\t\topacity: 1;\n\t\ttransform: translateY(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\ttransform: translateY(200%);\n\t}\n}\n@keyframes pops-anim-slide-left-reverse {\n\t0% {\n\t\topacity: 1;\n\t\ttransform: translateX(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\ttransform: translateX(-200%);\n\t}\n}\n@keyframes pops-anim-slide-right-reverse {\n\t0% {\n\t\topacity: 1;\n\t\ttransform: translateX(0);\n\t}\n\t100% {\n\t\ttransform: translateX(200%);\n\t}\n}\n@keyframes pops-anim-fadein-reverse {\n\t0% {\n\t\topacity: 1;\n\t}\n\t100% {\n\t\topacity: 0;\n\t}\n}\n@keyframes pops-anim-fadein-zoom-reverse {\n\t0% {\n\t\topacity: 1;\n\t\ttransform: scale(1);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\ttransform: scale(0.5);\n\t}\n}\n@keyframes pops-anim-fadein-alert-reverse {\n\t0% {\n\t\ttransform: scale(1);\n\t}\n\t45% {\n\t\ttransform: scale(0.95);\n\t}\n\t80% {\n\t\ttransform: scale(1.05);\n\t}\n\t100% {\n\t\ttransform: scale(0.5);\n\t}\n}\n@keyframes pops-anim-don-reverse {\n\t100% {\n\t\topacity: 0;\n\t\ttransform: matrix3d(0.7, 0, 0, 0, 0, 0.7, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t97.9167% {\n\t\ttransform: matrix3d(0.75266, 0, 0, 0, 0, 0.76342, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t95.8333% {\n\t\ttransform: matrix3d(0.81071, 0, 0, 0, 0, 0.84545, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t93.75% {\n\t\ttransform: matrix3d(0.86808, 0, 0, 0, 0, 0.9286, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t91.6667% {\n\t\ttransform: matrix3d(0.92038, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t89.5833% {\n\t\ttransform: matrix3d(0.96482, 0, 0, 0, 0, 1.05202, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t87.5% {\n\t\ttransform: matrix3d(1, 0, 0, 0, 0, 1.08204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t85.4167% {\n\t\ttransform: matrix3d(1.02563, 0, 0, 0, 0, 1.09149, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t83.3333% {\n\t\ttransform: matrix3d(1.04227, 0, 0, 0, 0, 1.08453, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t81.25% {\n\t\ttransform: matrix3d(1.05102, 0, 0, 0, 0, 1.06666, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t79.1667% {\n\t\ttransform: matrix3d(1.05334, 0, 0, 0, 0, 1.04355, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t77.0833% {\n\t\ttransform: matrix3d(1.05078, 0, 0, 0, 0, 1.02012, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t75% {\n\t\ttransform: matrix3d(1.04487, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t72.9167% {\n\t\ttransform: matrix3d(1.03699, 0, 0, 0, 0, 0.98534, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t70.8333% {\n\t\ttransform: matrix3d(1.02831, 0, 0, 0, 0, 0.97688, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t68.75% {\n\t\ttransform: matrix3d(1.01973, 0, 0, 0, 0, 0.97422, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t66.6667% {\n\t\ttransform: matrix3d(1.01191, 0, 0, 0, 0, 0.97618, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t64.5833% {\n\t\ttransform: matrix3d(1.00526, 0, 0, 0, 0, 0.98122, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t62.5% {\n\t\ttransform: matrix3d(1, 0, 0, 0, 0, 0.98773, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t60.4167% {\n\t\ttransform: matrix3d(0.99617, 0, 0, 0, 0, 0.99433, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t58.3333% {\n\t\ttransform: matrix3d(0.99368, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t56.25% {\n\t\ttransform: matrix3d(0.99237, 0, 0, 0, 0, 1.00413, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t54.1667% {\n\t\ttransform: matrix3d(0.99202, 0, 0, 0, 0, 1.00651, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t52.0833% {\n\t\ttransform: matrix3d(0.99241, 0, 0, 0, 0, 1.00726, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t50% {\n\t\topacity: 1;\n\t\ttransform: matrix3d(0.99329, 0, 0, 0, 0, 1.00671, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t47.9167% {\n\t\ttransform: matrix3d(0.99447, 0, 0, 0, 0, 1.00529, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t45.8333% {\n\t\ttransform: matrix3d(0.99577, 0, 0, 0, 0, 1.00346, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t43.75% {\n\t\ttransform: matrix3d(0.99705, 0, 0, 0, 0, 1.0016, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t41.6667% {\n\t\ttransform: matrix3d(0.99822, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t39.5833% {\n\t\ttransform: matrix3d(0.99921, 0, 0, 0, 0, 0.99884, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t37.5% {\n\t\ttransform: matrix3d(1, 0, 0, 0, 0, 0.99816, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t35.4167% {\n\t\ttransform: matrix3d(1.00057, 0, 0, 0, 0, 0.99795, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t33.3333% {\n\t\ttransform: matrix3d(1.00095, 0, 0, 0, 0, 0.99811, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t31.25% {\n\t\ttransform: matrix3d(1.00114, 0, 0, 0, 0, 0.99851, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t29.1667% {\n\t\ttransform: matrix3d(1.00119, 0, 0, 0, 0, 0.99903, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t27.0833% {\n\t\ttransform: matrix3d(1.00114, 0, 0, 0, 0, 0.99955, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t25% {\n\t\ttransform: matrix3d(1.001, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t22.9167% {\n\t\ttransform: matrix3d(1.00083, 0, 0, 0, 0, 1.00033, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t20.8333% {\n\t\ttransform: matrix3d(1.00063, 0, 0, 0, 0, 1.00052, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t18.75% {\n\t\ttransform: matrix3d(1.00044, 0, 0, 0, 0, 1.00058, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t16.6667% {\n\t\ttransform: matrix3d(1.00027, 0, 0, 0, 0, 1.00053, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t14.5833% {\n\t\ttransform: matrix3d(1.00012, 0, 0, 0, 0, 1.00042, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t12.5% {\n\t\ttransform: matrix3d(1, 0, 0, 0, 0, 1.00027, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t10.4167% {\n\t\ttransform: matrix3d(0.99991, 0, 0, 0, 0, 1.00013, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t8.33333% {\n\t\ttransform: matrix3d(0.99986, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t6.25% {\n\t\ttransform: matrix3d(0.99983, 0, 0, 0, 0, 0.99991, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t4.16667% {\n\t\ttransform: matrix3d(0.99982, 0, 0, 0, 0, 0.99985, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t2.08333% {\n\t\ttransform: matrix3d(0.99983, 0, 0, 0, 0, 0.99984, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n\t0% {\n\t\topacity: 1;\n\t\ttransform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n\t}\n}\n@keyframes pops-anim-roll-reverse {\n\t0% {\n\t\ttransform: perspective(1000px) rotate3d(1, 0, 0, 0deg);\n\t}\n\t100% {\n\t\ttransform: perspective(1000px) rotate3d(1, 0, 0, 90deg);\n\t}\n}\n@keyframes pops-anim-sandra-reverse {\n\t0% {\n\t\topacity: 1;\n\t\ttransform: scale3d(1, 1, 1);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\ttransform: scale3d(1.1, 1.1, 1);\n\t}\n}\n@keyframes pops-anim-gather-reverse {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: scale(5, 0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\ttransform: scale(5, 0);\n\t}\n}\n\n@-webkit-keyframes pops-motion-fadeInTop {\n\t0% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateY(-30px);\n\t\ttransform: translateY(-30px);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateX(0);\n\t\ttransform: translateX(0);\n\t}\n}\n@keyframes pops-motion-fadeInTop {\n\t0% {\n\t\topacity: 0;\n\t\ttransform: translateY(-30px);\n\t\t-ms-transform: translateY(-30px);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\ttransform: translateX(0);\n\t\t-ms-transform: translateX(0);\n\t}\n}\n@-webkit-keyframes pops-motion-fadeOutTop {\n\t0% {\n\t\topacity: 10;\n\t\t-webkit-transform: translateY(0);\n\t\ttransform: translateY(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateY(-30px);\n\t\ttransform: translateY(-30px);\n\t}\n}\n@keyframes pops-motion-fadeOutTop {\n\t0% {\n\t\topacity: 1;\n\t\ttransform: translateY(0);\n\t\t-ms-transform: translateY(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\ttransform: translateY(-30px);\n\t\t-ms-transform: translateY(-30px);\n\t}\n}\n@-webkit-keyframes pops-motion-fadeInBottom {\n\t0% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateY(20px);\n\t\ttransform: translateY(20px);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateY(0);\n\t\ttransform: translateY(0);\n\t}\n}\n@keyframes pops-motion-fadeInBottom {\n\t0% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateY(20px);\n\t\ttransform: translateY(20px);\n\t\t-ms-transform: translateY(20px);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateY(0);\n\t\ttransform: translateY(0);\n\t\t-ms-transform: translateY(0);\n\t}\n}\n@-webkit-keyframes pops-motion-fadeOutBottom {\n\t0% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateY(0);\n\t\ttransform: translateY(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateY(20px);\n\t\ttransform: translateY(20px);\n\t}\n}\n@keyframes pops-motion-fadeOutBottom {\n\t0% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateY(0);\n\t\ttransform: translateY(0);\n\t\t-ms-transform: translateY(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateY(20px);\n\t\ttransform: translateY(20px);\n\t\t-ms-transform: translateY(20px);\n\t}\n}\n@-webkit-keyframes pops-motion-fadeInLeft {\n\t0% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateX(-20px);\n\t\ttransform: translateX(-20px);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateX(0);\n\t\ttransform: translateX(0);\n\t}\n}\n@keyframes pops-motion-fadeInLeft {\n\t0% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateX(-30px);\n\t\ttransform: translateX(-30px);\n\t\t-ms-transform: translateX(-30px);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateX(0);\n\t\ttransform: translateX(0);\n\t\t-ms-transform: translateX(0);\n\t}\n}\n@-webkit-keyframes pops-motion-fadeOutLeft {\n\t0% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateX(0);\n\t\ttransform: translateX(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateX(-30px);\n\t\ttransform: translateX(-30px);\n\t}\n}\n@keyframes pops-motion-fadeOutLeft {\n\t0% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateX(0);\n\t\ttransform: translateX(0);\n\t\t-ms-transform: translateX(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateX(-20px);\n\t\ttransform: translateX(-20px);\n\t\t-ms-transform: translateX(-20px);\n\t}\n}\n@-webkit-keyframes pops-motion-fadeInRight {\n\t0% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateX(20px);\n\t\ttransform: translateX(20px);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateX(0);\n\t\ttransform: translateX(0);\n\t}\n}\n@keyframes pops-motion-fadeInRight {\n\t0% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateX(20px);\n\t\ttransform: translateX(20px);\n\t\t-ms-transform: translateX(20px);\n\t}\n\t100% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateX(0);\n\t\ttransform: translateX(0);\n\t\t-ms-transform: translateX(0);\n\t}\n}\n@-webkit-keyframes pops-motion-fadeOutRight {\n\t0% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateX(0);\n\t\ttransform: translateX(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateX(20px);\n\t\ttransform: translateX(20px);\n\t}\n}\n@keyframes pops-motion-fadeOutRight {\n\t0% {\n\t\topacity: 1;\n\t\t-webkit-transform: translateX(0);\n\t\ttransform: translateX(0);\n\t\t-ms-transform: translateX(0);\n\t}\n\t100% {\n\t\topacity: 0;\n\t\t-webkit-transform: translateX(20px);\n\t\ttransform: translateX(20px);\n\t\t-ms-transform: translateX(20px);\n\t}\n}\n\n/* 动画 */\n.pops-anim[anim=\"pops-anim-spread\"] {\n\tanimation: pops-anim-spread 0.3s;\n}\n.pops-anim[anim=\"pops-anim-shake\"] {\n\tanimation: pops-anim-shake 0.3s;\n}\n.pops-anim[anim=\"pops-anim-rolling-left\"] {\n\tanimation: pops-anim-rolling-left 0.3s;\n}\n.pops-anim[anim=\"pops-anim-rolling-right\"] {\n\tanimation: pops-anim-rolling-right 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-top\"] {\n\tanimation: pops-anim-slide-top 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-bottom\"] {\n\tanimation: pops-anim-slide-bottom 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-left\"] {\n\tanimation: pops-anim-slide-left 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-right\"] {\n\tanimation: pops-anim-slide-right 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein\"] {\n\tanimation: pops-anim-fadein 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein-zoom\"] {\n\tanimation: pops-anim-fadein-zoom 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein-alert\"] {\n\tanimation: pops-anim-fadein-alert 0.3s;\n}\n.pops-anim[anim=\"pops-anim-don\"] {\n\tanimation: pops-anim-don 0.3s;\n}\n.pops-anim[anim=\"pops-anim-roll\"] {\n\tanimation: pops-anim-roll 0.3s;\n}\n.pops-anim[anim=\"pops-anim-sandra\"] {\n\tanimation: pops-anim-sandra 0.3s;\n}\n.pops-anim[anim=\"pops-anim-gather\"] {\n\tanimation: pops-anim-gather 0.3s;\n}\n.pops-anim[anim=\"pops-anim-spread-reverse\"] {\n\tanimation: pops-anim-spread-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-shake-reverse\"] {\n\tanimation: pops-anim-shake-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-rolling-left-reverse\"] {\n\tanimation: pops-anim-rolling-left-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-rolling-right-reverse\"] {\n\tanimation: pops-anim-rolling-right-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-top-reverse\"] {\n\tanimation: pops-anim-slide-top-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-bottom-reverse\"] {\n\tanimation: pops-anim-slide-bottom-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-left-reverse\"] {\n\tanimation: pops-anim-slide-left-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-right-reverse\"] {\n\tanimation: pops-anim-slide-right-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein-reverse\"] {\n\tanimation: pops-anim-fadein-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein-zoom-reverse\"] {\n\tanimation: pops-anim-fadein-zoom-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein-alert-reverse\"] {\n\tanimation: pops-anim-fadein-alert-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-don-reverse\"] {\n\tanimation: pops-anim-don-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-roll-reverse\"] {\n\tanimation: pops-anim-roll-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-sandra-reverse\"] {\n\tanimation: pops-anim-sandra-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-gather-reverse\"] {\n\tanimation: pops-anim-gather-reverse 0.3s;\n}\n";
|
|
2818
|
+
var animCSS = "@keyframes rotating {\n 0% {\n transform: rotate(0);\n }\n to {\n transform: rotate(360deg);\n }\n}\n@keyframes iframeLoadingChange_85 {\n 0% {\n background: linear-gradient(to right, #4995dd, #fff, rgb(202 224 246));\n }\n 20% {\n background: linear-gradient(to right, #4995dd, #ead0d0, rgb(123 185 246));\n }\n 40% {\n background: linear-gradient(to right, #4995dd, #f4b7b7, rgb(112 178 244));\n }\n 60% {\n background: linear-gradient(to right, #4995dd, #ec9393, rgb(80 163 246));\n }\n 80% {\n background: linear-gradient(to right, #4995dd, #e87f7f, rgb(25 139 253));\n }\n 100% {\n background: linear-gradient(to right, #4995dd, #ee2c2c, rgb(0 124 247));\n }\n from {\n width: 75%;\n }\n to {\n width: 100%;\n }\n}\n@keyframes iframeLoadingChange {\n 0% {\n background: linear-gradient(to right, #4995dd, #fff, rgb(202 224 246));\n }\n 20% {\n background: linear-gradient(to right, #4995dd, #ead0d0, rgb(123 185 246));\n }\n 40% {\n background: linear-gradient(to right, #4995dd, #f4b7b7, rgb(112 178 244));\n }\n 60% {\n background: linear-gradient(to right, #4995dd, #ec9393, rgb(80 163 246));\n }\n 80% {\n background: linear-gradient(to right, #4995dd, #e87f7f, rgb(25 139 253));\n }\n 100% {\n background: linear-gradient(to right, #4995dd, #ee2c2c, rgb(0 124 247));\n }\n from {\n width: 0;\n }\n to {\n width: 75%;\n }\n}\n\n@keyframes searchSelectFalIn {\n from {\n opacity: 0;\n display: none;\n }\n to {\n display: block;\n opacity: 1;\n }\n}\n@keyframes searchSelectFalOut {\n from {\n display: block;\n opacity: 1;\n }\n to {\n opacity: 0;\n display: none;\n }\n}\n\n@keyframes pops-anim-wait-rotate {\n form {\n transform: rotate(0);\n }\n to {\n transform: rotate(360deg);\n }\n}\n@keyframes pops-anim-spread {\n 0% {\n opacity: 0;\n transform: scaleX(0);\n }\n 100% {\n opacity: 1;\n transform: scaleX(1);\n }\n}\n@keyframes pops-anim-shake {\n 0%,\n 100% {\n transform: translateX(0);\n }\n 10%,\n 30%,\n 50%,\n 70%,\n 90% {\n transform: translateX(-10px);\n }\n 20%,\n 40%,\n 60%,\n 80% {\n transform: translateX(10px);\n }\n}\n@keyframes pops-anim-rolling-left {\n 0% {\n opacity: 0;\n transform: translateX(-100%) rotate(-120deg);\n }\n 100% {\n opacity: 1;\n transform: translateX(0) rotate(0);\n }\n}\n@keyframes pops-anim-rolling-right {\n 0% {\n opacity: 0;\n transform: translateX(100%) rotate(120deg);\n }\n 100% {\n opacity: 1;\n transform: translateX(0) rotate(0);\n }\n}\n@keyframes pops-anim-slide-top {\n 0% {\n opacity: 0;\n transform: translateY(-200%);\n }\n 100% {\n opacity: 1;\n transform: translateY(0);\n }\n}\n@keyframes pops-anim-slide-bottom {\n 0% {\n opacity: 0;\n transform: translateY(200%);\n }\n 100% {\n opacity: 1;\n transform: translateY(0);\n }\n}\n@keyframes pops-anim-slide-left {\n 0% {\n opacity: 0;\n transform: translateX(-200%);\n }\n 100% {\n opacity: 1;\n transform: translateX(0);\n }\n}\n@keyframes pops-anim-slide-right {\n 0% {\n transform: translateX(200%);\n }\n 100% {\n opacity: 1;\n transform: translateX(0);\n }\n}\n@keyframes pops-anim-fadein {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n}\n@keyframes pops-anim-fadein-zoom {\n 0% {\n opacity: 0;\n transform: scale(0.5);\n }\n 100% {\n opacity: 1;\n transform: scale(1);\n }\n}\n@keyframes pops-anim-fadein-alert {\n 0% {\n transform: scale(0.5);\n }\n 45% {\n transform: scale(1.05);\n }\n 80% {\n transform: scale(0.95);\n }\n 100% {\n transform: scale(1);\n }\n}\n@keyframes pops-anim-don {\n 0% {\n opacity: 0;\n transform: matrix3d(0.7, 0, 0, 0, 0, 0.7, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 2.08333% {\n transform: matrix3d(0.75266, 0, 0, 0, 0, 0.76342, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 4.16667% {\n transform: matrix3d(0.81071, 0, 0, 0, 0, 0.84545, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 6.25% {\n transform: matrix3d(0.86808, 0, 0, 0, 0, 0.9286, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 8.33333% {\n transform: matrix3d(0.92038, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 10.4167% {\n transform: matrix3d(0.96482, 0, 0, 0, 0, 1.05202, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 12.5% {\n transform: matrix3d(1, 0, 0, 0, 0, 1.08204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 14.5833% {\n transform: matrix3d(1.02563, 0, 0, 0, 0, 1.09149, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 16.6667% {\n transform: matrix3d(1.04227, 0, 0, 0, 0, 1.08453, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 18.75% {\n transform: matrix3d(1.05102, 0, 0, 0, 0, 1.06666, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 20.8333% {\n transform: matrix3d(1.05334, 0, 0, 0, 0, 1.04355, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 22.9167% {\n transform: matrix3d(1.05078, 0, 0, 0, 0, 1.02012, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 25% {\n transform: matrix3d(1.04487, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 27.0833% {\n transform: matrix3d(1.03699, 0, 0, 0, 0, 0.98534, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 29.1667% {\n transform: matrix3d(1.02831, 0, 0, 0, 0, 0.97688, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 31.25% {\n transform: matrix3d(1.01973, 0, 0, 0, 0, 0.97422, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 33.3333% {\n transform: matrix3d(1.01191, 0, 0, 0, 0, 0.97618, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 35.4167% {\n transform: matrix3d(1.00526, 0, 0, 0, 0, 0.98122, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 37.5% {\n transform: matrix3d(1, 0, 0, 0, 0, 0.98773, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 39.5833% {\n transform: matrix3d(0.99617, 0, 0, 0, 0, 0.99433, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 41.6667% {\n transform: matrix3d(0.99368, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 43.75% {\n transform: matrix3d(0.99237, 0, 0, 0, 0, 1.00413, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 45.8333% {\n transform: matrix3d(0.99202, 0, 0, 0, 0, 1.00651, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 47.9167% {\n transform: matrix3d(0.99241, 0, 0, 0, 0, 1.00726, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 50% {\n opacity: 1;\n transform: matrix3d(0.99329, 0, 0, 0, 0, 1.00671, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 52.0833% {\n transform: matrix3d(0.99447, 0, 0, 0, 0, 1.00529, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 54.1667% {\n transform: matrix3d(0.99577, 0, 0, 0, 0, 1.00346, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 56.25% {\n transform: matrix3d(0.99705, 0, 0, 0, 0, 1.0016, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 58.3333% {\n transform: matrix3d(0.99822, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 60.4167% {\n transform: matrix3d(0.99921, 0, 0, 0, 0, 0.99884, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 62.5% {\n transform: matrix3d(1, 0, 0, 0, 0, 0.99816, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 64.5833% {\n transform: matrix3d(1.00057, 0, 0, 0, 0, 0.99795, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 66.6667% {\n transform: matrix3d(1.00095, 0, 0, 0, 0, 0.99811, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 68.75% {\n transform: matrix3d(1.00114, 0, 0, 0, 0, 0.99851, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 70.8333% {\n transform: matrix3d(1.00119, 0, 0, 0, 0, 0.99903, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 72.9167% {\n transform: matrix3d(1.00114, 0, 0, 0, 0, 0.99955, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 75% {\n transform: matrix3d(1.001, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 77.0833% {\n transform: matrix3d(1.00083, 0, 0, 0, 0, 1.00033, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 79.1667% {\n transform: matrix3d(1.00063, 0, 0, 0, 0, 1.00052, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 81.25% {\n transform: matrix3d(1.00044, 0, 0, 0, 0, 1.00058, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 83.3333% {\n transform: matrix3d(1.00027, 0, 0, 0, 0, 1.00053, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 85.4167% {\n transform: matrix3d(1.00012, 0, 0, 0, 0, 1.00042, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 87.5% {\n transform: matrix3d(1, 0, 0, 0, 0, 1.00027, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 89.5833% {\n transform: matrix3d(0.99991, 0, 0, 0, 0, 1.00013, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 91.6667% {\n transform: matrix3d(0.99986, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 93.75% {\n transform: matrix3d(0.99983, 0, 0, 0, 0, 0.99991, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 95.8333% {\n transform: matrix3d(0.99982, 0, 0, 0, 0, 0.99985, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 97.9167% {\n transform: matrix3d(0.99983, 0, 0, 0, 0, 0.99984, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 100% {\n opacity: 1;\n transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n}\n@keyframes pops-anim-roll {\n 0% {\n transform: perspective(1000px) rotate3d(1, 0, 0, 90deg);\n }\n 100% {\n transform: perspective(1000px) rotate3d(1, 0, 0, 0deg);\n }\n}\n@keyframes pops-anim-sandra {\n 0% {\n opacity: 0;\n transform: scale3d(1.1, 1.1, 1);\n }\n 100% {\n opacity: 1;\n transform: scale3d(1, 1, 1);\n }\n}\n@keyframes pops-anim-gather {\n 0% {\n opacity: 0;\n transform: scale(5, 0);\n }\n 100% {\n opacity: 1;\n transform: scale(1, 1);\n }\n}\n@keyframes pops-anim-spread-reverse {\n 0% {\n opacity: 1;\n transform: scaleX(1);\n }\n 100% {\n opacity: 0;\n transform: scaleX(0);\n }\n}\n@keyframes pops-anim-shake-reverse {\n 0%,\n 100% {\n transform: translateX(10px);\n }\n 10%,\n 30%,\n 50%,\n 70%,\n 90% {\n transform: translateX(-10px);\n }\n 20%,\n 40%,\n 60%,\n 80% {\n transform: translateX(0);\n }\n}\n@keyframes pops-anim-rolling-left-reverse {\n 0% {\n opacity: 1;\n transform: translateX(0) rotate(0);\n }\n 100% {\n opacity: 0;\n transform: translateX(-100%) rotate(-120deg);\n }\n}\n@keyframes pops-anim-rolling-right-reverse {\n 0% {\n opacity: 1;\n transform: translateX(0) rotate(0);\n }\n 100% {\n opacity: 0;\n transform: translateX(100%) rotate(120deg);\n }\n}\n@keyframes pops-anim-slide-top-reverse {\n 0% {\n opacity: 1;\n transform: translateY(0);\n }\n 100% {\n opacity: 0;\n transform: translateY(-200%);\n }\n}\n@keyframes pops-anim-slide-bottom-reverse {\n 0% {\n opacity: 1;\n transform: translateY(0);\n }\n 100% {\n opacity: 0;\n transform: translateY(200%);\n }\n}\n@keyframes pops-anim-slide-left-reverse {\n 0% {\n opacity: 1;\n transform: translateX(0);\n }\n 100% {\n opacity: 0;\n transform: translateX(-200%);\n }\n}\n@keyframes pops-anim-slide-right-reverse {\n 0% {\n opacity: 1;\n transform: translateX(0);\n }\n 100% {\n transform: translateX(200%);\n }\n}\n@keyframes pops-anim-fadein-reverse {\n 0% {\n opacity: 1;\n }\n 100% {\n opacity: 0;\n }\n}\n@keyframes pops-anim-fadein-zoom-reverse {\n 0% {\n opacity: 1;\n transform: scale(1);\n }\n 100% {\n opacity: 0;\n transform: scale(0.5);\n }\n}\n@keyframes pops-anim-fadein-alert-reverse {\n 0% {\n transform: scale(1);\n }\n 45% {\n transform: scale(0.95);\n }\n 80% {\n transform: scale(1.05);\n }\n 100% {\n transform: scale(0.5);\n }\n}\n@keyframes pops-anim-don-reverse {\n 100% {\n opacity: 0;\n transform: matrix3d(0.7, 0, 0, 0, 0, 0.7, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 97.9167% {\n transform: matrix3d(0.75266, 0, 0, 0, 0, 0.76342, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 95.8333% {\n transform: matrix3d(0.81071, 0, 0, 0, 0, 0.84545, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 93.75% {\n transform: matrix3d(0.86808, 0, 0, 0, 0, 0.9286, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 91.6667% {\n transform: matrix3d(0.92038, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 89.5833% {\n transform: matrix3d(0.96482, 0, 0, 0, 0, 1.05202, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 87.5% {\n transform: matrix3d(1, 0, 0, 0, 0, 1.08204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 85.4167% {\n transform: matrix3d(1.02563, 0, 0, 0, 0, 1.09149, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 83.3333% {\n transform: matrix3d(1.04227, 0, 0, 0, 0, 1.08453, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 81.25% {\n transform: matrix3d(1.05102, 0, 0, 0, 0, 1.06666, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 79.1667% {\n transform: matrix3d(1.05334, 0, 0, 0, 0, 1.04355, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 77.0833% {\n transform: matrix3d(1.05078, 0, 0, 0, 0, 1.02012, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 75% {\n transform: matrix3d(1.04487, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 72.9167% {\n transform: matrix3d(1.03699, 0, 0, 0, 0, 0.98534, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 70.8333% {\n transform: matrix3d(1.02831, 0, 0, 0, 0, 0.97688, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 68.75% {\n transform: matrix3d(1.01973, 0, 0, 0, 0, 0.97422, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 66.6667% {\n transform: matrix3d(1.01191, 0, 0, 0, 0, 0.97618, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 64.5833% {\n transform: matrix3d(1.00526, 0, 0, 0, 0, 0.98122, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 62.5% {\n transform: matrix3d(1, 0, 0, 0, 0, 0.98773, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 60.4167% {\n transform: matrix3d(0.99617, 0, 0, 0, 0, 0.99433, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 58.3333% {\n transform: matrix3d(0.99368, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 56.25% {\n transform: matrix3d(0.99237, 0, 0, 0, 0, 1.00413, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 54.1667% {\n transform: matrix3d(0.99202, 0, 0, 0, 0, 1.00651, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 52.0833% {\n transform: matrix3d(0.99241, 0, 0, 0, 0, 1.00726, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 50% {\n opacity: 1;\n transform: matrix3d(0.99329, 0, 0, 0, 0, 1.00671, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 47.9167% {\n transform: matrix3d(0.99447, 0, 0, 0, 0, 1.00529, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 45.8333% {\n transform: matrix3d(0.99577, 0, 0, 0, 0, 1.00346, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 43.75% {\n transform: matrix3d(0.99705, 0, 0, 0, 0, 1.0016, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 41.6667% {\n transform: matrix3d(0.99822, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 39.5833% {\n transform: matrix3d(0.99921, 0, 0, 0, 0, 0.99884, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 37.5% {\n transform: matrix3d(1, 0, 0, 0, 0, 0.99816, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 35.4167% {\n transform: matrix3d(1.00057, 0, 0, 0, 0, 0.99795, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 33.3333% {\n transform: matrix3d(1.00095, 0, 0, 0, 0, 0.99811, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 31.25% {\n transform: matrix3d(1.00114, 0, 0, 0, 0, 0.99851, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 29.1667% {\n transform: matrix3d(1.00119, 0, 0, 0, 0, 0.99903, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 27.0833% {\n transform: matrix3d(1.00114, 0, 0, 0, 0, 0.99955, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 25% {\n transform: matrix3d(1.001, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 22.9167% {\n transform: matrix3d(1.00083, 0, 0, 0, 0, 1.00033, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 20.8333% {\n transform: matrix3d(1.00063, 0, 0, 0, 0, 1.00052, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 18.75% {\n transform: matrix3d(1.00044, 0, 0, 0, 0, 1.00058, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 16.6667% {\n transform: matrix3d(1.00027, 0, 0, 0, 0, 1.00053, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 14.5833% {\n transform: matrix3d(1.00012, 0, 0, 0, 0, 1.00042, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 12.5% {\n transform: matrix3d(1, 0, 0, 0, 0, 1.00027, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 10.4167% {\n transform: matrix3d(0.99991, 0, 0, 0, 0, 1.00013, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 8.33333% {\n transform: matrix3d(0.99986, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 6.25% {\n transform: matrix3d(0.99983, 0, 0, 0, 0, 0.99991, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 4.16667% {\n transform: matrix3d(0.99982, 0, 0, 0, 0, 0.99985, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 2.08333% {\n transform: matrix3d(0.99983, 0, 0, 0, 0, 0.99984, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n 0% {\n opacity: 1;\n transform: matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1);\n }\n}\n@keyframes pops-anim-roll-reverse {\n 0% {\n transform: perspective(1000px) rotate3d(1, 0, 0, 0deg);\n }\n 100% {\n transform: perspective(1000px) rotate3d(1, 0, 0, 90deg);\n }\n}\n@keyframes pops-anim-sandra-reverse {\n 0% {\n opacity: 1;\n transform: scale3d(1, 1, 1);\n }\n 100% {\n opacity: 0;\n transform: scale3d(1.1, 1.1, 1);\n }\n}\n@keyframes pops-anim-gather-reverse {\n 0% {\n opacity: 0;\n transform: scale(5, 0);\n }\n 100% {\n opacity: 0;\n transform: scale(5, 0);\n }\n}\n\n@-webkit-keyframes pops-motion-fadeInTop {\n 0% {\n opacity: 0;\n -webkit-transform: translateY(-30px);\n transform: translateY(-30px);\n }\n 100% {\n opacity: 1;\n -webkit-transform: translateX(0);\n transform: translateX(0);\n }\n}\n@keyframes pops-motion-fadeInTop {\n 0% {\n opacity: 0;\n transform: translateY(-30px);\n -ms-transform: translateY(-30px);\n }\n 100% {\n opacity: 1;\n transform: translateX(0);\n -ms-transform: translateX(0);\n }\n}\n@-webkit-keyframes pops-motion-fadeOutTop {\n 0% {\n opacity: 10;\n -webkit-transform: translateY(0);\n transform: translateY(0);\n }\n 100% {\n opacity: 0;\n -webkit-transform: translateY(-30px);\n transform: translateY(-30px);\n }\n}\n@keyframes pops-motion-fadeOutTop {\n 0% {\n opacity: 1;\n transform: translateY(0);\n -ms-transform: translateY(0);\n }\n 100% {\n opacity: 0;\n transform: translateY(-30px);\n -ms-transform: translateY(-30px);\n }\n}\n@-webkit-keyframes pops-motion-fadeInBottom {\n 0% {\n opacity: 0;\n -webkit-transform: translateY(20px);\n transform: translateY(20px);\n }\n 100% {\n opacity: 1;\n -webkit-transform: translateY(0);\n transform: translateY(0);\n }\n}\n@keyframes pops-motion-fadeInBottom {\n 0% {\n opacity: 0;\n -webkit-transform: translateY(20px);\n transform: translateY(20px);\n -ms-transform: translateY(20px);\n }\n 100% {\n opacity: 1;\n -webkit-transform: translateY(0);\n transform: translateY(0);\n -ms-transform: translateY(0);\n }\n}\n@-webkit-keyframes pops-motion-fadeOutBottom {\n 0% {\n opacity: 1;\n -webkit-transform: translateY(0);\n transform: translateY(0);\n }\n 100% {\n opacity: 0;\n -webkit-transform: translateY(20px);\n transform: translateY(20px);\n }\n}\n@keyframes pops-motion-fadeOutBottom {\n 0% {\n opacity: 1;\n -webkit-transform: translateY(0);\n transform: translateY(0);\n -ms-transform: translateY(0);\n }\n 100% {\n opacity: 0;\n -webkit-transform: translateY(20px);\n transform: translateY(20px);\n -ms-transform: translateY(20px);\n }\n}\n@-webkit-keyframes pops-motion-fadeInLeft {\n 0% {\n opacity: 0;\n -webkit-transform: translateX(-20px);\n transform: translateX(-20px);\n }\n 100% {\n opacity: 1;\n -webkit-transform: translateX(0);\n transform: translateX(0);\n }\n}\n@keyframes pops-motion-fadeInLeft {\n 0% {\n opacity: 0;\n -webkit-transform: translateX(-30px);\n transform: translateX(-30px);\n -ms-transform: translateX(-30px);\n }\n 100% {\n opacity: 1;\n -webkit-transform: translateX(0);\n transform: translateX(0);\n -ms-transform: translateX(0);\n }\n}\n@-webkit-keyframes pops-motion-fadeOutLeft {\n 0% {\n opacity: 1;\n -webkit-transform: translateX(0);\n transform: translateX(0);\n }\n 100% {\n opacity: 0;\n -webkit-transform: translateX(-30px);\n transform: translateX(-30px);\n }\n}\n@keyframes pops-motion-fadeOutLeft {\n 0% {\n opacity: 1;\n -webkit-transform: translateX(0);\n transform: translateX(0);\n -ms-transform: translateX(0);\n }\n 100% {\n opacity: 0;\n -webkit-transform: translateX(-20px);\n transform: translateX(-20px);\n -ms-transform: translateX(-20px);\n }\n}\n@-webkit-keyframes pops-motion-fadeInRight {\n 0% {\n opacity: 0;\n -webkit-transform: translateX(20px);\n transform: translateX(20px);\n }\n 100% {\n opacity: 1;\n -webkit-transform: translateX(0);\n transform: translateX(0);\n }\n}\n@keyframes pops-motion-fadeInRight {\n 0% {\n opacity: 0;\n -webkit-transform: translateX(20px);\n transform: translateX(20px);\n -ms-transform: translateX(20px);\n }\n 100% {\n opacity: 1;\n -webkit-transform: translateX(0);\n transform: translateX(0);\n -ms-transform: translateX(0);\n }\n}\n@-webkit-keyframes pops-motion-fadeOutRight {\n 0% {\n opacity: 1;\n -webkit-transform: translateX(0);\n transform: translateX(0);\n }\n 100% {\n opacity: 0;\n -webkit-transform: translateX(20px);\n transform: translateX(20px);\n }\n}\n@keyframes pops-motion-fadeOutRight {\n 0% {\n opacity: 1;\n -webkit-transform: translateX(0);\n transform: translateX(0);\n -ms-transform: translateX(0);\n }\n 100% {\n opacity: 0;\n -webkit-transform: translateX(20px);\n transform: translateX(20px);\n -ms-transform: translateX(20px);\n }\n}\n\n/* 动画 */\n.pops-anim[anim=\"pops-anim-spread\"] {\n animation: pops-anim-spread 0.3s;\n}\n.pops-anim[anim=\"pops-anim-shake\"] {\n animation: pops-anim-shake 0.3s;\n}\n.pops-anim[anim=\"pops-anim-rolling-left\"] {\n animation: pops-anim-rolling-left 0.3s;\n}\n.pops-anim[anim=\"pops-anim-rolling-right\"] {\n animation: pops-anim-rolling-right 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-top\"] {\n animation: pops-anim-slide-top 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-bottom\"] {\n animation: pops-anim-slide-bottom 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-left\"] {\n animation: pops-anim-slide-left 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-right\"] {\n animation: pops-anim-slide-right 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein\"] {\n animation: pops-anim-fadein 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein-zoom\"] {\n animation: pops-anim-fadein-zoom 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein-alert\"] {\n animation: pops-anim-fadein-alert 0.3s;\n}\n.pops-anim[anim=\"pops-anim-don\"] {\n animation: pops-anim-don 0.3s;\n}\n.pops-anim[anim=\"pops-anim-roll\"] {\n animation: pops-anim-roll 0.3s;\n}\n.pops-anim[anim=\"pops-anim-sandra\"] {\n animation: pops-anim-sandra 0.3s;\n}\n.pops-anim[anim=\"pops-anim-gather\"] {\n animation: pops-anim-gather 0.3s;\n}\n.pops-anim[anim=\"pops-anim-spread-reverse\"] {\n animation: pops-anim-spread-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-shake-reverse\"] {\n animation: pops-anim-shake-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-rolling-left-reverse\"] {\n animation: pops-anim-rolling-left-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-rolling-right-reverse\"] {\n animation: pops-anim-rolling-right-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-top-reverse\"] {\n animation: pops-anim-slide-top-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-bottom-reverse\"] {\n animation: pops-anim-slide-bottom-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-left-reverse\"] {\n animation: pops-anim-slide-left-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-slide-right-reverse\"] {\n animation: pops-anim-slide-right-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein-reverse\"] {\n animation: pops-anim-fadein-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein-zoom-reverse\"] {\n animation: pops-anim-fadein-zoom-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-fadein-alert-reverse\"] {\n animation: pops-anim-fadein-alert-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-don-reverse\"] {\n animation: pops-anim-don-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-roll-reverse\"] {\n animation: pops-anim-roll-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-sandra-reverse\"] {\n animation: pops-anim-sandra-reverse 0.3s;\n}\n.pops-anim[anim=\"pops-anim-gather-reverse\"] {\n animation: pops-anim-gather-reverse 0.3s;\n}\n";
|
|
2838
2819
|
|
|
2839
2820
|
var alertCSS = "";
|
|
2840
2821
|
|
|
2841
2822
|
var confirmCSS = "";
|
|
2842
2823
|
|
|
2843
|
-
var promptCSS = ".pops[type-value=\"prompt\"] {\n
|
|
2824
|
+
var promptCSS = ".pops[type-value=\"prompt\"] {\n --input-color: #000000;\n --input-bg-color: none;\n --input-placeholder-color: #a1a4ac;\n}\n.pops[type-value=\"prompt\"] input[pops],\n.pops[type-value=\"prompt\"] textarea[pops] {\n width: 100%;\n height: 100%;\n outline: 0;\n border: 0;\n color: var(--input-color);\n background-color: var(--input-bg-color);\n}\n\n.pops[type-value=\"prompt\"] input[pops] {\n padding: 5px 10px;\n}\n.pops[type-value=\"prompt\"] textarea[pops] {\n padding: 5px 10px;\n resize: none;\n}\n\n.pops[type-value=\"prompt\"] input[pops]::placeholder,\n.pops[type-value=\"prompt\"] textarea[pops]::placeholder {\n color: var(--input-placeholder-color);\n}\n@media (prefers-color-scheme: dark) {\n .pops[type-value=\"prompt\"] {\n --input-color: #ffffff;\n --input-bg-color: #333333;\n --input-placeholder-color: #8d9095;\n }\n}\n";
|
|
2844
2825
|
|
|
2845
|
-
var loadingCSS = ".pops[type-value=\"loading\"] {\n
|
|
2826
|
+
var loadingCSS = ".pops[type-value=\"loading\"] {\n --loading-bd-color: rgba(0, 0, 0, 0.2);\n --loading-bg-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n --loading-box-shadow-color: rgb(0 0 0 / 50%);\n --loading-icon-color: rgba(100, 149, 237, 0.1);\n --loading-icon-bd-top-color: rgb(100, 149, 237, var(--pops-bd-opacity));\n}\n.pops[type-value=\"loading\"] {\n position: absolute;\n top: 272.5px;\n top: 50%;\n left: 26px;\n left: 50%;\n display: flex;\n overflow: hidden;\n padding: 10px 15px;\n max-width: 100%;\n max-height: 100%;\n min-width: 0;\n min-height: 0;\n border: 1px solid var(--loading-bd-color);\n border-radius: 5px;\n background-color: var(--loading-bg-color);\n box-shadow: 0 0 5px var(--loading-box-shadow-color);\n vertical-align: middle;\n transition: all 0.35s;\n transform: translate(-50%, -50%);\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n align-content: center;\n}\n.pops[type-value=\"loading\"]:before {\n float: left;\n display: inline-block;\n width: 2em;\n height: 2em;\n border: 0.3em solid var(--loading-icon-color);\n border-top: 0.3em solid var(--loading-icon-bd-top-color);\n border-radius: 50%;\n content: \" \";\n vertical-align: middle;\n font-size: inherit;\n animation: pops-anim-wait-rotate 1.2s linear infinite;\n}\n.pops[type-value=\"loading\"] .pops-loading-content {\n position: static;\n top: 0;\n bottom: 0;\n float: left;\n overflow: hidden;\n width: auto;\n font-size: inherit;\n line-height: normal;\n align-content: center;\n}\n\n@media (prefers-color-scheme: dark) {\n .pops[type-value=\"loading\"] {\n --loading-bg-color: #222222;\n }\n}\n";
|
|
2846
2827
|
|
|
2847
|
-
var iframeCSS = ".pops[type-value=\"iframe\"] {\n
|
|
2828
|
+
var iframeCSS = ".pops[type-value=\"iframe\"] {\n --container-title-height: 55px;\n transition:\n width 0.35s ease,\n height 0.35s ease;\n}\n.pops[type-value=\"iframe\"] .pops-content {\n overflow: hidden;\n}\n.pops-loading {\n position: absolute;\n top: 40px;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: 5;\n background-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n}\n.pops-loading:before {\n position: absolute;\n top: 50%;\n left: 50%;\n z-index: 3;\n display: block;\n margin: -20px 0 0 -20px;\n padding: 20px;\n border: 4px solid rgb(221, 221, 221, var(--pops-bd-opacity));\n border-radius: 50%;\n content: \"\";\n border-top-color: transparent;\n animation: pops-anim-wait-rotate 1.2s linear infinite;\n}\n.pops[type-value=\"iframe\"].pops[type-module=\"min\"] {\n bottom: 0;\n max-width: 200px;\n max-height: 53px;\n position: unset;\n}\n.pops[type-value=\"iframe\"].pops[type-module=\"min\"] .pops-header-control[data-type=\"min\"] {\n display: none;\n}\n.pops[type-value=\"iframe\"].pops-iframe-unset-top {\n top: unset !important;\n}\n.pops[type-value=\"iframe\"].pops-iframe-unset-left {\n left: unset !important;\n}\n.pops[type-value=\"iframe\"].pops-iframe-unset-transform {\n transform: none !important;\n}\n.pops[type-value=\"iframe\"].pops-iframe-unset-transition {\n transition: none !important;\n}\n.pops[type-value=\"iframe\"].pops[type-module=\"max\"] {\n width: 100% !important;\n height: 100% !important;\n}\n.pops[type-value=\"iframe\"] iframe[pops] {\n width: 100%;\n height: 100%;\n border: 0;\n}\n.pops-iframe-content-global-loading {\n position: absolute;\n top: 0;\n left: 0;\n z-index: 999999;\n width: 0;\n height: 4px;\n background: linear-gradient(to right, #4995dd, #fff, rgb(202 224 246));\n animation: iframeLoadingChange 2s forwards;\n}\n\n.pops-anim:has(.pops[type-value=\"iframe\"].pops[type-module=\"min\"]) {\n position: unset;\n}\n";
|
|
2848
2829
|
|
|
2849
|
-
var tooltipCSS = ".pops-tip {\n
|
|
2830
|
+
var tooltipCSS = ".pops-tip {\n --pops-bg-opacity: 1;\n --tooltip-color: #4e4e4e;\n --tooltip-bg-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n --tooltip-bd-radius: 2px;\n --tooltip-box-shadow-left-color: rgba(0, 0, 0, 0.24);\n --tooltip-box-shadow-right-color: rgba(0, 0, 0, 0.12);\n --tooltip-font-size: 14px;\n --tooltip-padding-top: 13px;\n --tooltip-padding-right: 13px;\n --tooltip-padding-bottom: 13px;\n --tooltip-padding-left: 13px;\n\n --tooltip-arrow-box-shadow-left-color: rgba(0, 0, 0, 0.24);\n --tooltip-arrow-box-shadow-right-color: rgba(0, 0, 0, 0.12);\n --tooltip-arrow--after-color: rgb(78, 78, 78);\n --tooltip-arrow--after-bg-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n --tooltip-arrow--after-width: 12px;\n --tooltip-arrow--after-height: 12px;\n}\n.pops-tip {\n padding: var(--tooltip-padding-top) var(--tooltip-padding-right) var(--tooltip-padding-bottom)\n var(--tooltip-padding-left);\n max-width: 400px;\n max-height: 300px;\n border-radius: var(--tooltip-bd-radius);\n background-color: var(--tooltip-bg-color);\n box-shadow:\n 0 1.5px 4px var(--tooltip-box-shadow-left-color),\n 0 1.5px 6px var(--tooltip-box-shadow-right-color);\n color: var(--tooltip-color);\n font-size: var(--tooltip-font-size);\n}\n.pops-tip[data-position=\"absolute\"] {\n position: absolute;\n}\n.pops-tip[data-position=\"fixed\"] {\n position: fixed;\n}\n\n.pops-tip .pops-tip-arrow {\n position: absolute;\n top: 100%;\n left: 50%;\n overflow: hidden;\n width: 100%;\n height: 12.5px;\n transform: translateX(-50%);\n}\n\n.pops-tip .pops-tip-arrow::after {\n position: absolute;\n top: 0;\n left: 50%;\n width: var(--tooltip-arrow--after-width);\n height: var(--tooltip-arrow--after-height);\n background: var(--tooltip-arrow--after-bg-color);\n color: var(--tooltip-arrow--after-color);\n box-shadow:\n 0 1px 7px var(--tooltip-arrow-box-shadow-left-color),\n 0 1px 7px var(--tooltip-arrow-box-shadow-right-color);\n content: \"\";\n transform: translateX(-50%) translateY(-50%) rotate(45deg);\n}\n\n.pops-tip .pops-tip-arrow[data-position=\"bottom\"] {\n position: absolute;\n top: 100%;\n left: 50%;\n overflow: hidden;\n width: 100%;\n height: 12.5px;\n transform: translateX(-50%);\n}\n\n.pops-tip .pops-tip-arrow[data-position=\"bottom\"]:after {\n position: absolute;\n top: 0;\n left: 50%;\n width: var(--tooltip-arrow--after-width);\n height: var(--tooltip-arrow--after-height);\n background: var(--tooltip-arrow--after-bg-color);\n box-shadow:\n 0 1px 7px var(--tooltip-arrow-box-shadow-left-color),\n 0 1px 7px var(--tooltip-arrow-box-shadow-right-color);\n content: \"\";\n transform: translateX(-50%) translateY(-50%) rotate(45deg);\n}\n\n.pops-tip .pops-tip-arrow[data-position=\"left\"] {\n top: 50%;\n left: -12.5px;\n width: 12.5px;\n height: 50px;\n transform: translateY(-50%);\n}\n\n.pops-tip .pops-tip-arrow[data-position=\"left\"]:after {\n position: absolute;\n top: 50%;\n left: 100%;\n content: \"\";\n}\n\n.pops-tip .pops-tip-arrow[data-position=\"right\"] {\n top: 50%;\n right: -12.5px;\n left: auto;\n width: 12.5px;\n height: 50px;\n transform: translateY(-50%);\n}\n\n.pops-tip .pops-tip-arrow[data-position=\"right\"]:after {\n position: absolute;\n top: 50%;\n left: 0;\n content: \"\";\n}\n\n.pops-tip .pops-tip-arrow[data-position=\"top\"] {\n top: -12.5px;\n left: 50%;\n transform: translateX(-50%);\n}\n\n.pops-tip .pops-tip-arrow[data-position=\"top\"]:after {\n position: absolute;\n top: 100%;\n left: 50%;\n content: \"\";\n}\n\n.pops-tip[data-motion] {\n -webkit-animation-duration: 0.25s;\n animation-duration: 0.25s;\n -webkit-animation-fill-mode: forwards;\n animation-fill-mode: forwards;\n}\n.pops-tip[data-motion=\"fadeOutRight\"] {\n -webkit-animation-name: pops-motion-fadeOutRight;\n animation-name: pops-motion-fadeOutRight;\n}\n.pops-tip[data-motion=\"fadeInTop\"] {\n -webkit-animation-name: pops-motion-fadeInTop;\n animation-name: pops-motion-fadeInTop;\n animation-timing-function: cubic-bezier(0.49, 0.49, 0.13, 1.3);\n}\n.pops-tip[data-motion=\"fadeOutTop\"] {\n -webkit-animation-name: pops-motion-fadeOutTop;\n animation-name: pops-motion-fadeOutTop;\n animation-timing-function: cubic-bezier(0.32, 0.37, 0.06, 0.87);\n}\n.pops-tip[data-motion=\"fadeInBottom\"] {\n -webkit-animation-name: pops-motion-fadeInBottom;\n animation-name: pops-motion-fadeInBottom;\n}\n.pops-tip[data-motion=\"fadeOutBottom\"] {\n -webkit-animation-name: pops-motion-fadeOutBottom;\n animation-name: pops-motion-fadeOutBottom;\n}\n.pops-tip[data-motion=\"fadeInLeft\"] {\n -webkit-animation-name: pops-motion-fadeInLeft;\n animation-name: pops-motion-fadeInLeft;\n}\n.pops-tip[data-motion=\"fadeOutLeft\"] {\n -webkit-animation-name: pops-motion-fadeOutLeft;\n animation-name: pops-motion-fadeOutLeft;\n}\n.pops-tip[data-motion=\"fadeInRight\"] {\n -webkit-animation-name: pops-motion-fadeInRight;\n animation-name: pops-motion-fadeInRight;\n}\n\n/* github的样式 */\n.pops-tip.github-tooltip {\n --tooltip-bg-opacity: 1;\n --tooltip-color: #ffffff;\n --tooltip-bg-color: rgb(36, 41, 47, var(--tooltip-bg-opacity));\n --tooltip-bd-radius: 6px;\n --tooltip-padding-top: 6px;\n --tooltip-padding-right: 8px;\n --tooltip-padding-bottom: 6px;\n --tooltip-padding-left: 8px;\n\n --tooltip-arrow--after-color: rgb(255, 255, 255);\n --tooltip-arrow--after-bg-color: rgb(36, 41, 47, var(--tooltip-bg-opacity));\n --tooltip-arrow--after-width: 8px;\n --tooltip-arrow--after-height: 8px;\n}\n\n@media (prefers-color-scheme: dark) {\n .pops-tip {\n --tooltip-color: #ffffff;\n --tooltip-bg-color: #fafafa;\n --tooltip-arrow--after-color: #fafafa;\n --tooltip-arrow--after-bg-color: rgb(250, 250, 250, var(--pops-bg-opacity));\n }\n}\n";
|
|
2850
2831
|
|
|
2851
|
-
var drawerCSS = ".pops[type-value=\"drawer\"] {\n
|
|
2832
|
+
var drawerCSS = ".pops[type-value=\"drawer\"] {\n position: fixed;\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n box-shadow:\n 0px 16px 48px 16px rgba(0, 0, 0, 0.08),\n 0px 12px 32px rgba(0, 0, 0, 0.12),\n 0px 8px 16px -8px rgba(0, 0, 0, 0.16);\n overflow: hidden;\n transition: all 0.3s;\n}\n\n.pops[type-value=\"drawer\"][direction=\"top\"] {\n width: 100%;\n left: 0;\n right: 0;\n top: 0;\n}\n.pops[type-value=\"drawer\"][direction=\"bottom\"] {\n width: 100%;\n left: 0;\n right: 0;\n bottom: 0;\n}\n.pops[type-value=\"drawer\"][direction=\"left\"] {\n height: 100%;\n top: 0;\n bottom: 0;\n left: 0;\n}\n.pops[type-value=\"drawer\"][direction=\"right\"] {\n height: 100%;\n top: 0;\n bottom: 0;\n right: 0;\n}\n";
|
|
2852
2833
|
|
|
2853
|
-
var folderCSS = ".pops-folder-list {\n
|
|
2834
|
+
var folderCSS = ".pops-folder-list {\n --folder-arrow-fill-color: #d4d7de;\n --folder-arrow-active-fill-color: #06a7ff;\n --header-breadcrumb-text-color: #06a7ff;\n --header-breadcrumb-all-files-text-color: var(--header-breadcrumb-text-color);\n --header-breadcrumb-all-files-first-text-color: var(--header-breadcrumb-text-color);\n --header-breadcrumb-all-files-last-text-color: #999999;\n --table-header-row-text-color: #818999;\n --table-body-td-text-color: rgb(247, 248, 250, var(--pops-bg-opacity));\n --table-body-th-text-color: rgb(247, 248, 250, var(--pops-bg-opacity));\n --table-body-row-text-color: #05082c;\n --table-body-row-file-name-text-color: #05082c;\n --table-body-row-hover-bd-color: rgb(245, 246, 247, var(--pops-bg-opacity));\n --table-body-row-hover-bg-color: rgb(245, 246, 247, var(--pops-bg-opacity));\n --table-body-row-file-name-hover-text-color: #06a7ff;\n --table-body-row-content-text-color: #818999;\n}\n.pops-folder-list .cursor-p {\n cursor: pointer;\n}\n.pops-folder-list a {\n background: 0 0;\n text-decoration: none;\n -webkit-tap-highlight-color: transparent;\n color: var(--header-breadcrumb-text-color);\n}\ntable.pops-folder-list-table__body,\ntable.pops-folder-list-table__header {\n width: 100%;\n table-layout: fixed;\n border-collapse: collapse;\n border-spacing: 0;\n padding: 0 20px;\n}\ntable.pops-folder-list-table__body,\ntable.pops-folder-list-table__header {\n height: 100%;\n background: 0 0;\n overflow: hidden;\n display: -webkit-box;\n display: -ms-flexbox;\n -ms-flex-direction: column;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n}\ntable.pops-folder-list-table__body {\n height: 100%;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n.pops-folder-list table tr {\n line-height: normal;\n align-content: center;\n}\n.pops-folder-list-table__header-row {\n height: 50px;\n line-height: normal;\n align-content: center;\n color: var(--table-header-row-text-color);\n text-align: left;\n font-size: 12px;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n.pops-folder-list-table__body-row {\n height: 50px;\n line-height: normal;\n align-content: center;\n color: var(--table-body-row-text-color);\n font-size: 12px;\n}\n.pops-folder-list-table__body-row:hover {\n background-color: var(--table-body-row-hover-bg-color);\n border-color: var(--table-body-row-hover-bd-color);\n border: 0;\n outline: none;\n}\n.pops-folder-list table th {\n border: 0;\n border-bottom: 1px solid var(--table-body-th-text-color);\n}\n.pops-folder-list table td {\n border: 0;\n border-bottom: 1px solid var(--table-body-td-text-color);\n position: relative;\n}\n.pops-folder-list .list-name-text {\n display: inline-block;\n padding-left: 12px;\n line-height: normal;\n align-content: center;\n max-width: 176px;\n}\n.pops-folder-list-file-name > div {\n display: flex;\n align-items: center;\n}\n\n.pops-mobile-folder-list-file-name {\n display: flex;\n align-items: center;\n}\n.pops-mobile-folder-list-file-name > div {\n display: flex;\n flex-wrap: wrap;\n justify-content: flex-start;\n align-items: flex-start;\n padding: 6px 0px;\n flex-direction: column;\n}\n.pops-mobile-folder-list-file-name img.pops-folder-list-file-icon {\n width: 45px;\n height: 45px;\n}\n.pops-mobile-folder-list-file-name a.pops-folder-list-file-name-title-text {\n padding-left: unset;\n max-width: 250px;\n overflow-x: hidden;\n font-weight: 400;\n line-height: unset;\n margin-bottom: 4px;\n white-space: normal;\n text-overflow: unset;\n}\n\n/* 修改滚动 */\n.pops-folder-content {\n overflow: hidden !important;\n}\n.pops-folder-content .pops-folder-list {\n height: 100%;\n display: flex;\n flex-direction: column;\n}\n.pops-folder-content .pops-folder-list-table__body-div {\n height: 100%;\n flex: 1 auto;\n overflow: auto;\n padding-bottom: 0;\n}\n.pops-mobile-folder-content .pops-folder-list-table__body-div {\n height: 100%;\n flex: 1 auto;\n overflow: auto;\n padding-bottom: 0;\n}\n.pops-folder-content table.pops-folder-list-table__body {\n overflow: auto;\n}\n.pops-folder-content .pops-folder-list-table__header-div {\n flex: 0;\n}\n.pops-mobile-folder-content .pops-folder-list-table__header-div {\n display: none;\n}\n\n.pops-folder-list .pops-folder-list-file-name-title-text {\n color: var(--table-body-row-file-name-text-color);\n}\n.pops-folder-list .pops-folder-list-file-name-title-text:hover {\n text-decoration: none;\n color: var(--table-body-row-file-name-hover-text-color);\n}\n.pops-folder-list .text-ellip {\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n.pops-folder-list .content {\n color: var(--table-body-row-content-text-color);\n position: relative;\n width: 100%;\n text-align: left;\n}\n.pops-folder-list .inline-block-v-middle {\n display: inline-block;\n vertical-align: middle;\n}\n.pops-folder-list .flex-a-i-center {\n display: flex;\n align-items: center;\n}\n.pops-folder-list .u-file-icon {\n display: inline-block;\n vertical-align: middle;\n}\n.pops-folder-list .u-file-icon--list {\n width: 32px;\n height: 32px;\n}\n.pops-folder-list .pops-folder-list-file-icon {\n line-height: normal;\n align-content: center;\n position: relative;\n vertical-align: middle;\n}\n.pops-folder-list .pops-folder-file-list-breadcrumb-primary {\n flex: 1;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n min-height: 17px;\n flex-wrap: wrap;\n}\n.pops-folder-list .pops-folder-list-table__sort {\n display: inline-flex;\n margin-left: 4px;\n flex-direction: column;\n}\n\n.pops-folder-list .pops-folder-icon-arrow {\n width: 10px;\n height: 10px;\n fill: var(--folder-arrow-fill-color);\n}\n.pops-folder-list .pops-folder-icon-active {\n fill: var(--folder-arrow-active-fill-color);\n}\n.pops-folder-list .pops-folder-file-list-breadcrumb {\n padding: 4px 20px;\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n display: -webkit-box;\n display: -webkit-flex;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -webkit-align-items: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-orient: horizontal;\n -webkit-box-direction: normal;\n -webkit-flex-direction: row;\n -ms-flex-direction: row;\n flex-direction: row;\n -webkit-box-pack: start;\n -webkit-justify-content: start;\n -ms-flex-pack: start;\n justify-content: flex-start;\n min-height: 35px;\n}\n.pops-folder-list .pops-folder-file-list-breadcrumb-allFiles {\n font-size: 12px;\n color: var(--header-breadcrumb-all-files-text-color);\n line-height: normal;\n align-content: center;\n font-weight: 700;\n display: inline-block;\n max-width: 140px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n word-wrap: normal;\n}\n.pops-folder-list .pops-folder-file-list-breadcrumb-allFiles:last-child a {\n color: var(--header-breadcrumb-all-files-last-text-color);\n}\n.pops-folder-list .pops-folder-file-list-breadcrumb-allFiles:first-child a {\n font-size: 14px;\n color: var(--header-breadcrumb-all-files-first-text-color);\n}\n.pops-folder-list .pops-folder-file-list-breadcrumb .iconArrow {\n width: 16px;\n height: 16px;\n}\n.pops-folder-list .iconArrow {\n background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAASCAMAAABYd88+AAAABGdBTUEAALGPC/xhBQAAAAFzUkdCAK7OHOkAAABFUExURUdwTOLi4uLi4t7e3uPj49/f397e3t3d3f///97e3vDw8N3d3d7e3t3d3d3d3ejo6N/f397e3t7e3t3d3d/f393d3d3d3RK+NoEAAAAWdFJOUwAnM4YPU/iQA+UIeMDaHhY41i7zX7UebpjFAAAAUElEQVQI15XOORaAIAwE0LATXHCd+x9VfCiksXCq+UUWou8oZ1vXHrt7YVBiYkW4gdMKYFIC4CSATWCNHWPuM6HuHkr1x3N0ZrBu/9gl0b9c3+kF7C7hS1YAAAAASUVORK5CYII=)\n 55% 50%/6px 9px no-repeat;\n}\n\n@media (prefers-color-scheme: dark) {\n .pops[type-value=\"folder\"] {\n --pops-title-border-color: rgb(73, 83, 102, var(--pops-bg-opacity));\n --pops-bottom-btn-controls-border-color: rgb(73, 83, 102, var(--pops-bg-opacity));\n }\n .pops-folder-list {\n --header-breadcrumb-text-color: #06a7ff;\n --header-breadcrumb-all-files-text-color: var(--header-breadcrumb-text-color);\n --header-breadcrumb-all-files-first-text-color: var(--header-breadcrumb-text-color);\n --header-breadcrumb-all-files-last-text-color: #818999;\n --table-body-row-text-color: #f7f8fa;\n --table-body-td-text-color: rgb(73, 83, 102, var(--pops-bg-opacity));\n --table-body-th-text-color: rgb(73, 83, 102, var(--pops-bg-opacity));\n --table-body-td-text-color: #495366;\n --table-body-row-hover-bd-color: #1f2022;\n --table-body-row-hover-bg-color: #1f2022;\n --table-body-row-file-name-text-color: #f7f8fa;\n }\n}\n";
|
|
2854
2835
|
|
|
2855
|
-
var panelCSS = ".pops[type-value=\"panel\"] {\n\t--pops-bg-color: #f2f2f2;\n\t--pops-color: #333333;\n\t--panel-title-bg-color: #ffffff;\n\n\t--panel-aside-bg-color: #ffffff;\n\t--panel-aside-hover-color: rgb(64, 158, 255);\n\t--panel-aside-hover-bg-color: rgba(64, 158, 255, 0.1);\n\n\t--pops-panel-forms-margin-top-bottom: 10px;\n\t--pops-panel-forms-margin-left-right: 20px;\n\t--pops-panel-forms-header-icon-size: calc(var(--pops-panel-forms-container-li-padding-left-right) + 1px);\n\t--pops-panel-forms-header-padding-top-bottom: 15px;\n\t--pops-panel-forms-header-padding-left-right: 10px;\n\t--pops-panel-forms-container-item-left-text-gap: 6px;\n\t--pops-panel-forms-container-item-left-desc-text-size: 0.8em;\n\t--pops-panel-forms-container-item-left-desc-text-color: #6c6c6c;\n\t--pops-panel-forms-container-item-bg-color: #ffffff;\n\t--pops-panel-forms-container-item-title-color: #333;\n\t--pops-panel-forms-container-item-border-radius: 6px;\n\t--pops-panel-forms-container-item-margin-top-bottom: 10px;\n\t--pops-panel-forms-container-item-margin-left-right: var(--pops-panel-forms-margin-left-right);\n\t--pops-panel-forms-container-li-border-color: var(--pops-bd-color);\n\t--pops-panel-forms-container-li-padding-top-bottom: 12px;\n\t--pops-panel-forms-container-li-padding-left-right: 16px;\n\n\t--pops-panel-forms-container-deepMenu-item-active-bg: #e9e9e9;\n}\n.pops[type-value=\"panel\"] {\n\tcolor: var(--pops-color);\n\tbackground: var(--pops-bg-color);\n}\n.pops[type-value] .pops-panel-title {\n\tbackground: var(--panel-title-bg-color);\n}\n\n/* ↓panel的CSS↓ */\n/* 左侧的列表 */\naside.pops-panel-aside {\n\tbox-sizing: border-box;\n\tflex-shrink: 0;\n\tmax-width: 200px;\n\tmin-width: 100px;\n\theight: 100%;\n\tbackground: var(--panel-aside-bg-color);\n\tborder-right: 1px solid var(--panel-aside-bg-color);\n\tfont-size: 0.9em;\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: space-between;\n}\naside.pops-panel-aside {\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-moz-user-select: none;\n\t-ms-user-select: none;\n}\naside.pops-panel-aside .pops-panel-aside-top-container {\n\toverflow: auto;\n}\naside.pops-panel-aside ul li {\n\tmargin: 6px 8px;\n\tborder-radius: 4px;\n\tpadding: 6px 10px;\n\tcursor: default;\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: flex-start;\n}\naside.pops-panel-aside .pops-is-visited,\naside.pops-panel-aside ul li:not(.pops-panel-disabled-aside-hover-css):hover {\n\tcolor: var(--panel-aside-hover-color);\n\tbackground: var(--panel-aside-hover-bg-color);\n}\n/* 左侧的列表 */\n\n.pops-panel-content {\n\tdisplay: flex;\n\tflex-direction: row;\n\tflex: 1;\n\toverflow: auto;\n\tflex-basis: auto;\n\tbox-sizing: border-box;\n\tmin-width: 0;\n\tbottom: 0 !important;\n}\n\n.pops-panel-section-wrapper {\n\twidth: 100%;\n\toverflow: hidden;\n\tdisplay: flex;\n\tflex-direction: column;\n}\n\nsection.pops-panel-container {\n\twidth: 100%;\n\toverflow: hidden;\n\tdisplay: flex;\n\tflex-direction: column;\n}\nsection.pops-panel-container .pops-panel-container-header-ul,\nsection.pops-panel-container .pops-panel-deepMenu-container-header-ul {\n\tborder-bottom: 1px solid rgba(223, 223, 223, var(--pops-bg-opacity));\n\tflex: 0 auto;\n}\nsection.pops-panel-container .pops-panel-container-header-ul li,\nsection.pops-panel-container .pops-panel-container-header-ul li.pops-panel-container-header-title-text {\n\tdisplay: flex;\n\tjustify-content: flex-start !important;\n\tmargin: 0px !important;\n\tpadding: var(--pops-panel-forms-header-padding-top-bottom)\n\t\tcalc(var(--pops-panel-forms-margin-left-right) + var(--pops-panel-forms-container-li-padding-left-right));\n\ttext-align: left;\n}\nsection.pops-panel-container ul.pops-panel-container-main-ul {\n\toverflow: auto;\n\t/*flex: 1;*/\n}\nsection.pops-panel-container > ul li:not(.pops-panel-forms-container-item) {\n\tdisplay: flex;\n\tjustify-content: space-between;\n\talign-items: center;\n\tmargin: var(--pops-panel-forms-margin-top-bottom)\n\t\tcalc(var(--pops-panel-forms-margin-left-right) + var(--pops-panel-forms-margin-left-right));\n\tgap: 10px;\n}\nsection.pops-panel-container .pops-panel-forms-container-item-header-text {\n\tmargin: 10px;\n\tmargin-left: calc(\n\t\tvar(--pops-panel-forms-margin-left-right) + var(--pops-panel-forms-container-li-padding-left-right)\n\t);\n\tfont-size: 0.9em;\n\ttext-align: left;\n\tcolor: var(--pops-panel-forms-container-item-title-color);\n}\nsection.pops-panel-container li.pops-panel-forms-container-item {\n\t/* 去除<li>左侧的圆点 */\n\tdisplay: block;\n}\nsection.pops-panel-container .pops-panel-forms-container-item ul.pops-panel-forms-container-item-formlist {\n\tborder-radius: var(--pops-panel-forms-container-item-border-radius);\n\tbackground: var(--pops-panel-forms-container-item-bg-color);\n\tmargin: var(--pops-panel-forms-container-item-margin-top-bottom) var(--pops-panel-forms-margin-left-right);\n}\nsection.pops-panel-container .pops-panel-forms-container-item ul.pops-panel-forms-container-item-formlist li {\n\tdisplay: flex;\n\tjustify-content: space-between;\n\talign-items: center;\n\tpadding: var(--pops-panel-forms-container-li-padding-top-bottom)\n\t\tvar(--pops-panel-forms-container-li-padding-left-right);\n\tmargin: 0px 0px;\n\tborder-bottom: 1px solid var(--pops-panel-forms-container-li-border-color);\n\ttext-align: left;\n}\n/*section.pops-panel-container\n\t.pops-panel-forms-container-item\n\tul\n\tli.pops-panel-deepMenu-nav-item {\n\tpadding: var(--pops-panel-forms-container-li-padding-top-bottom) 0px;\n\tmargin: 0px var(--pops-panel-forms-container-li-padding-left-right);\n\tborder-bottom: 1px solid var(--pops-panel-forms-container-li-border-color);\n}*/\nsection.pops-panel-container\n\t.pops-panel-forms-container-item\n\tul.pops-panel-forms-container-item-formlist\n\tli:last-child {\n\tborder: 0px;\n}\n/* 左侧的文字 */\nsection.pops-panel-container .pops-panel-item-left-text {\n\tdisplay: flex;\n\tflex-direction: column;\n\tgap: var(--pops-panel-forms-container-item-left-text-gap);\n}\n\n/* 左侧的主文字 */\n/*section.pops-panel-container .pops-panel-item-left-main-text {\n\t\n}*/\n/* 左侧的描述文字 */\nsection.pops-panel-container .pops-panel-item-left-desc-text {\n\tfont-size: var(--pops-panel-forms-container-item-left-desc-text-size);\n\tcolor: var(--pops-panel-forms-container-item-left-desc-text-color);\n}\n\n/* 折叠面板 */\nsection.pops-panel-container .pops-panel-forms-fold {\n\tborder-radius: var(--pops-panel-forms-container-item-border-radius);\n\tbackground: var(--pops-panel-forms-container-item-bg-color);\n\tmargin: var(--pops-panel-forms-margin-top-bottom) var(--pops-panel-forms-margin-left-right);\n}\nsection.pops-panel-container .pops-panel-forms-fold .pops-panel-forms-fold-container {\n\tdisplay: flex;\n\talign-items: center;\n\tfill: #6c6c6c;\n\tjustify-content: space-between;\n\tmargin: 0px var(--pops-panel-forms-container-li-padding-left-right) !important;\n\tpadding: var(--pops-panel-forms-container-li-padding-top-bottom) 0px !important;\n}\nsection.pops-panel-container .pops-panel-forms-fold[data-fold-enable] .pops-panel-forms-fold-container-icon {\n\ttransform: rotate(90deg);\n}\nsection.pops-panel-container .pops-panel-forms-fold .pops-panel-forms-fold-container-icon {\n\twidth: 15px;\n\theight: 15px;\n\tdisplay: flex;\n\talign-items: center;\n\ttransform: rotate(-90deg);\n\ttransition: transform 0.3s;\n}\n/* 折叠状态 */\nsection.pops-panel-container\n\t.pops-panel-forms-fold[data-fold-enable]\n\t.pops-panel-forms-container-item-formlist {\n\theight: 0;\n}\n/* 非折叠状态 */\nsection.pops-panel-container .pops-panel-forms-fold ul.pops-panel-forms-container-item-formlist {\n\tmargin: 0;\n}\nsection.pops-panel-container .pops-panel-forms-fold .pops-panel-forms-container-item-formlist {\n\ttransition: height 0.3s;\n\toverflow: hidden;\n\tborder-radius: unset;\n\tbackground: unset;\n\tmargin: 0;\n\theight: calc-size(auto, size);\n}\n/* 折叠面板 */\n\n/* 姑且认为小于600px的屏幕为移动端 */\n@media (max-width: 600px) {\n\t/* 兼容移动端CSS */\n\t.pops[type-value=\"panel\"] {\n\t\t--pops-panel-forms-margin-left-right: 10px;\n\t}\n\t.pops[type-value=\"panel\"] {\n\t\twidth: 92%;\n\t\twidth: 92vw;\n\t\twidth: 92dvw;\n\t}\n\t.pops[type-value=\"panel\"] .pops-panel-content aside.pops-panel-aside {\n\t\tmax-width: 20%;\n\t\tmin-width: auto;\n\t}\n\t.pops[type-value=\"panel\"] section.pops-panel-container .pops-panel-forms-container-item > div {\n\t\ttext-align: left;\n\t\t--pops-panel-forms-margin-left-right: 0px;\n\t}\n\t.pops[type-value=\"panel\"] section.pops-panel-container .pops-panel-forms-container-item ul {\n\t\tmargin: 0px !important;\n\t}\n\t.pops[type-value=\"panel\"] section.pops-panel-container > ul > li {\n\t\tmargin: 10px 10px;\n\t}\n\t.pops[type-value=\"panel\"] section.pops-panel-container > ul > li div:nth-child(2) {\n\t\tmax-width: 55%;\n\t}\n\t.pops[type-value=\"panel\"] section.pops-panel-container .pops-panel-select select {\n\t\tmin-width: 88px !important;\n\t\twidth: -webkit-fill-available;\n\t\twidth: -moz-available;\n\t}\n\t.pops[type-value=\"panel\"] section.pops-panel-container .pops-panel-container-header-ul li {\n\t\tfont-size: 16px;\n\t}\n\t.pops[type-value=\"panel\"] .pops-panel-title p[pops],\n\t.pops[type-value=\"panel\"] section.pops-panel-container > ul li,\n\t.pops[type-value=\"panel\"] aside.pops-panel-aside ul li {\n\t\tfont-size: 14px;\n\t}\n}\n/* switch的CSS */\n.pops-panel-switch {\n\t--panel-switch-core-bd-color: rgb(220, 223, 230, var(--pops-bd-opacity));\n\t--panel-switch-core-bg-color: rgb(220, 223, 230, var(--pops-bg-opacity));\n\t--panel-switch-circle-color: #dcdfe6;\n\t--panel-switch-circle-bg-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n\t--panel-switch-checked-circle-color: #409eff;\n\t--panel-switch-checked-core-bd-color: rgb(64, 158, 255, var(--pops-bd-opacity));\n\t--panel-switch-checked-core-bg-color: rgb(64, 158, 255, var(--pops-bg-opacity));\n}\n.pops-panel-switch {\n\tdisplay: inline-flex;\n\tflex-direction: row-reverse;\n\talign-items: center;\n\tposition: relative;\n\tfont-size: 14px;\n\tline-height: normal;\n\talign-content: center;\n\theight: 32px;\n\tvertical-align: middle;\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n\t-moz-user-select: none;\n}\n.pops-panel-switch input.pops-panel-switch__input {\n\tposition: absolute;\n\twidth: 0;\n\theight: 0;\n\topacity: 0;\n\tmargin: 0;\n}\n.pops-panel-switch:has(input.pops-panel-switch__input:disabled),\n.pops-panel-switch[data-disabled],\n.pops-panel-switch[data-disabled] .pops-panel-switch__core,\n.pops-panel-switch input.pops-panel-switch__input:disabled + .pops-panel-switch__core {\n\tcursor: not-allowed;\n\topacity: 0.6;\n}\n.pops-panel-switch span.pops-panel-switch__core {\n\tdisplay: inline-flex;\n\tposition: relative;\n\talign-items: center;\n\tmin-width: 40px;\n\theight: 20px;\n\tborder: 1px solid var(--panel-switch-core-bd-color);\n\toutline: 0;\n\tborder-radius: 10px;\n\tbox-sizing: border-box;\n\tbackground: var(--panel-switch-core-bg-color);\n\tcursor: pointer;\n\ttransition:\n\t\tborder-color 0.3s,\n\t\tbackground-color 0.3s;\n}\n.pops-panel-switch .pops-panel-switch__action {\n\tposition: absolute;\n\tleft: 1px;\n\tborder-radius: 100%;\n\ttransition: all 0.3s;\n\twidth: 16px;\n\theight: 16px;\n\tdisplay: flex;\n\tjustify-content: center;\n\talign-items: center;\n\tbackground-color: var(--panel-switch-circle-bg-color);\n\tcolor: var(--panel-switch-circle-color);\n}\n.pops-panel-switch.pops-panel-switch-is-checked span.pops-panel-switch__core {\n\tborder-color: var(--panel-switch-checked-core-bd-color);\n\tbackground-color: var(--panel-switch-checked-core-bg-color);\n}\n.pops-panel-switch.pops-panel-switch-is-checked .pops-panel-switch__action {\n\tleft: calc(100% - 17px);\n\tcolor: var(--panel-switch-checked-circle-color);\n}\n/* switch的CSS */\n\n/* slider旧的CSS */\nsection.pops-panel-container .pops-panel-slider:has(> input[type=\"range\"]) {\n\toverflow: hidden;\n\theight: 25px;\n\tline-height: normal;\n\talign-content: center;\n\tdisplay: flex;\n\talign-items: center;\n}\nsection.pops-panel-container .pops-panel-slider input[type=\"range\"] {\n\theight: 6px;\n\tbackground: rgb(228, 231, 237, var(--pops-bg-opacity));\n\toutline: 0;\n\t-webkit-appearance: none;\n\tappearance: none;\n\twidth: 100%;\n}\nsection.pops-panel-container .pops-panel-slider input[type=\"range\"]::-webkit-slider-thumb {\n\twidth: 20px;\n\theight: 20px;\n\tborder-radius: 50%;\n\tborder: 1px solid rgb(64, 158, 255, var(--pops-bd-opacity));\n\tbackground-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n\tbox-shadow:\n\t\t0 0 2px rgba(0, 0, 0, 0.3),\n\t\t0 3px 5px rgba(0, 0, 0, 0.2);\n\tcursor: pointer;\n\t-webkit-appearance: none;\n\tappearance: none;\n\tborder-image: linear-gradient(#409eff, #409eff) 0 fill/9 25 9 0/0 0 0 100vw;\n}\nsection.pops-panel-container .pops-panel-slider input[type=\"range\"]::-moz-range-thumb {\n\twidth: 20px;\n\theight: 20px;\n\tborder-radius: 50%;\n\tborder: 1px solid rgb(64, 159, 255, var(--pops-bd-opacity));\n\tbackground-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n\tbox-shadow:\n\t\t0 0 2px rgba(0, 0, 0, 0.3),\n\t\t0 3px 5px rgba(0, 0, 0, 0.2);\n\tcursor: pointer;\n\t-webkit-appearance: none;\n\tappearance: none;\n}\nsection.pops-panel-container .pops-panel-slider input[type=\"range\"]::-moz-range-progress {\n\theight: 6px;\n\tborder-image: linear-gradient(#409eff, #409eff) 0 fill/9 25 9 0/0 0 0 100vw;\n}\n/* slider旧的CSS */\n\n/* slider的CSS */\n.pops-slider {\n\t--pops-slider-color-white: #ffffff;\n\t--pops-slider-color-primary: #409eff;\n\t--pops-slider-color-info: #909399;\n\t--pops-slider-text-color-placeholder: #a8abb2;\n\t--pops-slider-border-color-light: #e4e7ed;\n\t--pops-slider-border-radius-circle: 100%;\n\t--pops-slider-transition-duration-fast: 0.2s;\n\n\t--pops-slider-main-bg-color: var(--pops-slider-color-primary);\n\t--pops-slider-runway-bg-color: var(--pops-slider-border-color-light);\n\t--pops-slider-stop-bg-color: var(--pops-slider-color-white);\n\t--pops-slider-disabled-color: var(--pops-slider-text-color-placeholder);\n\t--pops-slider-border-radius: 3px;\n\t--pops-slider-height: 6px;\n\t--pops-slider-button-size: 20px;\n\t--pops-slider-button-wrapper-size: 36px;\n\t--pops-slider-button-wrapper-offset: -15px;\n}\n\n.pops-slider {\n\twidth: 100%;\n\theight: 32px;\n\tdisplay: flex;\n\talign-items: center;\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-ms-user-select: none;\n\t-moz-user-select: none;\n}\n\n.pops-slider-width {\n\tflex: 0 0 52%;\n\tmargin-left: 10px;\n}\n\n.pops-slider__runway {\n\tflex: 1;\n\theight: var(--pops-slider-height);\n\tbackground-color: var(--pops-slider-runway-bg-color);\n\tborder-radius: var(--pops-slider-border-radius);\n\tposition: relative;\n\tcursor: pointer;\n}\n\n.pops-slider__runway.show-input {\n\tmargin-right: 30px;\n\twidth: auto;\n}\n\n.pops-slider__runway.pops-slider-is-disabled {\n\tcursor: default;\n}\n\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__bar {\n\tbackground-color: var(--pops-slider-disabled-color);\n}\n\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button {\n\tborder-color: var(--pops-slider-disabled-color);\n}\n\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button:hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.dragging {\n\tcursor: not-allowed;\n}\n\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button:hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.dragging {\n\ttransform: scale(1);\n}\n\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button:hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.dragging {\n\tcursor: not-allowed;\n}\n\n.pops-slider__input {\n\tflex-shrink: 0;\n\twidth: 130px;\n}\n\n.pops-slider__bar {\n\theight: var(--pops-slider-height);\n\tbackground-color: var(--pops-slider-main-bg-color);\n\tborder-top-left-radius: var(--pops-slider-border-radius);\n\tborder-bottom-left-radius: var(--pops-slider-border-radius);\n\tposition: absolute;\n}\n\n.pops-slider__button-wrapper {\n\theight: var(--pops-slider-button-wrapper-size);\n\twidth: var(--pops-slider-button-wrapper-size);\n\tposition: absolute;\n\tz-index: 1;\n\ttop: var(--pops-slider-button-wrapper-offset);\n\ttransform: translate(-50%);\n\tbackground-color: transparent;\n\ttext-align: center;\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-moz-user-select: none;\n\t-ms-user-select: none;\n\tline-height: normal;\n\toutline: none;\n}\n\n.pops-slider__button-wrapper:after {\n\tdisplay: inline-block;\n\tcontent: \"\";\n\theight: 100%;\n\tvertical-align: middle;\n}\n\n.pops-slider__button:hover,\n.pops-slider__button.hover {\n\tcursor: grab;\n}\n\n.pops-slider__button {\n\tdisplay: inline-block;\n\twidth: var(--pops-slider-button-size);\n\theight: var(--pops-slider-button-size);\n\tvertical-align: middle;\n\tborder: solid 2px var(--pops-slider-main-bg-color);\n\tbackground-color: var(--pops-slider-color-white);\n\tborder-radius: 50%;\n\tbox-sizing: border-box;\n\ttransition: var(--pops-slider-transition-duration-fast);\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-moz-user-select: none;\n\t-ms-user-select: none;\n}\n\n.pops-slider__button:hover,\n.pops-slider__button.hover,\n.pops-slider__button.dragging {\n\ttransform: scale(1.2);\n}\n\n.pops-slider__button:hover,\n.pops-slider__button.hover {\n\tcursor: grab;\n}\n\n.pops-slider__button.dragging {\n\tcursor: grabbing;\n}\n\n.pops-slider__stop {\n\tposition: absolute;\n\theight: var(--pops-slider-height);\n\twidth: var(--pops-slider-height);\n\tborder-radius: var(--pops-slider-border-radius-circle);\n\tbackground-color: var(--pops-slider-stop-bg-color);\n\ttransform: translate(-50%);\n}\n\n.pops-slider__marks {\n\ttop: 0;\n\tleft: 12px;\n\twidth: 18px;\n\theight: 100%;\n}\n\n.pops-slider__marks-text {\n\tposition: absolute;\n\ttransform: translate(-50%);\n\tfont-size: 14px;\n\tcolor: var(--pops-slider-color-info);\n\tmargin-top: 15px;\n\twhite-space: pre;\n}\n\n.pops-slider.is-vertical {\n\tposition: relative;\n\tdisplay: inline-flex;\n\twidth: auto;\n\theight: 100%;\n\tflex: 0;\n}\n\n.pops-slider.is-vertical .pops-slider__runway {\n\twidth: var(--pops-slider-height);\n\theight: 100%;\n\tmargin: 0 16px;\n}\n\n.pops-slider.is-vertical .pops-slider__bar {\n\twidth: var(--pops-slider-height);\n\theight: auto;\n\tborder-radius: 0 0 3px 3px;\n}\n\n.pops-slider.is-vertical .pops-slider__button-wrapper {\n\ttop: auto;\n\tleft: var(--pops-slider-button-wrapper-offset);\n\ttransform: translateY(50%);\n}\n\n.pops-slider.is-vertical .pops-slider__stop {\n\ttransform: translateY(50%);\n}\n\n.pops-slider.is-vertical .pops-slider__marks-text {\n\tmargin-top: 0;\n\tleft: 15px;\n\ttransform: translateY(50%);\n}\n\n.pops-slider--large {\n\theight: 40px;\n}\n\n.pops-slider--small {\n\theight: 24px;\n}\n/* slider的CSS */\n\n/* input的CSS */\n.pops-panel-input {\n\t--el-disabled-text-color: #a8abb2;\n\t--el-disabled-bg-color: #f5f7fa;\n\t--el-disabled-border-color: #e4e7ed;\n\n\t--pops-panel-components-input-text-color: #000000;\n\t--pops-panel-components-input-text-bg-color: transparent;\n\t--pops-panel-components-input-text-default-padding: 8px;\n\t--pops-panel-components-input-bd-color: #dcdfe6;\n\t--pops-panel-components-input-bg-color: #ffffff;\n\t--pops-panel-components-input-hover-bd-color: #c0c4cc;\n\t--pops-panel-components-input-focus-bd-color: #409eff;\n\t--pops-panel-components-input-suffix-color: #a8abb2;\n\t--pops-panel-components-input-suffix-bg-color: #ffffff;\n}\n.pops-panel-input {\n\tdisplay: flex;\n\talign-items: center;\n\tborder: 1px solid var(--pops-panel-components-input-bd-color);\n\tborder-radius: 4px;\n\tbackground-color: var(--pops-panel-components-input-bg-color);\n\tposition: relative;\n\tbox-shadow: none;\n}\n.pops-panel-input:hover {\n\tborder: 1px solid var(--pops-panel-components-input-hover-bd-color);\n}\n.pops-panel-input:has(input:disabled):hover {\n\t--pops-panel-components-input-hover-bd-color: var(--pops-panel-components-input-bd-color);\n}\n.pops-panel-input:has(input:focus) {\n\toutline: 0;\n\tborder: 1px solid var(--pops-panel-components-input-focus-bd-color);\n\tborder-radius: 4px;\n\tbox-shadow: none;\n}\n.pops-panel-input input {\n\tdisplay: inline-flex;\n\tjustify-content: center;\n\ttext-align: start;\n\talign-items: center;\n\talign-content: center;\n\twhite-space: nowrap;\n\tcursor: text;\n\tbox-sizing: border-box;\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-moz-user-select: none;\n\t-ms-user-select: none;\n\tvertical-align: middle;\n\t-webkit-appearance: none;\n\tappearance: none;\n\tcolor: var(--pops-panel-components-input-text-color);\n\tbackground-color: var(--pops-panel-components-input-text-bg-color);\n\toutline: 0;\n\ttransition: 0.1s;\n\tborder: 0;\n\tfont-size: 14px;\n\tfont-weight: 500;\n\tline-height: normal;\n\theight: 32px;\n\twidth: 100%;\n\tflex: 1;\n\t/*margin-right: calc(1em + 8px);*/\n\tmargin: 0px;\n\tpadding: var(--pops-panel-components-input-text-default-padding);\n}\n.pops-panel-input span.pops-panel-input__suffix {\n\tdisplay: inline-flex;\n\twhite-space: nowrap;\n\tflex-shrink: 0;\n\tflex-wrap: nowrap;\n\theight: 100%;\n\ttext-align: center;\n\tcolor: var(--pops-panel-components-input-suffix-color);\n\tbackground: var(--pops-panel-components-input-suffix-bg-color);\n\ttransition: all 0.3s;\n\tpointer-events: none;\n\tpadding: 0 8px;\n\tposition: absolute;\n\tright: 0px;\n\tborder-top-right-radius: 4px;\n\tborder-bottom-right-radius: 4px;\n\tborder: 1px solid transparent;\n}\n.pops-panel-input span.pops-panel-input__suffix-inner {\n\tpointer-events: all;\n\tdisplay: inline-flex;\n\talign-items: center;\n\tjustify-content: center;\n}\n/* 如果包含清空图标的按钮,则默认隐藏清空图标,当:hover、:focus、:focus-within、:active时显示清空图标 */\n.pops-panel-input span.pops-panel-input__suffix:has(svg[data-type=\"circleClose\"]) {\n\tdisplay: none;\n}\n.pops-panel-input:hover span.pops-panel-input__suffix:has(svg[data-type=\"circleClose\"]),\n.pops-panel-input:focus span.pops-panel-input__suffix:has(svg[data-type=\"circleClose\"]),\n.pops-panel-input:focus-within span.pops-panel-input__suffix:has(svg[data-type=\"circleClose\"]),\n.pops-panel-input:active span.pops-panel-input__suffix:has(svg[data-type=\"circleClose\"]) {\n\tdisplay: inline-flex;\n}\n.pops-panel-input .pops-panel-icon {\n\tcursor: pointer;\n}\n.pops-panel-input .pops-panel-icon {\n\theight: inherit;\n\tline-height: normal;\n\talign-content: center;\n\tdisplay: flex;\n\tjustify-content: center;\n\talign-items: center;\n\ttransition: all 0.3s;\n}\n.pops-panel-input .pops-panel-icon svg {\n\theight: 1em;\n\twidth: 1em;\n}\n\n.pops-input-disabled {\n\tbackground-color: var(--pops-components-is-disabled-bg-color);\n}\n.pops-panel-input.pops-input-disabled:hover {\n\t--pops-panel-components-input-hover-bd-color: var(--pops-panel-components-input-bd-color);\n}\n.pops-panel-input input:disabled,\n.pops-panel-input input:disabled + .pops-panel-input__suffix {\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-moz-user-select: none;\n\t-ms-user-select: none;\n\tcolor: var(--el-disabled-text-color);\n\t-webkit-text-fill-color: var(--el-disabled-text-color);\n\tcursor: not-allowed;\n}\n.pops-panel-input input:disabled + .pops-panel-input__suffix {\n\tdisplay: none;\n}\n/* input的CSS */\n\n/* textarea的CSS */\n.pops-panel-textarea {\n\t--pops-panel-components-textarea-text-color: #000000;\n\t--pops-panel-components-textarea-text-bg-color: #ffffff;\n\t--pops-panel-components-textarea-bd-color: #dcdfe6;\n\t--pops-panel-components-textarea-hover-bd-color: #c0c4cc;\n\t--pops-panel-components-textarea-focus-bd-color: #409eff;\n}\n.pops-panel-textarea textarea {\n\twidth: 100%;\n\t/*vertical-align: bottom;*/\n\tposition: relative;\n\tdisplay: block;\n\tresize: none;\n\tpadding: 5px 11px;\n\t/*line-height: 1;*/\n\tbox-sizing: border-box;\n\tfont-size: inherit;\n\tfont-family: inherit;\n\tcolor: var(--pops-panel-components-textarea-text-color);\n\tbackground-color: var(--pops-panel-components-textarea-text-bg-color);\n\tbackground-image: none;\n\t-webkit-appearance: none;\n\tappearance: none;\n\tbox-shadow: none;\n\tborder-radius: 0;\n\ttransition: box-shadow 0.2s cubic-bezier(0.645, 0.045, 0.355, 1);\n\tborder: 1px solid var(--pops-panel-components-textarea-bd-color);\n}\n.pops-panel-textarea textarea:hover {\n\tborder-color: var(--pops-panel-components-textarea-hover-bd-color);\n}\n.pops-panel-textarea:has(textarea:disabled):hover {\n\t--pops-panel-components-textarea-hover-bd-color: var(--pops-panel-components-textarea-bd-color);\n}\n.pops-panel-textarea-disable {\n\t--pops-panel-components-textarea-text-bg-color: var(--pops-components-is-disabled-bg-color) !important;\n\t--pops-panel-components-textarea-text-color: var(--pops-components-is-disabled-text-color);\n}\n.pops-panel-textarea-disable textarea {\n\tcursor: not-allowed;\n}\n.pops-panel-textarea textarea:focus {\n\toutline: 0;\n\tborder-color: var(--pops-panel-components-textarea-focus-bd-color);\n}\n/* textarea的CSS */\n\n/* select的CSS */\n.pops-panel-select {\n\t--pops-panel-components-select-text-color: #000000;\n\t--pops-panel-components-select-bd-color: rgb(184, 184, 184, var(--pops-bd-opacity));\n\t--pops-panel-components-select-hover-bd-color: rgb(184, 184, 184, var(--pops-bd-opacity));\n\t--pops-panel-components-select-bg-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n}\n.pops-panel-select {\n\tborder: 0;\n}\n.pops-panel-select select {\n\theight: 32px;\n\tline-height: normal;\n\talign-content: center;\n\tmin-width: 200px;\n\tborder: 1px solid var(--pops-panel-components-select-bd-color);\n\tborder-radius: 5px;\n\ttext-align: center;\n\toutline: 0;\n\tcolor: var(--pops-panel-components-select-text-color);\n\tbackground-color: var(--pops-panel-components-select-bg-color);\n\tbox-shadow: none;\n}\n.pops-panel-select select:hover {\n\tborder: 1px solid var(--pops-panel-components-select-hover-bd-color);\n}\n.pops-panel-select-disable {\n\t--pops-panel-components-select-text-color: var(--pops-components-is-disabled-text-color);\n\t--pops-panel-components-select-bg-color: var(--pops-components-is-disabled-bg-color);\n}\n.pops-panel-select-disable select {\n\tcursor: not-allowed;\n}\n.pops-panel-select-disable select:hover {\n\tbox-shadow: none;\n\t--pops-panel-components-select-hover-bd-color: var(--pops-panel-components-select-bd-color);\n}\n.pops-panel-select select:focus {\n\tborder: 1px solid rgb(64, 158, 255, var(--pops-bd-opacity));\n\tbox-shadow: none;\n}\n/* select的CSS */\n\n/* select-multiple的CSS*/\n.pops-panel-select-multiple {\n\t--el-border-radius-base: 4px;\n\t--el-fill-color-blank: #ffffff;\n\t--el-transition-duration: 0.3s;\n\t--el-border-color: #cbcbcb;\n\t--el-text-color-placeholder: #a8abb2;\n\t--color: inherit;\n\t--el-select-input-color: #a8abb2;\n\t--el-select-input-font-size: 14px;\n\t--el-text-color-regular: #606266;\n\t--el-color-info: #909399;\n\t--el-color-info-light-9: #f4f4f5;\n\t--el-color-info-light-8: #e9e9eb;\n\t--el-color-primary-light-9: #ecf5ff;\n\t--el-color-primary-light-8: #d9ecff;\n\t--el-color-primary: #409eff;\n\t--el-color-white: #ffffff;\n\twidth: 200px;\n}\n.pops-panel-select-multiple .el-select__wrapper {\n\tdisplay: flex;\n\talign-items: center;\n\tposition: relative;\n\tbox-sizing: border-box;\n\tcursor: pointer;\n\ttext-align: left;\n\tfont-size: 14px;\n\tpadding: 4px 12px;\n\tgap: 6px;\n\tmin-height: 32px;\n\tline-height: normal;\n\talign-content: center;\n\tborder-radius: var(--el-border-radius-base);\n\tbackground-color: var(--el-fill-color-blank);\n\ttransition: var(--el-transition-duration);\n\ttransform: translateZ(0);\n\tborder: 1px solid var(--el-border-color);\n}\n.pops-panel-select-multiple .el-select__wrapper.is-focused {\n\t--el-border-color: var(--el-color-primary);\n}\n.pops-panel-select-multiple .el-select__selection {\n\tposition: relative;\n\tdisplay: flex;\n\tflex-wrap: wrap;\n\talign-items: center;\n\tflex: 1;\n\tmin-width: 0;\n\tgap: 6px;\n}\n.pops-panel-select-multiple .el-select__selected-item {\n\tdisplay: flex;\n\tflex-wrap: wrap;\n\t-webkit-user-select: none;\n\tuser-select: none;\n}\n.pops-panel-select-multiple .el-select__selected-item.el-select__choose_tag .el-tag {\n\tmax-width: 200px;\n}\n.pops-panel-select-multiple .el-select__input-wrapper {\n\tmax-width: 100%;\n}\n.pops-panel-select-multiple .el-select__selection.is-near {\n\tmargin-left: -8px;\n}\n.pops-panel-select-multiple .el-select__placeholder {\n\tposition: absolute;\n\tdisplay: block;\n\ttop: 50%;\n\ttransform: translateY(-50%);\n\twidth: 100%;\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\twhite-space: nowrap;\n\tcolor: var(--el-input-text-color, var(--el-text-color-regular));\n}\n.pops-panel-select-multiple .el-select__placeholder.is-transparent {\n\t-webkit-user-select: none;\n\tuser-select: none;\n\tcolor: var(--el-text-color-placeholder);\n}\n.pops-panel-select-multiple .el-select__prefix,\n.pops-panel-select-multiple .el-select__suffix {\n\tdisplay: flex;\n\talign-items: center;\n\tflex-shrink: 0;\n\tgap: 6px;\n\tcolor: var(--el-input-icon-color, var(--el-text-color-placeholder));\n}\n.pops-panel-select-multiple .el-icon {\n\t--color: inherit;\n\theight: 1em;\n\twidth: 1em;\n\tline-height: normal;\n\talign-content: center;\n\tdisplay: inline-flex;\n\tjustify-content: center;\n\talign-items: center;\n\tposition: relative;\n\tfill: currentColor;\n\tcolor: var(--color);\n\tfont-size: inherit;\n}\n.pops-panel-select-multiple .el-icon svg {\n\theight: 1em;\n\twidth: 1em;\n}\n.pops-panel-select-multiple .el-select__caret {\n\tcolor: var(--el-select-input-color);\n\tfont-size: var(--el-select-input-font-size);\n\ttransition: var(--el-transition-duration);\n\ttransform: rotate(0);\n\tcursor: pointer;\n}\n.pops-panel-select-multiple .el-tag {\n\t--el-tag-font-size: 12px;\n\t--el-tag-border-radius: 4px;\n\t--el-tag-border-radius-rounded: 9999px;\n}\n.pops-panel-select-multiple .el-tag {\n\tbackground-color: var(--el-tag-bg-color);\n\tborder-color: var(--el-tag-border-color);\n\tcolor: var(--el-tag-text-color);\n\tdisplay: inline-flex;\n\tjustify-content: center;\n\talign-items: center;\n\tvertical-align: middle;\n\theight: 24px;\n\tpadding: 0 9px;\n\tfont-size: var(--el-tag-font-size);\n\tline-height: normal;\n\talign-content: center;\n\tborder-width: 1px;\n\tborder-style: solid;\n\tborder-radius: var(--el-tag-border-radius);\n\tbox-sizing: border-box;\n\twhite-space: nowrap;\n\t--el-icon-size: 14px;\n\t--el-tag-bg-color: var(--el-color-primary-light-9);\n\t--el-tag-border-color: var(--el-color-primary-light-8);\n\t--el-tag-hover-color: var(--el-color-primary);\n}\n.pops-panel-select-multiple .el-select__selection .el-tag {\n\tcursor: pointer;\n\tborder-color: transparent;\n}\n.pops-panel-select-multiple .el-tag.el-tag--info {\n\t--el-tag-bg-color: var(--el-color-info-light-9);\n\t--el-tag-border-color: var(--el-color-info-light-8);\n\t--el-tag-hover-color: var(--el-color-info);\n}\n.pops-panel-select-multiple .el-tag.el-tag--info {\n\t--el-tag-text-color: var(--el-color-info);\n}\n.pops-panel-select-multiple .el-tag.is-closable {\n\tpadding-right: 5px;\n}\n.pops-panel-select-multiple .el-select__selection .el-tag .el-tag__content {\n\tmin-width: 0;\n}\n.pops-panel-select-multiple .el-tag .el-tag__close {\n\tflex-shrink: 0;\n\tcolor: var(--el-tag-text-color);\n}\n.pops-panel-select-multiple .el-tag .el-tag__close:hover {\n\tcolor: var(--el-color-white);\n\tbackground-color: var(--el-tag-hover-color);\n}\n.pops-panel-select-multiple .el-tag .el-icon {\n\tborder-radius: 50%;\n\tcursor: pointer;\n\tfont-size: calc(var(--el-icon-size) - 2px);\n\theight: var(--el-icon-size);\n\twidth: var(--el-icon-size);\n}\n.pops-panel-select-multiple .el-tag .el-tag__close {\n\tmargin-left: 6px;\n}\n.pops-panel-select-multiple .el-select__tags-text {\n\tdisplay: block;\n\tline-height: normal;\n\talign-content: center;\n\toverflow: hidden;\n\ttext-overflow: ellipsis;\n\twhite-space: nowrap;\n}\n.pops-panel-select-multiple-disable {\n\t--el-fill-color-blank: #f5f7fa;\n\t--color: #a8abb2;\n\t--el-border-color: #cbcbcb;\n}\n.pops-panel-select-multiple-disable .el-tag.el-tag--info {\n\t--el-tag-bg-color: #e7e7e7;\n\t--el-tag-text-color: var(--pops-components-is-disabled-text-color);\n}\n.pops-panel-select-multiple-disable .el-select__selection .el-tag,\n.pops-panel-select-multiple-disable .el-tag .el-tag__close:hover,\n.pops-panel-select-multiple-disable .el-select__wrapper,\n.pops-panel-select-multiple-disable .el-select__caret {\n\tcursor: not-allowed;\n}\n/* select-multiple的CSS*/\n\n/* deepMenu的css */\n.pops-panel-deepMenu-nav-item {\n\tcursor: pointer;\n}\n.pops-panel-deepMenu-nav-item:active {\n\tbackground: var(--pops-panel-forms-container-deepMenu-item-active-bg);\n\tuser-select: none;\n\t-webkit-user-select: none;\n\t-moz-user-select: none;\n\t-ms-user-select: none;\n}\nsection.pops-panel-container .pops-panel-forms-container-item ul li.pops-panel-deepMenu-nav-item:active {\n\tpadding: var(--pops-panel-forms-container-li-padding-top-bottom)\n\t\tvar(--pops-panel-forms-container-li-padding-left-right);\n\tmargin: 0px;\n}\n/* 去除上个兄弟item的底部边框颜色 */\nsection.pops-panel-container\n\t.pops-panel-forms-container-item\n\tul\n\tli:has(+ .pops-panel-deepMenu-nav-item:active) {\n\tborder-bottom: 1px solid transparent;\n}\n/* 第一个和最后一个跟随圆角 */\nsection.pops-panel-container\n\t.pops-panel-forms-container-item\n\tul\n\tli.pops-panel-deepMenu-nav-item:first-child:active {\n\tborder-top-left-radius: var(--pops-panel-forms-container-item-border-radius);\n\tborder-top-right-radius: var(--pops-panel-forms-container-item-border-radius);\n}\nsection.pops-panel-container\n\t.pops-panel-forms-container-item\n\tul\n\tli.pops-panel-deepMenu-nav-item:last-child:active {\n\tborder-bottom-left-radius: var(--pops-panel-forms-container-item-border-radius);\n\tborder-bottom-right-radius: var(--pops-panel-forms-container-item-border-radius);\n}\n.pops-panel-deepMenu-nav-item .pops-panel-deepMenu {\n\tdisplay: flex;\n\talign-items: center;\n\tcolor: #6c6c6c;\n\tfill: #6c6c6c;\n}\n.pops-panel-deepMenu-nav-item .pops-panel-deepMenu-arrowRight-icon {\n\twidth: 15px;\n\theight: 15px;\n\tdisplay: flex;\n\talign-items: center;\n}\nsection.pops-panel-deepMenu-container\n\t.pops-panel-container-header-ul\n\tli.pops-panel-deepMenu-container-header {\n\tdisplay: flex;\n\talign-items: center;\n\twidth: -webkit-fill-available;\n\twidth: -moz-available;\n\tpadding: var(--pops-panel-forms-header-padding-top-bottom)\n\t\tcalc(\n\t\t\tvar(--pops-panel-forms-margin-left-right) + var(--pops-panel-forms-container-li-padding-left-right) -\n\t\t\t\tvar(--pops-panel-forms-header-icon-size)\n\t\t);\n\tgap: 0px;\n}\n.pops-panel-deepMenu-container .pops-panel-deepMenu-container-left-arrow-icon {\n\twidth: var(--pops-panel-forms-header-icon-size);\n\theight: var(--pops-panel-forms-header-icon-size);\n\tdisplay: flex;\n\talign-items: center;\n\tcursor: pointer;\n}\n/* 修复safari上图标大小未正常显示 */\n.pops-panel-deepMenu-container .pops-panel-deepMenu-container-left-arrow-icon > svg {\n\twidth: inherit;\n\theight: inherit;\n}\n/* deepMenu的css */\n\n/* 文字对齐 */\n.pops-panel-item-left-desc-text:has(code) {\n\tdisplay: flex;\n\talign-items: baseline;\n\tflex-wrap: wrap;\n}\n\n@media (prefers-color-scheme: dark) {\n\t.pops[type-value=\"panel\"] {\n\t\t--pops-bg-color: #000000;\n\t\t--pops-color: #f2f2f2;\n\t\t--panel-title-bg-color: #000000;\n\t\t--panel-aside-bg-color: #262626;\n\t\t--pops-panel-forms-container-item-left-desc-text-color: #6c6c6c;\n\t\t--pops-panel-forms-container-item-bg-color: #262626;\n\t\t--pops-panel-forms-container-item-title-color: #c1c1c1;\n\n\t\t--pops-panel-forms-container-li-border-color: rgb(51, 51, 51, var(--pops-bd-opacity));\n\t\t--pops-panel-forms-container-deepMenu-item-active-bg: #333333;\n\t}\n\t.pops[type-value=\"panel\"] .pops-panel-deepMenu-container .pops-panel-deepMenu-container-left-arrow-icon {\n\t\tfill: #f2f2f2;\n\t}\n\n\t/* switch的CSS */\n\t.pops-panel-switch {\n\t\t--panel-switch-core-bd-color: rgb(220, 223, 230, var(--pops-bd-opacity));\n\t\t--panel-switch-core-bg-color: rgb(220, 223, 230, var(--pops-bg-opacity));\n\t\t--panel-switch-circle-color: #dcdfe6;\n\t\t--panel-switch-circle-bg-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n\t\t--panel-switch-checked-circle-color: #409eff;\n\t\t--panel-switch-checked-core-bd-color: rgb(64, 158, 255, var(--pops-bd-opacity));\n\t\t--panel-switch-checked-core-bg-color: rgb(64, 158, 255, var(--pops-bg-opacity));\n\t}\n\t/* select的CSS */\n\t.pops-panel-select {\n\t\t--pops-panel-components-select-text-color: #f2f2f2;\n\t\t--pops-panel-components-select-bd-color: rgb(51, 51, 51, var(--pops-bd-opacity));\n\t\t--pops-panel-components-select-bg-color: #141414;\n\t}\n\t/* select-multiple的CSS*/\n\t.pops-panel-select-multiple {\n\t\t--el-fill-color-blank: #141414;\n\t\t--el-border-color: #4c4d4f;\n\t\t--el-text-color-placeholder: #a8abb2;\n\t\t--el-select-input-color: #a8abb2;\n\t\t--el-text-color-regular: #606266;\n\t\t--el-color-info: #909399;\n\t\t--el-color-info-light-8: #e9e9eb;\n\t\t--el-color-primary-light-9: #ecf5ff;\n\t\t--el-color-primary-light-8: #d9ecff;\n\t\t--el-color-primary: #409eff;\n\t\t--el-color-white: #ffffff;\n\t}\n\t.pops-panel-select-multiple .el-tag {\n\t\t--el-color-info-light-9: #202121;\n\t}\n\t.pops-panel-select-multiple-disable {\n\t\t--el-border-color: rgb(51, 51, 51, var(--pops-bd-opacity));\n\t}\n\t.pops-panel-select-multiple-disable .el-tag.el-tag--info {\n\t\t--el-tag-bg-color: #2f2f2f;\n\t}\n\t/* select-multiple的CSS*/\n\t/* slider的CSS */\n\t.pops-slider {\n\t\t--pops-slider-border-color-light: #414243;\n\t}\n\t/* input的CSS */\n\t.pops-panel-input {\n\t\t--pops-panel-components-input-text-color: #f2f2f2;\n\t\t--pops-panel-components-input-bd-color: #4f5052;\n\t\t--pops-panel-components-input-bg-color: #141414;\n\t\t--pops-panel-components-input-hover-bd-color: #6f7175;\n\t\t--pops-panel-components-input-focus-bd-color: #409eff;\n\t\t--pops-panel-components-input-suffix-color: #a8abb2;\n\t}\n\t/* textarea的CSS */\n\t.pops-panel-textarea {\n\t\t--pops-panel-components-textarea-text-color: #f2f2f2;\n\t\t--pops-panel-components-textarea-text-bg-color: #141414;\n\t\t--pops-panel-components-textarea-bd-color: #4f5052;\n\t\t--pops-panel-components-textarea-hover-bd-color: #6f7175;\n\t\t--pops-panel-components-textarea-focus-bd-color: #409eff;\n\t}\n\t.pops-panel-textarea-disable {\n\t\t--pops-panel-components-textarea-text-color: var(--pops-components-is-disabled-text-color);\n\t\t--pops-panel-components-textarea-text-bg-color: var(--pops-components-is-disabled-bg-color);\n\t}\n\t/* slider */\n\t.pops-slider {\n\t\t--pops-slider-text-color-placeholder: #8d9095;\n\t}\n}\n";
|
|
2836
|
+
var panelCSS = ".pops[type-value=\"panel\"] {\n --pops-bg-color: #f2f2f2;\n --pops-color: #333333;\n --panel-title-bg-color: #ffffff;\n\n --panel-aside-bg-color: #ffffff;\n --panel-aside-hover-color: rgb(64, 158, 255);\n --panel-aside-hover-bg-color: rgba(64, 158, 255, 0.1);\n\n --pops-panel-forms-margin-top-bottom: 10px;\n --pops-panel-forms-margin-left-right: 20px;\n --pops-panel-forms-header-icon-size: calc(var(--pops-panel-forms-container-li-padding-left-right) + 1px);\n --pops-panel-forms-header-padding-top-bottom: 15px;\n --pops-panel-forms-header-padding-left-right: 10px;\n --pops-panel-forms-container-item-left-text-gap: 6px;\n --pops-panel-forms-container-item-left-desc-text-size: 0.8em;\n --pops-panel-forms-container-item-left-desc-text-color: #6c6c6c;\n --pops-panel-forms-container-item-bg-color: #ffffff;\n --pops-panel-forms-container-item-title-color: #333;\n --pops-panel-forms-container-item-border-radius: 6px;\n --pops-panel-forms-container-item-margin-top-bottom: 10px;\n --pops-panel-forms-container-item-margin-left-right: var(--pops-panel-forms-margin-left-right);\n --pops-panel-forms-container-li-border-color: var(--pops-bd-color);\n --pops-panel-forms-container-li-padding-top-bottom: 12px;\n --pops-panel-forms-container-li-padding-left-right: 16px;\n\n --pops-panel-forms-container-deepMenu-item-active-bg: #e9e9e9;\n}\n.pops[type-value=\"panel\"] {\n color: var(--pops-color);\n background: var(--pops-bg-color);\n}\n.pops[type-value] .pops-panel-title {\n background: var(--panel-title-bg-color);\n}\n\n/* ↓panel的CSS↓ */\n/* 左侧的列表 */\naside.pops-panel-aside {\n box-sizing: border-box;\n flex-shrink: 0;\n max-width: 200px;\n min-width: 100px;\n height: 100%;\n background: var(--panel-aside-bg-color);\n border-right: 1px solid var(--panel-aside-bg-color);\n font-size: 0.9em;\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n}\naside.pops-panel-aside {\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\naside.pops-panel-aside .pops-panel-aside-top-container {\n overflow: auto;\n}\naside.pops-panel-aside ul li {\n margin: 6px 8px;\n border-radius: 4px;\n padding: 6px 10px;\n cursor: default;\n display: flex;\n align-items: center;\n justify-content: flex-start;\n}\naside.pops-panel-aside .pops-is-visited,\naside.pops-panel-aside ul li:not(.pops-panel-disabled-aside-hover-css):hover {\n color: var(--panel-aside-hover-color);\n background: var(--panel-aside-hover-bg-color);\n}\n/* 左侧的列表 */\n\n.pops-panel-content {\n display: flex;\n flex-direction: row;\n flex: 1;\n overflow: auto;\n flex-basis: auto;\n box-sizing: border-box;\n min-width: 0;\n bottom: 0 !important;\n}\n\n.pops-panel-section-wrapper {\n width: 100%;\n overflow: hidden;\n display: flex;\n flex-direction: column;\n}\n\nsection.pops-panel-container {\n width: 100%;\n overflow: hidden;\n display: flex;\n flex-direction: column;\n}\nsection.pops-panel-container .pops-panel-container-header-ul,\nsection.pops-panel-container .pops-panel-deepMenu-container-header-ul {\n border-bottom: 1px solid rgba(223, 223, 223, var(--pops-bg-opacity));\n flex: 0 auto;\n}\nsection.pops-panel-container .pops-panel-container-header-ul li,\nsection.pops-panel-container .pops-panel-container-header-ul li.pops-panel-container-header-title-text {\n display: flex;\n justify-content: flex-start !important;\n margin: 0px !important;\n padding: var(--pops-panel-forms-header-padding-top-bottom)\n calc(var(--pops-panel-forms-margin-left-right) + var(--pops-panel-forms-container-li-padding-left-right));\n text-align: left;\n}\nsection.pops-panel-container ul.pops-panel-container-main-ul {\n overflow: auto;\n /*flex: 1;*/\n}\nsection.pops-panel-container > ul li:not(.pops-panel-forms-container-item) {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin: var(--pops-panel-forms-margin-top-bottom)\n calc(var(--pops-panel-forms-margin-left-right) + var(--pops-panel-forms-margin-left-right));\n gap: 10px;\n}\nsection.pops-panel-container .pops-panel-forms-container-item-header-text {\n margin: 10px;\n margin-left: calc(\n var(--pops-panel-forms-margin-left-right) + var(--pops-panel-forms-container-li-padding-left-right)\n );\n font-size: 0.9em;\n text-align: left;\n color: var(--pops-panel-forms-container-item-title-color);\n}\nsection.pops-panel-container li.pops-panel-forms-container-item {\n /* 去除<li>左侧的圆点 */\n display: block;\n}\nsection.pops-panel-container .pops-panel-forms-container-item ul.pops-panel-forms-container-item-formlist {\n border-radius: var(--pops-panel-forms-container-item-border-radius);\n background: var(--pops-panel-forms-container-item-bg-color);\n margin: var(--pops-panel-forms-container-item-margin-top-bottom) var(--pops-panel-forms-margin-left-right);\n}\nsection.pops-panel-container .pops-panel-forms-container-item ul.pops-panel-forms-container-item-formlist li {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: var(--pops-panel-forms-container-li-padding-top-bottom)\n var(--pops-panel-forms-container-li-padding-left-right);\n margin: 0px 0px;\n border-bottom: 1px solid var(--pops-panel-forms-container-li-border-color);\n text-align: left;\n}\n/*section.pops-panel-container\n\t.pops-panel-forms-container-item\n\tul\n\tli.pops-panel-deepMenu-nav-item {\n\tpadding: var(--pops-panel-forms-container-li-padding-top-bottom) 0px;\n\tmargin: 0px var(--pops-panel-forms-container-li-padding-left-right);\n\tborder-bottom: 1px solid var(--pops-panel-forms-container-li-border-color);\n}*/\nsection.pops-panel-container\n .pops-panel-forms-container-item\n ul.pops-panel-forms-container-item-formlist\n li:last-child {\n border: 0px;\n}\n/* 左侧的文字 */\nsection.pops-panel-container .pops-panel-item-left-text {\n display: flex;\n flex-direction: column;\n gap: var(--pops-panel-forms-container-item-left-text-gap);\n}\n\n/* 左侧的主文字 */\n/*section.pops-panel-container .pops-panel-item-left-main-text {\n\t\n}*/\n/* 左侧的描述文字 */\nsection.pops-panel-container .pops-panel-item-left-desc-text {\n font-size: var(--pops-panel-forms-container-item-left-desc-text-size);\n color: var(--pops-panel-forms-container-item-left-desc-text-color);\n}\n\n/* 折叠面板 */\nsection.pops-panel-container .pops-panel-forms-fold {\n border-radius: var(--pops-panel-forms-container-item-border-radius);\n background: var(--pops-panel-forms-container-item-bg-color);\n margin: var(--pops-panel-forms-margin-top-bottom) var(--pops-panel-forms-margin-left-right);\n}\nsection.pops-panel-container .pops-panel-forms-fold .pops-panel-forms-fold-container {\n display: flex;\n align-items: center;\n fill: #6c6c6c;\n justify-content: space-between;\n margin: 0px var(--pops-panel-forms-container-li-padding-left-right) !important;\n padding: var(--pops-panel-forms-container-li-padding-top-bottom) 0px !important;\n}\nsection.pops-panel-container .pops-panel-forms-fold[data-fold-enable] .pops-panel-forms-fold-container-icon {\n transform: rotate(90deg);\n}\nsection.pops-panel-container .pops-panel-forms-fold .pops-panel-forms-fold-container-icon {\n width: 15px;\n height: 15px;\n display: flex;\n align-items: center;\n transform: rotate(-90deg);\n transition: transform 0.3s;\n}\n/* 折叠状态 */\nsection.pops-panel-container .pops-panel-forms-fold[data-fold-enable] .pops-panel-forms-container-item-formlist {\n height: 0;\n}\n/* 非折叠状态 */\nsection.pops-panel-container .pops-panel-forms-fold ul.pops-panel-forms-container-item-formlist {\n margin: 0;\n}\nsection.pops-panel-container .pops-panel-forms-fold .pops-panel-forms-container-item-formlist {\n transition: height 0.3s;\n overflow: hidden;\n border-radius: unset;\n background: unset;\n margin: 0;\n height: calc-size(auto, size);\n}\n/* 折叠面板 */\n\n/* 姑且认为小于600px的屏幕为移动端 */\n@media (max-width: 600px) {\n /* 兼容移动端CSS */\n .pops[type-value=\"panel\"] {\n --pops-panel-forms-margin-left-right: 10px;\n }\n .pops[type-value=\"panel\"] {\n width: 92%;\n width: 92vw;\n width: 92dvw;\n }\n .pops[type-value=\"panel\"] .pops-panel-content aside.pops-panel-aside {\n max-width: 20%;\n min-width: auto;\n }\n .pops[type-value=\"panel\"] section.pops-panel-container .pops-panel-forms-container-item > div {\n text-align: left;\n --pops-panel-forms-margin-left-right: 0px;\n }\n .pops[type-value=\"panel\"] section.pops-panel-container .pops-panel-forms-container-item ul {\n margin: 0px !important;\n }\n .pops[type-value=\"panel\"] section.pops-panel-container > ul > li {\n margin: 10px 10px;\n }\n .pops[type-value=\"panel\"] section.pops-panel-container > ul > li div:nth-child(2) {\n max-width: 55%;\n }\n .pops[type-value=\"panel\"] section.pops-panel-container .pops-panel-select select {\n min-width: 88px !important;\n width: -webkit-fill-available;\n width: -moz-available;\n }\n .pops[type-value=\"panel\"] section.pops-panel-container .pops-panel-container-header-ul li {\n font-size: 16px;\n }\n .pops[type-value=\"panel\"] .pops-panel-title p[pops],\n .pops[type-value=\"panel\"] section.pops-panel-container > ul li,\n .pops[type-value=\"panel\"] aside.pops-panel-aside ul li {\n font-size: 14px;\n }\n}\n/* switch的CSS */\n.pops-panel-switch {\n --panel-switch-core-bd-color: rgb(220, 223, 230, var(--pops-bd-opacity));\n --panel-switch-core-bg-color: rgb(220, 223, 230, var(--pops-bg-opacity));\n --panel-switch-circle-color: #dcdfe6;\n --panel-switch-circle-bg-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n --panel-switch-checked-circle-color: #409eff;\n --panel-switch-checked-core-bd-color: rgb(64, 158, 255, var(--pops-bd-opacity));\n --panel-switch-checked-core-bg-color: rgb(64, 158, 255, var(--pops-bg-opacity));\n}\n.pops-panel-switch {\n display: inline-flex;\n flex-direction: row-reverse;\n align-items: center;\n position: relative;\n font-size: 14px;\n line-height: normal;\n align-content: center;\n height: 32px;\n vertical-align: middle;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n.pops-panel-switch input.pops-panel-switch__input {\n position: absolute;\n width: 0;\n height: 0;\n opacity: 0;\n margin: 0;\n}\n.pops-panel-switch:has(input.pops-panel-switch__input:disabled),\n.pops-panel-switch[data-disabled],\n.pops-panel-switch[data-disabled] .pops-panel-switch__core,\n.pops-panel-switch input.pops-panel-switch__input:disabled + .pops-panel-switch__core {\n cursor: not-allowed;\n opacity: 0.6;\n}\n.pops-panel-switch span.pops-panel-switch__core {\n display: inline-flex;\n position: relative;\n align-items: center;\n min-width: 40px;\n height: 20px;\n border: 1px solid var(--panel-switch-core-bd-color);\n outline: 0;\n border-radius: 10px;\n box-sizing: border-box;\n background: var(--panel-switch-core-bg-color);\n cursor: pointer;\n transition:\n border-color 0.3s,\n background-color 0.3s;\n}\n.pops-panel-switch .pops-panel-switch__action {\n position: absolute;\n left: 1px;\n border-radius: 100%;\n transition: all 0.3s;\n width: 16px;\n height: 16px;\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: var(--panel-switch-circle-bg-color);\n color: var(--panel-switch-circle-color);\n}\n.pops-panel-switch.pops-panel-switch-is-checked span.pops-panel-switch__core {\n border-color: var(--panel-switch-checked-core-bd-color);\n background-color: var(--panel-switch-checked-core-bg-color);\n}\n.pops-panel-switch.pops-panel-switch-is-checked .pops-panel-switch__action {\n left: calc(100% - 17px);\n color: var(--panel-switch-checked-circle-color);\n}\n/* switch的CSS */\n\n/* slider旧的CSS */\nsection.pops-panel-container .pops-panel-slider:has(> input[type=\"range\"]) {\n overflow: hidden;\n height: 25px;\n line-height: normal;\n align-content: center;\n display: flex;\n align-items: center;\n}\nsection.pops-panel-container .pops-panel-slider input[type=\"range\"] {\n height: 6px;\n background: rgb(228, 231, 237, var(--pops-bg-opacity));\n outline: 0;\n -webkit-appearance: none;\n appearance: none;\n width: 100%;\n}\nsection.pops-panel-container .pops-panel-slider input[type=\"range\"]::-webkit-slider-thumb {\n width: 20px;\n height: 20px;\n border-radius: 50%;\n border: 1px solid rgb(64, 158, 255, var(--pops-bd-opacity));\n background-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n box-shadow:\n 0 0 2px rgba(0, 0, 0, 0.3),\n 0 3px 5px rgba(0, 0, 0, 0.2);\n cursor: pointer;\n -webkit-appearance: none;\n appearance: none;\n border-image: linear-gradient(#409eff, #409eff) 0 fill/9 25 9 0/0 0 0 100vw;\n}\nsection.pops-panel-container .pops-panel-slider input[type=\"range\"]::-moz-range-thumb {\n width: 20px;\n height: 20px;\n border-radius: 50%;\n border: 1px solid rgb(64, 159, 255, var(--pops-bd-opacity));\n background-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n box-shadow:\n 0 0 2px rgba(0, 0, 0, 0.3),\n 0 3px 5px rgba(0, 0, 0, 0.2);\n cursor: pointer;\n -webkit-appearance: none;\n appearance: none;\n}\nsection.pops-panel-container .pops-panel-slider input[type=\"range\"]::-moz-range-progress {\n height: 6px;\n border-image: linear-gradient(#409eff, #409eff) 0 fill/9 25 9 0/0 0 0 100vw;\n}\n/* slider旧的CSS */\n\n/* slider的CSS */\n.pops-slider {\n --pops-slider-color-white: #ffffff;\n --pops-slider-color-primary: #409eff;\n --pops-slider-color-info: #909399;\n --pops-slider-text-color-placeholder: #a8abb2;\n --pops-slider-border-color-light: #e4e7ed;\n --pops-slider-border-radius-circle: 100%;\n --pops-slider-transition-duration-fast: 0.2s;\n\n --pops-slider-main-bg-color: var(--pops-slider-color-primary);\n --pops-slider-runway-bg-color: var(--pops-slider-border-color-light);\n --pops-slider-stop-bg-color: var(--pops-slider-color-white);\n --pops-slider-disabled-color: var(--pops-slider-text-color-placeholder);\n --pops-slider-border-radius: 3px;\n --pops-slider-height: 6px;\n --pops-slider-button-size: 20px;\n --pops-slider-button-wrapper-size: 36px;\n --pops-slider-button-wrapper-offset: -15px;\n}\n\n.pops-slider {\n width: 100%;\n height: 32px;\n display: flex;\n align-items: center;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n\n.pops-slider-width {\n flex: 0 0 52%;\n margin-left: 10px;\n}\n\n.pops-slider__runway {\n flex: 1;\n height: var(--pops-slider-height);\n background-color: var(--pops-slider-runway-bg-color);\n border-radius: var(--pops-slider-border-radius);\n position: relative;\n cursor: pointer;\n}\n\n.pops-slider__runway.show-input {\n margin-right: 30px;\n width: auto;\n}\n\n.pops-slider__runway.pops-slider-is-disabled {\n cursor: default;\n}\n\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__bar {\n background-color: var(--pops-slider-disabled-color);\n}\n\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button {\n border-color: var(--pops-slider-disabled-color);\n}\n\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button:hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.dragging {\n cursor: not-allowed;\n}\n\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button:hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.dragging {\n transform: scale(1);\n}\n\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button:hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.hover,\n.pops-slider__runway.pops-slider-is-disabled .pops-slider__button.dragging {\n cursor: not-allowed;\n}\n\n.pops-slider__input {\n flex-shrink: 0;\n width: 130px;\n}\n\n.pops-slider__bar {\n height: var(--pops-slider-height);\n background-color: var(--pops-slider-main-bg-color);\n border-top-left-radius: var(--pops-slider-border-radius);\n border-bottom-left-radius: var(--pops-slider-border-radius);\n position: absolute;\n}\n\n.pops-slider__button-wrapper {\n height: var(--pops-slider-button-wrapper-size);\n width: var(--pops-slider-button-wrapper-size);\n position: absolute;\n z-index: 1;\n top: var(--pops-slider-button-wrapper-offset);\n transform: translate(-50%);\n background-color: transparent;\n text-align: center;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n line-height: normal;\n outline: none;\n}\n\n.pops-slider__button-wrapper:after {\n display: inline-block;\n content: \"\";\n height: 100%;\n vertical-align: middle;\n}\n\n.pops-slider__button:hover,\n.pops-slider__button.hover {\n cursor: grab;\n}\n\n.pops-slider__button {\n display: inline-block;\n width: var(--pops-slider-button-size);\n height: var(--pops-slider-button-size);\n vertical-align: middle;\n border: solid 2px var(--pops-slider-main-bg-color);\n background-color: var(--pops-slider-color-white);\n border-radius: 50%;\n box-sizing: border-box;\n transition: var(--pops-slider-transition-duration-fast);\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n\n.pops-slider__button:hover,\n.pops-slider__button.hover,\n.pops-slider__button.dragging {\n transform: scale(1.2);\n}\n\n.pops-slider__button:hover,\n.pops-slider__button.hover {\n cursor: grab;\n}\n\n.pops-slider__button.dragging {\n cursor: grabbing;\n}\n\n.pops-slider__stop {\n position: absolute;\n height: var(--pops-slider-height);\n width: var(--pops-slider-height);\n border-radius: var(--pops-slider-border-radius-circle);\n background-color: var(--pops-slider-stop-bg-color);\n transform: translate(-50%);\n}\n\n.pops-slider__marks {\n top: 0;\n left: 12px;\n width: 18px;\n height: 100%;\n}\n\n.pops-slider__marks-text {\n position: absolute;\n transform: translate(-50%);\n font-size: 14px;\n color: var(--pops-slider-color-info);\n margin-top: 15px;\n white-space: pre;\n}\n\n.pops-slider.is-vertical {\n position: relative;\n display: inline-flex;\n width: auto;\n height: 100%;\n flex: 0;\n}\n\n.pops-slider.is-vertical .pops-slider__runway {\n width: var(--pops-slider-height);\n height: 100%;\n margin: 0 16px;\n}\n\n.pops-slider.is-vertical .pops-slider__bar {\n width: var(--pops-slider-height);\n height: auto;\n border-radius: 0 0 3px 3px;\n}\n\n.pops-slider.is-vertical .pops-slider__button-wrapper {\n top: auto;\n left: var(--pops-slider-button-wrapper-offset);\n transform: translateY(50%);\n}\n\n.pops-slider.is-vertical .pops-slider__stop {\n transform: translateY(50%);\n}\n\n.pops-slider.is-vertical .pops-slider__marks-text {\n margin-top: 0;\n left: 15px;\n transform: translateY(50%);\n}\n\n.pops-slider--large {\n height: 40px;\n}\n\n.pops-slider--small {\n height: 24px;\n}\n/* slider的CSS */\n\n/* input的CSS */\n.pops-panel-input {\n --el-disabled-text-color: #a8abb2;\n --el-disabled-bg-color: #f5f7fa;\n --el-disabled-border-color: #e4e7ed;\n\n --pops-panel-components-input-text-color: #000000;\n --pops-panel-components-input-text-bg-color: transparent;\n --pops-panel-components-input-text-default-padding: 8px;\n --pops-panel-components-input-bd-color: #dcdfe6;\n --pops-panel-components-input-bg-color: #ffffff;\n --pops-panel-components-input-hover-bd-color: #c0c4cc;\n --pops-panel-components-input-focus-bd-color: #409eff;\n --pops-panel-components-input-suffix-color: #a8abb2;\n --pops-panel-components-input-suffix-bg-color: #ffffff;\n}\n.pops-panel-input {\n display: flex;\n align-items: center;\n border: 1px solid var(--pops-panel-components-input-bd-color);\n border-radius: 4px;\n background-color: var(--pops-panel-components-input-bg-color);\n position: relative;\n box-shadow: none;\n}\n.pops-panel-input:hover {\n border: 1px solid var(--pops-panel-components-input-hover-bd-color);\n}\n.pops-panel-input:has(input:disabled):hover {\n --pops-panel-components-input-hover-bd-color: var(--pops-panel-components-input-bd-color);\n}\n.pops-panel-input:has(input:focus) {\n outline: 0;\n border: 1px solid var(--pops-panel-components-input-focus-bd-color);\n border-radius: 4px;\n box-shadow: none;\n}\n.pops-panel-input input {\n display: inline-flex;\n justify-content: center;\n text-align: start;\n align-items: center;\n align-content: center;\n white-space: nowrap;\n cursor: text;\n box-sizing: border-box;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n vertical-align: middle;\n -webkit-appearance: none;\n appearance: none;\n color: var(--pops-panel-components-input-text-color);\n background-color: var(--pops-panel-components-input-text-bg-color);\n outline: 0;\n transition: 0.1s;\n border: 0;\n font-size: 14px;\n font-weight: 500;\n line-height: normal;\n height: 32px;\n width: 100%;\n flex: 1;\n /*margin-right: calc(1em + 8px);*/\n margin: 0px;\n padding: var(--pops-panel-components-input-text-default-padding);\n}\n.pops-panel-input span.pops-panel-input__suffix {\n display: inline-flex;\n white-space: nowrap;\n flex-shrink: 0;\n flex-wrap: nowrap;\n height: 100%;\n text-align: center;\n color: var(--pops-panel-components-input-suffix-color);\n background: var(--pops-panel-components-input-suffix-bg-color);\n transition: all 0.3s;\n pointer-events: none;\n padding: 0 8px;\n position: absolute;\n right: 0px;\n border-top-right-radius: 4px;\n border-bottom-right-radius: 4px;\n border: 1px solid transparent;\n}\n.pops-panel-input span.pops-panel-input__suffix-inner {\n pointer-events: all;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n}\n/* 如果包含清空图标的按钮,则默认隐藏清空图标,当:hover、:focus、:focus-within、:active时显示清空图标 */\n.pops-panel-input span.pops-panel-input__suffix:has(svg[data-type=\"circleClose\"]) {\n display: none;\n}\n.pops-panel-input:hover span.pops-panel-input__suffix:has(svg[data-type=\"circleClose\"]),\n.pops-panel-input:focus span.pops-panel-input__suffix:has(svg[data-type=\"circleClose\"]),\n.pops-panel-input:focus-within span.pops-panel-input__suffix:has(svg[data-type=\"circleClose\"]),\n.pops-panel-input:active span.pops-panel-input__suffix:has(svg[data-type=\"circleClose\"]) {\n display: inline-flex;\n}\n.pops-panel-input .pops-panel-icon {\n cursor: pointer;\n}\n.pops-panel-input .pops-panel-icon {\n height: inherit;\n line-height: normal;\n align-content: center;\n display: flex;\n justify-content: center;\n align-items: center;\n transition: all 0.3s;\n}\n.pops-panel-input .pops-panel-icon svg {\n height: 1em;\n width: 1em;\n}\n\n.pops-input-disabled {\n background-color: var(--pops-components-is-disabled-bg-color);\n}\n.pops-panel-input.pops-input-disabled:hover {\n --pops-panel-components-input-hover-bd-color: var(--pops-panel-components-input-bd-color);\n}\n.pops-panel-input input:disabled,\n.pops-panel-input input:disabled + .pops-panel-input__suffix {\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n color: var(--el-disabled-text-color);\n -webkit-text-fill-color: var(--el-disabled-text-color);\n cursor: not-allowed;\n}\n.pops-panel-input input:disabled + .pops-panel-input__suffix {\n display: none;\n}\n/* input的CSS */\n\n/* textarea的CSS */\n.pops-panel-textarea {\n --pops-panel-components-textarea-text-color: #000000;\n --pops-panel-components-textarea-text-bg-color: #ffffff;\n --pops-panel-components-textarea-bd-color: #dcdfe6;\n --pops-panel-components-textarea-hover-bd-color: #c0c4cc;\n --pops-panel-components-textarea-focus-bd-color: #409eff;\n}\n.pops-panel-textarea textarea {\n width: 100%;\n /*vertical-align: bottom;*/\n position: relative;\n display: block;\n resize: none;\n padding: 5px 11px;\n /*line-height: 1;*/\n box-sizing: border-box;\n font-size: inherit;\n font-family: inherit;\n color: var(--pops-panel-components-textarea-text-color);\n background-color: var(--pops-panel-components-textarea-text-bg-color);\n background-image: none;\n -webkit-appearance: none;\n appearance: none;\n box-shadow: none;\n border-radius: 0;\n transition: box-shadow 0.2s cubic-bezier(0.645, 0.045, 0.355, 1);\n border: 1px solid var(--pops-panel-components-textarea-bd-color);\n}\n.pops-panel-textarea textarea:hover {\n border-color: var(--pops-panel-components-textarea-hover-bd-color);\n}\n.pops-panel-textarea:has(textarea:disabled):hover {\n --pops-panel-components-textarea-hover-bd-color: var(--pops-panel-components-textarea-bd-color);\n}\n.pops-panel-textarea-disable {\n --pops-panel-components-textarea-text-bg-color: var(--pops-components-is-disabled-bg-color) !important;\n --pops-panel-components-textarea-text-color: var(--pops-components-is-disabled-text-color);\n}\n.pops-panel-textarea-disable textarea {\n cursor: not-allowed;\n}\n.pops-panel-textarea textarea:focus {\n outline: 0;\n border-color: var(--pops-panel-components-textarea-focus-bd-color);\n}\n/* textarea的CSS */\n\n/* select的CSS */\n.pops-panel-select {\n --pops-panel-components-select-text-color: #000000;\n --pops-panel-components-select-bd-color: rgb(184, 184, 184, var(--pops-bd-opacity));\n --pops-panel-components-select-hover-bd-color: rgb(184, 184, 184, var(--pops-bd-opacity));\n --pops-panel-components-select-bg-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n}\n.pops-panel-select {\n border: 0;\n}\n.pops-panel-select select {\n height: 32px;\n line-height: normal;\n align-content: center;\n min-width: 200px;\n border: 1px solid var(--pops-panel-components-select-bd-color);\n border-radius: 5px;\n text-align: center;\n outline: 0;\n color: var(--pops-panel-components-select-text-color);\n background-color: var(--pops-panel-components-select-bg-color);\n box-shadow: none;\n}\n.pops-panel-select select:hover {\n border: 1px solid var(--pops-panel-components-select-hover-bd-color);\n}\n.pops-panel-select-disable {\n --pops-panel-components-select-text-color: var(--pops-components-is-disabled-text-color);\n --pops-panel-components-select-bg-color: var(--pops-components-is-disabled-bg-color);\n}\n.pops-panel-select-disable select {\n cursor: not-allowed;\n}\n.pops-panel-select-disable select:hover {\n box-shadow: none;\n --pops-panel-components-select-hover-bd-color: var(--pops-panel-components-select-bd-color);\n}\n.pops-panel-select select:focus {\n border: 1px solid rgb(64, 158, 255, var(--pops-bd-opacity));\n box-shadow: none;\n}\n/* select的CSS */\n\n/* select-multiple的CSS*/\n.pops-panel-select-multiple {\n --el-border-radius-base: 4px;\n --el-fill-color-blank: #ffffff;\n --el-transition-duration: 0.3s;\n --el-border-color: #cbcbcb;\n --el-text-color-placeholder: #a8abb2;\n --color: inherit;\n --el-select-input-color: #a8abb2;\n --el-select-input-font-size: 14px;\n --el-text-color-regular: #606266;\n --el-color-info: #909399;\n --el-color-info-light-9: #f4f4f5;\n --el-color-info-light-8: #e9e9eb;\n --el-color-primary-light-9: #ecf5ff;\n --el-color-primary-light-8: #d9ecff;\n --el-color-primary: #409eff;\n --el-color-white: #ffffff;\n width: 200px;\n}\n.pops-panel-select-multiple .el-select__wrapper {\n display: flex;\n align-items: center;\n position: relative;\n box-sizing: border-box;\n cursor: pointer;\n text-align: left;\n font-size: 14px;\n padding: 4px 12px;\n gap: 6px;\n min-height: 32px;\n line-height: normal;\n align-content: center;\n border-radius: var(--el-border-radius-base);\n background-color: var(--el-fill-color-blank);\n transition: var(--el-transition-duration);\n transform: translateZ(0);\n border: 1px solid var(--el-border-color);\n}\n.pops-panel-select-multiple .el-select__wrapper.is-focused {\n --el-border-color: var(--el-color-primary);\n}\n.pops-panel-select-multiple .el-select__selection {\n position: relative;\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n flex: 1;\n min-width: 0;\n gap: 6px;\n}\n.pops-panel-select-multiple .el-select__selected-item {\n display: flex;\n flex-wrap: wrap;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n.pops-panel-select-multiple .el-select__selected-item.el-select__choose_tag .el-tag {\n max-width: 200px;\n}\n.pops-panel-select-multiple .el-select__input-wrapper {\n max-width: 100%;\n}\n.pops-panel-select-multiple .el-select__selection.is-near {\n margin-left: -8px;\n}\n.pops-panel-select-multiple .el-select__placeholder {\n position: absolute;\n display: block;\n top: 50%;\n transform: translateY(-50%);\n width: 100%;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n color: var(--el-input-text-color, var(--el-text-color-regular));\n}\n.pops-panel-select-multiple .el-select__placeholder.is-transparent {\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n color: var(--el-text-color-placeholder);\n}\n.pops-panel-select-multiple .el-select__prefix,\n.pops-panel-select-multiple .el-select__suffix {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n gap: 6px;\n color: var(--el-input-icon-color, var(--el-text-color-placeholder));\n}\n.pops-panel-select-multiple .el-icon {\n --color: inherit;\n height: 1em;\n width: 1em;\n line-height: normal;\n align-content: center;\n display: inline-flex;\n justify-content: center;\n align-items: center;\n position: relative;\n fill: currentColor;\n color: var(--color);\n font-size: inherit;\n}\n.pops-panel-select-multiple .el-icon svg {\n height: 1em;\n width: 1em;\n}\n.pops-panel-select-multiple .el-select__caret {\n color: var(--el-select-input-color);\n font-size: var(--el-select-input-font-size);\n transition: var(--el-transition-duration);\n transform: rotate(0);\n cursor: pointer;\n}\n.pops-panel-select-multiple .el-tag {\n --el-tag-font-size: 12px;\n --el-tag-border-radius: 4px;\n --el-tag-border-radius-rounded: 9999px;\n}\n.pops-panel-select-multiple .el-tag {\n background-color: var(--el-tag-bg-color);\n border-color: var(--el-tag-border-color);\n color: var(--el-tag-text-color);\n display: inline-flex;\n justify-content: center;\n align-items: center;\n vertical-align: middle;\n height: 24px;\n padding: 0 9px;\n font-size: var(--el-tag-font-size);\n line-height: normal;\n align-content: center;\n border-width: 1px;\n border-style: solid;\n border-radius: var(--el-tag-border-radius);\n box-sizing: border-box;\n white-space: nowrap;\n --el-icon-size: 14px;\n --el-tag-bg-color: var(--el-color-primary-light-9);\n --el-tag-border-color: var(--el-color-primary-light-8);\n --el-tag-hover-color: var(--el-color-primary);\n}\n.pops-panel-select-multiple .el-select__selection .el-tag {\n cursor: pointer;\n border-color: transparent;\n}\n.pops-panel-select-multiple .el-tag.el-tag--info {\n --el-tag-bg-color: var(--el-color-info-light-9);\n --el-tag-border-color: var(--el-color-info-light-8);\n --el-tag-hover-color: var(--el-color-info);\n}\n.pops-panel-select-multiple .el-tag.el-tag--info {\n --el-tag-text-color: var(--el-color-info);\n}\n.pops-panel-select-multiple .el-tag.is-closable {\n padding-right: 5px;\n}\n.pops-panel-select-multiple .el-select__selection .el-tag .el-tag__content {\n min-width: 0;\n}\n.pops-panel-select-multiple .el-tag .el-tag__close {\n flex-shrink: 0;\n color: var(--el-tag-text-color);\n}\n.pops-panel-select-multiple .el-tag .el-tag__close:hover {\n color: var(--el-color-white);\n background-color: var(--el-tag-hover-color);\n}\n.pops-panel-select-multiple .el-tag .el-icon {\n border-radius: 50%;\n cursor: pointer;\n font-size: calc(var(--el-icon-size) - 2px);\n height: var(--el-icon-size);\n width: var(--el-icon-size);\n}\n.pops-panel-select-multiple .el-tag .el-tag__close {\n margin-left: 6px;\n}\n.pops-panel-select-multiple .el-select__tags-text {\n display: block;\n line-height: normal;\n align-content: center;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.pops-panel-select-multiple-disable {\n --el-fill-color-blank: #f5f7fa;\n --color: #a8abb2;\n --el-border-color: #cbcbcb;\n}\n.pops-panel-select-multiple-disable .el-tag.el-tag--info {\n --el-tag-bg-color: #e7e7e7;\n --el-tag-text-color: var(--pops-components-is-disabled-text-color);\n}\n.pops-panel-select-multiple-disable .el-select__selection .el-tag,\n.pops-panel-select-multiple-disable .el-tag .el-tag__close:hover,\n.pops-panel-select-multiple-disable .el-select__wrapper,\n.pops-panel-select-multiple-disable .el-select__caret {\n cursor: not-allowed;\n}\n/* select-multiple的CSS*/\n\n/* deepMenu的css */\n.pops-panel-deepMenu-nav-item {\n cursor: pointer;\n}\n.pops-panel-deepMenu-nav-item:active {\n background: var(--pops-panel-forms-container-deepMenu-item-active-bg);\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\nsection.pops-panel-container .pops-panel-forms-container-item ul li.pops-panel-deepMenu-nav-item:active {\n padding: var(--pops-panel-forms-container-li-padding-top-bottom)\n var(--pops-panel-forms-container-li-padding-left-right);\n margin: 0px;\n}\n/* 去除上个兄弟item的底部边框颜色 */\nsection.pops-panel-container .pops-panel-forms-container-item ul li:has(+ .pops-panel-deepMenu-nav-item:active) {\n border-bottom: 1px solid transparent;\n}\n/* 第一个和最后一个跟随圆角 */\nsection.pops-panel-container .pops-panel-forms-container-item ul li.pops-panel-deepMenu-nav-item:first-child:active {\n border-top-left-radius: var(--pops-panel-forms-container-item-border-radius);\n border-top-right-radius: var(--pops-panel-forms-container-item-border-radius);\n}\nsection.pops-panel-container .pops-panel-forms-container-item ul li.pops-panel-deepMenu-nav-item:last-child:active {\n border-bottom-left-radius: var(--pops-panel-forms-container-item-border-radius);\n border-bottom-right-radius: var(--pops-panel-forms-container-item-border-radius);\n}\n.pops-panel-deepMenu-nav-item .pops-panel-deepMenu {\n display: flex;\n align-items: center;\n color: #6c6c6c;\n fill: #6c6c6c;\n}\n.pops-panel-deepMenu-nav-item .pops-panel-deepMenu-arrowRight-icon {\n width: 15px;\n height: 15px;\n display: flex;\n align-items: center;\n}\nsection.pops-panel-deepMenu-container .pops-panel-container-header-ul li.pops-panel-deepMenu-container-header {\n display: flex;\n align-items: center;\n width: -webkit-fill-available;\n width: -moz-available;\n padding: var(--pops-panel-forms-header-padding-top-bottom)\n calc(\n var(--pops-panel-forms-margin-left-right) + var(--pops-panel-forms-container-li-padding-left-right) -\n var(--pops-panel-forms-header-icon-size)\n );\n gap: 0px;\n}\n.pops-panel-deepMenu-container .pops-panel-deepMenu-container-left-arrow-icon {\n width: var(--pops-panel-forms-header-icon-size);\n height: var(--pops-panel-forms-header-icon-size);\n display: flex;\n align-items: center;\n cursor: pointer;\n}\n/* 修复safari上图标大小未正常显示 */\n.pops-panel-deepMenu-container .pops-panel-deepMenu-container-left-arrow-icon > svg {\n width: inherit;\n height: inherit;\n}\n/* deepMenu的css */\n\n/* 文字对齐 */\n.pops-panel-item-left-desc-text:has(code) {\n display: flex;\n align-items: baseline;\n flex-wrap: wrap;\n}\n\n@media (prefers-color-scheme: dark) {\n .pops[type-value=\"panel\"] {\n --pops-bg-color: #000000;\n --pops-color: #f2f2f2;\n --panel-title-bg-color: #000000;\n --panel-aside-bg-color: #262626;\n --pops-panel-forms-container-item-left-desc-text-color: #6c6c6c;\n --pops-panel-forms-container-item-bg-color: #262626;\n --pops-panel-forms-container-item-title-color: #c1c1c1;\n\n --pops-panel-forms-container-li-border-color: rgb(51, 51, 51, var(--pops-bd-opacity));\n --pops-panel-forms-container-deepMenu-item-active-bg: #333333;\n }\n .pops[type-value=\"panel\"] .pops-panel-deepMenu-container .pops-panel-deepMenu-container-left-arrow-icon {\n fill: #f2f2f2;\n }\n\n /* switch的CSS */\n .pops-panel-switch {\n --panel-switch-core-bd-color: rgb(220, 223, 230, var(--pops-bd-opacity));\n --panel-switch-core-bg-color: rgb(220, 223, 230, var(--pops-bg-opacity));\n --panel-switch-circle-color: #dcdfe6;\n --panel-switch-circle-bg-color: rgb(255, 255, 255, var(--pops-bg-opacity));\n --panel-switch-checked-circle-color: #409eff;\n --panel-switch-checked-core-bd-color: rgb(64, 158, 255, var(--pops-bd-opacity));\n --panel-switch-checked-core-bg-color: rgb(64, 158, 255, var(--pops-bg-opacity));\n }\n /* select的CSS */\n .pops-panel-select {\n --pops-panel-components-select-text-color: #f2f2f2;\n --pops-panel-components-select-bd-color: rgb(51, 51, 51, var(--pops-bd-opacity));\n --pops-panel-components-select-bg-color: #141414;\n }\n /* select-multiple的CSS*/\n .pops-panel-select-multiple {\n --el-fill-color-blank: #141414;\n --el-border-color: #4c4d4f;\n --el-text-color-placeholder: #a8abb2;\n --el-select-input-color: #a8abb2;\n --el-text-color-regular: #606266;\n --el-color-info: #909399;\n --el-color-info-light-8: #e9e9eb;\n --el-color-primary-light-9: #ecf5ff;\n --el-color-primary-light-8: #d9ecff;\n --el-color-primary: #409eff;\n --el-color-white: #ffffff;\n }\n .pops-panel-select-multiple .el-tag {\n --el-color-info-light-9: #202121;\n }\n .pops-panel-select-multiple-disable {\n --el-border-color: rgb(51, 51, 51, var(--pops-bd-opacity));\n }\n .pops-panel-select-multiple-disable .el-tag.el-tag--info {\n --el-tag-bg-color: #2f2f2f;\n }\n /* select-multiple的CSS*/\n /* slider的CSS */\n .pops-slider {\n --pops-slider-border-color-light: #414243;\n }\n /* input的CSS */\n .pops-panel-input {\n --pops-panel-components-input-text-color: #f2f2f2;\n --pops-panel-components-input-bd-color: #4f5052;\n --pops-panel-components-input-bg-color: #141414;\n --pops-panel-components-input-hover-bd-color: #6f7175;\n --pops-panel-components-input-focus-bd-color: #409eff;\n --pops-panel-components-input-suffix-color: #a8abb2;\n }\n /* textarea的CSS */\n .pops-panel-textarea {\n --pops-panel-components-textarea-text-color: #f2f2f2;\n --pops-panel-components-textarea-text-bg-color: #141414;\n --pops-panel-components-textarea-bd-color: #4f5052;\n --pops-panel-components-textarea-hover-bd-color: #6f7175;\n --pops-panel-components-textarea-focus-bd-color: #409eff;\n }\n .pops-panel-textarea-disable {\n --pops-panel-components-textarea-text-color: var(--pops-components-is-disabled-text-color);\n --pops-panel-components-textarea-text-bg-color: var(--pops-components-is-disabled-bg-color);\n }\n /* slider */\n .pops-slider {\n --pops-slider-text-color-placeholder: #8d9095;\n }\n}\n";
|
|
2856
2837
|
|
|
2857
|
-
var rightClickMenuCSS = ".pops-rightClickMenu {\n
|
|
2838
|
+
var rightClickMenuCSS = ".pops-rightClickMenu {\n --pops-right-context-color: #000000;\n --pops-right-context-bg-color: rgb(255, 255, 255, 0.733);\n --pops-right-context-backdrop-filter: blur(10px);\n --pops-right-context-z-index: 10000;\n --pops-right-context-bd-radius: 6px;\n --pops-right-context-menu-shadow-color: rgb(114, 114, 114, 0.251);\n --pops-right-context-menu-row-bd-radius: 6px;\n --pops-right-context-menu-row-visited-color: rgb(0, 0, 0, 0.067);\n --pops-right-context-menu-row-hover-color: rgb(0, 0, 0, 0.067);\n}\n.pops-rightClickMenu * {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n -webkit-tap-highlight-color: transparent;\n scrollbar-width: thin;\n}\n.pops-rightClickMenu {\n position: fixed;\n z-index: var(--pops-right-context-z-index);\n text-align: center;\n border-radius: var(--pops-right-context-bd-radius);\n font-size: 16px;\n font-weight: 500;\n color: var(--pops-right-context-color);\n background: var(--pops-right-context-bg-color);\n box-shadow: 0 0.25rem 0.5rem 0.125rem var(--pops-right-context-menu-shadow-color);\n -webkit-backdrop-filter: var(--pops-right-context-backdrop-filter);\n backdrop-filter: var(--pops-right-context-backdrop-filter);\n}\n/* scale动画 */\n.pops-rightClickMenu-anim-scale {\n transition:\n opacity 150ms cubic-bezier(0.2, 0, 0.2, 1),\n transform 150ms cubic-bezier(0.2, 0, 0.2, 1);\n transform: scale(0.85);\n}\n.pops-rightClickMenu-anim-scale-open {\n transform: scale(1);\n}\n.pops-rightClickMenu-anim-scale-not-open {\n opacity: 0;\n}\n/* 展开动画 */\n.pops-rightClickMenu-anim-grid {\n display: grid;\n transition: 0.3s;\n grid-template-rows: 0fr;\n}\n.pops-rightClickMenu-anim-show {\n grid-template-rows: 1fr;\n}\n.pops-rightClickMenu-is-visited {\n background: var(--pops-right-context-menu-row-visited-color);\n}\ni.pops-rightClickMenu-icon {\n height: 1em;\n width: 1em;\n line-height: normal;\n align-content: center;\n display: inline-flex;\n justify-content: center;\n align-items: center;\n position: relative;\n fill: currentColor;\n color: inherit;\n font-size: inherit;\n margin-right: 6px;\n}\ni.pops-rightClickMenu-icon[is-loading=\"true\"] {\n animation: rotating 2s linear infinite;\n}\n.pops-rightClickMenu li:hover {\n background: var(--pops-right-context-menu-row-hover-color);\n cursor: pointer;\n}\n.pops-rightClickMenu ul {\n margin: 0;\n padding: 0;\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n justify-content: center;\n overflow: hidden;\n}\n.pops-rightClickMenu ul li {\n padding: 5px 10px;\n margin: 5px 5px;\n border-radius: var(--pops-right-context-menu-row-bd-radius);\n display: flex;\n width: -webkit-fill-available;\n width: -moz-available;\n text-align: left;\n align-items: center;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n\n@media (prefers-color-scheme: dark) {\n /*.pops-rightClickMenu {\n\t\t--pops-right-context-menu-shadow-color: #3c3c3c;\n\t}*/\n}\n@media (hover: hover) {\n .pops-rightClickMenu ul li:active {\n transform: scale(0.98);\n }\n}\n";
|
|
2858
2839
|
|
|
2859
2840
|
const PopsCSS = {
|
|
2860
2841
|
/** 主CSS */
|
|
@@ -2901,7 +2882,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2901
2882
|
if (!this.$flag.isInit) {
|
|
2902
2883
|
this.$flag.isInit = true;
|
|
2903
2884
|
/* 处理获取当前所有的动画名 */
|
|
2904
|
-
|
|
2885
|
+
const animationStyle = document.createElement("style");
|
|
2905
2886
|
PopsSafeUtils.setSafeHTML(animationStyle, PopsCSS.anim);
|
|
2906
2887
|
popsDOMUtils.appendHead(animationStyle);
|
|
2907
2888
|
this.$data = null;
|
|
@@ -2915,7 +2896,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2915
2896
|
* 判断是否存在某个动画名
|
|
2916
2897
|
*/
|
|
2917
2898
|
hasAnim(name) {
|
|
2918
|
-
return this.$data
|
|
2899
|
+
return Object.prototype.hasOwnProperty.call(this.$data, name);
|
|
2919
2900
|
},
|
|
2920
2901
|
};
|
|
2921
2902
|
|
|
@@ -2958,7 +2939,6 @@ System.register('pops', [], (function (exports) {
|
|
|
2958
2939
|
// 当前页面最大的z-index
|
|
2959
2940
|
let zIndex = 0;
|
|
2960
2941
|
// 当前的最大z-index的元素,调试使用
|
|
2961
|
-
// @ts-ignore
|
|
2962
2942
|
let maxZIndexNode = null;
|
|
2963
2943
|
/**
|
|
2964
2944
|
* 元素是否可见
|
|
@@ -2974,7 +2954,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2974
2954
|
*/
|
|
2975
2955
|
function queryMaxZIndex($ele) {
|
|
2976
2956
|
if (typeof ignoreCallBack === "function") {
|
|
2977
|
-
|
|
2957
|
+
const ignoreResult = ignoreCallBack($ele);
|
|
2978
2958
|
if (typeof ignoreResult === "boolean" && !ignoreResult) {
|
|
2979
2959
|
return;
|
|
2980
2960
|
}
|
|
@@ -2983,7 +2963,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2983
2963
|
const nodeStyle = PopsCore.window.getComputedStyle($ele);
|
|
2984
2964
|
/* 不对position为static和display为none的元素进行获取它们的z-index */
|
|
2985
2965
|
if (isVisibleNode(nodeStyle)) {
|
|
2986
|
-
|
|
2966
|
+
const nodeZIndex = parseInt(nodeStyle.zIndex);
|
|
2987
2967
|
if (!isNaN(nodeZIndex)) {
|
|
2988
2968
|
if (nodeZIndex > zIndex) {
|
|
2989
2969
|
// 赋值到全局
|
|
@@ -2999,7 +2979,7 @@ System.register('pops', [], (function (exports) {
|
|
|
2999
2979
|
}
|
|
3000
2980
|
}
|
|
3001
2981
|
}
|
|
3002
|
-
target.querySelectorAll("*").forEach(($ele
|
|
2982
|
+
target.querySelectorAll("*").forEach(($ele) => {
|
|
3003
2983
|
queryMaxZIndex($ele);
|
|
3004
2984
|
});
|
|
3005
2985
|
zIndex += deviation;
|
|
@@ -3034,13 +3014,13 @@ System.register('pops', [], (function (exports) {
|
|
|
3034
3014
|
return $css.position !== "static" && $css.display !== "none";
|
|
3035
3015
|
}
|
|
3036
3016
|
Object.keys(PopsInstData).forEach((instKeyName) => {
|
|
3037
|
-
|
|
3017
|
+
const instData = PopsInstData[instKeyName];
|
|
3038
3018
|
for (let index = 0; index < instData.length; index++) {
|
|
3039
3019
|
const inst = instData[index];
|
|
3040
|
-
|
|
3020
|
+
const nodeStyle = window.getComputedStyle(inst.animElement);
|
|
3041
3021
|
/* 不对position为static和display为none的元素进行获取它们的z-index */
|
|
3042
3022
|
if (isVisibleNode(nodeStyle)) {
|
|
3043
|
-
|
|
3023
|
+
const nodeZIndex = parseInt(nodeStyle.zIndex);
|
|
3044
3024
|
if (!isNaN(nodeZIndex)) {
|
|
3045
3025
|
if (nodeZIndex > zIndex) {
|
|
3046
3026
|
zIndex = nodeZIndex;
|
|
@@ -3051,7 +3031,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3051
3031
|
}
|
|
3052
3032
|
});
|
|
3053
3033
|
zIndex += deviation;
|
|
3054
|
-
|
|
3034
|
+
const isOverMaxZIndex = zIndex >= maxZIndex;
|
|
3055
3035
|
if (isOverMaxZIndex) {
|
|
3056
3036
|
// 超出z-index最大值
|
|
3057
3037
|
zIndex = maxZIndex;
|
|
@@ -3096,9 +3076,9 @@ System.register('pops', [], (function (exports) {
|
|
|
3096
3076
|
// 移除全部或者guid相同
|
|
3097
3077
|
if (isAll || instConfigItem["guid"] === guid) {
|
|
3098
3078
|
// 判断是否有动画
|
|
3099
|
-
|
|
3079
|
+
const animName = instConfigItem.animElement.getAttribute("anim");
|
|
3100
3080
|
if (PopsAnimation.hasAnim(animName)) {
|
|
3101
|
-
|
|
3081
|
+
const reverseAnimName = animName + "-reverse";
|
|
3102
3082
|
instConfigItem.animElement.style.width = "100%";
|
|
3103
3083
|
instConfigItem.animElement.style.height = "100%";
|
|
3104
3084
|
instConfigItem.animElement.style["animation-name"] = reverseAnimName;
|
|
@@ -3133,9 +3113,9 @@ System.register('pops', [], (function (exports) {
|
|
|
3133
3113
|
*/
|
|
3134
3114
|
hide(popsType, instConfigList, guid, config, animElement, maskElement) {
|
|
3135
3115
|
return new Promise((resolve) => {
|
|
3136
|
-
|
|
3116
|
+
const popsElement = animElement.querySelector(".pops[type-value]");
|
|
3137
3117
|
if (popsType === "drawer") {
|
|
3138
|
-
|
|
3118
|
+
const drawerConfig = config;
|
|
3139
3119
|
popsUtils.setTimeout(() => {
|
|
3140
3120
|
maskElement.style.setProperty("display", "none");
|
|
3141
3121
|
if (["top", "bottom"].includes(drawerConfig.direction)) {
|
|
@@ -3151,18 +3131,14 @@ System.register('pops', [], (function (exports) {
|
|
|
3151
3131
|
}, drawerConfig.closeDelay);
|
|
3152
3132
|
}
|
|
3153
3133
|
else {
|
|
3154
|
-
|
|
3134
|
+
const fintInst = instConfigList.find((instConfigItem) => instConfigItem.guid === guid);
|
|
3155
3135
|
if (fintInst) {
|
|
3156
3136
|
/* 存在动画 */
|
|
3157
|
-
|
|
3137
|
+
const instConfigItem = fintInst;
|
|
3158
3138
|
instConfigItem.animElement.style.width = "100%";
|
|
3159
3139
|
instConfigItem.animElement.style.height = "100%";
|
|
3160
|
-
|
|
3161
|
-
instConfigItem.animElement.style
|
|
3162
|
-
instConfigItem.animElement.getAttribute("anim") + "-reverse";
|
|
3163
|
-
if (PopsAnimation.hasAnim(
|
|
3164
|
-
// @ts-ignore
|
|
3165
|
-
instConfigItem.animElement.style["animation-name"])) {
|
|
3140
|
+
Reflect.set(instConfigItem.animElement.style, "animation-name", instConfigItem.animElement.getAttribute("anim") + "-reverse");
|
|
3141
|
+
if (PopsAnimation.hasAnim(Reflect.get(instConfigItem.animElement.style, "animation-name"))) {
|
|
3166
3142
|
/**
|
|
3167
3143
|
* 动画结束的回调
|
|
3168
3144
|
*/
|
|
@@ -3202,13 +3178,13 @@ System.register('pops', [], (function (exports) {
|
|
|
3202
3178
|
*/
|
|
3203
3179
|
show(popsType, instConfigList, guid, config, animElement, maskElement) {
|
|
3204
3180
|
return new Promise((resolve) => {
|
|
3205
|
-
|
|
3181
|
+
const popsElement = animElement.querySelector(".pops[type-value]");
|
|
3206
3182
|
if (popsType === "drawer") {
|
|
3207
|
-
|
|
3183
|
+
const drawerConfig = config;
|
|
3208
3184
|
popsUtils.setTimeout(() => {
|
|
3209
3185
|
popsDOMUtils.css(maskElement, "display", "");
|
|
3210
|
-
|
|
3211
|
-
|
|
3186
|
+
const direction = drawerConfig.direction;
|
|
3187
|
+
const size = drawerConfig.size.toString();
|
|
3212
3188
|
if (["top", "bottom"].includes(direction)) {
|
|
3213
3189
|
popsElement.style.setProperty("height", size);
|
|
3214
3190
|
}
|
|
@@ -3222,18 +3198,13 @@ System.register('pops', [], (function (exports) {
|
|
|
3222
3198
|
}, drawerConfig.openDelay ?? 0);
|
|
3223
3199
|
}
|
|
3224
3200
|
else {
|
|
3225
|
-
|
|
3201
|
+
const fintInst = instConfigList.find((instConfigItem) => instConfigItem.guid === guid);
|
|
3226
3202
|
if (fintInst) {
|
|
3227
|
-
|
|
3203
|
+
const instConfigItem = fintInst;
|
|
3228
3204
|
instConfigItem.animElement.style.width = "";
|
|
3229
3205
|
instConfigItem.animElement.style.height = "";
|
|
3230
|
-
|
|
3231
|
-
instConfigItem.animElement.style
|
|
3232
|
-
.animElement.getAttribute("anim")
|
|
3233
|
-
.replace("-reverse", "");
|
|
3234
|
-
if (PopsAnimation.hasAnim(
|
|
3235
|
-
// @ts-ignore
|
|
3236
|
-
instConfigItem.animElement.style["animation-name"])) {
|
|
3206
|
+
Reflect.set(instConfigItem.animElement.style, "animation-name", instConfigItem.animElement.getAttribute("anim").replace("-reverse", ""));
|
|
3207
|
+
if (PopsAnimation.hasAnim(Reflect.get(instConfigItem.animElement.style, "animation-name"))) {
|
|
3237
3208
|
/**
|
|
3238
3209
|
* 动画结束的回调
|
|
3239
3210
|
*/
|
|
@@ -3272,8 +3243,8 @@ System.register('pops', [], (function (exports) {
|
|
|
3272
3243
|
*/
|
|
3273
3244
|
close(popsType, instConfigList, guid, config, animElement) {
|
|
3274
3245
|
return new Promise((resolve) => {
|
|
3275
|
-
|
|
3276
|
-
|
|
3246
|
+
const popsElement = animElement.querySelector(".pops[type-value]");
|
|
3247
|
+
const drawerConfig = config;
|
|
3277
3248
|
/**
|
|
3278
3249
|
* 动画结束事件
|
|
3279
3250
|
*/
|
|
@@ -3291,7 +3262,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3291
3262
|
}
|
|
3292
3263
|
/* 监听过渡结束 */
|
|
3293
3264
|
popsDOMUtils.on(popsElement, popsDOMUtils.getTransitionEndNameList(), closeCallBack);
|
|
3294
|
-
|
|
3265
|
+
const popsTransForm = getComputedStyle(popsElement).transform;
|
|
3295
3266
|
if (popsTransForm !== "none") {
|
|
3296
3267
|
popsDOMUtils.trigger(popsElement, popsDOMUtils.getTransitionEndNameList(), void 0, true);
|
|
3297
3268
|
return;
|
|
@@ -3343,8 +3314,8 @@ System.register('pops', [], (function (exports) {
|
|
|
3343
3314
|
let clickElementLeftOffset = 0;
|
|
3344
3315
|
/* 点击元素,top偏移 */
|
|
3345
3316
|
let clickElementTopOffset = 0;
|
|
3346
|
-
|
|
3347
|
-
|
|
3317
|
+
const AnyTouch = popsUtils.AnyTouch();
|
|
3318
|
+
const anyTouchElement = new AnyTouch(options.dragElement, {
|
|
3348
3319
|
preventDefault(event) {
|
|
3349
3320
|
if (typeof options.preventEvent === "function") {
|
|
3350
3321
|
return options.preventEvent(event);
|
|
@@ -3362,7 +3333,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3362
3333
|
* 修改移动的元素的style
|
|
3363
3334
|
*/
|
|
3364
3335
|
function changeMoveElementStyle(element) {
|
|
3365
|
-
|
|
3336
|
+
const old_transitionDuration = element.style.transitionDuration;
|
|
3366
3337
|
if (globalThis.getComputedStyle(element).transitionDuration !== "0s") {
|
|
3367
3338
|
element.style.transitionDuration = "0s";
|
|
3368
3339
|
}
|
|
@@ -3392,7 +3363,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3392
3363
|
};
|
|
3393
3364
|
}
|
|
3394
3365
|
else {
|
|
3395
|
-
|
|
3366
|
+
const rect = container.getBoundingClientRect();
|
|
3396
3367
|
return {
|
|
3397
3368
|
left: rect.left,
|
|
3398
3369
|
top: rect.top,
|
|
@@ -3405,7 +3376,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3405
3376
|
anyTouchElement.on("pan", function (event) {
|
|
3406
3377
|
if (!isMove) {
|
|
3407
3378
|
isMove = true;
|
|
3408
|
-
|
|
3379
|
+
const rect = options.dragElement.getBoundingClientRect();
|
|
3409
3380
|
clickElementLeftOffset = event.x - rect.left;
|
|
3410
3381
|
clickElementTopOffset = event.y - rect.top;
|
|
3411
3382
|
transformInfo = popsDOMUtils.getTransform(moveElement);
|
|
@@ -3430,12 +3401,12 @@ System.register('pops', [], (function (exports) {
|
|
|
3430
3401
|
if (options.limit) {
|
|
3431
3402
|
/* 限制在容器内移动 */
|
|
3432
3403
|
/* left偏移最大值 */
|
|
3433
|
-
|
|
3404
|
+
const maxLeftOffset = getContainerWidthOrHeight(options.container).width -
|
|
3434
3405
|
popsDOMUtils.width(moveElement) +
|
|
3435
3406
|
transformInfo.transformLeft;
|
|
3436
|
-
|
|
3407
|
+
const { left: minLeftOffset, top: minTopOffset } = getContainerTopOrLeft(options.container);
|
|
3437
3408
|
/* top偏移的最大值 */
|
|
3438
|
-
|
|
3409
|
+
const maxTopOffset = getContainerWidthOrHeight(options.container).height -
|
|
3439
3410
|
popsDOMUtils.height(moveElement) +
|
|
3440
3411
|
transformInfo.transformTop;
|
|
3441
3412
|
if (currentMoveLeftOffset > maxLeftOffset) {
|
|
@@ -3446,8 +3417,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3446
3417
|
/* 不允许超过容器的最大高度 */
|
|
3447
3418
|
currentMoveTopOffset = maxTopOffset;
|
|
3448
3419
|
}
|
|
3449
|
-
if (currentMoveLeftOffset - options.extraDistance * 2 <
|
|
3450
|
-
minLeftOffset + transformInfo.transformLeft) {
|
|
3420
|
+
if (currentMoveLeftOffset - options.extraDistance * 2 < minLeftOffset + transformInfo.transformLeft) {
|
|
3451
3421
|
/* 不允许left偏移小于容器最小值 */
|
|
3452
3422
|
currentMoveLeftOffset = minLeftOffset + transformInfo.transformLeft;
|
|
3453
3423
|
/* 最左边 +额外距离 */
|
|
@@ -3511,8 +3481,8 @@ System.register('pops', [], (function (exports) {
|
|
|
3511
3481
|
throw new Error("获取前面的值或后面的值的方法不能为空");
|
|
3512
3482
|
}
|
|
3513
3483
|
return function (after_obj, before_obj) {
|
|
3514
|
-
|
|
3515
|
-
|
|
3484
|
+
const beforeValue = getBeforeValueFun(before_obj); /* 前 */
|
|
3485
|
+
const afterValue = getAfterValueFun(after_obj); /* 后 */
|
|
3516
3486
|
if (sortByDesc) {
|
|
3517
3487
|
if (afterValue > beforeValue) {
|
|
3518
3488
|
return -1;
|
|
@@ -3544,10 +3514,10 @@ System.register('pops', [], (function (exports) {
|
|
|
3544
3514
|
* 创建shadow
|
|
3545
3515
|
*/
|
|
3546
3516
|
handlerShadow(config) {
|
|
3547
|
-
|
|
3517
|
+
const $shadowContainer = document.createElement("div");
|
|
3548
3518
|
$shadowContainer.className = "pops-shadow-container";
|
|
3549
3519
|
if (config.useShadowRoot) {
|
|
3550
|
-
|
|
3520
|
+
const $shadowRoot = $shadowContainer.attachShadow({ mode: "open" });
|
|
3551
3521
|
return {
|
|
3552
3522
|
$shadowContainer,
|
|
3553
3523
|
$shadowRoot,
|
|
@@ -3599,7 +3569,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3599
3569
|
});
|
|
3600
3570
|
}
|
|
3601
3571
|
for (const cssItem of css) {
|
|
3602
|
-
|
|
3572
|
+
const $css = popsDOMUtils.createElement("style", {}, {
|
|
3603
3573
|
"data-type": "PopsHandler.handleInit",
|
|
3604
3574
|
});
|
|
3605
3575
|
$css.textContent = cssItem.css;
|
|
@@ -3616,7 +3586,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3616
3586
|
* @param details 传递的配置
|
|
3617
3587
|
*/
|
|
3618
3588
|
handleMask(details = {}) {
|
|
3619
|
-
|
|
3589
|
+
const result = {
|
|
3620
3590
|
maskElement: popsDOMUtils.parseTextToDOM(details.maskHTML),
|
|
3621
3591
|
};
|
|
3622
3592
|
let isMaskClick = false;
|
|
@@ -3627,7 +3597,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3627
3597
|
function clickEvent(event) {
|
|
3628
3598
|
popsDOMUtils.preventEvent(event);
|
|
3629
3599
|
// 获取该类型实例存储列表
|
|
3630
|
-
|
|
3600
|
+
const targetInst = PopsInstData[details.type];
|
|
3631
3601
|
function originalRun() {
|
|
3632
3602
|
if (details.config.mask.clickEvent.toClose) {
|
|
3633
3603
|
/* 关闭 */
|
|
@@ -3661,12 +3631,12 @@ System.register('pops', [], (function (exports) {
|
|
|
3661
3631
|
}
|
|
3662
3632
|
/* 判断按下的元素是否是pops-anim */
|
|
3663
3633
|
popsDOMUtils.on(details.animElement, ["touchstart", "mousedown"], void 0, (event) => {
|
|
3664
|
-
|
|
3634
|
+
const $click = event.composedPath()[0];
|
|
3665
3635
|
isMaskClick = isAnimElement($click);
|
|
3666
3636
|
});
|
|
3667
3637
|
/* 如果有动画层,在动画层上监听点击事件 */
|
|
3668
3638
|
popsDOMUtils.on(details.animElement, "click", void 0, (event) => {
|
|
3669
|
-
|
|
3639
|
+
const $click = event.composedPath()[0];
|
|
3670
3640
|
if (isAnimElement($click) && isMaskClick) {
|
|
3671
3641
|
return clickEvent(event);
|
|
3672
3642
|
}
|
|
@@ -3859,7 +3829,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3859
3829
|
* 处理返回的配置,针对popsHandler.handleEventDetails
|
|
3860
3830
|
*/
|
|
3861
3831
|
handleResultDetails(details) {
|
|
3862
|
-
|
|
3832
|
+
const resultDetails = Object.assign({}, details);
|
|
3863
3833
|
popsUtils.delete(resultDetails, "type");
|
|
3864
3834
|
popsUtils.delete(resultDetails, "function");
|
|
3865
3835
|
return resultDetails;
|
|
@@ -3873,7 +3843,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3873
3843
|
*/
|
|
3874
3844
|
handleClickEvent(type, $btn, eventDetails, callback) {
|
|
3875
3845
|
popsDOMUtils.on($btn, "click", (event) => {
|
|
3876
|
-
|
|
3846
|
+
const extraParam = {
|
|
3877
3847
|
type: type,
|
|
3878
3848
|
};
|
|
3879
3849
|
callback(Object.assign(eventDetails, extraParam), event);
|
|
@@ -3888,9 +3858,9 @@ System.register('pops', [], (function (exports) {
|
|
|
3888
3858
|
* @param callback 回调函数
|
|
3889
3859
|
*/
|
|
3890
3860
|
handleKeyboardEvent(keyName, otherKeyList = [], callback) {
|
|
3891
|
-
|
|
3892
|
-
|
|
3893
|
-
|
|
3861
|
+
const keyboardEvent = function (event) {
|
|
3862
|
+
const _keyName = event.code || event.key;
|
|
3863
|
+
const _keyValue = event.charCode || event.keyCode || event.which;
|
|
3894
3864
|
if (otherKeyList.includes("ctrl") && !event.ctrlKey) {
|
|
3895
3865
|
return;
|
|
3896
3866
|
}
|
|
@@ -3932,7 +3902,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3932
3902
|
handlePromptClickEvent(type, inputElement, $btn, eventDetails, callback) {
|
|
3933
3903
|
popsDOMUtils.on($btn, "click", (event) => {
|
|
3934
3904
|
// 额外参数
|
|
3935
|
-
|
|
3905
|
+
const extraParam = {
|
|
3936
3906
|
type: type,
|
|
3937
3907
|
text: inputElement.value,
|
|
3938
3908
|
};
|
|
@@ -3965,7 +3935,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3965
3935
|
// .rightClickMenu
|
|
3966
3936
|
// 单独处理
|
|
3967
3937
|
if (type === "loading" || type === "tooltip" || type === "rightClickMenu") {
|
|
3968
|
-
|
|
3938
|
+
const inst = PopsInstData[type];
|
|
3969
3939
|
if (inst) {
|
|
3970
3940
|
PopsInstanceUtils.removeInstance([inst], "", true);
|
|
3971
3941
|
}
|
|
@@ -3985,7 +3955,7 @@ System.register('pops', [], (function (exports) {
|
|
|
3985
3955
|
else {
|
|
3986
3956
|
// 对配置进行处理
|
|
3987
3957
|
// 选择配置的z-index和已有的pops实例的最大z-index值
|
|
3988
|
-
|
|
3958
|
+
const originZIndex = config.zIndex;
|
|
3989
3959
|
config.zIndex = () => {
|
|
3990
3960
|
const { zIndex: maxZIndex } = PopsInstanceUtils.getPopsMaxZIndex(PopsHandler.handleZIndex(originZIndex) + 100);
|
|
3991
3961
|
return maxZIndex;
|
|
@@ -4105,13 +4075,13 @@ System.register('pops', [], (function (exports) {
|
|
|
4105
4075
|
},
|
|
4106
4076
|
]);
|
|
4107
4077
|
// 先把z-index提取出来
|
|
4108
|
-
|
|
4109
|
-
|
|
4110
|
-
|
|
4111
|
-
|
|
4112
|
-
|
|
4113
|
-
|
|
4114
|
-
|
|
4078
|
+
const zIndex = PopsHandler.handleZIndex(config.zIndex);
|
|
4079
|
+
const maskHTML = PopsElementHandler.createMask(guid, zIndex);
|
|
4080
|
+
const headerBtnHTML = PopsElementHandler.createHeader(popsType, config);
|
|
4081
|
+
const bottomBtnHTML = PopsElementHandler.createBottom(popsType, config);
|
|
4082
|
+
const { headerStyle, headerPStyle } = PopsElementHandler.createHeaderStyle(popsType, config);
|
|
4083
|
+
const { contentStyle, contentPStyle } = PopsElementHandler.createContentStyle(popsType, config);
|
|
4084
|
+
const animHTML = PopsElementHandler.createAnim(guid, popsType, config,
|
|
4115
4085
|
/*html*/ `
|
|
4116
4086
|
<div class="pops-title pops-${popsType}-title" style="text-align: ${config.title.position};${headerStyle}">${config.title.html
|
|
4117
4087
|
? config.title.text
|
|
@@ -4122,15 +4092,15 @@ System.register('pops', [], (function (exports) {
|
|
|
4122
4092
|
/**
|
|
4123
4093
|
* 弹窗的主元素,包括动画层
|
|
4124
4094
|
*/
|
|
4125
|
-
|
|
4126
|
-
|
|
4095
|
+
const $anim = PopsElementHandler.parseElement(animHTML);
|
|
4096
|
+
const { popsElement: $pops, headerCloseBtnElement: $headerCloseBtn, btnOkElement, titleElement: $title, } = PopsHandler.handleQueryElement($anim, popsType);
|
|
4127
4097
|
/** 遮罩层元素 */
|
|
4128
4098
|
let $mask = null;
|
|
4129
4099
|
/** 已创建的元素列表 */
|
|
4130
|
-
|
|
4100
|
+
const elementList = [$anim];
|
|
4131
4101
|
/* 遮罩层元素 */
|
|
4132
4102
|
if (config.mask.enable) {
|
|
4133
|
-
|
|
4103
|
+
const _handleMask_ = PopsHandler.handleMask({
|
|
4134
4104
|
type: popsType,
|
|
4135
4105
|
guid: guid,
|
|
4136
4106
|
config: config,
|
|
@@ -4141,7 +4111,7 @@ System.register('pops', [], (function (exports) {
|
|
|
4141
4111
|
elementList.push($mask);
|
|
4142
4112
|
}
|
|
4143
4113
|
/* 处理返回的配置 */
|
|
4144
|
-
|
|
4114
|
+
const eventDetails = PopsHandler.handleEventDetails(guid, $shadowContainer, $shadowRoot, popsType, $anim, $pops, $mask, config);
|
|
4145
4115
|
/* 为顶部右边的关闭按钮添加点击事件 */
|
|
4146
4116
|
PopsHandler.handleClickEvent("close", $headerCloseBtn, eventDetails, config.btn.close.callback);
|
|
4147
4117
|
/* 为底部ok按钮添加点击事件 */
|
|
@@ -4175,7 +4145,7 @@ System.register('pops', [], (function (exports) {
|
|
|
4175
4145
|
endCallBack: config.dragEndCallBack,
|
|
4176
4146
|
});
|
|
4177
4147
|
}
|
|
4178
|
-
|
|
4148
|
+
const result = PopsHandler.handleResultDetails(eventDetails);
|
|
4179
4149
|
return result;
|
|
4180
4150
|
},
|
|
4181
4151
|
};
|
|
@@ -4309,13 +4279,13 @@ System.register('pops', [], (function (exports) {
|
|
|
4309
4279
|
},
|
|
4310
4280
|
]);
|
|
4311
4281
|
// 先把z-index提取出来
|
|
4312
|
-
|
|
4313
|
-
|
|
4314
|
-
|
|
4315
|
-
|
|
4316
|
-
|
|
4317
|
-
|
|
4318
|
-
|
|
4282
|
+
const zIndex = PopsHandler.handleZIndex(config.zIndex);
|
|
4283
|
+
const maskHTML = PopsElementHandler.createMask(guid, zIndex);
|
|
4284
|
+
const headerBtnHTML = PopsElementHandler.createHeader(popsType, config);
|
|
4285
|
+
const bottomBtnHTML = PopsElementHandler.createBottom(popsType, config);
|
|
4286
|
+
const { headerStyle, headerPStyle } = PopsElementHandler.createHeaderStyle(popsType, config);
|
|
4287
|
+
const { contentStyle, contentPStyle } = PopsElementHandler.createContentStyle(popsType, config);
|
|
4288
|
+
const animHTML = PopsElementHandler.createAnim(guid, popsType, config,
|
|
4319
4289
|
/*html*/ `
|
|
4320
4290
|
<div class="pops-title pops-${popsType}-title" style="text-align: ${config.title.position};${headerStyle}">${config.title.html
|
|
4321
4291
|
? config.title.text
|
|
@@ -4326,8 +4296,8 @@ System.register('pops', [], (function (exports) {
|
|
|
4326
4296
|
/**
|
|
4327
4297
|
* 弹窗的主元素,包括动画层
|
|
4328
4298
|
*/
|
|
4329
|
-
|
|
4330
|
-
|
|
4299
|
+
const $anim = PopsElementHandler.parseElement(animHTML);
|
|
4300
|
+
const { popsElement: $pops, titleElement: $title, headerCloseBtnElement: $btnClose, btnOkElement: $btnOk, btnCancelElement: $btnCancel, btnOtherElement: $btnOther, } = PopsHandler.handleQueryElement($anim, popsType);
|
|
4331
4301
|
/**
|
|
4332
4302
|
* 遮罩层元素
|
|
4333
4303
|
*/
|
|
@@ -4335,10 +4305,10 @@ System.register('pops', [], (function (exports) {
|
|
|
4335
4305
|
/**
|
|
4336
4306
|
* 已创建的元素列表
|
|
4337
4307
|
*/
|
|
4338
|
-
|
|
4308
|
+
const elementList = [$anim];
|
|
4339
4309
|
if (config.mask.enable) {
|
|
4340
4310
|
// 启用遮罩层
|
|
4341
|
-
|
|
4311
|
+
const _handleMask_ = PopsHandler.handleMask({
|
|
4342
4312
|
type: popsType,
|
|
4343
4313
|
guid: guid,
|
|
4344
4314
|
config: config,
|
|
@@ -4348,7 +4318,7 @@ System.register('pops', [], (function (exports) {
|
|
|
4348
4318
|
$mask = _handleMask_.maskElement;
|
|
4349
4319
|
elementList.push($mask);
|
|
4350
4320
|
}
|
|
4351
|
-
|
|
4321
|
+
const eventDetails = PopsHandler.handleEventDetails(guid, $shadowContainer, $shadowRoot, popsType, $anim, $pops, $mask, config);
|
|
4352
4322
|
PopsHandler.handleClickEvent("close", $btnClose, eventDetails, config.btn.close.callback);
|
|
4353
4323
|
PopsHandler.handleClickEvent("ok", $btnOk, eventDetails, config.btn.ok.callback);
|
|
4354
4324
|
PopsHandler.handleClickEvent("cancel", $btnCancel, eventDetails, config.btn.cancel.callback);
|
|
@@ -4380,7 +4350,7 @@ System.register('pops', [], (function (exports) {
|
|
|
4380
4350
|
endCallBack: config.dragEndCallBack,
|
|
4381
4351
|
});
|
|
4382
4352
|
}
|
|
4383
|
-
|
|
4353
|
+
const result = PopsHandler.handleResultDetails(eventDetails);
|
|
4384
4354
|
return result;
|
|
4385
4355
|
},
|
|
4386
4356
|
};
|
|
@@ -4513,13 +4483,13 @@ System.register('pops', [], (function (exports) {
|
|
|
4513
4483
|
},
|
|
4514
4484
|
]);
|
|
4515
4485
|
// 先把z-index提取出来
|
|
4516
|
-
|
|
4517
|
-
|
|
4518
|
-
|
|
4519
|
-
|
|
4520
|
-
|
|
4521
|
-
|
|
4522
|
-
|
|
4486
|
+
const zIndex = PopsHandler.handleZIndex(config.zIndex);
|
|
4487
|
+
const maskHTML = PopsElementHandler.createMask(guid, zIndex);
|
|
4488
|
+
const headerBtnHTML = PopsElementHandler.createHeader(popsType, config);
|
|
4489
|
+
const bottomBtnHTML = PopsElementHandler.createBottom(popsType, config);
|
|
4490
|
+
const { headerStyle, headerPStyle } = PopsElementHandler.createHeaderStyle(popsType, config);
|
|
4491
|
+
const { contentStyle, contentPStyle } = PopsElementHandler.createContentStyle(popsType, config);
|
|
4492
|
+
const animHTML = PopsElementHandler.createAnim(guid, popsType, config,
|
|
4523
4493
|
/*html*/ `
|
|
4524
4494
|
${config.title.enable
|
|
4525
4495
|
? /*html*/ `<div class="pops-title pops-${popsType}-title" style="${headerStyle}">${config.title.html
|
|
@@ -4532,13 +4502,13 @@ System.register('pops', [], (function (exports) {
|
|
|
4532
4502
|
/**
|
|
4533
4503
|
* 弹窗的主元素,包括动画层
|
|
4534
4504
|
*/
|
|
4535
|
-
|
|
4536
|
-
|
|
4537
|
-
|
|
4538
|
-
|
|
4539
|
-
|
|
4540
|
-
|
|
4541
|
-
|
|
4505
|
+
const $anim = PopsElementHandler.parseElement(animHTML);
|
|
4506
|
+
const { popsElement, headerCloseBtnElement, btnCancelElement, btnOkElement, btnOtherElement } = PopsHandler.handleQueryElement($anim, popsType);
|
|
4507
|
+
const $pops = popsElement;
|
|
4508
|
+
const $headerCloseBtn = headerCloseBtnElement;
|
|
4509
|
+
const $btnCancel = btnCancelElement;
|
|
4510
|
+
const $btnOk = btnOkElement;
|
|
4511
|
+
const $btnOther = btnOtherElement;
|
|
4542
4512
|
/**
|
|
4543
4513
|
* 遮罩层元素
|
|
4544
4514
|
*/
|
|
@@ -4546,9 +4516,9 @@ System.register('pops', [], (function (exports) {
|
|
|
4546
4516
|
/**
|
|
4547
4517
|
* 已创建的元素列表
|
|
4548
4518
|
*/
|
|
4549
|
-
|
|
4519
|
+
const elementList = [$anim];
|
|
4550
4520
|
if (config.mask.enable) {
|
|
4551
|
-
|
|
4521
|
+
const _handleMask_ = PopsHandler.handleMask({
|
|
4552
4522
|
type: popsType,
|
|
4553
4523
|
guid: guid,
|
|
4554
4524
|
config: config,
|
|
@@ -4558,7 +4528,7 @@ System.register('pops', [], (function (exports) {
|
|
|
4558
4528
|
$mask = _handleMask_.maskElement;
|
|
4559
4529
|
elementList.push($mask);
|
|
4560
4530
|
}
|
|
4561
|
-
|
|
4531
|
+
const eventDetails = PopsHandler.handleEventDetails(guid, $shadowContainer, $shadowRoot, popsType, $anim, $pops, $mask, config);
|
|
4562
4532
|
/* 处理方向 */
|
|
4563
4533
|
$pops.setAttribute("direction", config.direction);
|
|
4564
4534
|
/* 处理border-radius */
|
|
@@ -4586,7 +4556,7 @@ System.register('pops', [], (function (exports) {
|
|
|
4586
4556
|
});
|
|
4587
4557
|
}
|
|
4588
4558
|
/* 待处理的点击事件列表 */
|
|
4589
|
-
|
|
4559
|
+
const needHandleClickEventList = [
|
|
4590
4560
|
{
|
|
4591
4561
|
type: "close",
|
|
4592
4562
|
ele: $headerCloseBtn,
|
|
@@ -4654,7 +4624,7 @@ System.register('pops', [], (function (exports) {
|
|
|
4654
4624
|
$shadowContainer: $shadowContainer,
|
|
4655
4625
|
$shadowRoot: $shadowRoot,
|
|
4656
4626
|
});
|
|
4657
|
-
|
|
4627
|
+
const result = PopsHandler.handleResultDetails(eventDetails);
|
|
4658
4628
|
return result;
|
|
4659
4629
|
},
|
|
4660
4630
|
};
|
|
@@ -4692,14 +4662,14 @@ System.register('pops', [], (function (exports) {
|
|
|
4692
4662
|
let config = PopsLoadingConfig();
|
|
4693
4663
|
config = popsUtils.assign(config, GlobalConfig.getGlobalConfig());
|
|
4694
4664
|
config = popsUtils.assign(config, details);
|
|
4695
|
-
|
|
4665
|
+
const guid = popsUtils.getRandomGUID();
|
|
4696
4666
|
const PopsType = "loading";
|
|
4697
4667
|
config = PopsHandler.handleOnly(PopsType, config);
|
|
4698
4668
|
// 先把z-index提取出来
|
|
4699
|
-
|
|
4700
|
-
|
|
4701
|
-
|
|
4702
|
-
|
|
4669
|
+
const zIndex = PopsHandler.handleZIndex(config.zIndex);
|
|
4670
|
+
const maskHTML = PopsElementHandler.createMask(guid, zIndex);
|
|
4671
|
+
const { contentPStyle } = PopsElementHandler.createContentStyle("loading", config);
|
|
4672
|
+
const animHTML = PopsElementHandler.createAnim(guid, PopsType, config,
|
|
4703
4673
|
/*html*/ `
|
|
4704
4674
|
<div class="pops-content pops-${PopsType}-content">${config.addIndexCSS
|
|
4705
4675
|
? /*html*/ `
|
|
@@ -4717,8 +4687,8 @@ System.register('pops', [], (function (exports) {
|
|
|
4717
4687
|
/**
|
|
4718
4688
|
* 弹窗的主元素,包括动画层
|
|
4719
4689
|
*/
|
|
4720
|
-
|
|
4721
|
-
|
|
4690
|
+
const $anim = PopsElementHandler.parseElement(animHTML);
|
|
4691
|
+
const { popsElement: $pops } = PopsHandler.handleQueryElement($anim, PopsType);
|
|
4722
4692
|
/**
|
|
4723
4693
|
* 遮罩层元素
|
|
4724
4694
|
*/
|
|
@@ -4726,10 +4696,10 @@ System.register('pops', [], (function (exports) {
|
|
|
4726
4696
|
/**
|
|
4727
4697
|
* 已创建的元素列表
|
|
4728
4698
|
*/
|
|
4729
|
-
|
|
4699
|
+
const elementList = [$anim];
|
|
4730
4700
|
if (config.mask.enable) {
|
|
4731
4701
|
// 创建遮罩层
|
|
4732
|
-
|
|
4702
|
+
const _handleMask_ = PopsHandler.handleMask({
|
|
4733
4703
|
type: PopsType,
|
|
4734
4704
|
guid: guid,
|
|
4735
4705
|
config: config,
|
|
@@ -4739,7 +4709,7 @@ System.register('pops', [], (function (exports) {
|
|
|
4739
4709
|
$mask = _handleMask_.maskElement;
|
|
4740
4710
|
elementList.push($mask);
|
|
4741
4711
|
}
|
|
4742
|
-
|
|
4712
|
+
const eventDetails = PopsHandler.handleLoadingEventDetails(guid, PopsType, $anim, $pops, $mask, config);
|
|
4743
4713
|
popsDOMUtils.append(config.parent, elementList);
|
|
4744
4714
|
if ($mask != null) {
|
|
4745
4715
|
$anim.after($mask);
|
|
@@ -4756,7 +4726,7 @@ System.register('pops', [], (function (exports) {
|
|
|
4756
4726
|
popsDOMUtils.css($anim, "position", "absolute !important");
|
|
4757
4727
|
$mask && popsDOMUtils.css($mask, "position", "absolute !important");
|
|
4758
4728
|
}
|
|
4759
|
-
|
|
4729
|
+
const result = PopsHandler.handleResultDetails(eventDetails);
|
|
4760
4730
|
return result;
|
|
4761
4731
|
},
|
|
4762
4732
|
};
|
|
@@ -4976,20 +4946,14 @@ System.register('pops', [], (function (exports) {
|
|
|
4976
4946
|
},
|
|
4977
4947
|
]);
|
|
4978
4948
|
/* 办公几件套 */
|
|
4979
|
-
|
|
4980
|
-
Folder_ICON
|
|
4981
|
-
|
|
4982
|
-
Folder_ICON
|
|
4983
|
-
|
|
4984
|
-
Folder_ICON
|
|
4985
|
-
// @ts-ignore
|
|
4986
|
-
Folder_ICON.pptx = Folder_ICON.ppt;
|
|
4987
|
-
// @ts-ignore;
|
|
4988
|
-
Folder_ICON.dmg = Folder_ICON.ipa;
|
|
4989
|
-
// @ts-ignore
|
|
4990
|
-
Folder_ICON.json = Folder_ICON.js;
|
|
4949
|
+
Reflect.set(Folder_ICON, "docx", Folder_ICON.doc);
|
|
4950
|
+
Reflect.set(Folder_ICON, "rtf", Folder_ICON.doc);
|
|
4951
|
+
Reflect.set(Folder_ICON, "xlsx", Folder_ICON.xls);
|
|
4952
|
+
Reflect.set(Folder_ICON, "pptx", Folder_ICON.ppt);
|
|
4953
|
+
Reflect.set(Folder_ICON, "dmg", Folder_ICON.ipa);
|
|
4954
|
+
Reflect.set(Folder_ICON, "json", Folder_ICON.js);
|
|
4991
4955
|
/* 压缩包 */
|
|
4992
|
-
|
|
4956
|
+
const zipIconList = [
|
|
4993
4957
|
"rar",
|
|
4994
4958
|
"7z",
|
|
4995
4959
|
"arj",
|
|
@@ -5008,11 +4972,11 @@ System.register('pops', [], (function (exports) {
|
|
|
5008
4972
|
"001",
|
|
5009
4973
|
];
|
|
5010
4974
|
/* 图片 */
|
|
5011
|
-
|
|
4975
|
+
const imageIconList = ["jpg", "jpeg", "ico", "webp"];
|
|
5012
4976
|
/* 代码语言 */
|
|
5013
|
-
|
|
4977
|
+
const codeLanguageIconList = ["htm", "py", "vue", "bat", "sh", "vbs", "java", "kt"];
|
|
5014
4978
|
/* Android安装包 */
|
|
5015
|
-
|
|
4979
|
+
const androidIconList = ["apk", "apkm", "xapk"];
|
|
5016
4980
|
zipIconList.forEach((keyName) => {
|
|
5017
4981
|
Folder_ICON[keyName] = Folder_ICON.zip;
|
|
5018
4982
|
});
|
|
@@ -5026,16 +4990,15 @@ System.register('pops', [], (function (exports) {
|
|
|
5026
4990
|
Folder_ICON[keyName] = Folder_ICON.apk;
|
|
5027
4991
|
});
|
|
5028
4992
|
if (details?.folder) {
|
|
5029
|
-
|
|
5030
|
-
config.folder = details.folder;
|
|
4993
|
+
Reflect.set(config, "folder", details.folder);
|
|
5031
4994
|
}
|
|
5032
4995
|
// 先把z-index提取出来
|
|
5033
|
-
|
|
5034
|
-
|
|
5035
|
-
|
|
5036
|
-
|
|
5037
|
-
|
|
5038
|
-
|
|
4996
|
+
const zIndex = PopsHandler.handleZIndex(config.zIndex);
|
|
4997
|
+
const maskHTML = PopsElementHandler.createMask(guid, zIndex);
|
|
4998
|
+
const headerBtnHTML = PopsElementHandler.createHeader(popsType, config);
|
|
4999
|
+
const bottomBtnHTML = PopsElementHandler.createBottom(popsType, config);
|
|
5000
|
+
const { headerStyle, headerPStyle } = PopsElementHandler.createHeaderStyle(popsType, config);
|
|
5001
|
+
const animHTML = PopsElementHandler.createAnim(guid, popsType, config,
|
|
5039
5002
|
/*html*/ `
|
|
5040
5003
|
<div class="pops-title pops-${popsType}-title" style="text-align: ${config.title.position};${headerStyle}">${config.title.html
|
|
5041
5004
|
? config.title.text
|
|
@@ -5137,8 +5100,8 @@ System.register('pops', [], (function (exports) {
|
|
|
5137
5100
|
/**
|
|
5138
5101
|
* 弹窗的主元素,包括动画层
|
|
5139
5102
|
*/
|
|
5140
|
-
|
|
5141
|
-
|
|
5103
|
+
const $anim = PopsElementHandler.parseElement(animHTML);
|
|
5104
|
+
const { popsElement: $pops, titleElement: $title, contentElement: $content,
|
|
5142
5105
|
// folderListElement,
|
|
5143
5106
|
// folderListHeaderElement,
|
|
5144
5107
|
// folderListHeaderRowElement,
|
|
@@ -5150,9 +5113,9 @@ System.register('pops', [], (function (exports) {
|
|
|
5150
5113
|
/**
|
|
5151
5114
|
* 已创建的元素列表
|
|
5152
5115
|
*/
|
|
5153
|
-
|
|
5116
|
+
const elementList = [$anim];
|
|
5154
5117
|
if (config.mask.enable) {
|
|
5155
|
-
|
|
5118
|
+
const _handleMask_ = PopsHandler.handleMask({
|
|
5156
5119
|
type: popsType,
|
|
5157
5120
|
guid: guid,
|
|
5158
5121
|
config: config,
|
|
@@ -5163,7 +5126,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5163
5126
|
elementList.push($mask);
|
|
5164
5127
|
}
|
|
5165
5128
|
/* 事件 */
|
|
5166
|
-
|
|
5129
|
+
const eventDetails = PopsHandler.handleEventDetails(guid, $shadowContainer, $shadowRoot, popsType, $anim, $pops, $mask, config);
|
|
5167
5130
|
PopsHandler.handleClickEvent("close", $btnCloseBtn, eventDetails, config.btn.close.callback);
|
|
5168
5131
|
PopsHandler.handleClickEvent("ok", btnOkElement, eventDetails, config.btn.ok.callback);
|
|
5169
5132
|
PopsHandler.handleClickEvent("cancel", btnCancelElement, eventDetails, config.btn.cancel.callback);
|
|
@@ -5182,7 +5145,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5182
5145
|
config.folder.sort();
|
|
5183
5146
|
this.initFolderView(config.folder);
|
|
5184
5147
|
/* 将数据存到全部文件的属性_config_中 */
|
|
5185
|
-
|
|
5148
|
+
const allFilesElement = folderFileListBreadcrumbPrimaryElement.querySelector(".pops-folder-list .pops-folder-file-list-breadcrumb-allFiles:first-child");
|
|
5186
5149
|
Reflect.set(allFilesElement, "_config_", config.folder);
|
|
5187
5150
|
/* 设置点击顶部的全部文件事件 */
|
|
5188
5151
|
popsDOMUtils.on(allFilesElement, "click", (event) => {
|
|
@@ -5231,13 +5194,13 @@ System.register('pops', [], (function (exports) {
|
|
|
5231
5194
|
* @param isFolder 是否是文件夹
|
|
5232
5195
|
*/
|
|
5233
5196
|
createFolderRowElement(fileName, latestTime = "-", fileSize = "-", isFolder = false) {
|
|
5234
|
-
|
|
5235
|
-
|
|
5236
|
-
|
|
5237
|
-
|
|
5238
|
-
|
|
5239
|
-
|
|
5240
|
-
|
|
5197
|
+
const origin_fileName = fileName;
|
|
5198
|
+
const origin_latestTime = latestTime;
|
|
5199
|
+
const origin_fileSize = fileSize;
|
|
5200
|
+
const folderElement = popsDOMUtils.createElement("tr");
|
|
5201
|
+
const fileNameElement = popsDOMUtils.createElement("td");
|
|
5202
|
+
const fileTimeElement = popsDOMUtils.createElement("td");
|
|
5203
|
+
const fileFormatSize = popsDOMUtils.createElement("td");
|
|
5241
5204
|
let fileType = "";
|
|
5242
5205
|
let fileIcon = Folder_ICON.folder;
|
|
5243
5206
|
if (isFolder) {
|
|
@@ -5254,14 +5217,14 @@ System.register('pops', [], (function (exports) {
|
|
|
5254
5217
|
if (typeof fileSize === "number") {
|
|
5255
5218
|
fileSize = popsUtils.formatByteToSize(fileSize);
|
|
5256
5219
|
}
|
|
5257
|
-
for (
|
|
5220
|
+
for (const keyName in Folder_ICON) {
|
|
5258
5221
|
if (fileName.toLowerCase().endsWith("." + keyName)) {
|
|
5259
5222
|
fileType = keyName;
|
|
5260
5223
|
fileIcon = Folder_ICON[keyName];
|
|
5261
5224
|
break;
|
|
5262
5225
|
}
|
|
5263
5226
|
}
|
|
5264
|
-
if (!
|
|
5227
|
+
if (!fileIcon) {
|
|
5265
5228
|
fileType = "Null";
|
|
5266
5229
|
fileIcon = Folder_ICON.Null;
|
|
5267
5230
|
}
|
|
@@ -5294,7 +5257,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5294
5257
|
</div>
|
|
5295
5258
|
`);
|
|
5296
5259
|
/* 存储原来的值 */
|
|
5297
|
-
|
|
5260
|
+
const __value__ = {
|
|
5298
5261
|
fileName: origin_fileName,
|
|
5299
5262
|
latestTime: origin_latestTime,
|
|
5300
5263
|
fileSize: origin_fileSize,
|
|
@@ -5322,11 +5285,11 @@ System.register('pops', [], (function (exports) {
|
|
|
5322
5285
|
* @param isFolder 是否是文件夹
|
|
5323
5286
|
*/
|
|
5324
5287
|
createFolderRowElementByMobile(fileName, latestTime = "-", fileSize = "-", isFolder = false) {
|
|
5325
|
-
|
|
5326
|
-
|
|
5327
|
-
|
|
5328
|
-
|
|
5329
|
-
|
|
5288
|
+
const origin_fileName = fileName;
|
|
5289
|
+
const origin_latestTime = latestTime;
|
|
5290
|
+
const origin_fileSize = fileSize;
|
|
5291
|
+
const folderElement = popsDOMUtils.createElement("tr");
|
|
5292
|
+
const fileNameElement = popsDOMUtils.createElement("td");
|
|
5330
5293
|
let fileType = "";
|
|
5331
5294
|
let fileIcon = Folder_ICON.folder;
|
|
5332
5295
|
if (isFolder) {
|
|
@@ -5343,14 +5306,14 @@ System.register('pops', [], (function (exports) {
|
|
|
5343
5306
|
if (typeof fileSize === "number") {
|
|
5344
5307
|
fileSize = popsUtils.formatByteToSize(fileSize);
|
|
5345
5308
|
}
|
|
5346
|
-
for (
|
|
5309
|
+
for (const keyName in Folder_ICON) {
|
|
5347
5310
|
if (fileName.toLowerCase().endsWith("." + keyName)) {
|
|
5348
5311
|
fileType = keyName;
|
|
5349
5312
|
fileIcon = Folder_ICON[keyName];
|
|
5350
5313
|
break;
|
|
5351
5314
|
}
|
|
5352
5315
|
}
|
|
5353
|
-
if (!
|
|
5316
|
+
if (!fileIcon) {
|
|
5354
5317
|
fileType = "Null";
|
|
5355
5318
|
fileIcon = Folder_ICON.Null;
|
|
5356
5319
|
}
|
|
@@ -5368,7 +5331,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5368
5331
|
</div>
|
|
5369
5332
|
`);
|
|
5370
5333
|
/* 存储原来的值 */
|
|
5371
|
-
|
|
5334
|
+
const __value__ = {
|
|
5372
5335
|
fileName: origin_fileName,
|
|
5373
5336
|
latestTime: origin_latestTime,
|
|
5374
5337
|
fileSize: origin_fileSize,
|
|
@@ -5392,7 +5355,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5392
5355
|
* 创建顶部导航的箭头图标
|
|
5393
5356
|
*/
|
|
5394
5357
|
createHeaderArrowIcon() {
|
|
5395
|
-
|
|
5358
|
+
const $arrowIcon = popsDOMUtils.createElement("div", {
|
|
5396
5359
|
className: "iconArrow",
|
|
5397
5360
|
});
|
|
5398
5361
|
return $arrowIcon;
|
|
@@ -5403,7 +5366,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5403
5366
|
* @param folderDataConfig 文件夹配置
|
|
5404
5367
|
*/
|
|
5405
5368
|
createBreadcrumb(folderName, folderDataConfig) {
|
|
5406
|
-
|
|
5369
|
+
const $breadcrumb = popsDOMUtils.createElement("span", {
|
|
5407
5370
|
className: "pops-folder-file-list-breadcrumb-allFiles cursor-p",
|
|
5408
5371
|
innerHTML: `<a>${folderName}</a>`,
|
|
5409
5372
|
_config_: folderDataConfig,
|
|
@@ -5421,8 +5384,8 @@ System.register('pops', [], (function (exports) {
|
|
|
5421
5384
|
setBreadcrumbClickEvent(clickEvent, isTop, dataConfigList) {
|
|
5422
5385
|
this.clearFolderInfoView();
|
|
5423
5386
|
/* 获取当前的导航元素 */
|
|
5424
|
-
|
|
5425
|
-
|
|
5387
|
+
const $click = clickEvent.target;
|
|
5388
|
+
const currentBreadcrumb = $click.closest("span.pops-folder-file-list-breadcrumb-allFiles");
|
|
5426
5389
|
if (currentBreadcrumb) {
|
|
5427
5390
|
while (currentBreadcrumb.nextElementSibling) {
|
|
5428
5391
|
currentBreadcrumb.nextElementSibling.remove();
|
|
@@ -5431,7 +5394,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5431
5394
|
else {
|
|
5432
5395
|
console.error("获取导航按钮失败");
|
|
5433
5396
|
}
|
|
5434
|
-
|
|
5397
|
+
const loadingMask = PopsLoading.init({
|
|
5435
5398
|
parent: $content,
|
|
5436
5399
|
content: {
|
|
5437
5400
|
text: "获取文件列表中...",
|
|
@@ -5457,7 +5420,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5457
5420
|
*/
|
|
5458
5421
|
async enterFolder(clickEvent, dataConfig) {
|
|
5459
5422
|
this.clearFolderInfoView();
|
|
5460
|
-
|
|
5423
|
+
const loadingMask = PopsLoading.init({
|
|
5461
5424
|
parent: $content,
|
|
5462
5425
|
content: {
|
|
5463
5426
|
text: "获取文件列表中...",
|
|
@@ -5468,11 +5431,11 @@ System.register('pops', [], (function (exports) {
|
|
|
5468
5431
|
addIndexCSS: false,
|
|
5469
5432
|
});
|
|
5470
5433
|
if (typeof dataConfig.clickEvent === "function") {
|
|
5471
|
-
|
|
5434
|
+
const childConfig = await dataConfig.clickEvent(clickEvent, dataConfig);
|
|
5472
5435
|
/* 添加顶部导航的箭头 */
|
|
5473
5436
|
folderFileListBreadcrumbPrimaryElement.appendChild(this.createHeaderArrowIcon());
|
|
5474
5437
|
/* 添加顶部导航的链接文字 */
|
|
5475
|
-
|
|
5438
|
+
const breadcrumbAllFilesElement = this.createBreadcrumb(dataConfig.fileName, childConfig);
|
|
5476
5439
|
folderFileListBreadcrumbPrimaryElement.appendChild(breadcrumbAllFilesElement);
|
|
5477
5440
|
/* 设置顶部导航点击事件 */
|
|
5478
5441
|
popsDOMUtils.on(breadcrumbAllFilesElement, "click", (event) => {
|
|
@@ -5489,9 +5452,9 @@ System.register('pops', [], (function (exports) {
|
|
|
5489
5452
|
*/
|
|
5490
5453
|
async downloadFile(clickEvent, $row, dataConfig) {
|
|
5491
5454
|
popsDOMUtils.preventEvent(clickEvent);
|
|
5492
|
-
|
|
5455
|
+
const $link = $row.querySelector("a");
|
|
5493
5456
|
if (typeof dataConfig.clickEvent === "function") {
|
|
5494
|
-
|
|
5457
|
+
const downloadInfo = await dataConfig.clickEvent(clickEvent, dataConfig);
|
|
5495
5458
|
if (downloadInfo != null &&
|
|
5496
5459
|
typeof downloadInfo === "object" &&
|
|
5497
5460
|
!Array.isArray(downloadInfo) &&
|
|
@@ -5506,7 +5469,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5506
5469
|
}
|
|
5507
5470
|
if (downloadInfo.mode === "a" || downloadInfo.mode === "aBlank") {
|
|
5508
5471
|
/* a标签下载 */
|
|
5509
|
-
|
|
5472
|
+
const downloadLinkElement = document.createElement("a");
|
|
5510
5473
|
if (downloadInfo.mode === "aBlank") {
|
|
5511
5474
|
downloadLinkElement.setAttribute("target", "_blank");
|
|
5512
5475
|
}
|
|
@@ -5524,7 +5487,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5524
5487
|
}
|
|
5525
5488
|
else if (downloadInfo.mode === "iframe") {
|
|
5526
5489
|
/* iframe下载 */
|
|
5527
|
-
|
|
5490
|
+
const downloadIframeLinkElement = document.createElement("iframe");
|
|
5528
5491
|
downloadIframeLinkElement.src = downloadInfo.url;
|
|
5529
5492
|
downloadIframeLinkElement.onload = function () {
|
|
5530
5493
|
popsUtils.setTimeout(() => {
|
|
@@ -5552,16 +5515,16 @@ System.register('pops', [], (function (exports) {
|
|
|
5552
5515
|
sortFolderConfig(folderDataConfigList, sortName = "fileName", isDesc = false) {
|
|
5553
5516
|
if (sortName === "fileName") {
|
|
5554
5517
|
// 如果是以文件名排序,文件夹优先放前面
|
|
5555
|
-
|
|
5518
|
+
const onlyFolderDataConfigList = folderDataConfigList.filter((value) => {
|
|
5556
5519
|
return value.isFolder;
|
|
5557
5520
|
});
|
|
5558
|
-
|
|
5521
|
+
const onlyFileDataConfigList = folderDataConfigList.filter((value) => {
|
|
5559
5522
|
return !value.isFolder;
|
|
5560
5523
|
});
|
|
5561
5524
|
// 文件夹排序
|
|
5562
5525
|
onlyFolderDataConfigList.sort((leftConfig, rightConfig) => {
|
|
5563
|
-
|
|
5564
|
-
|
|
5526
|
+
const beforeVal = leftConfig[sortName].toString();
|
|
5527
|
+
const afterVal = rightConfig[sortName].toString();
|
|
5565
5528
|
let compareVal = beforeVal.localeCompare(afterVal);
|
|
5566
5529
|
if (isDesc) {
|
|
5567
5530
|
/* 降序 */
|
|
@@ -5576,8 +5539,8 @@ System.register('pops', [], (function (exports) {
|
|
|
5576
5539
|
});
|
|
5577
5540
|
// 文件名排序
|
|
5578
5541
|
onlyFileDataConfigList.sort((leftConfig, rightConfig) => {
|
|
5579
|
-
|
|
5580
|
-
|
|
5542
|
+
const beforeVal = leftConfig[sortName].toString();
|
|
5543
|
+
const afterVal = rightConfig[sortName].toString();
|
|
5581
5544
|
let compareVal = beforeVal.localeCompare(afterVal);
|
|
5582
5545
|
if (isDesc) {
|
|
5583
5546
|
/* 降序 */
|
|
@@ -5647,7 +5610,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5647
5610
|
this.sortFolderConfig(dataConfig, config.sort.name, config.sort.isDesc);
|
|
5648
5611
|
dataConfig.forEach((item) => {
|
|
5649
5612
|
if (item.isFolder) {
|
|
5650
|
-
|
|
5613
|
+
const { folderElement, fileNameElement } = popsUtils.isPhone()
|
|
5651
5614
|
? this.createFolderRowElementByMobile(item.fileName, "", "", true)
|
|
5652
5615
|
: this.createFolderRowElement(item.fileName, "", "", true);
|
|
5653
5616
|
// 文件夹 - 点击事件
|
|
@@ -5658,7 +5621,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5658
5621
|
folderListBodyElement.appendChild(folderElement);
|
|
5659
5622
|
}
|
|
5660
5623
|
else {
|
|
5661
|
-
|
|
5624
|
+
const { folderElement, fileNameElement } = popsUtils.isPhone()
|
|
5662
5625
|
? this.createFolderRowElementByMobile(item.fileName, item.latestTime, item.fileSize, false)
|
|
5663
5626
|
: this.createFolderRowElement(item.fileName, item.latestTime, item.fileSize, false);
|
|
5664
5627
|
// 文件 - 点击事件
|
|
@@ -5704,20 +5667,20 @@ System.register('pops', [], (function (exports) {
|
|
|
5704
5667
|
config.sort.name = sortName;
|
|
5705
5668
|
config.sort.isDesc = !config.sort.isDesc;
|
|
5706
5669
|
}
|
|
5707
|
-
|
|
5708
|
-
|
|
5670
|
+
const arrowUp = target.querySelector(".pops-folder-icon-arrow-up");
|
|
5671
|
+
const arrowDown = target.querySelector(".pops-folder-icon-arrow-down");
|
|
5709
5672
|
this.changeArrowActive(arrowUp, arrowDown, config.sort.isDesc);
|
|
5710
5673
|
if (typeof config.sort.callback === "function" &&
|
|
5711
5674
|
config.sort.callback(target, event, config.sort.name, config.sort.isDesc)) {
|
|
5712
5675
|
return;
|
|
5713
5676
|
}
|
|
5714
|
-
|
|
5677
|
+
const childrenList = [];
|
|
5715
5678
|
Array.from(folderListBodyElement.children).forEach((trElement) => {
|
|
5716
|
-
|
|
5679
|
+
const __value__ = Reflect.get(trElement, "__value__");
|
|
5717
5680
|
Reflect.set(__value__, "target", trElement);
|
|
5718
5681
|
childrenList.push(__value__);
|
|
5719
5682
|
});
|
|
5720
|
-
|
|
5683
|
+
const sortedConfigList = this.sortFolderConfig(childrenList, config.sort.name, config.sort.isDesc);
|
|
5721
5684
|
sortedConfigList.forEach((item) => {
|
|
5722
5685
|
folderListBodyElement.appendChild(item.target);
|
|
5723
5686
|
});
|
|
@@ -5744,7 +5707,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5744
5707
|
$shadowContainer: $shadowContainer,
|
|
5745
5708
|
$shadowRoot: $shadowRoot,
|
|
5746
5709
|
});
|
|
5747
|
-
|
|
5710
|
+
const result = PopsHandler.handleResultDetails(eventDetails);
|
|
5748
5711
|
return result;
|
|
5749
5712
|
},
|
|
5750
5713
|
};
|
|
@@ -5846,17 +5809,15 @@ System.register('pops', [], (function (exports) {
|
|
|
5846
5809
|
css: PopsCSS.iframeCSS,
|
|
5847
5810
|
},
|
|
5848
5811
|
]);
|
|
5849
|
-
|
|
5850
|
-
// @ts-ignore
|
|
5851
|
-
config.animation != null && config.animation != "" ? "position:absolute;" : "";
|
|
5812
|
+
const maskExtraStyle = config.animation != null && config.animation != "" ? "position:absolute;" : "";
|
|
5852
5813
|
// 先把z-index提取出来
|
|
5853
|
-
|
|
5854
|
-
|
|
5855
|
-
|
|
5856
|
-
|
|
5857
|
-
|
|
5858
|
-
|
|
5859
|
-
|
|
5814
|
+
const zIndex = PopsHandler.handleZIndex(config.zIndex);
|
|
5815
|
+
const maskHTML = PopsElementHandler.createMask(guid, zIndex, maskExtraStyle);
|
|
5816
|
+
const headerBtnHTML = PopsElementHandler.createHeader(popsType, config);
|
|
5817
|
+
const iframeLoadingHTML = '<div class="pops-loading"></div>';
|
|
5818
|
+
const titleText = config.title.text.trim() !== "" ? config.title.text : config.url;
|
|
5819
|
+
const { headerStyle, headerPStyle } = PopsElementHandler.createHeaderStyle(popsType, config);
|
|
5820
|
+
const animHTML = PopsElementHandler.createAnim(guid, popsType, config,
|
|
5860
5821
|
/*html*/ `
|
|
5861
5822
|
<div class="pops-title pops-${popsType}-title" style="text-align: ${config.title.position};${headerStyle}">${config.title.html
|
|
5862
5823
|
? titleText
|
|
@@ -5869,14 +5830,14 @@ System.register('pops', [], (function (exports) {
|
|
|
5869
5830
|
/**
|
|
5870
5831
|
* 弹窗的主元素,包括动画层
|
|
5871
5832
|
*/
|
|
5872
|
-
|
|
5873
|
-
|
|
5833
|
+
const $anim = PopsElementHandler.parseElement(animHTML);
|
|
5834
|
+
const { popsElement: $pops, headerCloseBtnElement, headerControlsElement, titleElement: $title, iframeElement: $iframe, loadingElement, contentLoadingElement: $contentLoading, headerMinBtnElement, headerMaxBtnElement, headerMiseBtnElement, } = PopsHandler.handleQueryElement($anim, popsType);
|
|
5874
5835
|
let $iframeContainer = PopsCore.document.querySelector(".pops-iframe-container");
|
|
5875
5836
|
if (!$iframeContainer) {
|
|
5876
5837
|
$iframeContainer = PopsCore.document.createElement("div");
|
|
5877
5838
|
$iframeContainer.className = "pops-iframe-container";
|
|
5878
5839
|
$iframeContainer.style.cssText =
|
|
5879
|
-
"display: flex;position: fixed;bottom: 0px;flex-flow: wrap-reverse
|
|
5840
|
+
"display: flex;position: fixed;bottom: 0px;flex-flow: wrap-reverse;-webkit-user-select: none;-moz-user-select: none;-ms-user-select: none;user-select: none;";
|
|
5880
5841
|
popsDOMUtils.appendBody($iframeContainer);
|
|
5881
5842
|
}
|
|
5882
5843
|
/**
|
|
@@ -5886,9 +5847,9 @@ System.register('pops', [], (function (exports) {
|
|
|
5886
5847
|
/**
|
|
5887
5848
|
* 已创建的元素列表
|
|
5888
5849
|
*/
|
|
5889
|
-
|
|
5850
|
+
const elementList = [$anim];
|
|
5890
5851
|
if (config.mask.enable) {
|
|
5891
|
-
|
|
5852
|
+
const _handleMask_ = PopsHandler.handleMask({
|
|
5892
5853
|
type: popsType,
|
|
5893
5854
|
guid: guid,
|
|
5894
5855
|
config: config,
|
|
@@ -5898,7 +5859,7 @@ System.register('pops', [], (function (exports) {
|
|
|
5898
5859
|
$mask = _handleMask_.maskElement;
|
|
5899
5860
|
elementList.push($mask);
|
|
5900
5861
|
}
|
|
5901
|
-
|
|
5862
|
+
const eventDetails = PopsHandler.handleEventDetails(guid, $shadowContainer, $shadowRoot, popsType, $anim, $pops, $mask, config);
|
|
5902
5863
|
eventDetails["iframeElement"] = $iframe;
|
|
5903
5864
|
popsDOMUtils.on($anim, popsDOMUtils.getAnimationEndNameList(), function () {
|
|
5904
5865
|
/* 动画加载完毕 */
|
|
@@ -6049,7 +6010,7 @@ System.register('pops', [], (function (exports) {
|
|
|
6049
6010
|
$shadowContainer: $shadowContainer,
|
|
6050
6011
|
$shadowRoot: $shadowRoot,
|
|
6051
6012
|
});
|
|
6052
|
-
|
|
6013
|
+
const result = PopsHandler.handleResultDetails(eventDetails);
|
|
6053
6014
|
return result;
|
|
6054
6015
|
},
|
|
6055
6016
|
};
|
|
@@ -6320,7 +6281,7 @@ System.register('pops', [], (function (exports) {
|
|
|
6320
6281
|
text: "单选3",
|
|
6321
6282
|
isHTML: false,
|
|
6322
6283
|
disable(value, allSelectedInfo) {
|
|
6323
|
-
return
|
|
6284
|
+
return allSelectedInfo.findIndex((it) => ["select-2", "select-5"].includes(it.value)) !== -1;
|
|
6324
6285
|
},
|
|
6325
6286
|
},
|
|
6326
6287
|
{
|
|
@@ -6328,7 +6289,7 @@ System.register('pops', [], (function (exports) {
|
|
|
6328
6289
|
text: "单选4",
|
|
6329
6290
|
isHTML: false,
|
|
6330
6291
|
disable(value, allSelectedInfo) {
|
|
6331
|
-
return
|
|
6292
|
+
return allSelectedInfo.findIndex((it) => ["select-3", "select-5"].includes(it.value)) !== -1;
|
|
6332
6293
|
},
|
|
6333
6294
|
},
|
|
6334
6295
|
{
|
|
@@ -6510,7 +6471,7 @@ System.register('pops', [], (function (exports) {
|
|
|
6510
6471
|
// @ts-ignore
|
|
6511
6472
|
props: {},
|
|
6512
6473
|
forms: [],
|
|
6513
|
-
clickFirstCallback: function (
|
|
6474
|
+
clickFirstCallback: function () {
|
|
6514
6475
|
return false;
|
|
6515
6476
|
},
|
|
6516
6477
|
},
|
|
@@ -6527,7 +6488,7 @@ System.register('pops', [], (function (exports) {
|
|
|
6527
6488
|
// @ts-ignore
|
|
6528
6489
|
props: {},
|
|
6529
6490
|
forms: [],
|
|
6530
|
-
clickFirstCallback: function (
|
|
6491
|
+
clickFirstCallback: function () {
|
|
6531
6492
|
return false;
|
|
6532
6493
|
},
|
|
6533
6494
|
},
|
|
@@ -6584,20 +6545,20 @@ System.register('pops', [], (function (exports) {
|
|
|
6584
6545
|
* @param number2
|
|
6585
6546
|
*/
|
|
6586
6547
|
add(number1, number2) {
|
|
6587
|
-
let number1length, number2length
|
|
6548
|
+
let number1length, number2length;
|
|
6588
6549
|
try {
|
|
6589
6550
|
number1length = number1.toString().split(".")[1].length;
|
|
6590
6551
|
}
|
|
6591
|
-
catch
|
|
6552
|
+
catch {
|
|
6592
6553
|
number1length = 0;
|
|
6593
6554
|
}
|
|
6594
6555
|
try {
|
|
6595
6556
|
number2length = number2.toString().split(".")[1].length;
|
|
6596
6557
|
}
|
|
6597
|
-
catch
|
|
6558
|
+
catch {
|
|
6598
6559
|
number2length = 0;
|
|
6599
6560
|
}
|
|
6600
|
-
powValue = Math.pow(10, Math.max(number1length, number2length));
|
|
6561
|
+
const powValue = Math.pow(10, Math.max(number1length, number2length));
|
|
6601
6562
|
return Math.round(number1 * powValue + number2 * powValue) / powValue;
|
|
6602
6563
|
},
|
|
6603
6564
|
/**
|
|
@@ -6606,21 +6567,21 @@ System.register('pops', [], (function (exports) {
|
|
|
6606
6567
|
* @param number2
|
|
6607
6568
|
*/
|
|
6608
6569
|
sub(number1, number2) {
|
|
6609
|
-
let number1length, number2length
|
|
6570
|
+
let number1length, number2length;
|
|
6610
6571
|
try {
|
|
6611
6572
|
number1length = number1.toString().split(".")[1].length;
|
|
6612
6573
|
}
|
|
6613
|
-
catch
|
|
6574
|
+
catch {
|
|
6614
6575
|
number1length = 0;
|
|
6615
6576
|
}
|
|
6616
6577
|
try {
|
|
6617
6578
|
number2length = number2.toString().split(".")[1].length;
|
|
6618
6579
|
}
|
|
6619
|
-
catch
|
|
6580
|
+
catch {
|
|
6620
6581
|
number2length = 0;
|
|
6621
6582
|
}
|
|
6622
|
-
powValue = Math.pow(10, Math.max(number1length, number2length));
|
|
6623
|
-
|
|
6583
|
+
const powValue = Math.pow(10, Math.max(number1length, number2length));
|
|
6584
|
+
const fixedValue = number1length >= number2length ? number1length : number2length;
|
|
6624
6585
|
return (Math.round(number1 * powValue - number2 * powValue) / powValue).toFixed(fixedValue);
|
|
6625
6586
|
},
|
|
6626
6587
|
/**
|
|
@@ -6629,21 +6590,21 @@ System.register('pops', [], (function (exports) {
|
|
|
6629
6590
|
* @param number2
|
|
6630
6591
|
*/
|
|
6631
6592
|
division(number1, number2) {
|
|
6632
|
-
let number1length, number2length
|
|
6593
|
+
let number1length, number2length;
|
|
6633
6594
|
try {
|
|
6634
6595
|
number1length = number1.toString().split(".")[1].length;
|
|
6635
6596
|
}
|
|
6636
|
-
catch
|
|
6597
|
+
catch {
|
|
6637
6598
|
number1length = 0;
|
|
6638
6599
|
}
|
|
6639
6600
|
try {
|
|
6640
6601
|
number2length = number2.toString().split(".")[1].length;
|
|
6641
6602
|
}
|
|
6642
|
-
catch
|
|
6603
|
+
catch {
|
|
6643
6604
|
number2length = 0;
|
|
6644
6605
|
}
|
|
6645
|
-
number1ReplaceValue = Number(number1.toString().replace(".", ""));
|
|
6646
|
-
number2ReplaceValue = Number(number2.toString().replace(".", ""));
|
|
6606
|
+
const number1ReplaceValue = Number(number1.toString().replace(".", ""));
|
|
6607
|
+
const number2ReplaceValue = Number(number2.toString().replace(".", ""));
|
|
6647
6608
|
return (number1ReplaceValue / number2ReplaceValue) * Math.pow(10, number2length - number1length);
|
|
6648
6609
|
},
|
|
6649
6610
|
};
|
|
@@ -6708,7 +6669,7 @@ System.register('pops', [], (function (exports) {
|
|
|
6708
6669
|
this.init();
|
|
6709
6670
|
}
|
|
6710
6671
|
init() {
|
|
6711
|
-
|
|
6672
|
+
const toolTipInfo = this.createToolTip();
|
|
6712
6673
|
this.$el.$toolTip = toolTipInfo.$toolTipContainer;
|
|
6713
6674
|
this.$el.$content = toolTipInfo.$toolTipContent;
|
|
6714
6675
|
this.$el.$arrow = toolTipInfo.$toolTipArrow;
|
|
@@ -6724,7 +6685,7 @@ System.register('pops', [], (function (exports) {
|
|
|
6724
6685
|
* 创建提示元素
|
|
6725
6686
|
*/
|
|
6726
6687
|
createToolTip() {
|
|
6727
|
-
|
|
6688
|
+
const $toolTipContainer = popsDOMUtils.createElement("div", {
|
|
6728
6689
|
className: "pops-tip",
|
|
6729
6690
|
innerHTML: /*html*/ `
|
|
6730
6691
|
<div class="pops-tip-content" style="text-align: center;"></div>
|
|
@@ -6735,9 +6696,9 @@ System.register('pops', [], (function (exports) {
|
|
|
6735
6696
|
"data-guid": this.$data.guid,
|
|
6736
6697
|
});
|
|
6737
6698
|
/** 内容 */
|
|
6738
|
-
|
|
6699
|
+
const $toolTipContent = $toolTipContainer.querySelector(".pops-tip-content");
|
|
6739
6700
|
/** 箭头 */
|
|
6740
|
-
|
|
6701
|
+
const $toolTipArrow = $toolTipContainer.querySelector(".pops-tip-arrow");
|
|
6741
6702
|
// 处理className
|
|
6742
6703
|
if (typeof this.$data.config.className === "string" && this.$data.config.className.trim() !== "") {
|
|
6743
6704
|
popsDOMUtils.addClassName($toolTipContainer, this.$data.config.className);
|
|
@@ -6746,7 +6707,7 @@ System.register('pops', [], (function (exports) {
|
|
|
6746
6707
|
$toolTipContainer.style.zIndex = PopsHandler.handleZIndex(this.$data.config.zIndex).toString();
|
|
6747
6708
|
if (this.$data.config.style != null) {
|
|
6748
6709
|
/* 添加自定义style */
|
|
6749
|
-
|
|
6710
|
+
const cssNode = popsDOMUtils.createElement("style", {
|
|
6750
6711
|
type: "text/css",
|
|
6751
6712
|
innerHTML: this.$data.config.style,
|
|
6752
6713
|
});
|
|
@@ -6766,9 +6727,7 @@ System.register('pops', [], (function (exports) {
|
|
|
6766
6727
|
* 获取提示的内容
|
|
6767
6728
|
*/
|
|
6768
6729
|
getContent() {
|
|
6769
|
-
return typeof this.$data.config.content === "function"
|
|
6770
|
-
? this.$data.config.content()
|
|
6771
|
-
: this.$data.config.content;
|
|
6730
|
+
return typeof this.$data.config.content === "function" ? this.$data.config.content() : this.$data.config.content;
|
|
6772
6731
|
}
|
|
6773
6732
|
/**
|
|
6774
6733
|
* 修改提示的内容
|
|
@@ -6779,17 +6738,15 @@ System.register('pops', [], (function (exports) {
|
|
|
6779
6738
|
text = this.getContent();
|
|
6780
6739
|
}
|
|
6781
6740
|
if (this.$data.config.isDiffContent) {
|
|
6782
|
-
|
|
6783
|
-
|
|
6784
|
-
let originContentText = this.$el.$content[contentPropKey];
|
|
6741
|
+
const contentPropKey = "data-content";
|
|
6742
|
+
const originContentText = Reflect.get(this.$el.$content, contentPropKey);
|
|
6785
6743
|
if (typeof originContentText === "string") {
|
|
6786
6744
|
if (originContentText === text) {
|
|
6787
6745
|
// 内容未改变,不修改避免渲染
|
|
6788
6746
|
return;
|
|
6789
6747
|
}
|
|
6790
6748
|
}
|
|
6791
|
-
|
|
6792
|
-
this.$el.$content[contentPropKey] = text;
|
|
6749
|
+
Reflect.set(this.$el.$content, contentPropKey, text);
|
|
6793
6750
|
}
|
|
6794
6751
|
PopsSafeUtils.setSafeHTML(this.$el.$content, text);
|
|
6795
6752
|
}
|
|
@@ -6815,23 +6772,23 @@ System.register('pops', [], (function (exports) {
|
|
|
6815
6772
|
* @param otherDistance 其它位置的偏移
|
|
6816
6773
|
*/
|
|
6817
6774
|
calcToolTipPosition(targetElement, arrowDistance, otherDistance, event) {
|
|
6818
|
-
|
|
6775
|
+
const offsetInfo = popsDOMUtils.offset(targetElement, !this.$data.config.isFixed);
|
|
6819
6776
|
// 目标 宽
|
|
6820
|
-
|
|
6777
|
+
const targetElement_width = offsetInfo.width;
|
|
6821
6778
|
// 目标 高
|
|
6822
|
-
|
|
6779
|
+
const targetElement_height = offsetInfo.height;
|
|
6823
6780
|
// 目标 顶部距离
|
|
6824
|
-
|
|
6781
|
+
const targetElement_top = offsetInfo.top;
|
|
6825
6782
|
// let targetElement_bottom = offsetInfo.bottom;
|
|
6826
6783
|
// 目标 左边距离
|
|
6827
|
-
|
|
6784
|
+
const targetElement_left = offsetInfo.left;
|
|
6828
6785
|
// let targetElement_right = offsetInfo.right;
|
|
6829
|
-
|
|
6830
|
-
|
|
6786
|
+
const toolTipElement_width = popsDOMUtils.outerWidth(this.$el.$toolTip);
|
|
6787
|
+
const toolTipElement_height = popsDOMUtils.outerHeight(this.$el.$toolTip);
|
|
6831
6788
|
/* 目标元素的x轴的中间位置 */
|
|
6832
|
-
|
|
6789
|
+
const targetElement_X_center_pos = targetElement_left + targetElement_width / 2 - toolTipElement_width / 2;
|
|
6833
6790
|
/* 目标元素的Y轴的中间位置 */
|
|
6834
|
-
|
|
6791
|
+
const targetElement_Y_center_pos = targetElement_top + targetElement_height / 2 - toolTipElement_height / 2;
|
|
6835
6792
|
let mouseX = 0;
|
|
6836
6793
|
let mouseY = 0;
|
|
6837
6794
|
if (event != null) {
|
|
@@ -6840,19 +6797,15 @@ System.register('pops', [], (function (exports) {
|
|
|
6840
6797
|
mouseY = event.y;
|
|
6841
6798
|
}
|
|
6842
6799
|
else if (event instanceof TouchEvent) {
|
|
6843
|
-
|
|
6800
|
+
const touchEvent = event.touches[0];
|
|
6844
6801
|
mouseX = touchEvent.pageX;
|
|
6845
6802
|
mouseY = touchEvent.pageY;
|
|
6846
6803
|
}
|
|
6847
6804
|
else {
|
|
6848
|
-
// @ts-ignore
|
|
6849
6805
|
if (typeof event.clientX === "number") {
|
|
6850
|
-
// @ts-ignore
|
|
6851
6806
|
mouseX = event.clientX;
|
|
6852
6807
|
}
|
|
6853
|
-
// @ts-ignore
|
|
6854
6808
|
if (typeof event.clientY === "number") {
|
|
6855
|
-
// @ts-ignore
|
|
6856
6809
|
mouseY = event.clientY;
|
|
6857
6810
|
}
|
|
6858
6811
|
}
|
|
@@ -6894,9 +6847,9 @@ System.register('pops', [], (function (exports) {
|
|
|
6894
6847
|
* 动态修改tooltip的位置
|
|
6895
6848
|
*/
|
|
6896
6849
|
changePosition(event) {
|
|
6897
|
-
|
|
6898
|
-
|
|
6899
|
-
|
|
6850
|
+
const positionInfo = this.calcToolTipPosition(this.$data.config.target, this.$data.config.arrowDistance, this.$data.config.otherDistance, event);
|
|
6851
|
+
const positionKey = this.$data.config.position.toUpperCase();
|
|
6852
|
+
const positionDetail = positionInfo[positionKey];
|
|
6900
6853
|
if (positionDetail) {
|
|
6901
6854
|
this.$el.$toolTip.style.left = positionDetail.left + "px";
|
|
6902
6855
|
this.$el.$toolTip.style.top = positionDetail.top + "px";
|
|
@@ -6946,7 +6899,7 @@ System.register('pops', [], (function (exports) {
|
|
|
6946
6899
|
* @param type 事件类型
|
|
6947
6900
|
*/
|
|
6948
6901
|
clearCloseTimeoutId(type, timeId) {
|
|
6949
|
-
|
|
6902
|
+
const timeIdList = type === "MouseEvent" ? this.$data.timeId_close_MouseEvent : this.$data.timeId_close_TouchEvent;
|
|
6950
6903
|
for (let index = 0; index < timeIdList.length; index++) {
|
|
6951
6904
|
const currentTimeId = timeIdList[index];
|
|
6952
6905
|
if (typeof timeId === "number") {
|
|
@@ -6968,11 +6921,11 @@ System.register('pops', [], (function (exports) {
|
|
|
6968
6921
|
* 显示提示框
|
|
6969
6922
|
*/
|
|
6970
6923
|
show(...args) {
|
|
6971
|
-
|
|
6972
|
-
|
|
6924
|
+
const event = args[0];
|
|
6925
|
+
const eventType = event instanceof MouseEvent ? "MouseEvent" : "TouchEvent";
|
|
6973
6926
|
this.clearCloseTimeoutId(eventType);
|
|
6974
6927
|
if (typeof this.$data.config.showBeforeCallBack === "function") {
|
|
6975
|
-
|
|
6928
|
+
const result = this.$data.config.showBeforeCallBack(this.$el.$toolTip);
|
|
6976
6929
|
if (typeof result === "boolean" && !result) {
|
|
6977
6930
|
return;
|
|
6978
6931
|
}
|
|
@@ -7015,19 +6968,19 @@ System.register('pops', [], (function (exports) {
|
|
|
7015
6968
|
* 关闭提示框
|
|
7016
6969
|
*/
|
|
7017
6970
|
close(...args) {
|
|
7018
|
-
|
|
7019
|
-
|
|
6971
|
+
const event = args[0];
|
|
6972
|
+
const eventType = event instanceof MouseEvent ? "MouseEvent" : "TouchEvent";
|
|
7020
6973
|
// 只判断鼠标事件
|
|
7021
6974
|
// 其它的如Touch事件不做处理
|
|
7022
6975
|
if (event && event instanceof MouseEvent) {
|
|
7023
|
-
|
|
6976
|
+
const $target = event.composedPath()[0];
|
|
7024
6977
|
// 如果是目标元素的子元素/tooltip元素的子元素触发的话,那就不管
|
|
7025
6978
|
if ($target != this.$data.config.target && $target != this.$el.$toolTip) {
|
|
7026
6979
|
return;
|
|
7027
6980
|
}
|
|
7028
6981
|
}
|
|
7029
6982
|
if (typeof this.$data.config.closeBeforeCallBack === "function") {
|
|
7030
|
-
|
|
6983
|
+
const result = this.$data.config.closeBeforeCallBack(this.$el.$toolTip);
|
|
7031
6984
|
if (typeof result === "boolean" && !result) {
|
|
7032
6985
|
return;
|
|
7033
6986
|
}
|
|
@@ -7036,14 +6989,14 @@ System.register('pops', [], (function (exports) {
|
|
|
7036
6989
|
(typeof this.$data.config.delayCloseTime === "number" && this.$data.config.delayCloseTime <= 0)) {
|
|
7037
6990
|
this.$data.config.delayCloseTime = 100;
|
|
7038
6991
|
}
|
|
7039
|
-
|
|
6992
|
+
const timeId = popsUtils.setTimeout(() => {
|
|
7040
6993
|
// 设置属性触发关闭动画
|
|
7041
6994
|
this.clearCloseTimeoutId(eventType, timeId);
|
|
7042
6995
|
if (this.$el.$toolTip == null) {
|
|
7043
6996
|
// 已清除了
|
|
7044
6997
|
return;
|
|
7045
6998
|
}
|
|
7046
|
-
|
|
6999
|
+
const motion = this.$el.$toolTip.getAttribute("data-motion");
|
|
7047
7000
|
if (motion == null || motion.trim() === "") {
|
|
7048
7001
|
// 没有动画
|
|
7049
7002
|
this.toolTipAnimationFinishEvent();
|
|
@@ -7187,7 +7140,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7187
7140
|
css: PopsCSS.tooltipCSS,
|
|
7188
7141
|
},
|
|
7189
7142
|
]);
|
|
7190
|
-
|
|
7143
|
+
const toolTip = new ToolTip(config, guid, {
|
|
7191
7144
|
$shadowContainer,
|
|
7192
7145
|
$shadowRoot,
|
|
7193
7146
|
});
|
|
@@ -7255,8 +7208,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7255
7208
|
this.$config = details.config;
|
|
7256
7209
|
this.asideULElement = this.$el.$contentAside.querySelector(`ul.pops-${PopsType}-aside-top-container`);
|
|
7257
7210
|
this.asideBottomULElement = this.$el.$contentAside.querySelector(`ul.pops-${PopsType}-aside-bottom-container`);
|
|
7258
|
-
this.sectionContainerHeaderULElement =
|
|
7259
|
-
this.$el.$contentSectionContainer.querySelector(`ul.pops-${PopsType}-container-header-ul`);
|
|
7211
|
+
this.sectionContainerHeaderULElement = this.$el.$contentSectionContainer.querySelector(`ul.pops-${PopsType}-container-header-ul`);
|
|
7260
7212
|
this.sectionContainerULElement = this.$el.$contentSectionContainer.querySelector(`ul.pops-${PopsType}-container-main-ul`);
|
|
7261
7213
|
/**
|
|
7262
7214
|
* 默认点击的左侧容器项
|
|
@@ -7266,12 +7218,10 @@ System.register('pops', [], (function (exports) {
|
|
|
7266
7218
|
let isScrollToDefaultView = false;
|
|
7267
7219
|
// 初始化配置
|
|
7268
7220
|
details.config.content.forEach((asideItemConfig) => {
|
|
7269
|
-
|
|
7221
|
+
const $asideLiElement = this.createAsideItem(asideItemConfig);
|
|
7270
7222
|
this.setAsideItemClickEvent($asideLiElement, asideItemConfig);
|
|
7271
7223
|
// 是否处于底部
|
|
7272
|
-
|
|
7273
|
-
? asideItemConfig.isBottom()
|
|
7274
|
-
: asideItemConfig.isBottom;
|
|
7224
|
+
const isBottom = typeof asideItemConfig.isBottom === "function" ? asideItemConfig.isBottom() : asideItemConfig.isBottom;
|
|
7275
7225
|
if (isBottom) {
|
|
7276
7226
|
this.asideBottomULElement.appendChild($asideLiElement);
|
|
7277
7227
|
}
|
|
@@ -7377,7 +7327,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7377
7327
|
return;
|
|
7378
7328
|
}
|
|
7379
7329
|
Object.keys(props).forEach((propName) => {
|
|
7380
|
-
|
|
7330
|
+
const value = props[propName];
|
|
7381
7331
|
if (propName === "innerHTML") {
|
|
7382
7332
|
PopsSafeUtils.setSafeHTML(element, value);
|
|
7383
7333
|
return;
|
|
@@ -7398,7 +7348,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7398
7348
|
className = className();
|
|
7399
7349
|
}
|
|
7400
7350
|
if (typeof className === "string") {
|
|
7401
|
-
|
|
7351
|
+
const splitClassName = className.split(" ");
|
|
7402
7352
|
splitClassName.forEach((classNameStr) => {
|
|
7403
7353
|
element.classList.add(classNameStr);
|
|
7404
7354
|
});
|
|
@@ -7414,10 +7364,10 @@ System.register('pops', [], (function (exports) {
|
|
|
7414
7364
|
* @param asideConfig
|
|
7415
7365
|
*/
|
|
7416
7366
|
createAsideItem(asideConfig) {
|
|
7417
|
-
|
|
7367
|
+
const $li = document.createElement("li");
|
|
7418
7368
|
$li.id = asideConfig.id;
|
|
7419
7369
|
Reflect.set($li, "__forms__", asideConfig.forms);
|
|
7420
|
-
|
|
7370
|
+
const title = typeof asideConfig.title === "function" ? asideConfig.title() : asideConfig.title;
|
|
7421
7371
|
PopsSafeUtils.setSafeHTML($li, title);
|
|
7422
7372
|
/* 处理className */
|
|
7423
7373
|
this.setElementClassName($li, "pops-panel-aside-item");
|
|
@@ -7427,7 +7377,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7427
7377
|
/** 禁用左侧项的hover的CSS样式的类名 */
|
|
7428
7378
|
const disableAsideItemHoverCSSClassName = "pops-panel-disabled-aside-hover-css";
|
|
7429
7379
|
/** 是否禁用左侧项的hover的CSS样式 */
|
|
7430
|
-
|
|
7380
|
+
const disableAsideItemHoverCSS = typeof asideConfig.disableAsideItemHoverCSS === "function"
|
|
7431
7381
|
? asideConfig.disableAsideItemHoverCSS()
|
|
7432
7382
|
: asideConfig.disableAsideItemHoverCSS;
|
|
7433
7383
|
if (disableAsideItemHoverCSS) {
|
|
@@ -7444,14 +7394,14 @@ System.register('pops', [], (function (exports) {
|
|
|
7444
7394
|
* @param formConfig
|
|
7445
7395
|
*/
|
|
7446
7396
|
createSectionContainerItem_switch(formConfig) {
|
|
7447
|
-
|
|
7397
|
+
const $li = document.createElement("li");
|
|
7448
7398
|
Reflect.set($li, "__formConfig__", formConfig);
|
|
7449
7399
|
this.setElementClassName($li, formConfig.className);
|
|
7450
7400
|
this.setElementAttributes($li, formConfig.attributes);
|
|
7451
7401
|
this.setElementProps($li, formConfig.props);
|
|
7452
7402
|
/* 左边底部的描述的文字 */
|
|
7453
7403
|
let leftDescriptionText = "";
|
|
7454
|
-
if (
|
|
7404
|
+
if (formConfig.description) {
|
|
7455
7405
|
leftDescriptionText = /*html*/ `<p class="pops-panel-item-left-desc-text">${formConfig.description}</p>`;
|
|
7456
7406
|
}
|
|
7457
7407
|
PopsSafeUtils.setSafeHTML($li,
|
|
@@ -7478,7 +7428,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7478
7428
|
},
|
|
7479
7429
|
init() {
|
|
7480
7430
|
this.setStatus(this.$data.value);
|
|
7481
|
-
|
|
7431
|
+
const disabled = typeof formConfig.disabled === "function" ? formConfig.disabled() : formConfig.disabled;
|
|
7482
7432
|
if (disabled) {
|
|
7483
7433
|
this.disable();
|
|
7484
7434
|
}
|
|
@@ -7488,7 +7438,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7488
7438
|
* 设置点击事件
|
|
7489
7439
|
*/
|
|
7490
7440
|
setClickEvent() {
|
|
7491
|
-
|
|
7441
|
+
const that = this;
|
|
7492
7442
|
popsDOMUtils.on(this.$ele.core, "click", function (event) {
|
|
7493
7443
|
if (that.$ele.input.disabled || that.$ele.switch.hasAttribute("data-disabled")) {
|
|
7494
7444
|
return;
|
|
@@ -7550,14 +7500,14 @@ System.register('pops', [], (function (exports) {
|
|
|
7550
7500
|
* @param formConfig
|
|
7551
7501
|
*/
|
|
7552
7502
|
createSectionContainerItem_slider(formConfig) {
|
|
7553
|
-
|
|
7503
|
+
const $li = document.createElement("li");
|
|
7554
7504
|
Reflect.set($li, "__formConfig__", formConfig);
|
|
7555
7505
|
this.setElementClassName($li, formConfig.className);
|
|
7556
7506
|
this.setElementAttributes($li, formConfig.attributes);
|
|
7557
7507
|
this.setElementProps($li, formConfig.props);
|
|
7558
7508
|
/* 左边底部的描述的文字 */
|
|
7559
7509
|
let leftDescriptionText = "";
|
|
7560
|
-
if (
|
|
7510
|
+
if (formConfig.description) {
|
|
7561
7511
|
leftDescriptionText = `<p class="pops-panel-item-left-desc-text">${formConfig.description}</p>`;
|
|
7562
7512
|
}
|
|
7563
7513
|
PopsSafeUtils.setSafeHTML($li,
|
|
@@ -7568,7 +7518,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7568
7518
|
<input type="range" min="${formConfig.min}" max="${formConfig.max}">
|
|
7569
7519
|
</div>
|
|
7570
7520
|
`);
|
|
7571
|
-
|
|
7521
|
+
const $rangeInput = $li.querySelector(".pops-panel-slider input[type=range]");
|
|
7572
7522
|
if (formConfig.step) {
|
|
7573
7523
|
$rangeInput.setAttribute("step", formConfig.step.toString());
|
|
7574
7524
|
}
|
|
@@ -7577,7 +7527,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7577
7527
|
* 获取提示的内容
|
|
7578
7528
|
* @param value
|
|
7579
7529
|
*/
|
|
7580
|
-
|
|
7530
|
+
const getToolTipContent = function (value) {
|
|
7581
7531
|
if (typeof formConfig.getToolTipContent === "function") {
|
|
7582
7532
|
return formConfig.getToolTipContent(value);
|
|
7583
7533
|
}
|
|
@@ -7585,7 +7535,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7585
7535
|
return value;
|
|
7586
7536
|
}
|
|
7587
7537
|
};
|
|
7588
|
-
|
|
7538
|
+
const tooltip = PopsTooltip.init({
|
|
7589
7539
|
target: $rangeInput.parentElement,
|
|
7590
7540
|
content: () => {
|
|
7591
7541
|
return getToolTipContent($rangeInput.value);
|
|
@@ -7613,14 +7563,14 @@ System.register('pops', [], (function (exports) {
|
|
|
7613
7563
|
* @param formConfig
|
|
7614
7564
|
*/
|
|
7615
7565
|
createSectionContainerItem_slider_new(formConfig) {
|
|
7616
|
-
|
|
7566
|
+
const $li = document.createElement("li");
|
|
7617
7567
|
Reflect.set($li, "__formConfig__", formConfig);
|
|
7618
7568
|
this.setElementClassName($li, formConfig.className);
|
|
7619
7569
|
this.setElementAttributes($li, formConfig.attributes);
|
|
7620
7570
|
this.setElementProps($li, formConfig.props);
|
|
7621
7571
|
/* 左边底部的描述的文字 */
|
|
7622
7572
|
let leftDescriptionText = "";
|
|
7623
|
-
if (
|
|
7573
|
+
if (formConfig.description) {
|
|
7624
7574
|
leftDescriptionText = /*html*/ `<p class="pops-panel-item-left-desc-text">${formConfig.description}</p>`;
|
|
7625
7575
|
}
|
|
7626
7576
|
PopsSafeUtils.setSafeHTML($li,
|
|
@@ -7731,9 +7681,9 @@ System.register('pops', [], (function (exports) {
|
|
|
7731
7681
|
}
|
|
7732
7682
|
this.$interval.isCheck = true;
|
|
7733
7683
|
let isSuccess = false;
|
|
7734
|
-
|
|
7684
|
+
const oldTotalWidth = this.$data.totalWidth;
|
|
7735
7685
|
let timer = void 0;
|
|
7736
|
-
|
|
7686
|
+
const interval = setInterval(() => {
|
|
7737
7687
|
if (isSuccess) {
|
|
7738
7688
|
this.$interval.isCheck = false;
|
|
7739
7689
|
clearTimeout(timer);
|
|
@@ -7786,12 +7736,12 @@ System.register('pops', [], (function (exports) {
|
|
|
7786
7736
|
initStepMap() {
|
|
7787
7737
|
let index = 0;
|
|
7788
7738
|
// 计算出份数
|
|
7789
|
-
|
|
7739
|
+
const blockNums = (this.max - this.min) / this.step;
|
|
7790
7740
|
// 计算出每一份占据的px
|
|
7791
7741
|
this.$data.stepPx = this.$data.totalWidth / blockNums;
|
|
7792
7742
|
let widthPx = 0;
|
|
7793
7743
|
for (let stepValue = this.min; stepValue <= this.max; stepValue += this.step) {
|
|
7794
|
-
|
|
7744
|
+
const value = this.formatValue(stepValue);
|
|
7795
7745
|
let info;
|
|
7796
7746
|
if (value === this.min) {
|
|
7797
7747
|
/* 起始 */
|
|
@@ -7829,12 +7779,12 @@ System.register('pops', [], (function (exports) {
|
|
|
7829
7779
|
initFloatStepMap() {
|
|
7830
7780
|
let index = 0;
|
|
7831
7781
|
// 计算出份数
|
|
7832
|
-
|
|
7782
|
+
const blockNums = (this.max - this.min) / this.step;
|
|
7833
7783
|
// 计算出每一份占据的px
|
|
7834
7784
|
this.$data.stepPx = this.$data.totalWidth / blockNums;
|
|
7835
7785
|
let widthPx = 0;
|
|
7836
7786
|
for (let stepValue = this.min; stepValue <= this.max; stepValue = PopsMathFloatUtils.add(stepValue, this.step)) {
|
|
7837
|
-
|
|
7787
|
+
const value = this.formatValue(stepValue);
|
|
7838
7788
|
let info;
|
|
7839
7789
|
if (value === this.min) {
|
|
7840
7790
|
/* 起始 */
|
|
@@ -7974,7 +7924,7 @@ System.register('pops', [], (function (exports) {
|
|
|
7974
7924
|
* 判断当前滑块是否被禁用(配置中判断)
|
|
7975
7925
|
*/
|
|
7976
7926
|
isFormConfigDisabledDrag() {
|
|
7977
|
-
|
|
7927
|
+
const isDisabled = typeof formConfig.disabled === "function" ? formConfig.disabled() : formConfig.disabled;
|
|
7978
7928
|
if (typeof isDisabled === "boolean") {
|
|
7979
7929
|
return isDisabled;
|
|
7980
7930
|
}
|
|
@@ -7990,8 +7940,8 @@ System.register('pops', [], (function (exports) {
|
|
|
7990
7940
|
if (event.target !== this.$ele.runAway && event.target !== this.$ele.bar) {
|
|
7991
7941
|
return;
|
|
7992
7942
|
}
|
|
7993
|
-
|
|
7994
|
-
|
|
7943
|
+
const clickX = parseFloat(event.offsetX.toString());
|
|
7944
|
+
const dragStartResult = this.dragStartCallBack();
|
|
7995
7945
|
if (!dragStartResult) {
|
|
7996
7946
|
return;
|
|
7997
7947
|
}
|
|
@@ -8083,7 +8033,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8083
8033
|
if (!this.dragStartCallBack()) {
|
|
8084
8034
|
return;
|
|
8085
8035
|
}
|
|
8086
|
-
|
|
8036
|
+
const oldValue = this.value;
|
|
8087
8037
|
const runAwayRect = this.$ele.runAway.getBoundingClientRect();
|
|
8088
8038
|
let displacementX = event.x - (runAwayRect.left + globalThis.screenX);
|
|
8089
8039
|
if (displacementX <= 0) {
|
|
@@ -8097,7 +8047,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8097
8047
|
this.dragMoveCallBack(event, currentDragX, oldValue);
|
|
8098
8048
|
});
|
|
8099
8049
|
/* 监听触点离开,处理某些情况下,拖拽松开,但是未触发pan事件,可以通过设置这个来关闭tooltip */
|
|
8100
|
-
this.$tooltip.on("at:end", (
|
|
8050
|
+
this.$tooltip.on("at:end", () => {
|
|
8101
8051
|
this.dragEndCallBack(currentDragX);
|
|
8102
8052
|
});
|
|
8103
8053
|
},
|
|
@@ -8121,7 +8071,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8121
8071
|
return;
|
|
8122
8072
|
}
|
|
8123
8073
|
this.$data.isCheckingStopDragMove = true;
|
|
8124
|
-
|
|
8074
|
+
const interval = setInterval(() => {
|
|
8125
8075
|
if (!this.$data.isMove) {
|
|
8126
8076
|
this.$data.isCheckingStopDragMove = false;
|
|
8127
8077
|
this.closeToolTip();
|
|
@@ -8148,7 +8098,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8148
8098
|
return PopsPanelSlider.value.toString();
|
|
8149
8099
|
}
|
|
8150
8100
|
}
|
|
8151
|
-
|
|
8101
|
+
const tooltip = PopsTooltip.init({
|
|
8152
8102
|
target: this.$ele.button,
|
|
8153
8103
|
content: getToolTipContent,
|
|
8154
8104
|
zIndex: () => {
|
|
@@ -8162,7 +8112,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8162
8112
|
passive: true,
|
|
8163
8113
|
},
|
|
8164
8114
|
showBeforeCallBack: () => {
|
|
8165
|
-
|
|
8115
|
+
const isShowHoverTip = typeof formConfig.isShowHoverTip === "function"
|
|
8166
8116
|
? formConfig.isShowHoverTip()
|
|
8167
8117
|
: typeof formConfig.isShowHoverTip === "boolean"
|
|
8168
8118
|
? formConfig.isShowHoverTip
|
|
@@ -8172,7 +8122,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8172
8122
|
}
|
|
8173
8123
|
this.intervalInit();
|
|
8174
8124
|
},
|
|
8175
|
-
showAfterCallBack: (
|
|
8125
|
+
showAfterCallBack: () => {
|
|
8176
8126
|
tooltip.toolTip.changeContent(getToolTipContent());
|
|
8177
8127
|
},
|
|
8178
8128
|
closeBeforeCallBack: () => {
|
|
@@ -8198,7 +8148,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8198
8148
|
* @param formConfig
|
|
8199
8149
|
*/
|
|
8200
8150
|
createSectionContainerItem_input(formConfig) {
|
|
8201
|
-
|
|
8151
|
+
const $li = document.createElement("li");
|
|
8202
8152
|
Reflect.set($li, "__formConfig__", formConfig);
|
|
8203
8153
|
this.setElementClassName($li, formConfig.className);
|
|
8204
8154
|
this.setElementAttributes($li, formConfig.attributes);
|
|
@@ -8212,7 +8162,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8212
8162
|
}
|
|
8213
8163
|
/* 左边底部的描述的文字 */
|
|
8214
8164
|
let leftDescriptionText = "";
|
|
8215
|
-
if (
|
|
8165
|
+
if (formConfig.description) {
|
|
8216
8166
|
leftDescriptionText = `<p class="pops-panel-item-left-desc-text">${formConfig.description}</p>`;
|
|
8217
8167
|
}
|
|
8218
8168
|
PopsSafeUtils.setSafeHTML($li,
|
|
@@ -8254,7 +8204,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8254
8204
|
}
|
|
8255
8205
|
this.setInputChangeEvent();
|
|
8256
8206
|
// 是否禁用复选框
|
|
8257
|
-
|
|
8207
|
+
const disabled = typeof formConfig.disabled === "function" ? formConfig.disabled() : formConfig.disabled;
|
|
8258
8208
|
if (disabled) {
|
|
8259
8209
|
this.disable();
|
|
8260
8210
|
}
|
|
@@ -8403,14 +8353,14 @@ System.register('pops', [], (function (exports) {
|
|
|
8403
8353
|
* @param formConfig
|
|
8404
8354
|
*/
|
|
8405
8355
|
createSectionContainerItem_textarea(formConfig) {
|
|
8406
|
-
|
|
8356
|
+
const $li = document.createElement("li");
|
|
8407
8357
|
Reflect.set($li, "__formConfig__", formConfig);
|
|
8408
8358
|
this.setElementClassName($li, formConfig.className);
|
|
8409
8359
|
this.setElementAttributes($li, formConfig.attributes);
|
|
8410
8360
|
this.setElementProps($li, formConfig.props);
|
|
8411
8361
|
/* 左边底部的描述的文字 */
|
|
8412
8362
|
let leftDescriptionText = "";
|
|
8413
|
-
if (
|
|
8363
|
+
if (formConfig.description) {
|
|
8414
8364
|
leftDescriptionText = `<p class="pops-panel-item-left-desc-text">${formConfig.description}</p>`;
|
|
8415
8365
|
}
|
|
8416
8366
|
PopsSafeUtils.setSafeHTML($li,
|
|
@@ -8434,7 +8384,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8434
8384
|
init() {
|
|
8435
8385
|
this.setValue(this.$data.value);
|
|
8436
8386
|
this.setChangeEvent();
|
|
8437
|
-
|
|
8387
|
+
const disabled = typeof formConfig.disabled === "function" ? formConfig.disabled() : formConfig.disabled;
|
|
8438
8388
|
if (disabled) {
|
|
8439
8389
|
this.disable();
|
|
8440
8390
|
}
|
|
@@ -8461,7 +8411,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8461
8411
|
*/
|
|
8462
8412
|
setChangeEvent() {
|
|
8463
8413
|
popsDOMUtils.on(this.$ele.textarea, ["input", "propertychange"], (event) => {
|
|
8464
|
-
|
|
8414
|
+
const value = this.$ele.textarea.value;
|
|
8465
8415
|
this.$data.value = value;
|
|
8466
8416
|
if (typeof formConfig.callback === "function") {
|
|
8467
8417
|
formConfig.callback(event, value);
|
|
@@ -8480,14 +8430,14 @@ System.register('pops', [], (function (exports) {
|
|
|
8480
8430
|
*/
|
|
8481
8431
|
createSectionContainerItem_select(formConfig) {
|
|
8482
8432
|
const that = this;
|
|
8483
|
-
|
|
8433
|
+
const $li = document.createElement("li");
|
|
8484
8434
|
Reflect.set($li, "__formConfig__", formConfig);
|
|
8485
8435
|
this.setElementClassName($li, formConfig.className);
|
|
8486
8436
|
this.setElementAttributes($li, formConfig.attributes);
|
|
8487
8437
|
this.setElementProps($li, formConfig.props);
|
|
8488
8438
|
/* 左边底部的描述的文字 */
|
|
8489
8439
|
let leftDescriptionText = "";
|
|
8490
|
-
if (
|
|
8440
|
+
if (formConfig.description) {
|
|
8491
8441
|
leftDescriptionText = /*html*/ `<p class="pops-panel-item-left-desc-text">${formConfig.description}</p>`;
|
|
8492
8442
|
}
|
|
8493
8443
|
PopsSafeUtils.setSafeHTML($li,
|
|
@@ -8518,7 +8468,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8518
8468
|
this.initOption();
|
|
8519
8469
|
this.setChangeEvent();
|
|
8520
8470
|
this.setClickEvent();
|
|
8521
|
-
|
|
8471
|
+
const disabled = typeof formConfig.disabled === "function" ? formConfig.disabled() : formConfig.disabled;
|
|
8522
8472
|
if (disabled) {
|
|
8523
8473
|
this.disable();
|
|
8524
8474
|
}
|
|
@@ -8570,7 +8520,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8570
8520
|
initOption() {
|
|
8571
8521
|
formConfig.data.forEach((dataItem) => {
|
|
8572
8522
|
// 初始化默认选中
|
|
8573
|
-
|
|
8523
|
+
const optionElement = document.createElement("option");
|
|
8574
8524
|
this.setNodeValue(optionElement, this.$eleKey.value, dataItem.value);
|
|
8575
8525
|
this.setNodeValue(optionElement, this.$eleKey.disable, dataItem.disable);
|
|
8576
8526
|
this.setNodeValue(optionElement, this.$eleKey.forms, dataItem.forms);
|
|
@@ -8598,9 +8548,9 @@ System.register('pops', [], (function (exports) {
|
|
|
8598
8548
|
/** 设置禁用状态 */
|
|
8599
8549
|
setOptionDisableStatus(optionElement) {
|
|
8600
8550
|
let disable = false;
|
|
8601
|
-
|
|
8551
|
+
const optionDisableAttr = this.getNodeValue(optionElement, this.$eleKey.disable);
|
|
8602
8552
|
if (optionDisableAttr === "function") {
|
|
8603
|
-
|
|
8553
|
+
const value = this.getNodeValue(optionElement, this.$eleKey.value);
|
|
8604
8554
|
disable = Boolean(optionDisableAttr(value));
|
|
8605
8555
|
}
|
|
8606
8556
|
if (disable) {
|
|
@@ -8612,9 +8562,9 @@ System.register('pops', [], (function (exports) {
|
|
|
8612
8562
|
},
|
|
8613
8563
|
/** 获取option上的信息 */
|
|
8614
8564
|
getSelectOptionInfo($option) {
|
|
8615
|
-
|
|
8616
|
-
|
|
8617
|
-
|
|
8565
|
+
const optionValue = this.getNodeValue($option, this.$eleKey.value);
|
|
8566
|
+
const optionText = $option.innerText || $option.textContent;
|
|
8567
|
+
const optionForms = this.getNodeValue($option, this.$eleKey.forms);
|
|
8618
8568
|
return {
|
|
8619
8569
|
value: optionValue,
|
|
8620
8570
|
text: optionText,
|
|
@@ -8627,16 +8577,16 @@ System.register('pops', [], (function (exports) {
|
|
|
8627
8577
|
*/
|
|
8628
8578
|
setChangeEvent() {
|
|
8629
8579
|
popsDOMUtils.on(this.$ele.select, "change", void 0, (event) => {
|
|
8630
|
-
|
|
8631
|
-
|
|
8580
|
+
const $isSelectedElement = this.$ele.select[this.$ele.select.selectedIndex];
|
|
8581
|
+
const selectInfo = this.getSelectOptionInfo($isSelectedElement);
|
|
8632
8582
|
this.setSelectOptionsDisableStatus();
|
|
8633
8583
|
if (typeof formConfig.callback === "function") {
|
|
8634
8584
|
formConfig.callback(event, selectInfo.value, selectInfo.text);
|
|
8635
8585
|
}
|
|
8636
|
-
|
|
8586
|
+
const forms = typeof selectInfo.forms === "function" ? selectInfo.forms() : selectInfo.forms;
|
|
8637
8587
|
if (Array.isArray(forms)) {
|
|
8638
8588
|
/* 如果成功创建,加入到中间容器中 */
|
|
8639
|
-
|
|
8589
|
+
const childUListClassName = "pops-panel-select-child-forms";
|
|
8640
8590
|
// 移除旧的元素
|
|
8641
8591
|
while ($li.nextElementSibling) {
|
|
8642
8592
|
if ($li.nextElementSibling.classList.contains(childUListClassName)) {
|
|
@@ -8646,7 +8596,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8646
8596
|
break;
|
|
8647
8597
|
}
|
|
8648
8598
|
}
|
|
8649
|
-
|
|
8599
|
+
const $childUList = document.createElement("ul");
|
|
8650
8600
|
$childUList.className = childUListClassName;
|
|
8651
8601
|
popsDOMUtils.after($li, $childUList);
|
|
8652
8602
|
that.uListContainerAddItem(formConfig, {
|
|
@@ -8677,14 +8627,14 @@ System.register('pops', [], (function (exports) {
|
|
|
8677
8627
|
* @param formConfig
|
|
8678
8628
|
*/
|
|
8679
8629
|
createSectionContainerItem_select_multiple_new(formConfig) {
|
|
8680
|
-
|
|
8630
|
+
const $li = document.createElement("li");
|
|
8681
8631
|
Reflect.set($li, "__formConfig__", formConfig);
|
|
8682
8632
|
this.setElementClassName($li, formConfig.className);
|
|
8683
8633
|
this.setElementAttributes($li, formConfig.attributes);
|
|
8684
8634
|
this.setElementProps($li, formConfig.props);
|
|
8685
8635
|
/* 左边底部的描述的文字 */
|
|
8686
8636
|
let leftDescriptionText = "";
|
|
8687
|
-
if (
|
|
8637
|
+
if (formConfig.description) {
|
|
8688
8638
|
leftDescriptionText = /*html*/ `<p class="pops-panel-item-left-desc-text">${formConfig.description}</p>`;
|
|
8689
8639
|
}
|
|
8690
8640
|
PopsSafeUtils.setSafeHTML($li,
|
|
@@ -8747,7 +8697,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8747
8697
|
this.initPlaceHolder();
|
|
8748
8698
|
this.initTagElement();
|
|
8749
8699
|
this.setSelectContainerClickEvent();
|
|
8750
|
-
|
|
8700
|
+
const disabled = typeof formConfig.disabled === "function" ? formConfig.disabled() : formConfig.disabled;
|
|
8751
8701
|
if (disabled) {
|
|
8752
8702
|
this.disable();
|
|
8753
8703
|
}
|
|
@@ -8785,12 +8735,12 @@ System.register('pops', [], (function (exports) {
|
|
|
8785
8735
|
placeholder = formConfig.placeholder;
|
|
8786
8736
|
}
|
|
8787
8737
|
else if (typeof formConfig.placeholder === "function") {
|
|
8788
|
-
|
|
8738
|
+
const placeholderResult = formConfig.placeholder();
|
|
8789
8739
|
if (typeof placeholderResult === "string") {
|
|
8790
8740
|
placeholder = placeholderResult;
|
|
8791
8741
|
}
|
|
8792
8742
|
}
|
|
8793
|
-
|
|
8743
|
+
const $placeholder = popsDOMUtils.createElement("span", {
|
|
8794
8744
|
innerText: placeholder,
|
|
8795
8745
|
});
|
|
8796
8746
|
this.$el.$selectedPlaceHolderWrapper.appendChild($placeholder);
|
|
@@ -8799,10 +8749,10 @@ System.register('pops', [], (function (exports) {
|
|
|
8799
8749
|
initTagElement() {
|
|
8800
8750
|
// 遍历数据,寻找对应的值
|
|
8801
8751
|
formConfig.data.forEach((dataItem) => {
|
|
8802
|
-
|
|
8752
|
+
const findValue = this.$data.selectInfo.find((item) => item.value === dataItem.value);
|
|
8803
8753
|
if (findValue) {
|
|
8804
8754
|
// 存在对应的值
|
|
8805
|
-
|
|
8755
|
+
const selectedInfo = this.createSelectedTagItem(dataItem);
|
|
8806
8756
|
this.addSelectedTagItem(selectedInfo.$tag);
|
|
8807
8757
|
this.setSelectedItemCloseIconClickEvent({
|
|
8808
8758
|
$tag: selectedInfo.$tag,
|
|
@@ -8839,7 +8789,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8839
8789
|
const $tagText = $selectedItem.querySelector(".el-select__tags-text");
|
|
8840
8790
|
/** 关闭图标 */
|
|
8841
8791
|
const $closeIcon = $selectedItem.querySelector(".el-icon.el-tag__close");
|
|
8842
|
-
|
|
8792
|
+
const text = typeof data.text === "function" ? data.text(data, this.$data.selectInfo) : data.text;
|
|
8843
8793
|
if (data.isHTML) {
|
|
8844
8794
|
PopsSafeUtils.setSafeHTML($tagText, text);
|
|
8845
8795
|
}
|
|
@@ -8861,7 +8811,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8861
8811
|
// 去除前面的空白
|
|
8862
8812
|
this.setSectionIsNear();
|
|
8863
8813
|
if (this.$el.$section.contains(this.$el.$selectedInputWrapper)) {
|
|
8864
|
-
|
|
8814
|
+
const $prev = this.$el.$selectedInputWrapper.previousElementSibling;
|
|
8865
8815
|
if ($prev) {
|
|
8866
8816
|
// 存在前一个元素,添加到前面的元素的后面
|
|
8867
8817
|
popsDOMUtils.after($prev, $tag);
|
|
@@ -8872,7 +8822,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8872
8822
|
}
|
|
8873
8823
|
}
|
|
8874
8824
|
else if (this.$el.$section.contains(this.$el.$selectedPlaceHolderWrapper)) {
|
|
8875
|
-
|
|
8825
|
+
const $prev = this.$el.$selectedPlaceHolderWrapper.previousElementSibling;
|
|
8876
8826
|
if ($prev) {
|
|
8877
8827
|
// 存在前一个元素,添加到前面的元素的后面
|
|
8878
8828
|
popsDOMUtils.after($prev, $tag);
|
|
@@ -8932,7 +8882,7 @@ System.register('pops', [], (function (exports) {
|
|
|
8932
8882
|
this.removeSelectItemDisabled($select);
|
|
8933
8883
|
}
|
|
8934
8884
|
// 更新选中状态
|
|
8935
|
-
|
|
8885
|
+
const findValue = this.$data.selectInfo.find((it) => it.value === data.value);
|
|
8936
8886
|
if (findValue) {
|
|
8937
8887
|
this.setSelectItemSelected($select);
|
|
8938
8888
|
}
|
|
@@ -8970,8 +8920,8 @@ System.register('pops', [], (function (exports) {
|
|
|
8970
8920
|
* @param $select 选项元素
|
|
8971
8921
|
*/
|
|
8972
8922
|
addSelectedItemInfo(dataList, $select) {
|
|
8973
|
-
|
|
8974
|
-
|
|
8923
|
+
const info = this.getSelectedItemInfo($select);
|
|
8924
|
+
const findValue = dataList.find((item) => item.value === info.value);
|
|
8975
8925
|
if (!findValue) {
|
|
8976
8926
|
dataList.push({
|
|
8977
8927
|
value: info.value,
|
|
@@ -8995,8 +8945,8 @@ System.register('pops', [], (function (exports) {
|
|
|
8995
8945
|
* @param $select 选项元素
|
|
8996
8946
|
*/
|
|
8997
8947
|
removeSelectedItemInfo(dataList, $select) {
|
|
8998
|
-
|
|
8999
|
-
|
|
8948
|
+
const info = this.getSelectedItemInfo($select);
|
|
8949
|
+
const findIndex = dataList.findIndex((item) => item.value === info.value);
|
|
9000
8950
|
if (findIndex !== -1) {
|
|
9001
8951
|
dataList.splice(findIndex, 1);
|
|
9002
8952
|
}
|
|
@@ -9011,8 +8961,8 @@ System.register('pops', [], (function (exports) {
|
|
|
9011
8961
|
getAllSelectItemInfo(onlySelected = true) {
|
|
9012
8962
|
return Array.from(this.$el.$selectContainer?.querySelectorAll(".select-item") ?? [])
|
|
9013
8963
|
.map(($select) => {
|
|
9014
|
-
|
|
9015
|
-
|
|
8964
|
+
const data = this.getSelectedItemInfo($select);
|
|
8965
|
+
const result = {
|
|
9016
8966
|
/** 选项信息数据 */
|
|
9017
8967
|
data: data,
|
|
9018
8968
|
/** 选项元素 */
|
|
@@ -9020,7 +8970,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9020
8970
|
};
|
|
9021
8971
|
if (onlySelected) {
|
|
9022
8972
|
// 仅选中
|
|
9023
|
-
|
|
8973
|
+
const isSelected = this.isSelectItemSelected($select);
|
|
9024
8974
|
if (isSelected) {
|
|
9025
8975
|
return result;
|
|
9026
8976
|
}
|
|
@@ -9039,7 +8989,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9039
8989
|
* @param data 选择项的数据
|
|
9040
8990
|
*/
|
|
9041
8991
|
createSelectItemElement(data) {
|
|
9042
|
-
|
|
8992
|
+
const $select = popsDOMUtils.createElement("li", {
|
|
9043
8993
|
className: "select-item",
|
|
9044
8994
|
innerHTML: /*html*/ `
|
|
9045
8995
|
<span class="select-item-text"></span>
|
|
@@ -9055,8 +9005,8 @@ System.register('pops', [], (function (exports) {
|
|
|
9055
9005
|
* @param $select 选择项元素
|
|
9056
9006
|
*/
|
|
9057
9007
|
setSelectItemText(data, $select) {
|
|
9058
|
-
|
|
9059
|
-
|
|
9008
|
+
const text = typeof data.text === "function" ? data.text(data.value, this.$data.selectInfo) : data.text;
|
|
9009
|
+
const $selectSpan = $select.querySelector(".select-item-text");
|
|
9060
9010
|
if (data.isHTML) {
|
|
9061
9011
|
PopsSafeUtils.setSafeHTML($selectSpan, text);
|
|
9062
9012
|
}
|
|
@@ -9099,8 +9049,8 @@ System.register('pops', [], (function (exports) {
|
|
|
9099
9049
|
return;
|
|
9100
9050
|
}
|
|
9101
9051
|
if (typeof formConfig.clickCallBack === "function") {
|
|
9102
|
-
|
|
9103
|
-
|
|
9052
|
+
const allSelectedInfo = this.getAllSelectItemInfo().map((it) => it.data);
|
|
9053
|
+
const clickResult = formConfig.clickCallBack(event, allSelectedInfo);
|
|
9104
9054
|
if (typeof clickResult === "boolean" && !clickResult) {
|
|
9105
9055
|
return;
|
|
9106
9056
|
}
|
|
@@ -9121,14 +9071,14 @@ System.register('pops', [], (function (exports) {
|
|
|
9121
9071
|
*/
|
|
9122
9072
|
setSelectContainerClickEvent() {
|
|
9123
9073
|
const that = this;
|
|
9124
|
-
popsDOMUtils.on(this.$el.$container, "click", (
|
|
9074
|
+
popsDOMUtils.on(this.$el.$container, "click", () => {
|
|
9125
9075
|
if (this.isDisabled()) {
|
|
9126
9076
|
return;
|
|
9127
9077
|
}
|
|
9128
9078
|
/** 弹窗的选中的值 */
|
|
9129
|
-
|
|
9130
|
-
|
|
9131
|
-
|
|
9079
|
+
const selectedInfo = that.$data.selectInfo;
|
|
9080
|
+
const { style, ...userConfirmDetails } = formConfig.selectConfirmDialogDetails || {};
|
|
9081
|
+
const confirmDetails = popsUtils.assign({
|
|
9132
9082
|
title: {
|
|
9133
9083
|
text: "请勾选需要选择的选项",
|
|
9134
9084
|
position: "center",
|
|
@@ -9145,7 +9095,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9145
9095
|
},
|
|
9146
9096
|
close: {
|
|
9147
9097
|
enable: true,
|
|
9148
|
-
callback(details
|
|
9098
|
+
callback(details) {
|
|
9149
9099
|
that.$data.selectInfo = [...selectedInfo];
|
|
9150
9100
|
that.updateSelectTagItem();
|
|
9151
9101
|
that.$el.$selectContainer = null;
|
|
@@ -9155,7 +9105,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9155
9105
|
},
|
|
9156
9106
|
mask: {
|
|
9157
9107
|
enable: true,
|
|
9158
|
-
clickCallBack(originalRun
|
|
9108
|
+
clickCallBack(originalRun) {
|
|
9159
9109
|
originalRun();
|
|
9160
9110
|
that.$data.selectInfo = [...selectedInfo];
|
|
9161
9111
|
that.updateSelectTagItem();
|
|
@@ -9234,12 +9184,12 @@ System.register('pops', [], (function (exports) {
|
|
|
9234
9184
|
${style || ""}
|
|
9235
9185
|
`,
|
|
9236
9186
|
}, userConfirmDetails);
|
|
9237
|
-
|
|
9238
|
-
|
|
9187
|
+
const $dialog = PopsAlert.init(confirmDetails);
|
|
9188
|
+
const $selectContainer = $dialog.$shadowRoot.querySelector(".select-container");
|
|
9239
9189
|
this.$el.$selectContainer = $selectContainer;
|
|
9240
9190
|
// 配置选项元素
|
|
9241
9191
|
formConfig.data.forEach((item) => {
|
|
9242
|
-
|
|
9192
|
+
const $select = this.createSelectItemElement(item);
|
|
9243
9193
|
// 添加到confirm中
|
|
9244
9194
|
$selectContainer.appendChild($select);
|
|
9245
9195
|
// 设置每一项的点击事件
|
|
@@ -9260,7 +9210,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9260
9210
|
return;
|
|
9261
9211
|
}
|
|
9262
9212
|
if (typeof formConfig.closeIconClickCallBack === "function") {
|
|
9263
|
-
|
|
9213
|
+
const result = formConfig.closeIconClickCallBack(event, {
|
|
9264
9214
|
$tag: data.$tag,
|
|
9265
9215
|
$closeIcon: data.$closeIcon,
|
|
9266
9216
|
value: data.value,
|
|
@@ -9369,14 +9319,14 @@ System.register('pops', [], (function (exports) {
|
|
|
9369
9319
|
* @param formConfig
|
|
9370
9320
|
*/
|
|
9371
9321
|
createSectionContainerItem_button(formConfig) {
|
|
9372
|
-
|
|
9322
|
+
const $li = document.createElement("li");
|
|
9373
9323
|
Reflect.set($li, "__formConfig__", formConfig);
|
|
9374
9324
|
this.setElementClassName($li, formConfig.className);
|
|
9375
9325
|
this.setElementAttributes($li, formConfig.attributes);
|
|
9376
9326
|
this.setElementProps($li, formConfig.props);
|
|
9377
9327
|
/* 左边底部的描述的文字 */
|
|
9378
9328
|
let leftDescriptionText = "";
|
|
9379
|
-
if (
|
|
9329
|
+
if (formConfig.description) {
|
|
9380
9330
|
leftDescriptionText = /*html*/ `<p class="pops-panel-item-left-desc-text">${formConfig.description}</p>`;
|
|
9381
9331
|
}
|
|
9382
9332
|
PopsSafeUtils.setSafeHTML($li,
|
|
@@ -9517,8 +9467,8 @@ System.register('pops', [], (function (exports) {
|
|
|
9517
9467
|
* @param formConfig
|
|
9518
9468
|
*/
|
|
9519
9469
|
createSectionContainerItem_deepMenu(formConfig) {
|
|
9520
|
-
|
|
9521
|
-
|
|
9470
|
+
const that = this;
|
|
9471
|
+
const $li = document.createElement("li");
|
|
9522
9472
|
popsDOMUtils.addClassName($li, "pops-panel-deepMenu-nav-item");
|
|
9523
9473
|
Reflect.set($li, "__formConfig__", formConfig);
|
|
9524
9474
|
this.setElementClassName($li, formConfig.className);
|
|
@@ -9528,12 +9478,12 @@ System.register('pops', [], (function (exports) {
|
|
|
9528
9478
|
this.setElementProps($li, formConfig.props);
|
|
9529
9479
|
/* 左边底部的描述的文字 */
|
|
9530
9480
|
let leftDescriptionText = "";
|
|
9531
|
-
if (
|
|
9481
|
+
if (formConfig.description) {
|
|
9532
9482
|
// 设置描述
|
|
9533
9483
|
leftDescriptionText = `<p class="pops-panel-item-left-desc-text">${formConfig.description}</p>`;
|
|
9534
9484
|
}
|
|
9535
9485
|
// 箭头图标
|
|
9536
|
-
|
|
9486
|
+
const arrowRightIcon = typeof formConfig.arrowRightIcon === "boolean" ? formConfig.arrowRightIcon : true;
|
|
9537
9487
|
let arrowRightIconHTML = "";
|
|
9538
9488
|
if (arrowRightIcon) {
|
|
9539
9489
|
arrowRightIconHTML = `<i class="pops-panel-deepMenu-arrowRight-icon">${PopsIcon.getIcon("arrowRight")}</i>`;
|
|
@@ -9564,17 +9514,17 @@ System.register('pops', [], (function (exports) {
|
|
|
9564
9514
|
* @param formItemConfig
|
|
9565
9515
|
*/
|
|
9566
9516
|
initFormItem($container, formItemConfig) {
|
|
9567
|
-
|
|
9517
|
+
const formConfig_forms = formItemConfig;
|
|
9568
9518
|
if (formConfig_forms.type === "forms") {
|
|
9569
|
-
|
|
9519
|
+
const childForms = formConfig_forms["forms"];
|
|
9570
9520
|
/* 每一项<li>元素 */
|
|
9571
|
-
|
|
9521
|
+
const formContainerListElement = document.createElement("li");
|
|
9572
9522
|
/* 每一项<li>内的子<ul>元素 */
|
|
9573
|
-
|
|
9523
|
+
const formContainerULElement = document.createElement("ul");
|
|
9574
9524
|
formContainerULElement.classList.add("pops-panel-forms-container-item-formlist");
|
|
9575
9525
|
formContainerListElement.classList.add("pops-panel-forms-container-item");
|
|
9576
9526
|
/* 区域头部的文字 */
|
|
9577
|
-
|
|
9527
|
+
const formHeaderDivElement = popsDOMUtils.createElement("div", {
|
|
9578
9528
|
className: "pops-panel-forms-container-item-header-text",
|
|
9579
9529
|
});
|
|
9580
9530
|
PopsSafeUtils.setSafeHTML(formHeaderDivElement, formConfig_forms["text"]);
|
|
@@ -9591,7 +9541,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9591
9541
|
</i>
|
|
9592
9542
|
`);
|
|
9593
9543
|
// 添加点击事件
|
|
9594
|
-
popsDOMUtils.on(formHeaderDivElement, "click", (
|
|
9544
|
+
popsDOMUtils.on(formHeaderDivElement, "click", () => {
|
|
9595
9545
|
if (formContainerListElement.hasAttribute("data-fold-enable")) {
|
|
9596
9546
|
formContainerListElement.removeAttribute("data-fold-enable");
|
|
9597
9547
|
}
|
|
@@ -9646,26 +9596,26 @@ System.register('pops', [], (function (exports) {
|
|
|
9646
9596
|
*/
|
|
9647
9597
|
async gotoDeepMenu(event, liElement) {
|
|
9648
9598
|
/** 当前所在的容器 */
|
|
9649
|
-
|
|
9599
|
+
const $currentSection = liElement.closest("section.pops-panel-container");
|
|
9650
9600
|
// 子菜单的容器
|
|
9651
|
-
|
|
9601
|
+
const $deepMenuSection = popsDOMUtils.createElement("section", {
|
|
9652
9602
|
className: "pops-panel-container pops-panel-deepMenu-container",
|
|
9653
9603
|
});
|
|
9654
9604
|
Reflect.set($deepMenuSection, "__formConfig__", formConfig);
|
|
9655
|
-
|
|
9605
|
+
const $deepMenuHeaderUL = popsDOMUtils.createElement("ul", {
|
|
9656
9606
|
className: "pops-panel-container-header-ul pops-panel-deepMenu-container-header-ul",
|
|
9657
9607
|
});
|
|
9658
|
-
|
|
9608
|
+
const $deepMenuMain = popsDOMUtils.createElement("ul", {
|
|
9659
9609
|
className: "pops-panel-container-main-ul",
|
|
9660
9610
|
});
|
|
9661
9611
|
// 标题文字
|
|
9662
|
-
|
|
9663
|
-
|
|
9612
|
+
const headerTitleText = formConfig.headerTitle ?? formConfig.text;
|
|
9613
|
+
const $header = popsDOMUtils.createElement("li", {
|
|
9664
9614
|
className: "pops-panel-container-header-title-text pops-panel-deepMenu-container-header",
|
|
9665
9615
|
innerHTML: /*html*/ `<p class="pops-panel-deepMenu-container-header-title-text">${headerTitleText}</p>`,
|
|
9666
9616
|
});
|
|
9667
9617
|
// 返回箭头
|
|
9668
|
-
|
|
9618
|
+
const $headerLeftArrow = popsDOMUtils.createElement("i", {
|
|
9669
9619
|
className: "pops-panel-deepMenu-container-left-arrow-icon",
|
|
9670
9620
|
innerHTML: PopsIcon.getIcon("arrowLeft"),
|
|
9671
9621
|
});
|
|
@@ -9730,7 +9680,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9730
9680
|
$deepMenuSection.appendChild($deepMenuMain);
|
|
9731
9681
|
if (formConfig.forms && Array.isArray(formConfig.forms)) {
|
|
9732
9682
|
for (let index = 0; index < formConfig.forms.length; index++) {
|
|
9733
|
-
|
|
9683
|
+
const formItemConfig = formConfig.forms[index];
|
|
9734
9684
|
this.initFormItem($deepMenuMain, formItemConfig);
|
|
9735
9685
|
}
|
|
9736
9686
|
}
|
|
@@ -9768,7 +9718,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9768
9718
|
setLiClickEvent() {
|
|
9769
9719
|
popsDOMUtils.on($li, "click", void 0, async (event) => {
|
|
9770
9720
|
if (typeof formConfig.clickCallBack === "function") {
|
|
9771
|
-
|
|
9721
|
+
const result = await formConfig.clickCallBack(event, formConfig);
|
|
9772
9722
|
if (result) {
|
|
9773
9723
|
return;
|
|
9774
9724
|
}
|
|
@@ -9801,7 +9751,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9801
9751
|
*/
|
|
9802
9752
|
createSectionContainerItem(formConfig) {
|
|
9803
9753
|
/** 配置项的类型 */
|
|
9804
|
-
|
|
9754
|
+
const formType = formConfig.type;
|
|
9805
9755
|
if (formType === "switch") {
|
|
9806
9756
|
return this.createSectionContainerItem_switch(formConfig);
|
|
9807
9757
|
}
|
|
@@ -9839,18 +9789,18 @@ System.register('pops', [], (function (exports) {
|
|
|
9839
9789
|
* @param formConfig
|
|
9840
9790
|
*/
|
|
9841
9791
|
createSectionContainerItem_forms(formConfig) {
|
|
9842
|
-
|
|
9843
|
-
|
|
9792
|
+
const that = this;
|
|
9793
|
+
const formConfig_forms = formConfig;
|
|
9844
9794
|
if (formConfig_forms.type === "forms") {
|
|
9845
|
-
|
|
9795
|
+
const childForms = formConfig["forms"];
|
|
9846
9796
|
/* 每一项<li>元素 */
|
|
9847
|
-
|
|
9797
|
+
const formContainerListElement = document.createElement("li");
|
|
9848
9798
|
/* 每一项<li>内的子<ul>元素 */
|
|
9849
|
-
|
|
9799
|
+
const formContainerULElement = document.createElement("ul");
|
|
9850
9800
|
formContainerListElement.classList.add("pops-panel-forms-container-item");
|
|
9851
9801
|
formContainerULElement.classList.add("pops-panel-forms-container-item-formlist");
|
|
9852
9802
|
/* 区域头部的文字 */
|
|
9853
|
-
|
|
9803
|
+
const formHeaderDivElement = popsDOMUtils.createElement("div", {
|
|
9854
9804
|
className: "pops-panel-forms-container-item-header-text",
|
|
9855
9805
|
});
|
|
9856
9806
|
PopsSafeUtils.setSafeHTML(formHeaderDivElement, formConfig_forms["text"]);
|
|
@@ -9866,7 +9816,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9866
9816
|
</i>
|
|
9867
9817
|
`);
|
|
9868
9818
|
// 添加点击事件
|
|
9869
|
-
popsDOMUtils.on(formHeaderDivElement, "click", (
|
|
9819
|
+
popsDOMUtils.on(formHeaderDivElement, "click", () => {
|
|
9870
9820
|
if (formContainerListElement.hasAttribute("data-fold-enable")) {
|
|
9871
9821
|
formContainerListElement.removeAttribute("data-fold-enable");
|
|
9872
9822
|
}
|
|
@@ -9918,7 +9868,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9918
9868
|
* 触发触发渲染右侧容器的事件
|
|
9919
9869
|
*/
|
|
9920
9870
|
triggerRenderRightContainer($container) {
|
|
9921
|
-
|
|
9871
|
+
const __formConfig__ = Reflect.get($container, "__formConfig__");
|
|
9922
9872
|
this.$el.$pops.dispatchEvent(new CustomEvent("pops:renderRightContainer", {
|
|
9923
9873
|
detail: {
|
|
9924
9874
|
formConfig: __formConfig__,
|
|
@@ -9931,7 +9881,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9931
9881
|
* @param containerOptions
|
|
9932
9882
|
*/
|
|
9933
9883
|
uListContainerAddItem(formConfig, containerOptions) {
|
|
9934
|
-
|
|
9884
|
+
const itemLiElement = this.createSectionContainerItem(formConfig);
|
|
9935
9885
|
if (itemLiElement) {
|
|
9936
9886
|
containerOptions["ulElement"].appendChild(itemLiElement);
|
|
9937
9887
|
}
|
|
@@ -9950,23 +9900,23 @@ System.register('pops', [], (function (exports) {
|
|
|
9950
9900
|
setAsideItemClickEvent(asideLiElement, asideConfig) {
|
|
9951
9901
|
popsDOMUtils.on(asideLiElement, "click", async (event) => {
|
|
9952
9902
|
if (typeof asideConfig.clickFirstCallback === "function") {
|
|
9953
|
-
|
|
9903
|
+
const clickFirstCallbackResult = await asideConfig.clickFirstCallback(event, this.sectionContainerHeaderULElement, this.sectionContainerULElement);
|
|
9954
9904
|
if (typeof clickFirstCallbackResult === "boolean" && !clickFirstCallbackResult) {
|
|
9955
9905
|
return;
|
|
9956
9906
|
}
|
|
9957
9907
|
}
|
|
9958
9908
|
this.clearContainer();
|
|
9959
|
-
|
|
9909
|
+
const rightContainerFormConfig = Reflect.get(asideLiElement, "__forms__");
|
|
9960
9910
|
Reflect.set(this.$el.$contentSectionContainer, "__formConfig__", rightContainerFormConfig);
|
|
9961
9911
|
popsDOMUtils.cssShow(this.$el.$contentSectionContainer);
|
|
9962
9912
|
this.clearAsideItemIsVisited();
|
|
9963
9913
|
this.setAsideItemIsVisited(asideLiElement);
|
|
9964
9914
|
/* 顶部标题栏,存在就设置 */
|
|
9965
|
-
|
|
9915
|
+
const title = typeof asideConfig.title === "function" ? asideConfig.title() : asideConfig.title;
|
|
9966
9916
|
let headerTitleText = typeof asideConfig.headerTitle === "function" ? asideConfig.headerTitle() : asideConfig.headerTitle;
|
|
9967
9917
|
headerTitleText = headerTitleText ?? title;
|
|
9968
9918
|
if (typeof headerTitleText === "string" && headerTitleText.trim() !== "") {
|
|
9969
|
-
|
|
9919
|
+
const $containerHeaderTitle = document.createElement("li");
|
|
9970
9920
|
$containerHeaderTitle.classList.add("pops-panel-container-header-title-text");
|
|
9971
9921
|
Reflect.set($containerHeaderTitle, "__asideConfig__", asideConfig);
|
|
9972
9922
|
PopsSafeUtils.setSafeHTML($containerHeaderTitle, headerTitleText);
|
|
@@ -9977,7 +9927,7 @@ System.register('pops', [], (function (exports) {
|
|
|
9977
9927
|
});
|
|
9978
9928
|
if (typeof asideConfig.clickCallback === "function") {
|
|
9979
9929
|
/* 执行回调 */
|
|
9980
|
-
|
|
9930
|
+
const asideClickCallbackResult = await asideConfig.clickCallback(event, this.sectionContainerHeaderULElement, this.sectionContainerULElement);
|
|
9981
9931
|
if (typeof asideClickCallbackResult === "boolean" && !asideClickCallbackResult) {
|
|
9982
9932
|
return;
|
|
9983
9933
|
}
|
|
@@ -10032,11 +9982,11 @@ System.register('pops', [], (function (exports) {
|
|
|
10032
9982
|
},
|
|
10033
9983
|
]);
|
|
10034
9984
|
// 先把z-index提取出来
|
|
10035
|
-
|
|
10036
|
-
|
|
10037
|
-
|
|
10038
|
-
|
|
10039
|
-
|
|
9985
|
+
const zIndex = PopsHandler.handleZIndex(config.zIndex);
|
|
9986
|
+
const maskHTML = PopsElementHandler.createMask(guid, zIndex);
|
|
9987
|
+
const headerBtnHTML = PopsElementHandler.createHeader(popsType, config);
|
|
9988
|
+
const { headerStyle, headerPStyle } = PopsElementHandler.createHeaderStyle(popsType, config);
|
|
9989
|
+
const animHTML = PopsElementHandler.createAnim(guid, popsType, config,
|
|
10040
9990
|
/*html*/ `
|
|
10041
9991
|
<div class="pops-title pops-${popsType}-title" style="text-align: ${config.title.position};${headerStyle}">${config.title.html
|
|
10042
9992
|
? config.title.text
|
|
@@ -10056,9 +10006,9 @@ System.register('pops', [], (function (exports) {
|
|
|
10056
10006
|
/**
|
|
10057
10007
|
* 弹窗的主元素,包括动画层
|
|
10058
10008
|
*/
|
|
10059
|
-
|
|
10009
|
+
const $anim = PopsElementHandler.parseElement(animHTML);
|
|
10060
10010
|
/* 结构元素 */
|
|
10061
|
-
|
|
10011
|
+
const { popsElement: $pops, headerCloseBtnElement: $headerCloseBtn, titleElement: $title, contentElement: $content, panelSectionWrapper: $panelSectionWrapper, contentAsideElement: $contentAside, contentSectionContainerElement: $contentSectionContainer, } = PopsHandler.handleQueryElement($anim, popsType);
|
|
10062
10012
|
if (config.isMobile || popsUtils.isPhone()) {
|
|
10063
10013
|
popsDOMUtils.addClassName($pops, config.mobileClassName);
|
|
10064
10014
|
}
|
|
@@ -10069,10 +10019,10 @@ System.register('pops', [], (function (exports) {
|
|
|
10069
10019
|
/**
|
|
10070
10020
|
* 已创建的元素列表
|
|
10071
10021
|
*/
|
|
10072
|
-
|
|
10022
|
+
const isCreatedElementList = [$anim];
|
|
10073
10023
|
/* 遮罩层元素 */
|
|
10074
10024
|
if (config.mask.enable) {
|
|
10075
|
-
|
|
10025
|
+
const { maskElement } = PopsHandler.handleMask({
|
|
10076
10026
|
type: popsType,
|
|
10077
10027
|
guid: guid,
|
|
10078
10028
|
config: config,
|
|
@@ -10083,7 +10033,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10083
10033
|
isCreatedElementList.push($mask);
|
|
10084
10034
|
}
|
|
10085
10035
|
/* 处理返回的配置 */
|
|
10086
|
-
|
|
10036
|
+
const eventDetails = PopsHandler.handleEventDetails(guid, $shadowContainer, $shadowRoot, popsType, $anim, $pops, $mask, config);
|
|
10087
10037
|
/* 为顶部右边的关闭按钮添加点击事件 */
|
|
10088
10038
|
PopsHandler.handleClickEvent("close", $headerCloseBtn, eventDetails, config.btn.close.callback);
|
|
10089
10039
|
/* 创建到页面中 */
|
|
@@ -10096,7 +10046,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10096
10046
|
if ($mask != null) {
|
|
10097
10047
|
$anim.after($mask);
|
|
10098
10048
|
}
|
|
10099
|
-
|
|
10049
|
+
const panelHandlerComponents = PanelHandlerComponents();
|
|
10100
10050
|
/**
|
|
10101
10051
|
* 处理内部配置
|
|
10102
10052
|
*/
|
|
@@ -10128,7 +10078,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10128
10078
|
endCallBack: config.dragEndCallBack,
|
|
10129
10079
|
});
|
|
10130
10080
|
}
|
|
10131
|
-
|
|
10081
|
+
const result = PopsHandler.handleResultDetails(eventDetails);
|
|
10132
10082
|
return {
|
|
10133
10083
|
...result,
|
|
10134
10084
|
addEventListener: (event, listener, options) => {
|
|
@@ -10274,13 +10224,13 @@ System.register('pops', [], (function (exports) {
|
|
|
10274
10224
|
},
|
|
10275
10225
|
]);
|
|
10276
10226
|
// 先把z-index提取出来
|
|
10277
|
-
|
|
10278
|
-
|
|
10279
|
-
|
|
10280
|
-
|
|
10281
|
-
|
|
10282
|
-
|
|
10283
|
-
|
|
10227
|
+
const zIndex = PopsHandler.handleZIndex(config.zIndex);
|
|
10228
|
+
const maskHTML = PopsElementHandler.createMask(guid, zIndex);
|
|
10229
|
+
const headerBtnHTML = PopsElementHandler.createHeader(popsType, config);
|
|
10230
|
+
const bottomBtnHTML = PopsElementHandler.createBottom(popsType, config);
|
|
10231
|
+
const { headerStyle, headerPStyle } = PopsElementHandler.createHeaderStyle(popsType, config);
|
|
10232
|
+
const { contentPStyle } = PopsElementHandler.createContentStyle(popsType, config);
|
|
10233
|
+
const animHTML = PopsElementHandler.createAnim(guid, popsType, config,
|
|
10284
10234
|
/*html*/ `
|
|
10285
10235
|
<div class="pops-title pops-${popsType}-title" style="text-align: ${config.title.position};${headerStyle}">${config.title.html
|
|
10286
10236
|
? config.title.text
|
|
@@ -10297,8 +10247,8 @@ System.register('pops', [], (function (exports) {
|
|
|
10297
10247
|
/**
|
|
10298
10248
|
* 弹窗的主元素,包括动画层
|
|
10299
10249
|
*/
|
|
10300
|
-
|
|
10301
|
-
|
|
10250
|
+
const $anim = PopsElementHandler.parseElement(animHTML);
|
|
10251
|
+
const { popsElement: $pops, inputElement: $input, headerCloseBtnElement: $btnClose, btnOkElement: $btnOk, btnCancelElement: $btnCancel, btnOtherElement: $btnOther, titleElement: $title, } = PopsHandler.handleQueryElement($anim, popsType);
|
|
10302
10252
|
/**
|
|
10303
10253
|
* 遮罩层元素
|
|
10304
10254
|
*/
|
|
@@ -10306,10 +10256,10 @@ System.register('pops', [], (function (exports) {
|
|
|
10306
10256
|
/**
|
|
10307
10257
|
* 已创建的元素列表
|
|
10308
10258
|
*/
|
|
10309
|
-
|
|
10259
|
+
const elementList = [$anim];
|
|
10310
10260
|
if (config.mask.enable) {
|
|
10311
10261
|
// 启用遮罩层
|
|
10312
|
-
|
|
10262
|
+
const _handleMask_ = PopsHandler.handleMask({
|
|
10313
10263
|
type: popsType,
|
|
10314
10264
|
guid: guid,
|
|
10315
10265
|
config: config,
|
|
@@ -10319,7 +10269,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10319
10269
|
$mask = _handleMask_.maskElement;
|
|
10320
10270
|
elementList.push($mask);
|
|
10321
10271
|
}
|
|
10322
|
-
|
|
10272
|
+
const eventDetails = PopsHandler.handleEventDetails(guid, $shadowContainer, $shadowRoot, popsType, $anim, $pops, $mask, config);
|
|
10323
10273
|
/* 输入框赋值初始值 */
|
|
10324
10274
|
$input.value = config.content.text;
|
|
10325
10275
|
PopsHandler.handlePromptClickEvent("close", $input, $btnClose, eventDetails, config.btn.close.callback);
|
|
@@ -10361,7 +10311,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10361
10311
|
if (config.content.select) {
|
|
10362
10312
|
$input.select();
|
|
10363
10313
|
}
|
|
10364
|
-
|
|
10314
|
+
const result = PopsHandler.handleResultDetails(eventDetails);
|
|
10365
10315
|
return result;
|
|
10366
10316
|
},
|
|
10367
10317
|
};
|
|
@@ -10475,8 +10425,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10475
10425
|
throw new Error("config.target 不能为空");
|
|
10476
10426
|
}
|
|
10477
10427
|
if (details.data) {
|
|
10478
|
-
|
|
10479
|
-
config.data = details.data;
|
|
10428
|
+
Reflect.set(config, "data", details.data);
|
|
10480
10429
|
}
|
|
10481
10430
|
const { $shadowContainer, $shadowRoot } = PopsHandler.handlerShadow(config);
|
|
10482
10431
|
PopsHandler.handleInit($shadowRoot, [
|
|
@@ -10498,7 +10447,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10498
10447
|
},
|
|
10499
10448
|
]);
|
|
10500
10449
|
if (config.style != null) {
|
|
10501
|
-
|
|
10450
|
+
const cssNode = popsDOMUtils.createElement("style", {
|
|
10502
10451
|
innerHTML: config.style,
|
|
10503
10452
|
}, {
|
|
10504
10453
|
type: "text/css",
|
|
@@ -10518,7 +10467,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10518
10467
|
if (!PopsContextMenu.rootElement) {
|
|
10519
10468
|
return;
|
|
10520
10469
|
}
|
|
10521
|
-
|
|
10470
|
+
const $click = event.target;
|
|
10522
10471
|
if ($click.closest(`.pops-${popsType}`)) {
|
|
10523
10472
|
return;
|
|
10524
10473
|
}
|
|
@@ -10535,7 +10484,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10535
10484
|
if (!PopsContextMenu.rootElement) {
|
|
10536
10485
|
return;
|
|
10537
10486
|
}
|
|
10538
|
-
|
|
10487
|
+
const $click = event.target;
|
|
10539
10488
|
if ($click.closest(`.pops-${popsType}`)) {
|
|
10540
10489
|
return;
|
|
10541
10490
|
}
|
|
@@ -10586,7 +10535,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10586
10535
|
if (PopsContextMenu.rootElement) {
|
|
10587
10536
|
PopsContextMenu.closeAllMenu(PopsContextMenu.rootElement);
|
|
10588
10537
|
}
|
|
10589
|
-
|
|
10538
|
+
const rootElement = PopsContextMenu.showMenu(event, config.data, selectorTarget);
|
|
10590
10539
|
PopsContextMenu.rootElement = rootElement;
|
|
10591
10540
|
if (config.only) {
|
|
10592
10541
|
PopsHandler.handlePush(popsType, {
|
|
@@ -10625,7 +10574,8 @@ System.register('pops', [], (function (exports) {
|
|
|
10625
10574
|
/**
|
|
10626
10575
|
* 动画结束触发的事件
|
|
10627
10576
|
*/
|
|
10628
|
-
|
|
10577
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
10578
|
+
const transitionEndEvent = (event) => {
|
|
10629
10579
|
popsDOMUtils.off($menu, popsDOMUtils.getTransitionEndNameList(), transitionEndEvent, {
|
|
10630
10580
|
capture: true,
|
|
10631
10581
|
});
|
|
@@ -10665,7 +10615,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10665
10615
|
if (rootElementMenuData?.root) {
|
|
10666
10616
|
rootElement = rootElementMenuData.root;
|
|
10667
10617
|
}
|
|
10668
|
-
|
|
10618
|
+
const childMenuList = rootElementMenuData.child;
|
|
10669
10619
|
childMenuList.forEach((childMenuElement) => {
|
|
10670
10620
|
this.animationCloseMenu(childMenuElement);
|
|
10671
10621
|
});
|
|
@@ -10677,11 +10627,11 @@ System.register('pops', [], (function (exports) {
|
|
|
10677
10627
|
* @param isChildren 是否是rightClickMenu的某一项的子菜单
|
|
10678
10628
|
*/
|
|
10679
10629
|
createMenuContainerElement(isChildren) {
|
|
10680
|
-
|
|
10630
|
+
const $menu = popsDOMUtils.createElement("div", {
|
|
10681
10631
|
className: `pops-${popsType}`,
|
|
10682
10632
|
innerHTML: /*html*/ `<ul class="pops-${popsType}-wrapper"></ul>`,
|
|
10683
10633
|
});
|
|
10684
|
-
|
|
10634
|
+
const zIndex = this.getMenuZIndex();
|
|
10685
10635
|
if (zIndex > 10000) {
|
|
10686
10636
|
$menu.style.zIndex = zIndex.toString();
|
|
10687
10637
|
}
|
|
@@ -10712,26 +10662,26 @@ System.register('pops', [], (function (exports) {
|
|
|
10712
10662
|
* @param isMainMenu 是否是主菜单
|
|
10713
10663
|
*/
|
|
10714
10664
|
getOffset(menuElement, mousePosition, parentInfo) {
|
|
10715
|
-
|
|
10665
|
+
const result = {
|
|
10716
10666
|
top: 0,
|
|
10717
10667
|
right: 0,
|
|
10718
10668
|
bottom: 0,
|
|
10719
10669
|
left: 0,
|
|
10720
10670
|
};
|
|
10721
|
-
|
|
10722
|
-
|
|
10671
|
+
const menuElementWidth = popsDOMUtils.width(menuElement);
|
|
10672
|
+
const menuElementHeight = popsDOMUtils.height(menuElement);
|
|
10723
10673
|
/**
|
|
10724
10674
|
* 限制的间隙距离
|
|
10725
10675
|
*/
|
|
10726
|
-
|
|
10727
|
-
|
|
10728
|
-
|
|
10676
|
+
const limitDistance = 1;
|
|
10677
|
+
const maxPageLeftOffset = popsDOMUtils.width(globalThis) - limitDistance;
|
|
10678
|
+
const maxPageTopOffset = popsDOMUtils.height(globalThis) - limitDistance;
|
|
10729
10679
|
/* left最大偏移 */
|
|
10730
|
-
|
|
10680
|
+
const maxLeftOffset = maxPageLeftOffset - menuElementWidth;
|
|
10731
10681
|
/* top最大偏移 */
|
|
10732
|
-
|
|
10733
|
-
|
|
10734
|
-
|
|
10682
|
+
const maxTopOffset = maxPageTopOffset - menuElementHeight;
|
|
10683
|
+
const chileMenuLeftOrRightDistance = config.chileMenuLeftOrRightDistance;
|
|
10684
|
+
const childMenuTopOrBottomDistance = config.childMenuTopOrBottomDistance;
|
|
10735
10685
|
let currentLeftOffset = mousePosition.x;
|
|
10736
10686
|
let currentTopOffset = mousePosition.y;
|
|
10737
10687
|
currentLeftOffset = currentLeftOffset < 0 ? 0 : currentLeftOffset;
|
|
@@ -10741,9 +10691,8 @@ System.register('pops', [], (function (exports) {
|
|
|
10741
10691
|
// 偏移计算方式就是父菜单的右偏移+父菜单的宽度
|
|
10742
10692
|
if (parentInfo) {
|
|
10743
10693
|
// 子菜单
|
|
10744
|
-
|
|
10745
|
-
currentLeftOffset =
|
|
10746
|
-
maxPageLeftOffset - mainMenuOffset.left - chileMenuLeftOrRightDistance + limitDistance;
|
|
10694
|
+
const mainMenuOffset = popsDOMUtils.offset(parentInfo.$menu);
|
|
10695
|
+
currentLeftOffset = maxPageLeftOffset - mainMenuOffset.left - chileMenuLeftOrRightDistance + limitDistance;
|
|
10747
10696
|
}
|
|
10748
10697
|
else {
|
|
10749
10698
|
// 主菜单 默认的
|
|
@@ -10771,7 +10720,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10771
10720
|
// 超过,那么子菜单将会在放在上面
|
|
10772
10721
|
if (parentInfo) {
|
|
10773
10722
|
// 以项的top偏移为基准
|
|
10774
|
-
|
|
10723
|
+
const parentItemOffset = popsDOMUtils.offset(parentInfo.$parentItem, false);
|
|
10775
10724
|
currentTopOffset =
|
|
10776
10725
|
maxPageTopOffset - parentItemOffset.bottom - childMenuTopOrBottomDistance + limitDistance;
|
|
10777
10726
|
}
|
|
@@ -10802,7 +10751,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10802
10751
|
* @param menuListenerRootNode 右键菜单监听的元素
|
|
10803
10752
|
*/
|
|
10804
10753
|
showMenu(menuEvent, _config_, menuListenerRootNode) {
|
|
10805
|
-
|
|
10754
|
+
const menuElement = this.createMenuContainerElement(false);
|
|
10806
10755
|
Reflect.set(menuElement, "__menuData__", {
|
|
10807
10756
|
child: [],
|
|
10808
10757
|
});
|
|
@@ -10830,19 +10779,19 @@ System.register('pops', [], (function (exports) {
|
|
|
10830
10779
|
* @param menuListenerRootNode 右键菜单监听的元素
|
|
10831
10780
|
*/
|
|
10832
10781
|
showClildMenu(menuEvent, posInfo, _config_, rootElement, targetLiElement, menuListenerRootNode) {
|
|
10833
|
-
|
|
10782
|
+
const menuElement = this.createMenuContainerElement(true);
|
|
10834
10783
|
Reflect.set(menuElement, "__menuData__", {
|
|
10835
10784
|
parent: targetLiElement,
|
|
10836
10785
|
root: rootElement,
|
|
10837
10786
|
});
|
|
10838
10787
|
// 根菜单数据
|
|
10839
|
-
|
|
10788
|
+
const rootElementMenuData = Reflect.get(rootElement, "__menuData__");
|
|
10840
10789
|
rootElementMenuData.child.push(menuElement);
|
|
10841
10790
|
// 添加子元素
|
|
10842
10791
|
PopsContextMenu.addMenuLiELement(menuEvent, rootElement, menuElement, _config_, menuListenerRootNode);
|
|
10843
10792
|
// 添加到页面
|
|
10844
10793
|
popsDOMUtils.append($shadowRoot, menuElement);
|
|
10845
|
-
|
|
10794
|
+
const $parentMenu = targetLiElement.closest(".pops-rightClickMenu");
|
|
10846
10795
|
this.handlerShowMenuCSS(menuElement, posInfo, {
|
|
10847
10796
|
$menu: $parentMenu,
|
|
10848
10797
|
$parentItem: targetLiElement,
|
|
@@ -10856,7 +10805,7 @@ System.register('pops', [], (function (exports) {
|
|
|
10856
10805
|
* @param parentInfo 配置子菜单的父级信息
|
|
10857
10806
|
*/
|
|
10858
10807
|
handlerShowMenuCSS($menu, posInfo, parentInfo) {
|
|
10859
|
-
|
|
10808
|
+
const offset = this.getOffset($menu, {
|
|
10860
10809
|
x: posInfo.clientX,
|
|
10861
10810
|
y: posInfo.clientY,
|
|
10862
10811
|
}, parentInfo);
|
|
@@ -10882,14 +10831,14 @@ System.register('pops', [], (function (exports) {
|
|
|
10882
10831
|
* @param menuListenerRootNode 右键菜单监听的元素
|
|
10883
10832
|
*/
|
|
10884
10833
|
addMenuLiELement(menuEvent, rootElement, menuElement, _config_, menuListenerRootNode) {
|
|
10885
|
-
|
|
10886
|
-
|
|
10834
|
+
const menuEventTarget = menuEvent.target;
|
|
10835
|
+
const menuULElement = menuElement.querySelector("ul");
|
|
10887
10836
|
_config_.forEach((item) => {
|
|
10888
|
-
|
|
10837
|
+
const menuLiElement = popsDOMUtils.parseTextToDOM(`<li></li>`);
|
|
10889
10838
|
/* 判断有无图标,有就添加进去 */
|
|
10890
10839
|
if (typeof item.icon === "string" && item.icon.trim() !== "") {
|
|
10891
|
-
|
|
10892
|
-
|
|
10840
|
+
const iconSVGHTML = PopsIcon.getIcon(item.icon) ?? item.icon;
|
|
10841
|
+
const iconElement = popsDOMUtils.parseTextToDOM(
|
|
10893
10842
|
/*html*/ `<i class="pops-${popsType}-icon" is-loading="${item.iconIsLoading ?? false}">${iconSVGHTML}</i>`);
|
|
10894
10843
|
menuLiElement.appendChild(iconElement);
|
|
10895
10844
|
}
|
|
@@ -10914,13 +10863,13 @@ System.register('pops', [], (function (exports) {
|
|
|
10914
10863
|
}
|
|
10915
10864
|
Array.from(menuULElement.children).forEach((liElement) => {
|
|
10916
10865
|
popsDOMUtils.removeClassName(liElement, `pops-${popsType}-is-visited`);
|
|
10917
|
-
|
|
10866
|
+
const li_menuData = Reflect.get(liElement, "__menuData__");
|
|
10918
10867
|
if (!li_menuData) {
|
|
10919
10868
|
return;
|
|
10920
10869
|
}
|
|
10921
10870
|
function removeElement(element) {
|
|
10922
10871
|
element.querySelectorAll("ul li").forEach(($ele) => {
|
|
10923
|
-
|
|
10872
|
+
const menuData = Reflect.get($ele, "__menuData__");
|
|
10924
10873
|
if (menuData?.child) {
|
|
10925
10874
|
removeElement(menuData.child);
|
|
10926
10875
|
}
|
|
@@ -10931,9 +10880,9 @@ System.register('pops', [], (function (exports) {
|
|
|
10931
10880
|
removeElement(li_menuData.child);
|
|
10932
10881
|
});
|
|
10933
10882
|
/* 清理根元素上的children不存在于页面中的元素 */
|
|
10934
|
-
|
|
10883
|
+
const root_menuData = Reflect.get(rootElement, "__menuData__");
|
|
10935
10884
|
for (let index = 0; index < root_menuData.child.length; index++) {
|
|
10936
|
-
|
|
10885
|
+
const element = root_menuData.child[index];
|
|
10937
10886
|
if (!$shadowRoot.contains(element)) {
|
|
10938
10887
|
root_menuData.child.splice(index, 1);
|
|
10939
10888
|
index--;
|
|
@@ -10943,8 +10892,8 @@ System.register('pops', [], (function (exports) {
|
|
|
10943
10892
|
if (!item.item) {
|
|
10944
10893
|
return;
|
|
10945
10894
|
}
|
|
10946
|
-
|
|
10947
|
-
|
|
10895
|
+
const rect = menuLiElement.getBoundingClientRect();
|
|
10896
|
+
const childMenu = PopsContextMenu.showClildMenu(menuEvent, {
|
|
10948
10897
|
clientX: rect.left + popsDOMUtils.outerWidth(menuLiElement),
|
|
10949
10898
|
clientY: rect.top,
|
|
10950
10899
|
}, item.item, rootElement, menuLiElement, menuListenerRootNode);
|
|
@@ -10965,8 +10914,10 @@ System.register('pops', [], (function (exports) {
|
|
|
10965
10914
|
},
|
|
10966
10915
|
});
|
|
10967
10916
|
}
|
|
10968
|
-
catch
|
|
10969
|
-
|
|
10917
|
+
catch {
|
|
10918
|
+
// 忽略
|
|
10919
|
+
}
|
|
10920
|
+
const callbackResult = await item.callback(clickEvent, menuEvent, menuLiElement, menuListenerRootNode);
|
|
10970
10921
|
if (typeof callbackResult === "boolean" && callbackResult == false) {
|
|
10971
10922
|
return;
|
|
10972
10923
|
}
|
|
@@ -11009,8 +10960,8 @@ System.register('pops', [], (function (exports) {
|
|
|
11009
10960
|
console.log("删除当前项", [event, $dataItem, dataItem, config]);
|
|
11010
10961
|
return true;
|
|
11011
10962
|
},
|
|
11012
|
-
itemView(dateItem
|
|
11013
|
-
return
|
|
10963
|
+
itemView(dateItem) {
|
|
10964
|
+
return `${dateItem.value}-html`;
|
|
11014
10965
|
},
|
|
11015
10966
|
clickCallback(event, $dataItem, dataItem, config) {
|
|
11016
10967
|
console.log("item项的点击回调", [event, $dataItem, data, config]);
|
|
@@ -11088,7 +11039,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11088
11039
|
},
|
|
11089
11040
|
]);
|
|
11090
11041
|
if (config.style != null) {
|
|
11091
|
-
|
|
11042
|
+
const cssNode = document.createElement("style");
|
|
11092
11043
|
popsDOMUtils.createElement("style", {
|
|
11093
11044
|
innerHTML: config.style,
|
|
11094
11045
|
}, {
|
|
@@ -11136,8 +11087,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11136
11087
|
Reflect.set(SearchSuggestion.$el.root, "data-SearchSuggestion", SearchSuggestion);
|
|
11137
11088
|
SearchSuggestion.$el.$dynamicCSS =
|
|
11138
11089
|
SearchSuggestion.$el.root.querySelector("style[data-dynamic]");
|
|
11139
|
-
SearchSuggestion.$el.$hintULContainer =
|
|
11140
|
-
SearchSuggestion.$el.root.querySelector("ul");
|
|
11090
|
+
SearchSuggestion.$el.$hintULContainer = SearchSuggestion.$el.root.querySelector("ul");
|
|
11141
11091
|
},
|
|
11142
11092
|
/**
|
|
11143
11093
|
* 获取数据
|
|
@@ -11156,7 +11106,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11156
11106
|
* 获取显示出搜索建议框的html
|
|
11157
11107
|
*/
|
|
11158
11108
|
createSearchSelectElement() {
|
|
11159
|
-
|
|
11109
|
+
const $el = popsDOMUtils.createElement("div", {
|
|
11160
11110
|
className: `pops pops-${popsType}-search-suggestion`,
|
|
11161
11111
|
innerHTML: /*html*/ `
|
|
11162
11112
|
<style type="text/css">
|
|
@@ -11357,7 +11307,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11357
11307
|
*/
|
|
11358
11308
|
createSearchItemLiElement(dataItem, dateItemIndex) {
|
|
11359
11309
|
const dataValue = SearchSuggestion.getItemDataValue(dataItem);
|
|
11360
|
-
|
|
11310
|
+
const $li = popsDOMUtils.createElement("li", {
|
|
11361
11311
|
className: `pops-${popsType}-search-suggestion-hint-item`,
|
|
11362
11312
|
"data-index": dateItemIndex,
|
|
11363
11313
|
"data-value": dataValue,
|
|
@@ -11365,7 +11315,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11365
11315
|
Reflect.set($li, "data-index", dateItemIndex);
|
|
11366
11316
|
Reflect.set($li, "data-value", dataValue);
|
|
11367
11317
|
// 项内容
|
|
11368
|
-
|
|
11318
|
+
const $itemInner = dataItem.itemView(dataItem, $li, config);
|
|
11369
11319
|
if (typeof $itemInner === "string") {
|
|
11370
11320
|
PopsSafeUtils.setSafeHTML($li, $itemInner);
|
|
11371
11321
|
}
|
|
@@ -11375,7 +11325,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11375
11325
|
// 删除按钮
|
|
11376
11326
|
const enableDeleteButton = dataItem.enableDeleteButton;
|
|
11377
11327
|
if (typeof enableDeleteButton === "boolean" && enableDeleteButton) {
|
|
11378
|
-
|
|
11328
|
+
const $deleteIcon = SearchSuggestion.createItemDeleteIcon();
|
|
11379
11329
|
popsDOMUtils.append($li, $deleteIcon);
|
|
11380
11330
|
}
|
|
11381
11331
|
popsDOMUtils.addClassName($li, PopsCommonCSSClassName.flexCenter);
|
|
@@ -11389,14 +11339,14 @@ System.register('pops', [], (function (exports) {
|
|
|
11389
11339
|
setSearchItemClickEvent($searchItem) {
|
|
11390
11340
|
popsDOMUtils.on($searchItem, "click", async (event) => {
|
|
11391
11341
|
popsDOMUtils.preventEvent(event);
|
|
11392
|
-
|
|
11342
|
+
const $click = event.target;
|
|
11393
11343
|
const data = SearchSuggestion.getData();
|
|
11394
11344
|
const dataItem = Reflect.get($searchItem, "data-value");
|
|
11395
|
-
|
|
11345
|
+
const isDelete = Boolean($click.closest(`.pops-${popsType}-delete-icon`));
|
|
11396
11346
|
if (isDelete) {
|
|
11397
11347
|
// 删除
|
|
11398
11348
|
if (typeof dataItem.deleteButtonClickCallback === "function") {
|
|
11399
|
-
|
|
11349
|
+
const result = await dataItem.deleteButtonClickCallback(event, $searchItem, dataItem, config);
|
|
11400
11350
|
if (typeof result === "boolean" && result) {
|
|
11401
11351
|
data.splice(data.indexOf(dataItem), 1);
|
|
11402
11352
|
$searchItem.remove();
|
|
@@ -11411,7 +11361,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11411
11361
|
else {
|
|
11412
11362
|
// 点击选择项
|
|
11413
11363
|
if (typeof dataItem.clickCallback === "function") {
|
|
11414
|
-
|
|
11364
|
+
const result = await dataItem.clickCallback(event, $searchItem, dataItem, config);
|
|
11415
11365
|
if (typeof result === "boolean" && result) {
|
|
11416
11366
|
if (config.inputTarget instanceof HTMLInputElement ||
|
|
11417
11367
|
config.inputTarget instanceof HTMLTextAreaElement) {
|
|
@@ -11428,6 +11378,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11428
11378
|
* 设置搜索建议框每一项的选中事件
|
|
11429
11379
|
* @param liElement
|
|
11430
11380
|
*/
|
|
11381
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
11431
11382
|
setSearchItemSelectEvent(liElement) {
|
|
11432
11383
|
// popsDOMUtils.on(
|
|
11433
11384
|
// liElement,
|
|
@@ -11449,17 +11400,18 @@ System.register('pops', [], (function (exports) {
|
|
|
11449
11400
|
capture: true,
|
|
11450
11401
|
}) {
|
|
11451
11402
|
/* 必须是input或者textarea才有input事件 */
|
|
11452
|
-
if (!(config.inputTarget instanceof HTMLInputElement ||
|
|
11453
|
-
config.inputTarget instanceof HTMLTextAreaElement)) {
|
|
11403
|
+
if (!(config.inputTarget instanceof HTMLInputElement || config.inputTarget instanceof HTMLTextAreaElement)) {
|
|
11454
11404
|
return;
|
|
11455
11405
|
}
|
|
11456
11406
|
/* 是input输入框 */
|
|
11457
11407
|
/* 禁用输入框自动提示 */
|
|
11458
11408
|
config.inputTarget.setAttribute("autocomplete", "off");
|
|
11459
11409
|
/* 内容改变事件 */
|
|
11460
|
-
const listenerHandler = popsDOMUtils.onInput(config.inputTarget,
|
|
11410
|
+
const listenerHandler = popsDOMUtils.onInput(config.inputTarget,
|
|
11411
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
11412
|
+
async (_event) => {
|
|
11461
11413
|
const data = SearchSuggestion.getData();
|
|
11462
|
-
|
|
11414
|
+
const queryDataResult = await config.inputTargetChangeRefreshShowDataCallback(config.inputTarget.value, data, config);
|
|
11463
11415
|
SearchSuggestion.update(queryDataResult);
|
|
11464
11416
|
SearchSuggestion.updateStyleSheet();
|
|
11465
11417
|
}, option);
|
|
@@ -11468,7 +11420,9 @@ System.register('pops', [], (function (exports) {
|
|
|
11468
11420
|
/**
|
|
11469
11421
|
* 移除输入框内容改变的监听
|
|
11470
11422
|
*/
|
|
11471
|
-
removeInputChangeEvent(
|
|
11423
|
+
removeInputChangeEvent(
|
|
11424
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
11425
|
+
option = {
|
|
11472
11426
|
capture: true,
|
|
11473
11427
|
}) {
|
|
11474
11428
|
for (let index = 0; index < SearchSuggestion.$evt.offInputChangeEvtHandler.length; index++) {
|
|
@@ -11603,7 +11557,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11603
11557
|
* 获取删除按钮的html
|
|
11604
11558
|
*/
|
|
11605
11559
|
createItemDeleteIcon(size = 16, fill = "#bababa") {
|
|
11606
|
-
|
|
11560
|
+
const $svg = popsDOMUtils.parseTextToDOM(/*html*/ `
|
|
11607
11561
|
<svg class="pops-${popsType}-delete-icon" viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg" width="${size}" height="${size}" fill="${fill}">
|
|
11608
11562
|
<path d="M512 883.2A371.2 371.2 0 1 0 140.8 512 371.2 371.2 0 0 0 512 883.2z m0 64a435.2 435.2 0 1 1 435.2-435.2 435.2 435.2 0 0 1-435.2 435.2z"></path>
|
|
11609
11563
|
<path d="M557.056 512l122.368 122.368a31.744 31.744 0 1 1-45.056 45.056L512 557.056l-122.368 122.368a31.744 31.744 0 1 1-45.056-45.056L466.944 512 344.576 389.632a31.744 31.744 0 1 1 45.056-45.056L512 466.944l122.368-122.368a31.744 31.744 0 1 1 45.056 45.056z"></path>
|
|
@@ -11615,7 +11569,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11615
11569
|
* 设置当前正在搜索中的提示
|
|
11616
11570
|
*/
|
|
11617
11571
|
setPromptsInSearch() {
|
|
11618
|
-
|
|
11572
|
+
const $isSearching = popsDOMUtils.createElement("li", {
|
|
11619
11573
|
className: `pops-${popsType}-search-suggestion-hint-searching-item`,
|
|
11620
11574
|
innerHTML: config.searchingTip,
|
|
11621
11575
|
});
|
|
@@ -11653,12 +11607,12 @@ System.register('pops', [], (function (exports) {
|
|
|
11653
11607
|
documentHeight = popsDOMUtils.height(document);
|
|
11654
11608
|
}
|
|
11655
11609
|
// 文档最大宽度
|
|
11656
|
-
|
|
11610
|
+
const documentWidth = popsDOMUtils.width(document);
|
|
11657
11611
|
let position = config.position;
|
|
11658
11612
|
if (config.position === "auto") {
|
|
11659
11613
|
// 需目标高度+搜索建议框高度大于文档高度,则显示在上面
|
|
11660
|
-
|
|
11661
|
-
|
|
11614
|
+
const targetBottom = targetRect.bottom;
|
|
11615
|
+
const searchSuggestionContainerHeight = popsDOMUtils.height(SearchSuggestion.$el.$hintULContainer);
|
|
11662
11616
|
if (targetBottom + searchSuggestionContainerHeight > documentHeight) {
|
|
11663
11617
|
// 在上面
|
|
11664
11618
|
position = "top";
|
|
@@ -11678,7 +11632,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11678
11632
|
// 翻转折叠
|
|
11679
11633
|
SearchSuggestion.$el.root.setAttribute("data-popper-placement", "top");
|
|
11680
11634
|
}
|
|
11681
|
-
|
|
11635
|
+
const bottom = documentHeight - targetRect.top + config.topDistance;
|
|
11682
11636
|
SearchSuggestion.$el.root.style.top = "";
|
|
11683
11637
|
SearchSuggestion.$el.root.style.bottom = bottom + "px";
|
|
11684
11638
|
}
|
|
@@ -11687,13 +11641,13 @@ System.register('pops', [], (function (exports) {
|
|
|
11687
11641
|
if (config.useFoldAnimation) {
|
|
11688
11642
|
SearchSuggestion.$el.root.setAttribute("data-popper-placement", "bottom-center");
|
|
11689
11643
|
}
|
|
11690
|
-
|
|
11644
|
+
const top = targetRect.height + targetRect.top + config.topDistance;
|
|
11691
11645
|
SearchSuggestion.$el.root.removeAttribute("data-top-reverse");
|
|
11692
11646
|
SearchSuggestion.$el.root.style.bottom = "";
|
|
11693
11647
|
SearchSuggestion.$el.root.style.top = top + "px";
|
|
11694
11648
|
}
|
|
11695
11649
|
let left = targetRect.left;
|
|
11696
|
-
|
|
11650
|
+
const hintUIWidth = popsDOMUtils.width(SearchSuggestion.$el.$hintULContainer);
|
|
11697
11651
|
if (hintUIWidth > documentWidth) {
|
|
11698
11652
|
// 超出宽度
|
|
11699
11653
|
left = left + documentWidth - hintUIWidth;
|
|
@@ -11714,7 +11668,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11714
11668
|
* @param target 目标元素
|
|
11715
11669
|
*/
|
|
11716
11670
|
changeHintULElementWidth(target = config.target ?? config.inputTarget) {
|
|
11717
|
-
|
|
11671
|
+
const targetRect = target.getBoundingClientRect();
|
|
11718
11672
|
if (config.followTargetWidth) {
|
|
11719
11673
|
SearchSuggestion.$el.$hintULContainer.style.width = targetRect.width + "px";
|
|
11720
11674
|
}
|
|
@@ -11726,7 +11680,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11726
11680
|
* 动态更新CSS
|
|
11727
11681
|
*/
|
|
11728
11682
|
updateDynamicCSS() {
|
|
11729
|
-
|
|
11683
|
+
const cssText = SearchSuggestion.getDynamicCSS();
|
|
11730
11684
|
PopsSafeUtils.setSafeHTML(SearchSuggestion.$el.$dynamicCSS, cssText);
|
|
11731
11685
|
},
|
|
11732
11686
|
/**
|
|
@@ -11768,9 +11722,9 @@ System.register('pops', [], (function (exports) {
|
|
|
11768
11722
|
}
|
|
11769
11723
|
SearchSuggestion.clear(true);
|
|
11770
11724
|
/* 添加进ul中 */
|
|
11771
|
-
|
|
11725
|
+
const fragment = document.createDocumentFragment();
|
|
11772
11726
|
data.forEach((item, index) => {
|
|
11773
|
-
|
|
11727
|
+
const $item = SearchSuggestion.createSearchItemLiElement(item, index);
|
|
11774
11728
|
SearchSuggestion.setSearchItemClickEvent($item);
|
|
11775
11729
|
SearchSuggestion.setSearchItemSelectEvent($item);
|
|
11776
11730
|
fragment.appendChild($item);
|
|
@@ -11838,11 +11792,13 @@ System.register('pops', [], (function (exports) {
|
|
|
11838
11792
|
},
|
|
11839
11793
|
};
|
|
11840
11794
|
|
|
11795
|
+
const version = "2.4.6";
|
|
11796
|
+
|
|
11841
11797
|
class Pops {
|
|
11842
11798
|
/** 配置 */
|
|
11843
11799
|
config = {
|
|
11844
11800
|
/** 版本号 */
|
|
11845
|
-
version:
|
|
11801
|
+
version: version,
|
|
11846
11802
|
cssText: PopsCSS,
|
|
11847
11803
|
/** icon图标的svg代码 */
|
|
11848
11804
|
iconSVG: PopsIcon.$data,
|
|
@@ -11877,9 +11833,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11877
11833
|
if (typeof PopsCore.globalThis.pops === "object") {
|
|
11878
11834
|
popsUtils.delete(PopsCore.globalThis, "pops");
|
|
11879
11835
|
}
|
|
11880
|
-
if (typeof unsafeWindow === "object" &&
|
|
11881
|
-
unsafeWindow != null &&
|
|
11882
|
-
typeof unsafeWindow.pops === "object") {
|
|
11836
|
+
if (typeof unsafeWindow === "object" && unsafeWindow != null && typeof unsafeWindow.pops === "object") {
|
|
11883
11837
|
popsUtils.delete(unsafeWindow, "pops");
|
|
11884
11838
|
}
|
|
11885
11839
|
return new Pops();
|
|
@@ -11900,7 +11854,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11900
11854
|
* @param details 配置
|
|
11901
11855
|
*/
|
|
11902
11856
|
alert = (details) => {
|
|
11903
|
-
|
|
11857
|
+
const dialog = PopsAlert.init(details);
|
|
11904
11858
|
return dialog;
|
|
11905
11859
|
};
|
|
11906
11860
|
/**
|
|
@@ -11908,7 +11862,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11908
11862
|
* @param details 配置
|
|
11909
11863
|
*/
|
|
11910
11864
|
confirm = (details) => {
|
|
11911
|
-
|
|
11865
|
+
const dialog = PopsConfirm.init(details);
|
|
11912
11866
|
return dialog;
|
|
11913
11867
|
};
|
|
11914
11868
|
/**
|
|
@@ -11916,7 +11870,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11916
11870
|
* @param details 配置
|
|
11917
11871
|
*/
|
|
11918
11872
|
prompt = (details) => {
|
|
11919
|
-
|
|
11873
|
+
const dialog = PopsPrompt.init(details);
|
|
11920
11874
|
return dialog;
|
|
11921
11875
|
};
|
|
11922
11876
|
/**
|
|
@@ -11924,7 +11878,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11924
11878
|
* @param details 配置
|
|
11925
11879
|
*/
|
|
11926
11880
|
loading = (details) => {
|
|
11927
|
-
|
|
11881
|
+
const popsLoading = PopsLoading.init(details);
|
|
11928
11882
|
return popsLoading;
|
|
11929
11883
|
};
|
|
11930
11884
|
/**
|
|
@@ -11932,7 +11886,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11932
11886
|
* @param details 配置
|
|
11933
11887
|
*/
|
|
11934
11888
|
iframe = (details) => {
|
|
11935
|
-
|
|
11889
|
+
const dialog = PopsIframe.init(details);
|
|
11936
11890
|
return dialog;
|
|
11937
11891
|
};
|
|
11938
11892
|
/**
|
|
@@ -11940,7 +11894,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11940
11894
|
* @param details 配置
|
|
11941
11895
|
*/
|
|
11942
11896
|
tooltip = (details) => {
|
|
11943
|
-
|
|
11897
|
+
const popsTooltip = PopsTooltip.init(details);
|
|
11944
11898
|
return popsTooltip;
|
|
11945
11899
|
};
|
|
11946
11900
|
/**
|
|
@@ -11948,7 +11902,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11948
11902
|
* @param details 配置
|
|
11949
11903
|
*/
|
|
11950
11904
|
drawer = (details) => {
|
|
11951
|
-
|
|
11905
|
+
const dialog = PopsDrawer.init(details);
|
|
11952
11906
|
return dialog;
|
|
11953
11907
|
};
|
|
11954
11908
|
/**
|
|
@@ -11956,7 +11910,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11956
11910
|
* @param details 配置
|
|
11957
11911
|
*/
|
|
11958
11912
|
folder = (details) => {
|
|
11959
|
-
|
|
11913
|
+
const dialog = PopsFolder.init(details);
|
|
11960
11914
|
return dialog;
|
|
11961
11915
|
};
|
|
11962
11916
|
/**
|
|
@@ -11964,7 +11918,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11964
11918
|
* @param details 配置
|
|
11965
11919
|
*/
|
|
11966
11920
|
panel = (details) => {
|
|
11967
|
-
|
|
11921
|
+
const dialog = PopsPanel.init(details);
|
|
11968
11922
|
return dialog;
|
|
11969
11923
|
};
|
|
11970
11924
|
/**
|
|
@@ -11972,7 +11926,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11972
11926
|
* @param details 配置
|
|
11973
11927
|
*/
|
|
11974
11928
|
rightClickMenu = (details) => {
|
|
11975
|
-
|
|
11929
|
+
const popsRightClickMenu = PopsRightClickMenu.init(details);
|
|
11976
11930
|
return popsRightClickMenu;
|
|
11977
11931
|
};
|
|
11978
11932
|
/**
|
|
@@ -11993,7 +11947,7 @@ System.register('pops', [], (function (exports) {
|
|
|
11993
11947
|
* searchSuggestion.setAllEvent();
|
|
11994
11948
|
*/
|
|
11995
11949
|
searchSuggestion = (details) => {
|
|
11996
|
-
|
|
11950
|
+
const popsSearchSuggestion = PopsSearchSuggestion.init(details);
|
|
11997
11951
|
return popsSearchSuggestion;
|
|
11998
11952
|
};
|
|
11999
11953
|
}
|