UNPKG

@airgram-dev/vue

Version:
168 lines (167 loc) 5.46 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var AirgramDollar = /** @class */ (function () { function AirgramDollar(vm) { this.vm = vm; } Object.defineProperty(AirgramDollar.prototype, "airgram", { get: function () { return this.provider.airgram; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "api", { get: function () { var _this = this; return new Proxy({}, { get: function (target, name) { if (Object.hasOwnProperty.call(target, name) || ['_vm', 'state', 'toJson'].includes(name)) { return target[name]; } return function (params, options) { return _this.airgram.api[name](params, options); }; } }); }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "authorizationState", { get: function () { return this.storeState.authorizationState; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "connectionState", { get: function () { return this.storeState.connectionState; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "basicGroups", { get: function () { return this.storeState.basicGroups; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "basicGroupFullInfo", { get: function () { return this.storeState.basicGroupFullInfo; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "chats", { get: function () { return this.storeState.chats; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "chatMessages", { get: function () { return this.storeState.chatMessages; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "files", { get: function () { return this.storeState.files; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "messages", { get: function () { return this.storeState.messages; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "supergroups", { get: function () { return this.storeState.supergroups; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "supergroupFullInfo", { get: function () { return this.storeState.supergroupFullInfo; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "onlineMemberCount", { get: function () { return this.storeState.onlineMemberCount; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "options", { get: function () { return this.storeState.options; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "stickerSet", { get: function () { return this.storeState.stickerSet; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "users", { get: function () { return this.storeState.users; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "userFullInfo", { get: function () { return this.storeState.userFullInfo; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "provider", { get: function () { return this.vm.$_airgramProvider; }, enumerable: true, configurable: true }); Object.defineProperty(AirgramDollar.prototype, "storeState", { get: function () { return this.provider.store.state.airgram; }, enumerable: true, configurable: true }); AirgramDollar.prototype.emit = function (update) { return this.airgram.emit(update); }; AirgramDollar.prototype.off = function (eventName, handler) { this.provider.off(eventName, handler); }; AirgramDollar.prototype.on = function (eventName, handler) { return this.provider.on(eventName, handler); }; AirgramDollar.prototype.once = function (eventName, handler) { return this.provider.once(eventName, handler); }; AirgramDollar.prototype.watch = function (getter, cb, options) { return this.provider.store.watch(function (state, getters) { return getter(state.airgram, getters.airgram); }, cb, options); }; return AirgramDollar; }()); exports.AirgramDollar = AirgramDollar;