@thinkpixellab-public/px-vue 3.0.48 → 3.0.49

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.
@@ -78,6 +78,7 @@ export default {
78
78
  data() {
79
79
  return {
80
80
  direction: 1,
81
+ lastInteractionType: null,
81
82
  activeTransitions: 0,
82
83
  scrollPreview: 0,
83
84
  };
@@ -130,8 +131,11 @@ export default {
130
131
  oldKey: ov,
131
132
  index: newIndex,
132
133
  previousIndex: oldIndex,
134
+ interactionType: this.lastInteractionType,
133
135
  });
134
136
 
137
+ this.lastInteractionType = null;
138
+
135
139
  newIndex = this.selectedRelativeIndex(newIndex);
136
140
  oldIndex = this.selectedRelativeIndex(oldIndex);
137
141
 
@@ -222,6 +226,9 @@ export default {
222
226
  if (Math.abs(ev.delta.x) < 10) {
223
227
  gsap.to(this.dragElements, { x: 0 });
224
228
  } else {
229
+ this.lastInteractionType = 'drag';
230
+ this.$emit('drag-complete');
231
+
225
232
  if (ev.delta.x > 0) {
226
233
  this.previous();
227
234
  } else {
@@ -247,6 +254,9 @@ export default {
247
254
 
248
255
  if (check !== this.lethargyPrevCheck) {
249
256
  if (check) {
257
+ this.lastInteractionType = 'scroll';
258
+ this.$emit('scroll-complete');
259
+
250
260
  if (check > 0) {
251
261
  this.previous(false);
252
262
  } else {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thinkpixellab-public/px-vue",
3
- "version": "3.0.48",
3
+ "version": "3.0.49",
4
4
  "description": "General purpose Vue components and helpers that can be used across projects.",
5
5
  "author": "Pixel Lab",
6
6
  "license": "MIT",