parse 3.4.4-beta.1 → 3.5.0-alpha.2
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/parse.js +14 -24
- package/dist/parse.min.js +2 -2
- package/dist/parse.weapp.js +14 -24
- package/dist/parse.weapp.min.js +2 -2
- package/lib/browser/CoreManager.js +1 -1
- package/lib/browser/ParseFile.js +3 -22
- package/lib/browser/ParseQuery.js +5 -0
- package/lib/browser/ParseUser.js +4 -0
- package/lib/node/CoreManager.js +1 -1
- package/lib/node/ParseFile.js +2 -19
- package/lib/node/ParseQuery.js +5 -0
- package/lib/node/ParseUser.js +4 -0
- package/lib/react-native/CoreManager.js +1 -1
- package/lib/react-native/ParseFile.js +2 -17
- package/lib/react-native/ParseQuery.js +4 -0
- package/lib/react-native/ParseUser.js +4 -0
- package/lib/weapp/CoreManager.js +1 -1
- package/lib/weapp/ParseFile.js +3 -22
- package/lib/weapp/ParseQuery.js +5 -0
- package/lib/weapp/ParseUser.js +4 -0
- package/package.json +2 -2
package/dist/parse.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Parse JavaScript SDK v3.
|
|
2
|
+
* Parse JavaScript SDK v3.5.0-alpha.2
|
|
3
3
|
*
|
|
4
4
|
* The source tree of this library can be found at
|
|
5
5
|
* https://github.com/ParsePlatform/Parse-SDK-JS
|
|
@@ -699,7 +699,7 @@ var config
|
|
|
699
699
|
SERVER_AUTH_TOKEN: null,
|
|
700
700
|
LIVEQUERY_SERVER_URL: null,
|
|
701
701
|
ENCRYPTED_KEY: null,
|
|
702
|
-
VERSION: 'js' + "3.
|
|
702
|
+
VERSION: 'js' + "3.5.0-alpha.2",
|
|
703
703
|
APPLICATION_ID: null,
|
|
704
704
|
JAVASCRIPT_KEY: null,
|
|
705
705
|
MASTER_KEY: null,
|
|
@@ -8477,9 +8477,6 @@ if (typeof XMLHttpRequest !== 'undefined') {
|
|
|
8477
8477
|
uri: string,
|
|
8478
8478
|
type: string,
|
|
8479
8479
|
};*/
|
|
8480
|
-
var base64Regex = new RegExp('([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))', 'i');
|
|
8481
|
-
var dataUriRegex = new RegExp("^data:([a-zA-Z]+\\/[-a-zA-Z0-9+.]+(;[a-z-]+=[a-zA-Z0-9+.-]+)?)?(;base64)?,(".concat(base64Regex.source, ")*$"), 'i');
|
|
8482
|
-
|
|
8483
8480
|
function b64Digit(number
|
|
8484
8481
|
/*: number*/
|
|
8485
8482
|
)
|
|
@@ -8592,30 +8589,14 @@ var ParseFile = /*#__PURE__*/function () {
|
|
|
8592
8589
|
type: specifiedType
|
|
8593
8590
|
};
|
|
8594
8591
|
} else if (data && typeof data.base64 === 'string') {
|
|
8595
|
-
var _context, _context2, _context3;
|
|
8596
|
-
|
|
8597
|
-
|
|
8598
|
-
var validationRegex = new RegExp(base64Regex.source + '|' + dataUriRegex.source, 'i');
|
|
8599
|
-
|
|
8600
|
-
if (!validationRegex.test(data.base64)) {
|
|
8601
|
-
throw new Error('Cannot create a Parse.File without valid data URIs or base64 encoded data.');
|
|
8602
|
-
}
|
|
8592
|
+
var _context, _context2, _context3;
|
|
8603
8593
|
|
|
8604
8594
|
var base64 = (0, _slice.default)(_context = data.base64.split(',')).call(_context, -1)[0];
|
|
8605
|
-
|
|
8606
|
-
var _type = specifiedType || (0, _slice.default)(_context2 = (0, _slice.default)(_context3 = data.base64.split(';')).call(_context3, 0, 1)[0].split(':')).call(_context2, 1, 2)[0] || ''; // https://tools.ietf.org/html/rfc2397
|
|
8607
|
-
// If <mediatype> is omitted, it defaults to text/plain;charset=US-ASCII.
|
|
8608
|
-
// As a shorthand, "text/plain" can be omitted but the charset parameter supplied.
|
|
8609
|
-
|
|
8610
|
-
|
|
8611
|
-
if (dataUriRegex.test(data.base64)) {
|
|
8612
|
-
_type = _type || 'text/plain';
|
|
8613
|
-
}
|
|
8614
|
-
|
|
8595
|
+
var dataType = specifiedType || (0, _slice.default)(_context2 = (0, _slice.default)(_context3 = data.base64.split(';')).call(_context3, 0, 1)[0].split(':')).call(_context2, 1, 2)[0] || 'text/plain';
|
|
8615
8596
|
this._source = {
|
|
8616
8597
|
format: 'base64',
|
|
8617
8598
|
base64: base64,
|
|
8618
|
-
type:
|
|
8599
|
+
type: dataType
|
|
8619
8600
|
};
|
|
8620
8601
|
} else {
|
|
8621
8602
|
throw new TypeError('Cannot create a Parse.File with that data.');
|
|
@@ -15970,6 +15951,10 @@ var ParseQuery = /*#__PURE__*/function () {
|
|
|
15970
15951
|
findOptions.context = options.context;
|
|
15971
15952
|
}
|
|
15972
15953
|
|
|
15954
|
+
if (options.hasOwnProperty('json')) {
|
|
15955
|
+
findOptions.json = options.json;
|
|
15956
|
+
}
|
|
15957
|
+
|
|
15973
15958
|
var finished = false;
|
|
15974
15959
|
var previousResults = [];
|
|
15975
15960
|
return (0, _promiseUtils.continueWhile)(function () {
|
|
@@ -16039,6 +16024,7 @@ var ParseQuery = /*#__PURE__*/function () {
|
|
|
16039
16024
|
* be used for this request.
|
|
16040
16025
|
* <li>sessionToken: A valid session token, used for making a request on
|
|
16041
16026
|
* behalf of a specific user.
|
|
16027
|
+
* <li>json: Return raw json without converting to Parse.Object
|
|
16042
16028
|
* </ul>
|
|
16043
16029
|
* @returns {Promise} A promise that will be fulfilled once the
|
|
16044
16030
|
* iteration has completed.
|
|
@@ -19783,6 +19769,10 @@ var ParseUser = /*#__PURE__*/function (_ParseObject) {
|
|
|
19783
19769
|
signupOptions.installationId = options.installationId;
|
|
19784
19770
|
}
|
|
19785
19771
|
|
|
19772
|
+
if (options.hasOwnProperty('context') && Object.prototype.toString.call(options.context) === '[object Object]') {
|
|
19773
|
+
signupOptions.context = options.context;
|
|
19774
|
+
}
|
|
19775
|
+
|
|
19786
19776
|
var controller = _CoreManager.default.getUserController();
|
|
19787
19777
|
|
|
19788
19778
|
return controller.signUp(this, attrs, signupOptions);
|