@thinkpixellab-public/px-vue 3.0.11 → 3.0.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/PxFloat.vue +12 -11
- package/package.json +2 -2
- package/plugins/common.js +10 -0
package/components/PxFloat.vue
CHANGED
|
@@ -549,11 +549,20 @@ $d: 0.4s;
|
|
|
549
549
|
// styles
|
|
550
550
|
|
|
551
551
|
&--none {
|
|
552
|
-
// reset
|
|
552
|
+
// reset (do nothing)
|
|
553
553
|
}
|
|
554
554
|
|
|
555
|
-
&--dialog &,
|
|
556
555
|
&--default & {
|
|
556
|
+
// default does natural center spacing and that's it
|
|
557
|
+
&__popup {
|
|
558
|
+
top: 40%;
|
|
559
|
+
left: 50%;
|
|
560
|
+
transform: translate(-50%, -40%);
|
|
561
|
+
}
|
|
562
|
+
}
|
|
563
|
+
|
|
564
|
+
&--dialog & {
|
|
565
|
+
// dialog adds basic popup styling
|
|
557
566
|
&__popup {
|
|
558
567
|
@include css-map(
|
|
559
568
|
popup(
|
|
@@ -565,14 +574,6 @@ $d: 0.4s;
|
|
|
565
574
|
}
|
|
566
575
|
}
|
|
567
576
|
|
|
568
|
-
&--dialog & {
|
|
569
|
-
&__popup {
|
|
570
|
-
top: 40%;
|
|
571
|
-
left: 50%;
|
|
572
|
-
transform: translate(-50%, -40%);
|
|
573
|
-
}
|
|
574
|
-
}
|
|
575
|
-
|
|
576
577
|
// sizes
|
|
577
578
|
|
|
578
579
|
&--sm & {
|
|
@@ -625,7 +626,7 @@ $d: 0.4s;
|
|
|
625
626
|
// default 'fade' transition
|
|
626
627
|
// ----------------------------------------------------------------------------
|
|
627
628
|
|
|
628
|
-
@include vue-transition-fade(px-float-fade, $dur: $d);
|
|
629
|
+
@include vue-transition-fade(px-float-fade, $dur: $d, $leave-pointer-events: none);
|
|
629
630
|
|
|
630
631
|
// ----------------------------------------------------------------------------
|
|
631
632
|
// blur variant transition (uses filter for opacity and animates backdrop-filter)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thinkpixellab-public/px-vue",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.12",
|
|
4
4
|
"description": "General purpose Vue components and helpers that can be used across projects.",
|
|
5
5
|
"author": "Pixel Lab",
|
|
6
6
|
"license": "MIT",
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"dependencies": {
|
|
15
15
|
"@floating-ui/dom": "^1.0.1",
|
|
16
16
|
"@popperjs/core": "^2.11.5",
|
|
17
|
-
"@thinkpixellab-public/px-styles": "^3.7.
|
|
17
|
+
"@thinkpixellab-public/px-styles": "^3.7.2",
|
|
18
18
|
"@thinkpixellab-public/px-vue-tester": "^2.0.0",
|
|
19
19
|
"@thinkpixellab-public/vue-resize-directive": "^1.2.2",
|
|
20
20
|
"body-scroll-lock": "^3.1.5",
|
package/plugins/common.js
CHANGED
|
@@ -45,5 +45,15 @@ export default {
|
|
|
45
45
|
Vue.prototype.hasSlot = function (slotName) {
|
|
46
46
|
return this.$slots && slotName in this.$slots;
|
|
47
47
|
};
|
|
48
|
+
|
|
49
|
+
/*
|
|
50
|
+
Get a unique id derived from vue's unique component identifier (this._uid) for use when an
|
|
51
|
+
id is required for an inputs, labels, etc.
|
|
52
|
+
uniqueId('label') => 'label-0003'
|
|
53
|
+
*/
|
|
54
|
+
Vue.prototype.uniqueId = function (prefix = null) {
|
|
55
|
+
let id = ('000000' + Number(this._uid).toString(16).toLowerCase()).slice(-4);
|
|
56
|
+
return prefix ? prefix + '-' + id : id;
|
|
57
|
+
};
|
|
48
58
|
},
|
|
49
59
|
};
|