Comparing version 1.12.3 to 1.12.4
@@ -148,6 +148,6 @@ define(["./kernel", "./lang", "./array", "./config"], function(dojo, lang, ArrayUtil, config){ | ||
var t = obj || new Color(); | ||
ArrayUtil.forEach(["r", "g", "b", "a"], function(x){ | ||
t[x] = start[x] + (end[x] - start[x]) * weight; | ||
if(x != "a"){ t[x] = Math.round(t[x]); } | ||
}); | ||
t.r = Math.round(start.r + (end.r - start.r) * weight); | ||
t.g = Math.round(start.g + (end.g - start.g) * weight); | ||
t.b = Math.round(start.b + (end.b - start.b) * weight); | ||
t.a = start.a + (end.a - start.a) * weight; | ||
return t.sanitize(); // Color | ||
@@ -154,0 +154,0 @@ }; |
@@ -82,3 +82,3 @@ define(["../global", "../has", "./config", "require", "module"], function(global, has, config, require, module){ | ||
var rev = "$Rev: 82d5dd3 $".match(/[0-9a-f]{7,}/); | ||
var rev = "$Rev: 2e27f9ad $".match(/[0-9a-f]{7,}/); | ||
dojo.version = { | ||
@@ -96,3 +96,3 @@ // summary: | ||
major: 1, minor: 12, patch: 3, flag: "", | ||
major: 1, minor: 12, patch: 4, flag: "", | ||
revision: rev ? rev[0] : NaN, | ||
@@ -99,0 +99,0 @@ toString: function(){ |
@@ -321,15 +321,7 @@ define(["./kernel", "../has", "require", "module", "../json", "./lang", "./array"], function(dojo, has, require, thisModule, json, lang, array) { | ||
// the following regex is taken from 1.6. It is a very poor technique to remove comments and | ||
// will fail in some cases; for example, consider the code... | ||
// The following regex matches all comments and strings, with the strings in the capturing group. | ||
// Replacing all matches with "$1" will remove comments and keep strings. | ||
// | ||
// var message = "Category-1 */* Category-2"; | ||
// | ||
// The regex that follows will see a /* comment and trash the code accordingly. In fact, there are all | ||
// kinds of cases like this with strings and regexs that will cause this design to fail miserably. | ||
// | ||
// Alternative regex designs exist that will result in less-likely failures, but will still fail in many cases. | ||
// The only solution guaranteed 100% correct is to parse the code and that seems overkill for this | ||
// backcompat/unbuilt-xdomain layer. In the end, since it's been this way for a while, we won't change it. | ||
// See the opening paragraphs of Chapter 7 or ECME-262 which describes the lexical abiguity further. | ||
removeCommentRe = /(\/\*([\s\S]*?)\*\/|\/\/(.*)$)/mg, | ||
// It accounts for single quotes, double quotes, backslashes (line continuations and escaped characters), and template strings. | ||
removeCommentRe = /\/\/.*|\/\*[\s\S]*?\*\/|("(?:\\.|[^"])*"|'(?:\\.|[^'])*'|`(?:\\.|[^`])*`)/mg, | ||
@@ -364,8 +356,3 @@ syncLoaderApiRe = /(^|\s)dojo\.(loadInit|require|provide|requireLocalization|requireIf|requireAfterIf|platformRequire)\s*\(/mg, | ||
// noCommentText may be provided by a build app with comments extracted by a better method than regex (hopefully) | ||
noCommentText = noCommentText || text.replace(removeCommentRe, function(match){ | ||
// remove iff the detected comment has text that looks like a sync loader API application; this helps by | ||
// removing as little as possible, minimizing the changes the janky regex will kill the module | ||
syncLoaderApiRe.lastIndex = amdLoaderApiRe.lastIndex = 0; | ||
return (syncLoaderApiRe.test(match) || amdLoaderApiRe.test(match)) ? "" : match; | ||
}); | ||
noCommentText = noCommentText || text.replace(removeCommentRe, "$1"); | ||
@@ -372,0 +359,0 @@ // find and extract all dojo.loadInit applications |
@@ -342,16 +342,16 @@ define([ | ||
// set up the query params | ||
var miArgs = [{}]; | ||
var miArgs = {}; | ||
if(formObject){ | ||
// potentially over-ride url-provided params w/ form values | ||
miArgs.push(formObject); | ||
lang.mixin(miArgs, formObject); | ||
} | ||
if(args.content){ | ||
// stuff in content over-rides what's set by form | ||
miArgs.push(args.content); | ||
lang.mixin(miArgs, args.content); | ||
} | ||
if(args.preventCache){ | ||
miArgs.push({"dojo.preventCache": new Date().valueOf()}); | ||
miArgs["dojo.preventCache"] = new Date().valueOf(); | ||
} | ||
ioArgs.query = ioq.objectToQuery(lang.mixin.apply(null, miArgs)); | ||
ioArgs.query = ioq.objectToQuery(miArgs); | ||
@@ -358,0 +358,0 @@ // .. and the real work of getting the deferred in order, etc. |
@@ -290,3 +290,3 @@ define( | ||
"field-mon-relative+1": "来週の月曜日", | ||
"dateFormat-short": "y/MM/dd", | ||
"dateFormat-short": "y年M月d日", | ||
"dateFormatItem-EHms": "H:mm:ss (E)", | ||
@@ -304,3 +304,3 @@ "dateFormatItem-Ehms": "aK:mm:ss (E)", | ||
"field-week": "週", | ||
"dateFormat-medium": "y/MM/dd", | ||
"dateFormat-medium": "y年M月d日", | ||
"field-year-relative+0": "今年", | ||
@@ -319,2 +319,2 @@ "field-week-relative+-1": "先週", | ||
//end v1.x content | ||
); | ||
); |
@@ -309,3 +309,3 @@ define(["./_base/kernel", "./_base/lang", "./_base/array", "./_base/declare", "./dom", "./dom-construct", "./parser"], | ||
}, function(e){ | ||
self._onError('Content', e, "Error parsing in _ContentSetter#" + this.id); | ||
self._onError('Content', e, "Error parsing in _ContentSetter#" + self.id); | ||
}); | ||
@@ -312,0 +312,0 @@ }catch(e){ |
{ | ||
"name": "dojo", | ||
"version": "1.12.3", | ||
"version": "1.12.4", | ||
"directories": { | ||
@@ -14,3 +14,3 @@ "lib": "." | ||
"sinon": "1.12.2", | ||
"dojo": "1.12.3" | ||
"dojo": "1.12.4" | ||
}, | ||
@@ -17,0 +17,0 @@ "main": "main", |
define([ | ||
"../_base/array", | ||
"../_base/lang", | ||
"../Deferred", | ||
"../when" | ||
], function(array, Deferred, when){ | ||
], function(array, lang, Deferred, when){ | ||
"use strict"; | ||
@@ -30,3 +31,3 @@ | ||
var object, array; | ||
if(objectOrArray instanceof Array){ | ||
if(lang.isArray(objectOrArray)){ | ||
array = objectOrArray; | ||
@@ -33,0 +34,0 @@ }else if(objectOrArray && typeof objectOrArray === "object"){ |
@@ -14,6 +14,7 @@ define([ | ||
'../_base/window', | ||
'../NodeList-dom'/*=====, | ||
'../request', | ||
'../_base/declare' =====*/ | ||
], function(module, require, watch, util, handlers, lang, ioQuery, query, has, dom, domConstruct, win/*=====, NodeList, request, declare =====*/){ | ||
// NodeList enhancement modules; | ||
// must be loaded (but no reference needed) | ||
'../NodeList-dom', | ||
'../NodeList-manipulate' | ||
], function(module, require, watch, util, handlers, lang, ioQuery, query, has, dom, domConstruct, win){ | ||
var mid = module.id.replace(/[\/\.\-]/g, '_'), | ||
@@ -216,6 +217,12 @@ onload = mid + '_onload'; | ||
}else{ | ||
if(!formNode[x]){ | ||
// Explicitly search for nodes in the dom tree | ||
// using formNode[x] may access attributes of the | ||
// form node itself, e.g. formNode['action'] | ||
var n = query("input[name='"+x+"']", formNode); | ||
// Not found if indexOf == -1 | ||
if(n.indexOf() == -1){ | ||
createInput(x, val); | ||
}else{ | ||
formNode[x].value = val; | ||
n.val(val); | ||
} | ||
@@ -222,0 +229,0 @@ } |
@@ -70,9 +70,2 @@ define([ | ||
if(!error){ | ||
try{ | ||
handlers(response); | ||
}catch(e){ | ||
error = e; | ||
} | ||
} | ||
var handleError; | ||
@@ -100,3 +93,3 @@ if(error){ | ||
' and an error in handleAs: transformation of response', response); | ||
this.reject(error); | ||
this.reject(error); | ||
} | ||
@@ -193,2 +186,3 @@ } | ||
options = response.options; | ||
var hasNoData = !options.data && options.method !== 'POST' && options.method !== 'PUT'; | ||
@@ -247,3 +241,3 @@ if(has('ie') <= 10){ | ||
var headers = options.headers, | ||
contentType = isFormData ? false : 'application/x-www-form-urlencoded'; | ||
contentType = (isFormData || hasNoData) ? false : 'application/x-www-form-urlencoded'; | ||
if(headers){ | ||
@@ -250,0 +244,0 @@ for(var hdr in headers){ |
@@ -18,6 +18,2 @@ define([ | ||
"sync,,rel,./built-i18n-test/rel/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
"sync,,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,src,./i18n-test,amd", | ||
"sync,,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built/i18nTest,amd", | ||
"sync,,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers/i18nTest,amd", | ||
"sync,,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
@@ -35,6 +31,2 @@ "sync,ab,src,./dojo,src,./i18n-test,legacy", | ||
"sync,ab,rel,./built-i18n-test/rel/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
"sync,ab,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,src,./i18n-test,amd", | ||
"sync,ab,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built/i18nTest,amd", | ||
"sync,ab,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers/i18nTest,amd", | ||
"sync,ab,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
@@ -52,6 +44,2 @@ "sync,ab-cd,src,./dojo,src,./i18n-test,legacy", | ||
"sync,ab-cd,rel,./built-i18n-test/rel/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
"sync,ab-cd,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,src,./i18n-test,amd", | ||
"sync,ab-cd,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built/i18nTest,amd", | ||
"sync,ab-cd,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers/i18nTest,amd", | ||
"sync,ab-cd,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
@@ -69,6 +57,2 @@ "sync,ab-cd-ef,src,./dojo,src,./i18n-test,legacy", | ||
"sync,ab-cd-ef,rel,./built-i18n-test/rel/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
"sync,ab-cd-ef,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,src,./i18n-test,amd", | ||
"sync,ab-cd-ef,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built/i18nTest,amd", | ||
"sync,ab-cd-ef,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers/i18nTest,amd", | ||
"sync,ab-cd-ef,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
"async,,src,./dojo,src,./i18n-test,amd", | ||
@@ -82,6 +66,2 @@ "async,,src,./dojo,built,./built-i18n-test/built/i18nTest,amd", | ||
"async,,rel,./built-i18n-test/rel/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
"async,,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,src,./i18n-test,amd", | ||
"async,,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built/i18nTest,amd", | ||
"async,,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers/i18nTest,amd", | ||
"async,,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
@@ -96,6 +76,2 @@ "async,ab,src,./dojo,src,./i18n-test,amd", | ||
"async,ab,rel,./built-i18n-test/rel/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
"async,ab,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,src,./i18n-test,amd", | ||
"async,ab,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built/i18nTest,amd", | ||
"async,ab,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers/i18nTest,amd", | ||
"async,ab,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
@@ -110,6 +86,2 @@ "async,ab-cd,src,./dojo,src,./i18n-test,amd", | ||
"async,ab-cd,rel,./built-i18n-test/rel/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
"async,ab-cd,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,src,./i18n-test,amd", | ||
"async,ab-cd,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built/i18nTest,amd", | ||
"async,ab-cd,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers/i18nTest,amd", | ||
"async,ab-cd,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
@@ -123,7 +95,3 @@ "async,ab-cd-ef,src,./dojo,src,./i18n-test,amd", | ||
"async,ab-cd-ef,rel,./built-i18n-test/rel/dojo,built,./built-i18n-test/built-with-layers/i18nTest,amd", | ||
"async,ab-cd-ef,rel,./built-i18n-test/rel/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd", | ||
"async,ab-cd-ef,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,src,./i18n-test,amd", | ||
"async,ab-cd-ef,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built/i18nTest,amd", | ||
"async,ab-cd-ef,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers/i18nTest,amd", | ||
"async,ab-cd-ef,cdn,http://192.168.1.114/dev/dtk/built-i18n-test/cdn/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd"]; | ||
"async,ab-cd-ef,rel,./built-i18n-test/rel/dojo,built,./built-i18n-test/built-with-layers-and-preloads/i18nTest,amd"]; | ||
@@ -130,0 +98,0 @@ for(var i = 0; i<testParams.length; i++){ |
@@ -62,4 +62,4 @@ Analysis of i18n Bundle Loading in 1.7+ | ||
A unit test html page is constructed at i18n-test/unit.html. Given a query string, it will load a particular loader and | ||
exercise a particular set of modules. | ||
exercise a particular set of modules. Its contents must be uncommented before running the tests. | ||
Finally, the DOH test dojo/testsDOH/_base/i18nExhaustive runs all the various combinations. |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Debug access
Supply chain riskUses debug, reflection and dynamic code execution features.
Found 5 instances in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
4625451
1263
137579
202