roboto-js 1.1.5 → 1.1.7
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/cjs/index.cjs +100 -62
- package/dist/cjs/rbt_api.cjs +234 -165
- package/dist/esm/index.js +100 -62
- package/dist/esm/rbt_api.js +234 -165
- package/package.json +1 -1
- package/src/index.js +9 -0
- package/src/rbt_api.js +41 -10
package/dist/cjs/index.cjs
CHANGED
|
@@ -158,42 +158,80 @@ var Roboto = exports["default"] = /*#__PURE__*/function () {
|
|
|
158
158
|
return registerUser;
|
|
159
159
|
}()
|
|
160
160
|
}, {
|
|
161
|
-
key: "
|
|
161
|
+
key: "loadUser",
|
|
162
162
|
value: function () {
|
|
163
|
-
var
|
|
163
|
+
var _loadUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5(params) {
|
|
164
164
|
return _regeneratorRuntime().wrap(function _callee5$(_context5) {
|
|
165
165
|
while (1) switch (_context5.prev = _context5.next) {
|
|
166
166
|
case 0:
|
|
167
|
-
return _context5.abrupt("return", this.api.
|
|
167
|
+
return _context5.abrupt("return", this.api.loadUser(params));
|
|
168
168
|
case 1:
|
|
169
169
|
case "end":
|
|
170
170
|
return _context5.stop();
|
|
171
171
|
}
|
|
172
172
|
}, _callee5, this);
|
|
173
173
|
}));
|
|
174
|
+
function loadUser(_x3) {
|
|
175
|
+
return _loadUser.apply(this, arguments);
|
|
176
|
+
}
|
|
177
|
+
return loadUser;
|
|
178
|
+
}()
|
|
179
|
+
}, {
|
|
180
|
+
key: "loadCurrentUser",
|
|
181
|
+
value: function () {
|
|
182
|
+
var _loadCurrentUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6() {
|
|
183
|
+
return _regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
184
|
+
while (1) switch (_context6.prev = _context6.next) {
|
|
185
|
+
case 0:
|
|
186
|
+
return _context6.abrupt("return", this.api.loadCurrentUser());
|
|
187
|
+
case 1:
|
|
188
|
+
case "end":
|
|
189
|
+
return _context6.stop();
|
|
190
|
+
}
|
|
191
|
+
}, _callee6, this);
|
|
192
|
+
}));
|
|
174
193
|
function loadCurrentUser() {
|
|
175
194
|
return _loadCurrentUser.apply(this, arguments);
|
|
176
195
|
}
|
|
177
196
|
return loadCurrentUser;
|
|
197
|
+
}()
|
|
198
|
+
}, {
|
|
199
|
+
key: "confirmUserEmail",
|
|
200
|
+
value: function () {
|
|
201
|
+
var _confirmUserEmail = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee7(params) {
|
|
202
|
+
return _regeneratorRuntime().wrap(function _callee7$(_context7) {
|
|
203
|
+
while (1) switch (_context7.prev = _context7.next) {
|
|
204
|
+
case 0:
|
|
205
|
+
return _context7.abrupt("return", this.api.confirmUserEmail(params));
|
|
206
|
+
case 1:
|
|
207
|
+
case "end":
|
|
208
|
+
return _context7.stop();
|
|
209
|
+
}
|
|
210
|
+
}, _callee7, this);
|
|
211
|
+
}));
|
|
212
|
+
function confirmUserEmail(_x4) {
|
|
213
|
+
return _confirmUserEmail.apply(this, arguments);
|
|
214
|
+
}
|
|
215
|
+
return confirmUserEmail;
|
|
178
216
|
}() //
|
|
179
217
|
// create and upload files
|
|
180
218
|
//
|
|
181
219
|
}, {
|
|
182
220
|
key: "createFile",
|
|
183
221
|
value: function () {
|
|
184
|
-
var _createFile = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
222
|
+
var _createFile = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee8() {
|
|
185
223
|
var data,
|
|
186
|
-
|
|
187
|
-
return _regeneratorRuntime().wrap(function
|
|
188
|
-
while (1) switch (
|
|
224
|
+
_args8 = arguments;
|
|
225
|
+
return _regeneratorRuntime().wrap(function _callee8$(_context8) {
|
|
226
|
+
while (1) switch (_context8.prev = _context8.next) {
|
|
189
227
|
case 0:
|
|
190
|
-
data =
|
|
191
|
-
return
|
|
228
|
+
data = _args8.length > 0 && _args8[0] !== undefined ? _args8[0] : {};
|
|
229
|
+
return _context8.abrupt("return", this.api.createFile(data));
|
|
192
230
|
case 2:
|
|
193
231
|
case "end":
|
|
194
|
-
return
|
|
232
|
+
return _context8.stop();
|
|
195
233
|
}
|
|
196
|
-
},
|
|
234
|
+
}, _callee8, this);
|
|
197
235
|
}));
|
|
198
236
|
function createFile() {
|
|
199
237
|
return _createFile.apply(this, arguments);
|
|
@@ -205,21 +243,21 @@ var Roboto = exports["default"] = /*#__PURE__*/function () {
|
|
|
205
243
|
}, {
|
|
206
244
|
key: "create",
|
|
207
245
|
value: function () {
|
|
208
|
-
var _create = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
246
|
+
var _create = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee9(params) {
|
|
209
247
|
var data,
|
|
210
|
-
|
|
211
|
-
return _regeneratorRuntime().wrap(function
|
|
212
|
-
while (1) switch (
|
|
248
|
+
_args9 = arguments;
|
|
249
|
+
return _regeneratorRuntime().wrap(function _callee9$(_context9) {
|
|
250
|
+
while (1) switch (_context9.prev = _context9.next) {
|
|
213
251
|
case 0:
|
|
214
|
-
data =
|
|
215
|
-
return
|
|
252
|
+
data = _args9.length > 1 && _args9[1] !== undefined ? _args9[1] : {};
|
|
253
|
+
return _context9.abrupt("return", this.api.create(params, data));
|
|
216
254
|
case 2:
|
|
217
255
|
case "end":
|
|
218
|
-
return
|
|
256
|
+
return _context9.stop();
|
|
219
257
|
}
|
|
220
|
-
},
|
|
258
|
+
}, _callee9, this);
|
|
221
259
|
}));
|
|
222
|
-
function create(
|
|
260
|
+
function create(_x5) {
|
|
223
261
|
return _create.apply(this, arguments);
|
|
224
262
|
}
|
|
225
263
|
return create;
|
|
@@ -227,18 +265,18 @@ var Roboto = exports["default"] = /*#__PURE__*/function () {
|
|
|
227
265
|
}, {
|
|
228
266
|
key: "load",
|
|
229
267
|
value: function () {
|
|
230
|
-
var _load = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
231
|
-
return _regeneratorRuntime().wrap(function
|
|
232
|
-
while (1) switch (
|
|
268
|
+
var _load = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee10(type, ids, options) {
|
|
269
|
+
return _regeneratorRuntime().wrap(function _callee10$(_context10) {
|
|
270
|
+
while (1) switch (_context10.prev = _context10.next) {
|
|
233
271
|
case 0:
|
|
234
|
-
return
|
|
272
|
+
return _context10.abrupt("return", this.api.load(type, ids, options));
|
|
235
273
|
case 1:
|
|
236
274
|
case "end":
|
|
237
|
-
return
|
|
275
|
+
return _context10.stop();
|
|
238
276
|
}
|
|
239
|
-
},
|
|
277
|
+
}, _callee10, this);
|
|
240
278
|
}));
|
|
241
|
-
function load(
|
|
279
|
+
function load(_x6, _x7, _x8) {
|
|
242
280
|
return _load.apply(this, arguments);
|
|
243
281
|
}
|
|
244
282
|
return load;
|
|
@@ -246,18 +284,18 @@ var Roboto = exports["default"] = /*#__PURE__*/function () {
|
|
|
246
284
|
}, {
|
|
247
285
|
key: "query",
|
|
248
286
|
value: function () {
|
|
249
|
-
var _query = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
250
|
-
return _regeneratorRuntime().wrap(function
|
|
251
|
-
while (1) switch (
|
|
287
|
+
var _query = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee11(type, params) {
|
|
288
|
+
return _regeneratorRuntime().wrap(function _callee11$(_context11) {
|
|
289
|
+
while (1) switch (_context11.prev = _context11.next) {
|
|
252
290
|
case 0:
|
|
253
|
-
return
|
|
291
|
+
return _context11.abrupt("return", this.api.query(type, params));
|
|
254
292
|
case 1:
|
|
255
293
|
case "end":
|
|
256
|
-
return
|
|
294
|
+
return _context11.stop();
|
|
257
295
|
}
|
|
258
|
-
},
|
|
296
|
+
}, _callee11, this);
|
|
259
297
|
}));
|
|
260
|
-
function query(
|
|
298
|
+
function query(_x9, _x10) {
|
|
261
299
|
return _query.apply(this, arguments);
|
|
262
300
|
}
|
|
263
301
|
return query;
|
|
@@ -267,18 +305,18 @@ var Roboto = exports["default"] = /*#__PURE__*/function () {
|
|
|
267
305
|
}, {
|
|
268
306
|
key: "runTask",
|
|
269
307
|
value: function () {
|
|
270
|
-
var _runTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
271
|
-
return _regeneratorRuntime().wrap(function
|
|
272
|
-
while (1) switch (
|
|
308
|
+
var _runTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee12(params, callbacks) {
|
|
309
|
+
return _regeneratorRuntime().wrap(function _callee12$(_context12) {
|
|
310
|
+
while (1) switch (_context12.prev = _context12.next) {
|
|
273
311
|
case 0:
|
|
274
|
-
return
|
|
312
|
+
return _context12.abrupt("return", this.api.runTask(params, callbacks));
|
|
275
313
|
case 1:
|
|
276
314
|
case "end":
|
|
277
|
-
return
|
|
315
|
+
return _context12.stop();
|
|
278
316
|
}
|
|
279
|
-
},
|
|
317
|
+
}, _callee12, this);
|
|
280
318
|
}));
|
|
281
|
-
function runTask(
|
|
319
|
+
function runTask(_x11, _x12) {
|
|
282
320
|
return _runTask.apply(this, arguments);
|
|
283
321
|
}
|
|
284
322
|
return runTask;
|
|
@@ -286,18 +324,18 @@ var Roboto = exports["default"] = /*#__PURE__*/function () {
|
|
|
286
324
|
}, {
|
|
287
325
|
key: "pollTaskProgress",
|
|
288
326
|
value: function () {
|
|
289
|
-
var _pollTaskProgress = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
290
|
-
return _regeneratorRuntime().wrap(function
|
|
291
|
-
while (1) switch (
|
|
327
|
+
var _pollTaskProgress = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee13(params) {
|
|
328
|
+
return _regeneratorRuntime().wrap(function _callee13$(_context13) {
|
|
329
|
+
while (1) switch (_context13.prev = _context13.next) {
|
|
292
330
|
case 0:
|
|
293
|
-
return
|
|
331
|
+
return _context13.abrupt("return", this.api.pollTaskProgress(params));
|
|
294
332
|
case 1:
|
|
295
333
|
case "end":
|
|
296
|
-
return
|
|
334
|
+
return _context13.stop();
|
|
297
335
|
}
|
|
298
|
-
},
|
|
336
|
+
}, _callee13, this);
|
|
299
337
|
}));
|
|
300
|
-
function pollTaskProgress(
|
|
338
|
+
function pollTaskProgress(_x13) {
|
|
301
339
|
return _pollTaskProgress.apply(this, arguments);
|
|
302
340
|
}
|
|
303
341
|
return pollTaskProgress;
|
|
@@ -307,18 +345,18 @@ var Roboto = exports["default"] = /*#__PURE__*/function () {
|
|
|
307
345
|
}, {
|
|
308
346
|
key: "get",
|
|
309
347
|
value: function () {
|
|
310
|
-
var _get = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
311
|
-
return _regeneratorRuntime().wrap(function
|
|
312
|
-
while (1) switch (
|
|
348
|
+
var _get = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee14(endpoint, params) {
|
|
349
|
+
return _regeneratorRuntime().wrap(function _callee14$(_context14) {
|
|
350
|
+
while (1) switch (_context14.prev = _context14.next) {
|
|
313
351
|
case 0:
|
|
314
|
-
return
|
|
352
|
+
return _context14.abrupt("return", this.api.get(endpoint, params));
|
|
315
353
|
case 1:
|
|
316
354
|
case "end":
|
|
317
|
-
return
|
|
355
|
+
return _context14.stop();
|
|
318
356
|
}
|
|
319
|
-
},
|
|
357
|
+
}, _callee14, this);
|
|
320
358
|
}));
|
|
321
|
-
function get(
|
|
359
|
+
function get(_x14, _x15) {
|
|
322
360
|
return _get.apply(this, arguments);
|
|
323
361
|
}
|
|
324
362
|
return get;
|
|
@@ -326,18 +364,18 @@ var Roboto = exports["default"] = /*#__PURE__*/function () {
|
|
|
326
364
|
}, {
|
|
327
365
|
key: "post",
|
|
328
366
|
value: function () {
|
|
329
|
-
var _post = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function
|
|
330
|
-
return _regeneratorRuntime().wrap(function
|
|
331
|
-
while (1) switch (
|
|
367
|
+
var _post = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee15(endpoint, data) {
|
|
368
|
+
return _regeneratorRuntime().wrap(function _callee15$(_context15) {
|
|
369
|
+
while (1) switch (_context15.prev = _context15.next) {
|
|
332
370
|
case 0:
|
|
333
|
-
return
|
|
371
|
+
return _context15.abrupt("return", this.api.post(endpoint, data));
|
|
334
372
|
case 1:
|
|
335
373
|
case "end":
|
|
336
|
-
return
|
|
374
|
+
return _context15.stop();
|
|
337
375
|
}
|
|
338
|
-
},
|
|
376
|
+
}, _callee15, this);
|
|
339
377
|
}));
|
|
340
|
-
function post(
|
|
378
|
+
function post(_x16, _x17) {
|
|
341
379
|
return _post.apply(this, arguments);
|
|
342
380
|
}
|
|
343
381
|
return post;
|