@whitesev/pops 1.9.4 → 1.9.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/dist/index.amd.js +18 -12
- package/dist/index.amd.js.map +1 -1
- package/dist/index.cjs.js +18 -12
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +18 -12
- package/dist/index.esm.js.map +1 -1
- package/dist/index.iife.js +18 -12
- package/dist/index.iife.js.map +1 -1
- package/dist/index.system.js +18 -12
- package/dist/index.system.js.map +1 -1
- package/dist/index.umd.js +18 -12
- package/dist/index.umd.js.map +1 -1
- package/dist/types/src/handler/PopsHandler.d.ts +1 -10
- package/package.json +1 -1
- package/src/Pops.ts +1 -1
- package/src/components/drawer/index.ts +1 -5
- package/src/components/panel/index.css +7 -0
- package/src/components/tooltip/index.ts +16 -11
- package/src/handler/PopsHandler.ts +1 -10
|
@@ -174,16 +174,7 @@ export declare const PopsHandler: {
|
|
|
174
174
|
/**
|
|
175
175
|
* 处理返回的配置,针对popsHandler.handleEventDetails
|
|
176
176
|
*/
|
|
177
|
-
handleResultDetails(details:
|
|
178
|
-
$shadowContainer: HTMLDivElement;
|
|
179
|
-
$shadowRoot: ShadowRoot;
|
|
180
|
-
animElement: HTMLElement;
|
|
181
|
-
popsElement: HTMLElement;
|
|
182
|
-
maskElement: HTMLElement;
|
|
183
|
-
close: () => void;
|
|
184
|
-
hide: () => void;
|
|
185
|
-
show: () => void;
|
|
186
|
-
};
|
|
177
|
+
handleResultDetails<T extends unknown>(details: T): Omit<T, "type" | "function">;
|
|
187
178
|
/**
|
|
188
179
|
* 处理点击事件
|
|
189
180
|
* @param type 当前按钮类型
|
package/package.json
CHANGED
package/src/Pops.ts
CHANGED
|
@@ -16,7 +16,7 @@ export class PopsDrawer {
|
|
|
16
16
|
config = popsUtils.assign(config, GlobalConfig.getGlobalConfig());
|
|
17
17
|
config = popsUtils.assign(config, details);
|
|
18
18
|
config = PopsHandler.handleOnly(PopsType, config);
|
|
19
|
-
|
|
19
|
+
|
|
20
20
|
const { $shadowContainer, $shadowRoot } = PopsHandler.handlerShadow(config);
|
|
21
21
|
PopsHandler.handleInit($shadowRoot, [
|
|
22
22
|
pops.config.cssText.index,
|
|
@@ -121,7 +121,6 @@ export class PopsDrawer {
|
|
|
121
121
|
$shadowContainer,
|
|
122
122
|
$shadowRoot,
|
|
123
123
|
PopsType,
|
|
124
|
-
|
|
125
124
|
$anim,
|
|
126
125
|
$pops,
|
|
127
126
|
$mask!,
|
|
@@ -243,11 +242,8 @@ export class PopsDrawer {
|
|
|
243
242
|
|
|
244
243
|
PopsHandler.handlePush(PopsType, {
|
|
245
244
|
guid: guid,
|
|
246
|
-
|
|
247
245
|
animElement: $anim,
|
|
248
|
-
|
|
249
246
|
popsElement: $pops,
|
|
250
|
-
|
|
251
247
|
maskElement: $mask!,
|
|
252
248
|
$shadowContainer: $shadowContainer,
|
|
253
249
|
$shadowRoot: $shadowRoot,
|
|
@@ -1068,4 +1068,11 @@ section.pops-panel-container
|
|
|
1068
1068
|
align-items: center;
|
|
1069
1069
|
cursor: pointer;
|
|
1070
1070
|
}
|
|
1071
|
+
/* 修复safari上图标大小未正常显示 */
|
|
1072
|
+
.pops-panel-deepMenu-container
|
|
1073
|
+
.pops-panel-deepMenu-container-left-arrow-icon
|
|
1074
|
+
> svg {
|
|
1075
|
+
width: inherit;
|
|
1076
|
+
height: inherit;
|
|
1077
|
+
}
|
|
1071
1078
|
/* deepMenu的css */
|
|
@@ -34,7 +34,12 @@ export class ToolTip {
|
|
|
34
34
|
this.$data.guid = guid;
|
|
35
35
|
this.$el.$shadowContainer = ShadowInfo.$shadowContainer;
|
|
36
36
|
this.$el.$shadowRoot = ShadowInfo.$shadowRoot;
|
|
37
|
-
|
|
37
|
+
this.show = this.show.bind(this);
|
|
38
|
+
this.close = this.close.bind(this);
|
|
39
|
+
this.toolTipAnimationFinishEvent =
|
|
40
|
+
this.toolTipAnimationFinishEvent.bind(this);
|
|
41
|
+
this.toolTipMouseEnterEvent = this.toolTipMouseEnterEvent.bind(this);
|
|
42
|
+
this.toolTipMouseLeaveEvent = this.toolTipMouseLeaveEvent.bind(this);
|
|
38
43
|
this.init();
|
|
39
44
|
}
|
|
40
45
|
init() {
|
|
@@ -328,7 +333,7 @@ export class ToolTip {
|
|
|
328
333
|
popsDOMUtils.on(
|
|
329
334
|
this.$data.config.target,
|
|
330
335
|
this.$data.config.triggerShowEventName,
|
|
331
|
-
this.show
|
|
336
|
+
this.show,
|
|
332
337
|
this.$data.config.eventOption
|
|
333
338
|
);
|
|
334
339
|
}
|
|
@@ -339,7 +344,7 @@ export class ToolTip {
|
|
|
339
344
|
popsDOMUtils.off(
|
|
340
345
|
this.$data.config.target,
|
|
341
346
|
this.$data.config.triggerShowEventName,
|
|
342
|
-
this.show
|
|
347
|
+
this.show,
|
|
343
348
|
{
|
|
344
349
|
capture: true,
|
|
345
350
|
}
|
|
@@ -400,7 +405,7 @@ export class ToolTip {
|
|
|
400
405
|
popsDOMUtils.on(
|
|
401
406
|
this.$data.config.target,
|
|
402
407
|
this.$data.config.triggerCloseEventName,
|
|
403
|
-
this.close
|
|
408
|
+
this.close,
|
|
404
409
|
this.$data.config.eventOption
|
|
405
410
|
);
|
|
406
411
|
}
|
|
@@ -411,7 +416,7 @@ export class ToolTip {
|
|
|
411
416
|
popsDOMUtils.off(
|
|
412
417
|
this.$data.config.target,
|
|
413
418
|
this.$data.config.triggerCloseEventName,
|
|
414
|
-
this.close
|
|
419
|
+
this.close,
|
|
415
420
|
{
|
|
416
421
|
capture: true,
|
|
417
422
|
}
|
|
@@ -450,7 +455,7 @@ export class ToolTip {
|
|
|
450
455
|
popsDOMUtils.on(
|
|
451
456
|
this.$el.$toolTip,
|
|
452
457
|
popsDOMUtils.getAnimationEndNameList(),
|
|
453
|
-
this.toolTipAnimationFinishEvent
|
|
458
|
+
this.toolTipAnimationFinishEvent
|
|
454
459
|
);
|
|
455
460
|
}
|
|
456
461
|
/**
|
|
@@ -460,7 +465,7 @@ export class ToolTip {
|
|
|
460
465
|
popsDOMUtils.off(
|
|
461
466
|
this.$el.$toolTip,
|
|
462
467
|
popsDOMUtils.getAnimationEndNameList(),
|
|
463
|
-
this.toolTipAnimationFinishEvent
|
|
468
|
+
this.toolTipAnimationFinishEvent
|
|
464
469
|
);
|
|
465
470
|
}
|
|
466
471
|
/**
|
|
@@ -484,7 +489,7 @@ export class ToolTip {
|
|
|
484
489
|
popsDOMUtils.on(
|
|
485
490
|
this.$el.$toolTip,
|
|
486
491
|
"mouseenter touchstart",
|
|
487
|
-
this.toolTipMouseEnterEvent
|
|
492
|
+
this.toolTipMouseEnterEvent,
|
|
488
493
|
this.$data.config.eventOption
|
|
489
494
|
);
|
|
490
495
|
}
|
|
@@ -495,7 +500,7 @@ export class ToolTip {
|
|
|
495
500
|
popsDOMUtils.off(
|
|
496
501
|
this.$el.$toolTip,
|
|
497
502
|
"mouseenter touchstart",
|
|
498
|
-
this.toolTipMouseEnterEvent
|
|
503
|
+
this.toolTipMouseEnterEvent,
|
|
499
504
|
this.$data.config.eventOption
|
|
500
505
|
);
|
|
501
506
|
}
|
|
@@ -513,7 +518,7 @@ export class ToolTip {
|
|
|
513
518
|
popsDOMUtils.on(
|
|
514
519
|
this.$el.$toolTip,
|
|
515
520
|
"mouseleave touchend",
|
|
516
|
-
this.toolTipMouseLeaveEvent
|
|
521
|
+
this.toolTipMouseLeaveEvent,
|
|
517
522
|
this.$data.config.eventOption
|
|
518
523
|
);
|
|
519
524
|
}
|
|
@@ -524,7 +529,7 @@ export class ToolTip {
|
|
|
524
529
|
popsDOMUtils.off(
|
|
525
530
|
this.$el.$toolTip,
|
|
526
531
|
"mouseleave touchend",
|
|
527
|
-
this.toolTipMouseLeaveEvent
|
|
532
|
+
this.toolTipMouseLeaveEvent,
|
|
528
533
|
this.$data.config.eventOption
|
|
529
534
|
);
|
|
530
535
|
}
|
|
@@ -496,16 +496,7 @@ export const PopsHandler = {
|
|
|
496
496
|
/**
|
|
497
497
|
* 处理返回的配置,针对popsHandler.handleEventDetails
|
|
498
498
|
*/
|
|
499
|
-
handleResultDetails(details:
|
|
500
|
-
$shadowContainer: HTMLDivElement;
|
|
501
|
-
$shadowRoot: ShadowRoot;
|
|
502
|
-
animElement: HTMLElement;
|
|
503
|
-
popsElement: HTMLElement;
|
|
504
|
-
maskElement: HTMLElement;
|
|
505
|
-
close: () => void;
|
|
506
|
-
hide: () => void;
|
|
507
|
-
show: () => void;
|
|
508
|
-
} {
|
|
499
|
+
handleResultDetails<T extends any>(details: T): Omit<T, "type" | "function"> {
|
|
509
500
|
let resultDetails = Object.assign({}, details);
|
|
510
501
|
popsUtils.delete(resultDetails, "type");
|
|
511
502
|
popsUtils.delete(resultDetails, "function");
|