Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

oribella-framework

Package Overview
Dependencies
Maintainers
1
Versions
31
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

oribella-framework - npm Package Compare versions

Comparing version 0.9.0 to 0.10.0

17

dist/amd/gesture.js

@@ -1,2 +0,2 @@

define(["require", "exports", "tslib"], function (require, exports, tslib_1) {
define(["require", "exports", "tslib", "./utils"], function (require, exports, tslib_1, utils_1) {
"use strict";

@@ -16,12 +16,7 @@ var Gesture = (function () {

Gesture.prototype.bind = function () { };
Gesture.prototype.unbind = function () { return 0; };
Gesture.prototype.start = function (args) {
return this.listener.start(args);
};
Gesture.prototype.update = function (args) {
return this.listener.update(args);
};
Gesture.prototype.end = function (args) {
return this.listener.end(args);
};
Gesture.prototype.unbind = function () { return utils_1.RETURN_FLAG.IDLE; };
Gesture.prototype.start = function () { return utils_1.RETURN_FLAG.IDLE; };
Gesture.prototype.update = function () { return utils_1.RETURN_FLAG.IDLE; };
Gesture.prototype.end = function () { return utils_1.RETURN_FLAG.IDLE; };
;
Gesture.prototype.cancel = function () { return this.listener.cancel(); };

@@ -28,0 +23,0 @@ Gesture.prototype.stop = function () { this.listener.stop(); };

"use strict";
var tslib_1 = require("tslib");
var utils_1 = require("./utils");
var Gesture = (function () {

@@ -16,12 +17,7 @@ function Gesture(listener, data, target) {

Gesture.prototype.bind = function () { };
Gesture.prototype.unbind = function () { return 0; };
Gesture.prototype.start = function (args) {
return this.listener.start(args);
};
Gesture.prototype.update = function (args) {
return this.listener.update(args);
};
Gesture.prototype.end = function (args) {
return this.listener.end(args);
};
Gesture.prototype.unbind = function () { return utils_1.RETURN_FLAG.IDLE; };
Gesture.prototype.start = function () { return utils_1.RETURN_FLAG.IDLE; };
Gesture.prototype.update = function () { return utils_1.RETURN_FLAG.IDLE; };
Gesture.prototype.end = function () { return utils_1.RETURN_FLAG.IDLE; };
;
Gesture.prototype.cancel = function () { return this.listener.cancel(); };

@@ -28,0 +24,0 @@ Gesture.prototype.stop = function () { this.listener.stop(); };

@@ -0,1 +1,2 @@

import { RETURN_FLAG } from './utils';
export class Gesture {

@@ -14,12 +15,7 @@ constructor(listener, data, target) {

bind() { }
unbind() { return 0; }
start(args) {
return this.listener.start(args);
}
update(args) {
return this.listener.update(args);
}
end(args) {
return this.listener.end(args);
}
unbind() { return RETURN_FLAG.IDLE; }
start() { return RETURN_FLAG.IDLE; }
update() { return RETURN_FLAG.IDLE; }
end() { return RETURN_FLAG.IDLE; }
;
cancel() { return this.listener.cancel(); }

@@ -26,0 +22,0 @@ stop() { this.listener.stop(); }

@@ -191,3 +191,3 @@ define("point", ["require", "exports"], function (require, exports) {

});
define("gesture", ["require", "exports", "tslib"], function (require, exports, tslib_3) {
define("gesture", ["require", "exports", "tslib", "utils"], function (require, exports, tslib_3, utils_2) {
"use strict";

@@ -207,12 +207,7 @@ var Gesture = (function () {

Gesture.prototype.bind = function () { };
Gesture.prototype.unbind = function () { return 0; };
Gesture.prototype.start = function (args) {
return this.listener.start(args);
};
Gesture.prototype.update = function (args) {
return this.listener.update(args);
};
Gesture.prototype.end = function (args) {
return this.listener.end(args);
};
Gesture.prototype.unbind = function () { return utils_2.RETURN_FLAG.IDLE; };
Gesture.prototype.start = function () { return utils_2.RETURN_FLAG.IDLE; };
Gesture.prototype.update = function () { return utils_2.RETURN_FLAG.IDLE; };
Gesture.prototype.end = function () { return utils_2.RETURN_FLAG.IDLE; };
;
Gesture.prototype.cancel = function () { return this.listener.cancel(); };

@@ -232,3 +227,3 @@ Gesture.prototype.stop = function () { this.listener.stop(); };

});
define("registry", ["require", "exports", "listener", "utils"], function (require, exports, listener_1, utils_2) {
define("registry", ["require", "exports", "listener", "utils"], function (require, exports, listener_1, utils_3) {
"use strict";

@@ -240,5 +235,5 @@ var Registry = (function () {

Registry.prototype.register = function (Gesture, GestureOptions, GestureListener, GestureData) {
if (GestureOptions === void 0) { GestureOptions = utils_2.Options; }
if (GestureOptions === void 0) { GestureOptions = utils_3.Options; }
if (GestureListener === void 0) { GestureListener = listener_1.Listener; }
if (GestureData === void 0) { GestureData = utils_2.Data; }
if (GestureData === void 0) { GestureData = utils_3.Data; }
this.gestures.set(Gesture, { Gesture: Gesture, GestureOptions: GestureOptions, GestureListener: GestureListener, GestureData: GestureData });

@@ -386,3 +381,3 @@ };

});
define("engine", ["require", "exports", "registry", "listener", "utils", "listener-handle"], function (require, exports, registry_1, listener_2, utils_3, listener_handle_1) {
define("engine", ["require", "exports", "registry", "listener", "utils", "listener-handle"], function (require, exports, registry_1, listener_2, utils_4, listener_handle_1) {
"use strict";

@@ -402,5 +397,5 @@ ;

Engine.prototype.registerGesture = function (Gesture, GestureOptions, GestureListener, GestureData) {
if (GestureOptions === void 0) { GestureOptions = utils_3.Options; }
if (GestureOptions === void 0) { GestureOptions = utils_4.Options; }
if (GestureListener === void 0) { GestureListener = listener_2.Listener; }
if (GestureData === void 0) { GestureData = utils_3.Data; }
if (GestureData === void 0) { GestureData = utils_4.Data; }
this.registry.register(Gesture, GestureOptions, GestureListener, GestureData);

@@ -435,4 +430,4 @@ };

Engine.prototype.getPointersDelta = function (evt, pointers, configuredPointers, configuredWhich) {
if (utils_3.isMouse(evt) &&
!utils_3.isValidMouseButton(evt, configuredWhich)) {
if (utils_4.isMouse(evt) &&
!utils_4.isValidMouseButton(evt, configuredWhich)) {
return { all: -1, changed: -1 };

@@ -462,9 +457,9 @@ }

Engine.prototype.evaluateStrategyReturnFlag = function (gesture, flag) {
if (flag & utils_3.RETURN_FLAG.START_EMITTED) {
if (flag & utils_4.RETURN_FLAG.START_EMITTED) {
gesture.startEmitted = true;
}
if (flag & utils_3.RETURN_FLAG.REMOVE) {
if (flag & utils_4.RETURN_FLAG.REMOVE) {
this.removeGesture(gesture, this.gestures, this.composedGestures);
}
if (flag & utils_3.RETURN_FLAG.REMOVE_OTHERS) {
if (flag & utils_4.RETURN_FLAG.REMOVE_OTHERS) {
var others = this.gestures.slice();

@@ -485,3 +480,3 @@ var otherGesture = void 0;

var pointersDelta = this.getPointersDelta(evt, pointers, configuredPointers, which);
if (pointersDelta.all > 0 && strategy === utils_3.GESTURE_STRATEGY_FLAG.REMOVE_IF_POINTERS_GT) {
if (pointersDelta.all > 0 && strategy === utils_4.GESTURE_STRATEGY_FLAG.REMOVE_IF_POINTERS_GT) {
this.removeGesture(gesture, this.gestures, this.composedGestures);

@@ -529,3 +524,3 @@ continue;

if (state.pointersDelta.all !== 0) {
return utils_3.RETURN_FLAG.IDLE;
return utils_4.RETURN_FLAG.IDLE;
}

@@ -540,3 +535,3 @@ // Lock pointer ids on gesture

if (!this.isLockedPointers(state.gesture, state.pointers.all)) {
return utils_3.RETURN_FLAG.IDLE;
return utils_4.RETURN_FLAG.IDLE;
}

@@ -550,7 +545,7 @@ state.gesture.args.data.pointers = this.getPointers(state.pointers.all, this.getPointerIds(state.gesture));

state.gesture.stop();
return utils_3.RETURN_FLAG.REMOVE;
return utils_4.RETURN_FLAG.REMOVE;
}
this.removePointerIds(state.pointers.changed, state.gesture, Array.from(state.pointers.changed.keys()));
if (this.getPointerIds(state.gesture).length !== 0) {
return utils_3.RETURN_FLAG.IDLE;
return utils_4.RETURN_FLAG.IDLE;
}

@@ -605,3 +600,3 @@ state.gesture.args.data.pointers = this.getRemovedPointers(state.gesture);

while (gesture = gestures.shift()) {
if (utils_3.RETURN_FLAG.COMPOSE === gesture.unbind()) {
if (utils_4.RETURN_FLAG.COMPOSE === gesture.unbind()) {
this.composedGestures.push(gesture);

@@ -641,3 +636,3 @@ }

}
if (selector && !utils_3.matchesSelector(element, selector)) {
if (selector && !utils_4.matchesSelector(element, selector)) {
return false;

@@ -795,3 +790,3 @@ }

});
define("oribella-api", ["require", "exports", "engine", "flows/ms-pointer", "flows/pointer", "flows/touch", "flows/mouse", "listener", "utils"], function (require, exports, engine_1, ms_pointer_1, pointer_2, touch_1, mouse_1, listener_3, utils_4) {
define("oribella-api", ["require", "exports", "engine", "flows/ms-pointer", "flows/pointer", "flows/touch", "flows/mouse", "listener", "utils"], function (require, exports, engine_1, ms_pointer_1, pointer_2, touch_1, mouse_1, listener_3, utils_5) {
"use strict";

@@ -807,3 +802,3 @@ ;

OribellaApi.prototype.registerDefaultFlowStrategy = function (supports) {
if (supports === void 0) { supports = utils_4.SUPPORTS; }
if (supports === void 0) { supports = utils_5.SUPPORTS; }
if (supports.msPointerEnabled) {

@@ -821,5 +816,5 @@ this.engine.registerFlow(new ms_pointer_1.MSPointerFlow(this.element));

OribellaApi.prototype.registerGesture = function (Gesture, GestureOptions, GestureListener, GestureData) {
if (GestureOptions === void 0) { GestureOptions = utils_4.Options; }
if (GestureOptions === void 0) { GestureOptions = utils_5.Options; }
if (GestureListener === void 0) { GestureListener = listener_3.Listener; }
if (GestureData === void 0) { GestureData = utils_4.Data; }
if (GestureData === void 0) { GestureData = utils_5.Data; }
this.engine.registerGesture(Gesture, GestureOptions, GestureListener, GestureData);

@@ -843,3 +838,3 @@ };

});
define("oribella-framework", ["require", "exports", "point", "utils", "listener", "gesture", "oribella-api"], function (require, exports, point_4, utils_5, listener_4, gesture_1, oribella_api_1) {
define("oribella-framework", ["require", "exports", "point", "utils", "listener", "gesture", "oribella-api"], function (require, exports, point_4, utils_6, listener_4, gesture_1, oribella_api_1) {
"use strict";

@@ -850,3 +845,3 @@ function __export(m) {

__export(point_4);
__export(utils_5);
__export(utils_6);
__export(listener_4);

@@ -853,0 +848,0 @@ __export(gesture_1);

@@ -1,5 +0,5 @@

System.register(["tslib"], function (exports_1, context_1) {
System.register(["tslib", "./utils"], function (exports_1, context_1) {
"use strict";
var __moduleName = context_1 && context_1.id;
var tslib_1, Gesture, DefaultGesture;
var tslib_1, utils_1, Gesture, DefaultGesture;
return {

@@ -9,2 +9,5 @@ setters: [

tslib_1 = tslib_1_1;
},
function (utils_1_1) {
utils_1 = utils_1_1;
}

@@ -26,12 +29,7 @@ ],

Gesture.prototype.bind = function () { };
Gesture.prototype.unbind = function () { return 0; };
Gesture.prototype.start = function (args) {
return this.listener.start(args);
};
Gesture.prototype.update = function (args) {
return this.listener.update(args);
};
Gesture.prototype.end = function (args) {
return this.listener.end(args);
};
Gesture.prototype.unbind = function () { return utils_1.RETURN_FLAG.IDLE; };
Gesture.prototype.start = function () { return utils_1.RETURN_FLAG.IDLE; };
Gesture.prototype.update = function () { return utils_1.RETURN_FLAG.IDLE; };
Gesture.prototype.end = function () { return utils_1.RETURN_FLAG.IDLE; };
;
Gesture.prototype.cancel = function () { return this.listener.cancel(); };

@@ -38,0 +36,0 @@ Gesture.prototype.stop = function () { this.listener.stop(); };

{
"name": "oribella-framework",
"version": "0.9.0",
"version": "0.10.0",
"description": "Normalizes event flows into an understandable consistent api",

@@ -5,0 +5,0 @@ "repository": {

@@ -1,2 +0,2 @@

import { Data, PointerData } from './utils';
import { Data, PointerData, RETURN_FLAG } from './utils';
import { DefaultListener, ListenerArgs } from './listener';

@@ -16,12 +16,9 @@

public bind() { }
public unbind(): number { return 0; }
public start(args: ListenerArgs<D>): number {
return this.listener.start(args);
}
public update(args: ListenerArgs<D>): number {
return this.listener.update(args);
}
public end(args: ListenerArgs<D>): number {
return this.listener.end(args);
}
public unbind(): number { return RETURN_FLAG.IDLE; }
public start(args: ListenerArgs<D>): number;
public start() { return RETURN_FLAG.IDLE; }
public update(args: ListenerArgs<D>): number;
public update() { return RETURN_FLAG.IDLE; }
public end(args: ListenerArgs<D>): number;
public end() { return RETURN_FLAG.IDLE; };
public cancel(): number { return this.listener.cancel(); }

@@ -28,0 +25,0 @@ public stop(): void { this.listener.stop(); }

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc