repo
stringclasses
195 values
path
stringlengths
4
99
func_name
stringlengths
0
41
original_string
stringlengths
72
56.1k
language
stringclasses
1 value
code
stringlengths
72
56.1k
code_tokens
listlengths
25
8.12k
docstring
stringlengths
2
12.5k
docstring_tokens
listlengths
1
449
sha
stringclasses
197 values
url
stringlengths
88
186
partition
stringclasses
1 value
summary
stringlengths
8
338
input_ids
listlengths
502
502
token_type_ids
listlengths
502
502
attention_mask
listlengths
502
502
labels
listlengths
502
502
uber/deck.gl
modules/core/src/utils/old-log.js
checkForAssertionErrors
function checkForAssertionErrors(args) { const isAssertion = args && args.length > 0 && typeof args[0] === 'object' && args[0] !== null && args[0].name === 'AssertionError'; if (isAssertion) { args = Array.prototype.slice.call(args); args.unshift(`assert(${args[0].message})`); } ret...
javascript
function checkForAssertionErrors(args) { const isAssertion = args && args.length > 0 && typeof args[0] === 'object' && args[0] !== null && args[0].name === 'AssertionError'; if (isAssertion) { args = Array.prototype.slice.call(args); args.unshift(`assert(${args[0].message})`); } ret...
[ "function", "checkForAssertionErrors", "(", "args", ")", "{", "const", "isAssertion", "=", "args", "&&", "args", ".", "length", ">", "0", "&&", "typeof", "args", "[", "0", "]", "===", "'object'", "&&", "args", "[", "0", "]", "!==", "null", "&&", "args"...
Assertions don't generate standard exceptions and don't print nicely
[ "Assertions", "don", "t", "generate", "standard", "exceptions", "and", "don", "t", "print", "nicely" ]
a2010448b7f268bbd03617b812334c68a6b9e5b2
https://github.com/uber/deck.gl/blob/a2010448b7f268bbd03617b812334c68a6b9e5b2/modules/core/src/utils/old-log.js#L127-L140
train
Check if an error is thrown
[ 30522, 3853, 4638, 29278, 27241, 28228, 5643, 18933, 2869, 1006, 12098, 5620, 1007, 1063, 9530, 3367, 18061, 18116, 3508, 1027, 12098, 5620, 1004, 1004, 12098, 5620, 1012, 3091, 1028, 1014, 1004, 1004, 2828, 11253, 12098, 5620, 1031, 1014, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
eslint/eslint
lib/rules/semi-spacing.js
isFirstTokenInCurrentLine
function isFirstTokenInCurrentLine(token) { const tokenBefore = sourceCode.getTokenBefore(token); return !(tokenBefore && astUtils.isTokenOnSameLine(token, tokenBefore)); }
javascript
function isFirstTokenInCurrentLine(token) { const tokenBefore = sourceCode.getTokenBefore(token); return !(tokenBefore && astUtils.isTokenOnSameLine(token, tokenBefore)); }
[ "function", "isFirstTokenInCurrentLine", "(", "token", ")", "{", "const", "tokenBefore", "=", "sourceCode", ".", "getTokenBefore", "(", "token", ")", ";", "return", "!", "(", "tokenBefore", "&&", "astUtils", ".", "isTokenOnSameLine", "(", "token", ",", "tokenBef...
Checks if the given token is the first token in its line @param {Token} token The token to check. @returns {boolean} Whether or not the token is the first in its line.
[ "Checks", "if", "the", "given", "token", "is", "the", "first", "token", "in", "its", "line" ]
bc0819c94aad14f7fad3cbc2338ea15658b0f272
https://github.com/eslint/eslint/blob/bc0819c94aad14f7fad3cbc2338ea15658b0f272/lib/rules/semi-spacing.js#L95-L99
train
Check if the given token is the first token in the current line
[ 30522, 3853, 2003, 8873, 12096, 18715, 18595, 12273, 29264, 4179, 1006, 19204, 1007, 1063, 9530, 3367, 19204, 4783, 29278, 2063, 1027, 3120, 16044, 1012, 2131, 18715, 2368, 4783, 29278, 2063, 1006, 19204, 1007, 1025, 2709, 999, 1006, 19204, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aframevr/aframe
src/systems/geometry.js
function (data) { var cache = this.cache; var cachedGeometry; var hash; // Skip all caching logic. if (data.skipCache) { return createGeometry(data); } // Try to retrieve from cache first. hash = this.hash(data); cachedGeometry = cache[hash]; incrementCacheCount(this.cacheCount, ha...
javascript
function (data) { var cache = this.cache; var cachedGeometry; var hash; // Skip all caching logic. if (data.skipCache) { return createGeometry(data); } // Try to retrieve from cache first. hash = this.hash(data); cachedGeometry = cache[hash]; incrementCacheCount(this.cacheCount, ha...
[ "function", "(", "data", ")", "{", "var", "cache", "=", "this", ".", "cache", ";", "var", "cachedGeometry", ";", "var", "hash", ";", "// Skip all caching logic.", "if", "(", "data", ".", "skipCache", ")", "{", "return", "createGeometry", "(", "data", ")", ...
Attempt to retrieve from cache. @returns {Object|null} A geometry if it exists, else null.
[ "Attempt", "to", "retrieve", "from", "cache", "." ]
24acc78a7299a4cdfe3ef617f4d40ddf6275c992
https://github.com/aframevr/aframe/blob/24acc78a7299a4cdfe3ef617f4d40ddf6275c992/src/systems/geometry.js#L32-L53
train
Returns geometry from cache
[ 30522, 3853, 1006, 2951, 1007, 1063, 13075, 17053, 1027, 2023, 1012, 17053, 1025, 13075, 17053, 11818, 8462, 11129, 1025, 13075, 23325, 1025, 1013, 1013, 13558, 2035, 6187, 8450, 7961, 1012, 2065, 1006, 2951, 1012, 13558, 3540, 5403, 1007, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
airyland/vux
src/components/video/zy.media.js
function() { var t = this; var loading = document.createElement('div'); loading.className = 'dec_loading'; loading.style.display = 'none'; t.container.appendChild(loading); var error = document.createElement('div'); error.className = 'dec_error'; error.style.display = 'none'; error.innerHTML = '播放异常...
javascript
function() { var t = this; var loading = document.createElement('div'); loading.className = 'dec_loading'; loading.style.display = 'none'; t.container.appendChild(loading); var error = document.createElement('div'); error.className = 'dec_error'; error.style.display = 'none'; error.innerHTML = '播放异常...
[ "function", "(", ")", "{", "var", "t", "=", "this", ";", "var", "loading", "=", "document", ".", "createElement", "(", "'div'", ")", ";", "loading", ".", "className", "=", "'dec_loading'", ";", "loading", ".", "style", ".", "display", "=", "'none'", ";...
bigPlay, loading and error info
[ "bigPlay", "loading", "and", "error", "info" ]
484fc3c18bdca99b0c08efbb678c0ee0f5ceedd6
https://github.com/airyland/vux/blob/484fc3c18bdca99b0c08efbb678c0ee0f5ceedd6/src/components/video/zy.media.js#L738-L821
train
Creates the popup
[ 30522, 3853, 1006, 1007, 1063, 13075, 1056, 1027, 2023, 1025, 13075, 10578, 1027, 6254, 1012, 3443, 12260, 3672, 1006, 1005, 4487, 2615, 1005, 1007, 1025, 10578, 1012, 2465, 18442, 1027, 1005, 11703, 1035, 10578, 1005, 1025, 10578, 1012, 28...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
eslint/eslint
lib/rules/no-implicit-coercion.js
isEmptyString
function isEmptyString(node) { return astUtils.isStringLiteral(node) && (node.value === "" || (node.type === "TemplateLiteral" && node.quasis.length === 1 && node.quasis[0].value.cooked === "")); }
javascript
function isEmptyString(node) { return astUtils.isStringLiteral(node) && (node.value === "" || (node.type === "TemplateLiteral" && node.quasis.length === 1 && node.quasis[0].value.cooked === "")); }
[ "function", "isEmptyString", "(", "node", ")", "{", "return", "astUtils", ".", "isStringLiteral", "(", "node", ")", "&&", "(", "node", ".", "value", "===", "\"\"", "||", "(", "node", ".", "type", "===", "\"TemplateLiteral\"", "&&", "node", ".", "quasis", ...
Checks whether a node is an empty string literal or not. @param {ASTNode} node The node to check. @returns {boolean} Whether or not the passed in node is an empty string literal or not.
[ "Checks", "whether", "a", "node", "is", "an", "empty", "string", "literal", "or", "not", "." ]
bc0819c94aad14f7fad3cbc2338ea15658b0f272
https://github.com/eslint/eslint/blob/bc0819c94aad14f7fad3cbc2338ea15658b0f272/lib/rules/no-implicit-coercion.js#L115-L117
train
Returns true if node is empty string
[ 30522, 3853, 2003, 6633, 13876, 27268, 4892, 1006, 13045, 1007, 1063, 2709, 2004, 8525, 3775, 4877, 1012, 26354, 18886, 3070, 22779, 7941, 1006, 13045, 1007, 1004, 1004, 1006, 13045, 1012, 3643, 1027, 1027, 1027, 1000, 1000, 1064, 1064, 100...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
nhn/tui.editor
src/js/wysiwygCommands/tableAddCol.js
focusToNextCell
function focusToNextCell(sq, $cell) { const range = sq.getSelection(); range.selectNodeContents($cell.next()[0]); range.collapse(true); sq.setSelection(range); }
javascript
function focusToNextCell(sq, $cell) { const range = sq.getSelection(); range.selectNodeContents($cell.next()[0]); range.collapse(true); sq.setSelection(range); }
[ "function", "focusToNextCell", "(", "sq", ",", "$cell", ")", "{", "const", "range", "=", "sq", ".", "getSelection", "(", ")", ";", "range", ".", "selectNodeContents", "(", "$cell", ".", "next", "(", ")", "[", "0", "]", ")", ";", "range", ".", "collap...
Focus to next cell @param {Squire} sq - Squire instance @param {jQuery} $cell - jQuery wrapped table cell @ignore
[ "Focus", "to", "next", "cell" ]
e75ab08c2a7ab07d1143e318f7cde135c5e3002e
https://github.com/nhn/tui.editor/blob/e75ab08c2a7ab07d1143e318f7cde135c5e3002e/src/js/wysiwygCommands/tableAddCol.js#L114-L121
train
Focus to next cell
[ 30522, 3853, 3579, 5524, 18413, 29109, 2140, 1006, 5490, 1010, 1002, 3526, 1007, 1063, 9530, 3367, 2846, 1027, 5490, 1012, 4152, 12260, 7542, 1006, 1007, 1025, 30524, 102, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
eslint/eslint
lib/rules/no-fallthrough.js
hasFallthroughComment
function hasFallthroughComment(node, context, fallthroughCommentPattern) { const sourceCode = context.getSourceCode(); const comment = lodash.last(sourceCode.getCommentsBefore(node)); return Boolean(comment && fallthroughCommentPattern.test(comment.value)); }
javascript
function hasFallthroughComment(node, context, fallthroughCommentPattern) { const sourceCode = context.getSourceCode(); const comment = lodash.last(sourceCode.getCommentsBefore(node)); return Boolean(comment && fallthroughCommentPattern.test(comment.value)); }
[ "function", "hasFallthroughComment", "(", "node", ",", "context", ",", "fallthroughCommentPattern", ")", "{", "const", "sourceCode", "=", "context", ".", "getSourceCode", "(", ")", ";", "const", "comment", "=", "lodash", ".", "last", "(", "sourceCode", ".", "g...
Checks whether or not a given node has a fallthrough comment. @param {ASTNode} node - A SwitchCase node to get comments. @param {RuleContext} context - A rule context which stores comments. @param {RegExp} fallthroughCommentPattern - A pattern to match comment to. @returns {boolean} `true` if the node has a valid fallt...
[ "Checks", "whether", "or", "not", "a", "given", "node", "has", "a", "fallthrough", "comment", "." ]
bc0819c94aad14f7fad3cbc2338ea15658b0f272
https://github.com/eslint/eslint/blob/bc0819c94aad14f7fad3cbc2338ea15658b0f272/lib/rules/no-fallthrough.js#L26-L31
train
Checks if a node has a fallthrough comment
[ 30522, 3853, 2038, 13976, 2705, 22494, 5603, 9006, 3672, 1006, 13045, 1010, 6123, 1010, 2991, 2705, 22494, 5603, 9006, 3672, 4502, 12079, 2078, 1007, 1063, 9530, 3367, 3120, 16044, 1027, 6123, 1012, 4152, 8162, 3401, 16044, 1006, 1007, 1025...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
marcuswestin/store.js
plugins/operations.js
push
function push(_, key, val1, val2, val3, etc) { return _arrayOp.call(this, 'push', arguments) }
javascript
function push(_, key, val1, val2, val3, etc) { return _arrayOp.call(this, 'push', arguments) }
[ "function", "push", "(", "_", ",", "key", ",", "val1", ",", "val2", ",", "val3", ",", "etc", ")", "{", "return", "_arrayOp", ".", "call", "(", "this", ",", "'push'", ",", "arguments", ")", "}" ]
array
[ "array" ]
b8e22fea8738fc19da4d9e7dbf1cda6e5185c481
https://github.com/marcuswestin/store.js/blob/b8e22fea8738fc19da4d9e7dbf1cda6e5185c481/plugins/operations.js#L22-L24
train
push a value to the end of the array
[ 30522, 3853, 5245, 1006, 1035, 1010, 3145, 1010, 11748, 2487, 1010, 11748, 2475, 1010, 11748, 2509, 1010, 4385, 1007, 1063, 2709, 1035, 9140, 7361, 1012, 2655, 1006, 2023, 1010, 1005, 5245, 1005, 1010, 9918, 1007, 1065, 102, 0, 0, 0, 0,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/material
src/components/dialog/dialog.js
getDomElement
function getDomElement(element, defaultElement) { if (angular.isString(element)) { element = $document[0].querySelector(element); } // If we have a reference to a raw dom element, always wrap it in jqLite return angular.element(element || defaultElement); ...
javascript
function getDomElement(element, defaultElement) { if (angular.isString(element)) { element = $document[0].querySelector(element); } // If we have a reference to a raw dom element, always wrap it in jqLite return angular.element(element || defaultElement); ...
[ "function", "getDomElement", "(", "element", ",", "defaultElement", ")", "{", "if", "(", "angular", ".", "isString", "(", "element", ")", ")", "{", "element", "=", "$document", "[", "0", "]", ".", "querySelector", "(", "element", ")", ";", "}", "// If we...
If the specifier is a simple string selector, then query for the DOM element.
[ "If", "the", "specifier", "is", "a", "simple", "string", "selector", "then", "query", "for", "the", "DOM", "element", "." ]
84ac558674e73958be84312444c48d9f823f6684
https://github.com/angular/material/blob/84ac558674e73958be84312444c48d9f823f6684/src/components/dialog/dialog.js#L935-L942
train
Get the dom element
[ 30522, 3853, 2131, 26173, 16930, 4765, 1006, 5783, 1010, 12398, 12260, 3672, 1007, 1063, 2065, 1006, 16108, 1012, 26354, 18886, 3070, 1006, 5783, 1007, 1007, 1063, 5783, 1027, 1002, 6254, 1031, 1014, 1033, 1012, 23032, 11246, 22471, 2953, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
apache/incubator-echarts
src/chart/tree/layoutHelper.js
executeShifts
function executeShifts(node) { var children = node.children; var n = children.length; var shift = 0; var change = 0; while (--n >= 0) { var child = children[n]; child.hierNode.prelim += shift; child.hierNode.modifier += shift; change += child.hierNode.change; ...
javascript
function executeShifts(node) { var children = node.children; var n = children.length; var shift = 0; var change = 0; while (--n >= 0) { var child = children[n]; child.hierNode.prelim += shift; child.hierNode.modifier += shift; change += child.hierNode.change; ...
[ "function", "executeShifts", "(", "node", ")", "{", "var", "children", "=", "node", ".", "children", ";", "var", "n", "=", "children", ".", "length", ";", "var", "shift", "=", "0", ";", "var", "change", "=", "0", ";", "while", "(", "--", "n", ">=",...
All other shifts, applied to the smaller subtrees between w- and w+, are performed by this function. The implementation of this function was originally copied from "d3.js" <https://github.com/d3/d3-hierarchy/blob/4c1f038f2725d6eae2e49b61d01456400694bac4/src/tree.js> with some modifications made for this program. See t...
[ "All", "other", "shifts", "applied", "to", "the", "smaller", "subtrees", "between", "w", "-", "and", "w", "+", "are", "performed", "by", "this", "function", "." ]
4d0ea095dc3929cb6de40c45748826e7999c7aa8
https://github.com/apache/incubator-echarts/blob/4d0ea095dc3929cb6de40c45748826e7999c7aa8/src/chart/tree/layoutHelper.js#L185-L197
train
Execute shifts of a node
[ 30522, 3853, 15389, 6182, 6199, 2015, 1006, 13045, 1007, 1063, 13075, 2336, 1027, 13045, 1012, 2336, 1025, 13075, 1050, 1027, 2336, 1012, 3091, 1025, 13075, 5670, 1027, 1014, 1025, 13075, 2689, 1027, 1014, 1025, 2096, 1006, 1011, 1011, 1050...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
swimlane/ngx-datatable
release/utils/throttle.js
throttleable
function throttleable(duration, options) { return function innerDecorator(target, key, descriptor) { return { configurable: true, enumerable: descriptor.enumerable, get: function getter() { Object.defineProperty(this, key, { configurabl...
javascript
function throttleable(duration, options) { return function innerDecorator(target, key, descriptor) { return { configurable: true, enumerable: descriptor.enumerable, get: function getter() { Object.defineProperty(this, key, { configurabl...
[ "function", "throttleable", "(", "duration", ",", "options", ")", "{", "return", "function", "innerDecorator", "(", "target", ",", "key", ",", "descriptor", ")", "{", "return", "{", "configurable", ":", "true", ",", "enumerable", ":", "descriptor", ".", "enu...
Throttle decorator class MyClass { throttleable(10) myFn() { ... } }
[ "Throttle", "decorator" ]
d7df15a070282a169524dba51d9572008b74804c
https://github.com/swimlane/ngx-datatable/blob/d7df15a070282a169524dba51d9572008b74804c/release/utils/throttle.js#L47-L62
train
Creates a decorator that throttles the given duration of the resource.
[ 30522, 3853, 24420, 3085, 1006, 9367, 1010, 7047, 1007, 1063, 2709, 3853, 5110, 3207, 27108, 8844, 1006, 4539, 1010, 3145, 1010, 4078, 23235, 2953, 1007, 1063, 2709, 1063, 9530, 8873, 27390, 3085, 1024, 2995, 1010, 4372, 17897, 16670, 1024,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
zloirock/core-js
packages/core-js/modules/es.promise.js
race
function race(iterable) { var C = this; var capability = newPromiseCapability(C); var reject = capability.reject; var result = perform(function () { var $promiseResolve = aFunction(C.resolve); iterate(iterable, function (promise) { $promiseResolve.call(C, promise).then(capability.res...
javascript
function race(iterable) { var C = this; var capability = newPromiseCapability(C); var reject = capability.reject; var result = perform(function () { var $promiseResolve = aFunction(C.resolve); iterate(iterable, function (promise) { $promiseResolve.call(C, promise).then(capability.res...
[ "function", "race", "(", "iterable", ")", "{", "var", "C", "=", "this", ";", "var", "capability", "=", "newPromiseCapability", "(", "C", ")", ";", "var", "reject", "=", "capability", ".", "reject", ";", "var", "result", "=", "perform", "(", "function", ...
`Promise.race` method https://tc39.github.io/ecma262/#sec-promise.race
[ "Promise", ".", "race", "method", "https", ":", "//", "tc39", ".", "github", ".", "io", "/", "ecma262", "/", "#sec", "-", "promise", ".", "race" ]
fe7c8511a6d27d03a9b8e075b3351416aae95c58
https://github.com/zloirock/core-js/blob/fe7c8511a6d27d03a9b8e075b3351416aae95c58/packages/core-js/modules/es.promise.js#L335-L347
train
Returns a promise that resolves to the first promise in iterable.
[ 30522, 3853, 2679, 1006, 2009, 6906, 3468, 1007, 1063, 13075, 1039, 1027, 2023, 1025, 13075, 10673, 1027, 2047, 21572, 28732, 17695, 8010, 1006, 1039, 1007, 1025, 13075, 15454, 1027, 10673, 1012, 15454, 1025, 13075, 2765, 1027, 4685, 1006, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
eslint/eslint
lib/rules/multiline-comment-style.js
convertToBlock
function convertToBlock(firstComment, commentLinesList) { const initialOffset = sourceCode.text.slice(firstComment.range[0] - firstComment.loc.start.column, firstComment.range[0]); const blockLines = commentLinesList.map(line => line.trim()); return `/* ${blockLines.join(`\n${initia...
javascript
function convertToBlock(firstComment, commentLinesList) { const initialOffset = sourceCode.text.slice(firstComment.range[0] - firstComment.loc.start.column, firstComment.range[0]); const blockLines = commentLinesList.map(line => line.trim()); return `/* ${blockLines.join(`\n${initia...
[ "function", "convertToBlock", "(", "firstComment", ",", "commentLinesList", ")", "{", "const", "initialOffset", "=", "sourceCode", ".", "text", ".", "slice", "(", "firstComment", ".", "range", "[", "0", "]", "-", "firstComment", ".", "loc", ".", "start", "."...
Converts a comment into bare-block form @param {Token} firstComment The first comment of the group being converted @param {string[]} commentLinesList A list of lines to appear in the new starred-block comment @returns {string} A representation of the comment value in bare-block form
[ "Converts", "a", "comment", "into", "bare", "-", "block", "form" ]
bc0819c94aad14f7fad3cbc2338ea15658b0f272
https://github.com/eslint/eslint/blob/bc0819c94aad14f7fad3cbc2338ea15658b0f272/lib/rules/multiline-comment-style.js#L90-L95
train
converts a comment to a block
[ 30522, 3853, 10463, 3406, 23467, 1006, 2034, 9006, 3672, 1010, 7615, 12735, 9863, 1007, 1063, 9530, 3367, 3988, 27475, 3388, 1027, 3120, 16044, 1012, 3793, 1012, 14704, 1006, 2034, 9006, 3672, 1012, 2846, 1031, 1014, 1033, 1011, 2034, 9006,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
dcloudio/mui
examples/login/libs/easymob-webim-sdk/strophe-custom-2.0.0.js
function (elem) { if (elem.getAttribute("type") == "error") { Strophe.info("SASL binding failed."); var conflict = elem.getElementsByTagName("conflict"), condition; if (conflict.length > 0) { condition = 'conflict'; } this._...
javascript
function (elem) { if (elem.getAttribute("type") == "error") { Strophe.info("SASL binding failed."); var conflict = elem.getElementsByTagName("conflict"), condition; if (conflict.length > 0) { condition = 'conflict'; } this._...
[ "function", "(", "elem", ")", "{", "if", "(", "elem", ".", "getAttribute", "(", "\"type\"", ")", "==", "\"error\"", ")", "{", "Strophe", ".", "info", "(", "\"SASL binding failed.\"", ")", ";", "var", "conflict", "=", "elem", ".", "getElementsByTagName", "(...
PrivateFunction: _sasl_bind_cb _Private_ handler for binding result and session start. Parameters: (XMLElement) elem - The matching stanza. Returns: false to remove the handler.
[ "PrivateFunction", ":", "_sasl_bind_cb", "_Private_", "handler", "for", "binding", "result", "and", "session", "start", "." ]
ff74c90a1671a552f3604b1288bf38a4126312d0
https://github.com/dcloudio/mui/blob/ff74c90a1671a552f3604b1288bf38a4126312d0/examples/login/libs/easymob-webim-sdk/strophe-custom-2.0.0.js#L3252-L3290
train
End of function elib
[ 30522, 3853, 30524, 12260, 8163, 3762, 15900, 18442, 1006, 1000, 4736, 1000, 1007, 1010, 4650, 1025, 2065, 1006, 4736, 1012, 3091, 1028, 1014, 1007, 1063, 4650, 1027, 1005, 4736, 1005, 1025, 1065, 2023, 1012, 1035, 2689, 8663, 2638, 16649, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
nhn/tui.editor
src/js/extensions/table/mergeCell.js
_initCellData
function _initCellData(targetRows, startColIndex, endColIndex) { const limitColIndex = endColIndex + 1; const targetCells = targetRows.map(rowData => rowData.slice(startColIndex, limitColIndex)); [].concat(...targetCells).slice(1).forEach(cellData => { const {nodeName} = cellData; util.forEach(cellData,...
javascript
function _initCellData(targetRows, startColIndex, endColIndex) { const limitColIndex = endColIndex + 1; const targetCells = targetRows.map(rowData => rowData.slice(startColIndex, limitColIndex)); [].concat(...targetCells).slice(1).forEach(cellData => { const {nodeName} = cellData; util.forEach(cellData,...
[ "function", "_initCellData", "(", "targetRows", ",", "startColIndex", ",", "endColIndex", ")", "{", "const", "limitColIndex", "=", "endColIndex", "+", "1", ";", "const", "targetCells", "=", "targetRows", ".", "map", "(", "rowData", "=>", "rowData", ".", "slice...
Initialize cell data of target rows. @param {Array.<Array.<object>>} targetRows - target rows @param {number} startColIndex - start column index @param {number} endColIndex - end column index @private
[ "Initialize", "cell", "data", "of", "target", "rows", "." ]
e75ab08c2a7ab07d1143e318f7cde135c5e3002e
https://github.com/nhn/tui.editor/blob/e75ab08c2a7ab07d1143e318f7cde135c5e3002e/src/js/extensions/table/mergeCell.js#L79-L89
train
Initialize cell data for the target cells
[ 30522, 3853, 1035, 1999, 4183, 29109, 15150, 2696, 1006, 4539, 10524, 2015, 1010, 2707, 25778, 22254, 10288, 1010, 2203, 25778, 22254, 10288, 1007, 1063, 9530, 3367, 5787, 25778, 22254, 10288, 1027, 2203, 25778, 22254, 10288, 1009, 1015, 1025...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/odata/v4/lib/_Requestor.js
Requestor
function Requestor(sServiceUrl, mHeaders, mQueryParams, oModelInterface) { this.mBatchQueue = {}; this.mHeaders = mHeaders || {}; this.oModelInterface = oModelInterface; this.sQueryParams = _Helper.buildQuery(mQueryParams); // Used for $batch and CSRF token only this.mRunningChangeRequests = {}; this.oSecur...
javascript
function Requestor(sServiceUrl, mHeaders, mQueryParams, oModelInterface) { this.mBatchQueue = {}; this.mHeaders = mHeaders || {}; this.oModelInterface = oModelInterface; this.sQueryParams = _Helper.buildQuery(mQueryParams); // Used for $batch and CSRF token only this.mRunningChangeRequests = {}; this.oSecur...
[ "function", "Requestor", "(", "sServiceUrl", ",", "mHeaders", ",", "mQueryParams", ",", "oModelInterface", ")", "{", "this", ".", "mBatchQueue", "=", "{", "}", ";", "this", ".", "mHeaders", "=", "mHeaders", "||", "{", "}", ";", "this", ".", "oModelInterfac...
Constructor for a new <code>_Requestor</code> instance for the given service URL and default headers. @param {string} sServiceUrl URL of the service document to request the CSRF token from; also used to resolve relative resource paths (see {@link #request}) @param {object} [mHeaders={}] Map of default headers; may be ...
[ "Constructor", "for", "a", "new", "<code", ">", "_Requestor<", "/", "code", ">", "instance", "for", "the", "given", "service", "URL", "and", "default", "headers", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/odata/v4/lib/_Requestor.js#L80-L90
train
Creates a new Requestor instance.
[ 30522, 3853, 5227, 2953, 1006, 7020, 2121, 7903, 11236, 2140, 1010, 1049, 4974, 2545, 1010, 1049, 4226, 2854, 28689, 5244, 1010, 18168, 10244, 4115, 3334, 12172, 1007, 1063, 2023, 1012, 15038, 10649, 4226, 5657, 1027, 1063, 1065, 1025, 2023...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
jhipster/generator-jhipster
generators/docker-cli.js
pushImage
function pushImage(repository) { const commandLine = `docker push ${repository}`; return new Promise((resolve, reject) => command(commandLine, (err, stdout) => { if (err) { reject(err); } resolve(stdout); }) ); }
javascript
function pushImage(repository) { const commandLine = `docker push ${repository}`; return new Promise((resolve, reject) => command(commandLine, (err, stdout) => { if (err) { reject(err); } resolve(stdout); }) ); }
[ "function", "pushImage", "(", "repository", ")", "{", "const", "commandLine", "=", "`", "${", "repository", "}", "`", ";", "return", "new", "Promise", "(", "(", "resolve", ",", "reject", ")", "=>", "command", "(", "commandLine", ",", "(", "err", ",", "...
Pushes the locally constructed Docker image to the supplied respository @param repository tag, for example: 111111111.dkr.ecr.us-east-1.amazonaws.com/sample @returns {Promise<any>}
[ "Pushes", "the", "locally", "constructed", "Docker", "image", "to", "the", "supplied", "respository" ]
f76fa8de0818ce6bda6c7b1455942e2a9b0ae3ff
https://github.com/jhipster/generator-jhipster/blob/f76fa8de0818ce6bda6c7b1455942e2a9b0ae3ff/generators/docker-cli.js#L138-L148
train
Pushes an image to the specified repository
[ 30522, 3853, 5245, 9581, 3351, 1006, 22409, 1007, 1063, 9530, 3367, 3094, 4179, 1027, 1036, 8946, 2121, 5245, 1002, 1063, 22409, 1065, 1036, 1025, 2709, 2047, 4872, 1006, 1006, 10663, 1010, 15454, 1007, 1027, 1028, 3094, 1006, 3094, 4179, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ecomfe/zrender
build/babel-plugin-transform-modules-commonjs-ec.js
normalizeModuleAndLoadMetadata
function normalizeModuleAndLoadMetadata(programPath) { nameAnonymousExports(programPath); const {local, source} = getModuleMetadata(programPath); removeModuleDeclarations(programPath); // Reuse the imported namespace name if there is one. for (const [, metadata] of source) { if (metadata...
javascript
function normalizeModuleAndLoadMetadata(programPath) { nameAnonymousExports(programPath); const {local, source} = getModuleMetadata(programPath); removeModuleDeclarations(programPath); // Reuse the imported namespace name if there is one. for (const [, metadata] of source) { if (metadata...
[ "function", "normalizeModuleAndLoadMetadata", "(", "programPath", ")", "{", "nameAnonymousExports", "(", "programPath", ")", ";", "const", "{", "local", ",", "source", "}", "=", "getModuleMetadata", "(", "programPath", ")", ";", "removeModuleDeclarations", "(", "pro...
Remove all imports and exports from the file, and return all metadata needed to reconstruct the module's behavior. @return {ModuleMetadata}
[ "Remove", "all", "imports", "and", "exports", "from", "the", "file", "and", "return", "all", "metadata", "needed", "to", "reconstruct", "the", "module", "s", "behavior", "." ]
30321b57cba3149c30eacb0c1e18276f0f001b9f
https://github.com/ecomfe/zrender/blob/30321b57cba3149c30eacb0c1e18276f0f001b9f/build/babel-plugin-transform-modules-commonjs-ec.js#L70-L93
train
Normalize the module and load the metadata
[ 30522, 3853, 3671, 4697, 5302, 8566, 20898, 19422, 10441, 22117, 12928, 2850, 2696, 1006, 2565, 15069, 1007, 1063, 2171, 6761, 4890, 27711, 10288, 25378, 1006, 2565, 15069, 1007, 1025, 9530, 3367, 1063, 2334, 1010, 3120, 1065, 1027, 2131, 5...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
lib/jsdoc/ui5/plugin.js
function(e) { pathPrefixes = env.opts._.reduce(function(result, fileOrDir) { fileOrDir = path.resolve( path.normalize(fileOrDir) ); if ( fs.statSync(fileOrDir).isDirectory() ) { // ensure a trailing path separator if ( fileOrDir.indexOf(path.sep, fileOrDir.length - path.sep.length) < 0 ) { fileOrD...
javascript
function(e) { pathPrefixes = env.opts._.reduce(function(result, fileOrDir) { fileOrDir = path.resolve( path.normalize(fileOrDir) ); if ( fs.statSync(fileOrDir).isDirectory() ) { // ensure a trailing path separator if ( fileOrDir.indexOf(path.sep, fileOrDir.length - path.sep.length) < 0 ) { fileOrD...
[ "function", "(", "e", ")", "{", "pathPrefixes", "=", "env", ".", "opts", ".", "_", ".", "reduce", "(", "function", "(", "result", ",", "fileOrDir", ")", "{", "fileOrDir", "=", "path", ".", "resolve", "(", "path", ".", "normalize", "(", "fileOrDir", "...
Before all files are parsed, determine the common path prefix of all filenames @param {object} e Event info object
[ "Before", "all", "files", "are", "parsed", "determine", "the", "common", "path", "prefix", "of", "all", "filenames" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/lib/jsdoc/ui5/plugin.js#L2076-L2100
train
This function is called when the user clicks on a file or directory
[ 30522, 3853, 1006, 1041, 1007, 1063, 4130, 28139, 8873, 20156, 1027, 4372, 2615, 1012, 23569, 2015, 1012, 1035, 1012, 5547, 1006, 3853, 1006, 2765, 1010, 5371, 8551, 4313, 1007, 1063, 5371, 8551, 4313, 1027, 4130, 1012, 10663, 1006, 4130, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/search/FindReplace.js
_getWordAt
function _getWordAt(editor, pos) { var cm = editor._codeMirror, start = pos.ch, end = start, line = cm.getLine(pos.line); while (start && CodeMirror.isWordChar(line.charAt(start - 1))) { --start; } while (end < line.length && CodeMirror.isW...
javascript
function _getWordAt(editor, pos) { var cm = editor._codeMirror, start = pos.ch, end = start, line = cm.getLine(pos.line); while (start && CodeMirror.isWordChar(line.charAt(start - 1))) { --start; } while (end < line.length && CodeMirror.isW...
[ "function", "_getWordAt", "(", "editor", ",", "pos", ")", "{", "var", "cm", "=", "editor", ".", "_codeMirror", ",", "start", "=", "pos", ".", "ch", ",", "end", "=", "start", ",", "line", "=", "cm", ".", "getLine", "(", "pos", ".", "line", ")", ";...
Returns the range of the word surrounding the given editor position. Similar to getWordAt() from CodeMirror. @param {!Editor} editor The editor to search in @param {!{line: number, ch: number}} pos The position to find a word at. @return {{start:{line: number, ch: number}, end:{line:number, ch:number}, text:string}} T...
[ "Returns", "the", "range", "of", "the", "word", "surrounding", "the", "given", "editor", "position", ".", "Similar", "to", "getWordAt", "()", "from", "CodeMirror", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/search/FindReplace.js#L242-L254
train
Get word at pos
[ 30522, 3853, 1035, 2131, 18351, 4017, 1006, 3559, 1010, 13433, 2015, 1007, 1063, 13075, 4642, 1027, 3559, 1012, 1035, 3642, 14503, 29165, 1010, 2707, 1027, 13433, 2015, 1012, 10381, 1010, 2203, 1027, 2707, 1010, 2240, 1027, 4642, 1012, 2131...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
badges/shields
core/server/log.js
date
function date() { const date = new Date() return ( pad(date.getUTCMonth() + 1) + pad(date.getUTCDate()) + pad(date.getUTCHours()) + pad(date.getUTCMinutes()) + pad(date.getUTCSeconds()) ) }
javascript
function date() { const date = new Date() return ( pad(date.getUTCMonth() + 1) + pad(date.getUTCDate()) + pad(date.getUTCHours()) + pad(date.getUTCMinutes()) + pad(date.getUTCSeconds()) ) }
[ "function", "date", "(", ")", "{", "const", "date", "=", "new", "Date", "(", ")", "return", "(", "pad", "(", "date", ".", "getUTCMonth", "(", ")", "+", "1", ")", "+", "pad", "(", "date", ".", "getUTCDate", "(", ")", ")", "+", "pad", "(", "date"...
Compact date representation. eg. 0611093840 for June 11, 9:38:40 UTC.
[ "Compact", "date", "representation", ".", "eg", ".", "0611093840", "for", "June", "11", "9", ":", "38", ":", "40", "UTC", "." ]
283601423f3d1a19aae83bf62032d40683948636
https://github.com/badges/shields/blob/283601423f3d1a19aae83bf62032d40683948636/core/server/log.js#L16-L25
train
Get the date of the current cluster
[ 30522, 3853, 3058, 1006, 1007, 1063, 9530, 3367, 3058, 1027, 2047, 3058, 1006, 1007, 2709, 1006, 11687, 1006, 3058, 1012, 2131, 4904, 27487, 12162, 2232, 1006, 1007, 1009, 1015, 1007, 1009, 11687, 1006, 3058, 1012, 2131, 4904, 19797, 3686, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SeleniumHQ/selenium
javascript/selenium-core/scripts/htmlutils.js
o2s
function o2s(obj) { var s = ""; for (key in obj) { var line = key + "->" + obj[key]; line.replace("\n", " "); s += line + "\n"; } return s; }
javascript
function o2s(obj) { var s = ""; for (key in obj) { var line = key + "->" + obj[key]; line.replace("\n", " "); s += line + "\n"; } return s; }
[ "function", "o2s", "(", "obj", ")", "{", "var", "s", "=", "\"\"", ";", "for", "(", "key", "in", "obj", ")", "{", "var", "line", "=", "key", "+", "\"->\"", "+", "obj", "[", "key", "]", ";", "line", ".", "replace", "(", "\"\\n\"", ",", "\" \"", ...
for use from vs.2003 debugger
[ "for", "use", "from", "vs", ".", "2003", "debugger" ]
38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd
https://github.com/SeleniumHQ/selenium/blob/38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd/javascript/selenium-core/scripts/htmlutils.js#L821-L829
train
Convert an object to a string
[ 30522, 3853, 1051, 2475, 2015, 1006, 27885, 3501, 1007, 1063, 13075, 1055, 1027, 1000, 1000, 1025, 2005, 1006, 3145, 1999, 27885, 3501, 1007, 1063, 13075, 2240, 1027, 3145, 1009, 1000, 1011, 1028, 1000, 1009, 27885, 3501, 1031, 3145, 1033, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.fl/src/sap/ui/fl/support/apps/contentbrowser/controller/LayerContentMaster.controller.js
function (oEvent) { var sSource = oEvent.getSource(); var sContentBindingPath = sSource.getBindingContextPath().substring(1); var sContentModelData = this.getView().getModel("content").getData(); var sContent = sContentModelData[sContentBindingPath]; var sContentName = sContent.name; var sContentFileT...
javascript
function (oEvent) { var sSource = oEvent.getSource(); var sContentBindingPath = sSource.getBindingContextPath().substring(1); var sContentModelData = this.getView().getModel("content").getData(); var sContent = sContentModelData[sContentBindingPath]; var sContentName = sContent.name; var sContentFileT...
[ "function", "(", "oEvent", ")", "{", "var", "sSource", "=", "oEvent", ".", "getSource", "(", ")", ";", "var", "sContentBindingPath", "=", "sSource", ".", "getBindingContextPath", "(", ")", ".", "substring", "(", "1", ")", ";", "var", "sContentModelData", "...
Handles the selection of a layer entry in the master page; Gathers the selected namespace and the current layer, then navigates to the target. @param {Object} oEvent - press event of master components list @public
[ "Handles", "the", "selection", "of", "a", "layer", "entry", "in", "the", "master", "page", ";", "Gathers", "the", "selected", "namespace", "and", "the", "current", "layer", "then", "navigates", "to", "the", "target", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.fl/src/sap/ui/fl/support/apps/contentbrowser/controller/LayerContentMaster.controller.js#L121-L146
train
The default event handler for the content navigation
[ 30522, 3853, 1006, 1051, 18697, 3372, 1007, 1063, 13075, 7020, 8162, 3401, 1027, 1051, 18697, 3372, 1012, 4152, 8162, 3401, 1006, 1007, 1025, 13075, 8040, 28040, 3372, 8428, 4667, 15069, 1027, 7020, 8162, 3401, 1012, 2131, 8428, 4667, 8663,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/core/support/RuleEngineOpaExtension.js
function () { var bLoaded = sap.ui.getCore().getLoadedLibraries()["sap.ui.support"], deferred = jQueryDOM.Deferred(); if (!bLoaded) { sap.ui.require(["sap/ui/support/Bootstrap"], function (bootstrap) { bootstrap.initSupportRules(["true", "silent"], { onReady: function () { deferred.reso...
javascript
function () { var bLoaded = sap.ui.getCore().getLoadedLibraries()["sap.ui.support"], deferred = jQueryDOM.Deferred(); if (!bLoaded) { sap.ui.require(["sap/ui/support/Bootstrap"], function (bootstrap) { bootstrap.initSupportRules(["true", "silent"], { onReady: function () { deferred.reso...
[ "function", "(", ")", "{", "var", "bLoaded", "=", "sap", ".", "ui", ".", "getCore", "(", ")", ".", "getLoadedLibraries", "(", ")", "[", "\"sap.ui.support\"", "]", ",", "deferred", "=", "jQueryDOM", ".", "Deferred", "(", ")", ";", "if", "(", "!", "bLo...
When the application under test is started in a UIComponent container instead of an iframe the Support Assistant is not loaded because the application doesn't start a separate instance of the Core to start in Support Mode. In such cases manually start the Support Assistant in the current instance of the Core. @returns...
[ "When", "the", "application", "under", "test", "is", "started", "in", "a", "UIComponent", "container", "instead", "of", "an", "iframe", "the", "Support", "Assistant", "is", "not", "loaded", "because", "the", "application", "doesn", "t", "start", "a", "separate...
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/core/support/RuleEngineOpaExtension.js#L45-L62
train
Initializes the support rules
[ 30522, 3853, 1006, 1007, 1063, 13075, 1038, 17468, 1027, 20066, 1012, 21318, 1012, 2131, 17345, 1006, 1007, 1012, 2131, 17468, 29521, 19848, 3111, 1006, 1007, 1031, 1000, 20066, 1012, 21318, 1012, 2490, 1000, 1033, 1010, 13366, 28849, 2094, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
jgraph/mxgraph
javascript/mxClient.js
mxSelectionChange
function mxSelectionChange(selectionModel, added, removed) { this.selectionModel = selectionModel; this.added = (added != null) ? added.slice() : null; this.removed = (removed != null) ? removed.slice() : null; }
javascript
function mxSelectionChange(selectionModel, added, removed) { this.selectionModel = selectionModel; this.added = (added != null) ? added.slice() : null; this.removed = (removed != null) ? removed.slice() : null; }
[ "function", "mxSelectionChange", "(", "selectionModel", ",", "added", ",", "removed", ")", "{", "this", ".", "selectionModel", "=", "selectionModel", ";", "this", ".", "added", "=", "(", "added", "!=", "null", ")", "?", "added", ".", "slice", "(", ")", "...
Class: mxSelectionChange Action to change the current root in a view. Constructor: mxCurrentRootChange Constructs a change of the current root in the given view.
[ "Class", ":", "mxSelectionChange" ]
33911ed7e055c17b74d0367f5f1f6c9ee4b4fd44
https://github.com/jgraph/mxgraph/blob/33911ed7e055c17b74d0367f5f1f6c9ee4b4fd44/javascript/mxClient.js#L46602-L46607
train
This function is called when the selection model changes
[ 30522, 3853, 25630, 11246, 18491, 22305, 2063, 1006, 4989, 5302, 9247, 1010, 2794, 1010, 3718, 1007, 1063, 2023, 1012, 4989, 5302, 9247, 1027, 4989, 5302, 9247, 1025, 2023, 1012, 2794, 1027, 1006, 2794, 999, 1027, 19701, 1007, 1029, 2794, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.documentation/src/sap/ui/documentation/sdk/controller/Code.controller.js
function () { this.oModel = new JSONModel(); this.getView().setModel(this.oModel); this.router = this.getRouter(); this.router.getRoute("code").attachPatternMatched(this.onRouteMatched, this); this.router.getRoute("codeFile").attachPatternMatched(this.onRouteMatched, this); this._codeCache = {...
javascript
function () { this.oModel = new JSONModel(); this.getView().setModel(this.oModel); this.router = this.getRouter(); this.router.getRoute("code").attachPatternMatched(this.onRouteMatched, this); this.router.getRoute("codeFile").attachPatternMatched(this.onRouteMatched, this); this._codeCache = {...
[ "function", "(", ")", "{", "this", ".", "oModel", "=", "new", "JSONModel", "(", ")", ";", "this", ".", "getView", "(", ")", ".", "setModel", "(", "this", ".", "oModel", ")", ";", "this", ".", "router", "=", "this", ".", "getRouter", "(", ")", ";"...
Called when the controller is instantiated. @public
[ "Called", "when", "the", "controller", "is", "instantiated", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.documentation/src/sap/ui/documentation/sdk/controller/Code.controller.js#L23-L35
train
Initializes the model of the data model
[ 30522, 3853, 1006, 1007, 1063, 2023, 1012, 18168, 10244, 2140, 1027, 2047, 1046, 3385, 5302, 9247, 1006, 1007, 1025, 2023, 1012, 2131, 8584, 1006, 1007, 1012, 2275, 5302, 9247, 1006, 2023, 1012, 18168, 10244, 2140, 1007, 1025, 2023, 1012, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/project/FileTreeView.js
function (nextProps, nextState) { return nextProps.forceRender || this.props.contents !== nextProps.contents || this.props.sortDirectoriesFirst !== nextProps.sortDirectoriesFirst || this.props.extensions !== nextProps.extensions; }
javascript
function (nextProps, nextState) { return nextProps.forceRender || this.props.contents !== nextProps.contents || this.props.sortDirectoriesFirst !== nextProps.sortDirectoriesFirst || this.props.extensions !== nextProps.extensions; }
[ "function", "(", "nextProps", ",", "nextState", ")", "{", "return", "nextProps", ".", "forceRender", "||", "this", ".", "props", ".", "contents", "!==", "nextProps", ".", "contents", "||", "this", ".", "props", ".", "sortDirectoriesFirst", "!==", "nextProps", ...
Need to re-render if the sort order or the contents change.
[ "Need", "to", "re", "-", "render", "if", "the", "sort", "order", "or", "the", "contents", "change", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/project/FileTreeView.js#L937-L942
train
Check if the component is different from the current state
[ 30522, 3853, 1006, 2279, 21572, 4523, 1010, 2279, 9153, 2618, 1007, 1063, 2709, 2279, 21572, 4523, 1012, 2486, 7389, 4063, 1064, 1064, 2023, 1012, 24387, 1012, 8417, 999, 1027, 1027, 2279, 21572, 4523, 1012, 8417, 1064, 1064, 2023, 1012, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
firebase/firebase-js-sdk
packages/auth/demo/public/script.js
onSendSignInLinkToEmailCurrentUrl
function onSendSignInLinkToEmailCurrentUrl() { var email = $('#sign-in-with-email-link-email').val(); var actionCodeSettings = { 'url': window.location.href, 'handleCodeInApp': true }; auth.sendSignInLinkToEmail(email, actionCodeSettings).then(function() { if ('localStorage' in window && window['lo...
javascript
function onSendSignInLinkToEmailCurrentUrl() { var email = $('#sign-in-with-email-link-email').val(); var actionCodeSettings = { 'url': window.location.href, 'handleCodeInApp': true }; auth.sendSignInLinkToEmail(email, actionCodeSettings).then(function() { if ('localStorage' in window && window['lo...
[ "function", "onSendSignInLinkToEmailCurrentUrl", "(", ")", "{", "var", "email", "=", "$", "(", "'#sign-in-with-email-link-email'", ")", ".", "val", "(", ")", ";", "var", "actionCodeSettings", "=", "{", "'url'", ":", "window", ".", "location", ".", "href", ",",...
Sends sign in with email link to the user and pass in current url.
[ "Sends", "sign", "in", "with", "email", "link", "to", "the", "user", "and", "pass", "in", "current", "url", "." ]
491598a499813dacc23724de5e237ec220cc560e
https://github.com/firebase/firebase-js-sdk/blob/491598a499813dacc23724de5e237ec220cc560e/packages/auth/demo/public/script.js#L651-L670
train
Send the sign - in link to the current URL
[ 30522, 3853, 2006, 5054, 5104, 23773, 2378, 13767, 3406, 14545, 4014, 10841, 14343, 3372, 3126, 2140, 1006, 1007, 1063, 13075, 10373, 1027, 1002, 1006, 1005, 1001, 3696, 1011, 1999, 1011, 2007, 1011, 10373, 1011, 4957, 1011, 10373, 1005, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/editor/EditorManager.js
_openInlineWidget
function _openInlineWidget(editor, providers, defaultErrorMsg) { PerfUtils.markStart(PerfUtils.INLINE_WIDGET_OPEN); // Run through inline-editor providers until one responds var pos = editor.getCursorPos(), inlinePromise, i, result = new $.Deferred(), ...
javascript
function _openInlineWidget(editor, providers, defaultErrorMsg) { PerfUtils.markStart(PerfUtils.INLINE_WIDGET_OPEN); // Run through inline-editor providers until one responds var pos = editor.getCursorPos(), inlinePromise, i, result = new $.Deferred(), ...
[ "function", "_openInlineWidget", "(", "editor", ",", "providers", ",", "defaultErrorMsg", ")", "{", "PerfUtils", ".", "markStart", "(", "PerfUtils", ".", "INLINE_WIDGET_OPEN", ")", ";", "// Run through inline-editor providers until one responds", "var", "pos", "=", "edi...
@private Finds an inline widget provider from the given list that can offer a widget for the current cursor position, and once the widget has been created inserts it into the editor. @param {!Editor} editor The host editor @param {Array.<{priority:number, provider:function(...)}>} providers prioritized list of provide...
[ "@private", "Finds", "an", "inline", "widget", "provider", "from", "the", "given", "list", "that", "can", "offer", "a", "widget", "for", "the", "current", "cursor", "position", "and", "once", "the", "widget", "has", "been", "created", "inserts", "it", "into"...
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/editor/EditorManager.js#L213-L269
train
Open inline widget
[ 30522, 3853, 1035, 2330, 2378, 4179, 9148, 24291, 1006, 3559, 1010, 11670, 1010, 12398, 2121, 29165, 5244, 2290, 1007, 1063, 2566, 11263, 3775, 4877, 1012, 6017, 7559, 2102, 1006, 2566, 11263, 3775, 4877, 1012, 23881, 1035, 15536, 24291, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ecomfe/zrender
src/graphic/States.js
function (state, subPropKey, key, transitionCfg, done) { var el = this._el; var stateObj = subPropKey ? state[subPropKey] : state; var elObj = subPropKey ? el[subPropKey] : el; var availableProp = stateObj && (key in stateObj) && elObj && (key in elObj); var transiti...
javascript
function (state, subPropKey, key, transitionCfg, done) { var el = this._el; var stateObj = subPropKey ? state[subPropKey] : state; var elObj = subPropKey ? el[subPropKey] : el; var availableProp = stateObj && (key in stateObj) && elObj && (key in elObj); var transiti...
[ "function", "(", "state", ",", "subPropKey", ",", "key", ",", "transitionCfg", ",", "done", ")", "{", "var", "el", "=", "this", ".", "_el", ";", "var", "stateObj", "=", "subPropKey", "?", "state", "[", "subPropKey", "]", ":", "state", ";", "var", "el...
Do transition animation of particular property @param {Object} state @param {string} subPropKey @param {string} key @param {Object} transitionCfg @param {Function} done @private
[ "Do", "transition", "animation", "of", "particular", "property" ]
30321b57cba3149c30eacb0c1e18276f0f001b9f
https://github.com/ecomfe/zrender/blob/30321b57cba3149c30eacb0c1e18276f0f001b9f/src/graphic/States.js#L359-L390
train
transition to state
[ 30522, 3853, 1006, 2110, 1010, 4942, 21572, 2361, 14839, 1010, 3145, 1010, 6653, 2278, 2546, 2290, 1010, 2589, 1007, 1063, 13075, 3449, 1027, 2023, 1012, 1035, 3449, 1025, 13075, 2110, 16429, 3501, 1027, 4942, 21572, 2361, 14839, 1029, 2110...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
uber/deck.gl
modules/aggregation-layers/src/grid-layer/grid-aggregator.js
_pointsToGridHashing
function _pointsToGridHashing(points = [], cellSize, getPosition) { // find the geometric center of sample points let latMin = Infinity; let latMax = -Infinity; let pLat; for (const pt of points) { pLat = getPosition(pt)[1]; if (Number.isFinite(pLat)) { latMin = pLat < latMin ? pLat : latMin; ...
javascript
function _pointsToGridHashing(points = [], cellSize, getPosition) { // find the geometric center of sample points let latMin = Infinity; let latMax = -Infinity; let pLat; for (const pt of points) { pLat = getPosition(pt)[1]; if (Number.isFinite(pLat)) { latMin = pLat < latMin ? pLat : latMin; ...
[ "function", "_pointsToGridHashing", "(", "points", "=", "[", "]", ",", "cellSize", ",", "getPosition", ")", "{", "// find the geometric center of sample points", "let", "latMin", "=", "Infinity", ";", "let", "latMax", "=", "-", "Infinity", ";", "let", "pLat", ";...
Project points into each cell, return a hash table of cells @param {Iterable} points @param {number} cellSize - unit size in meters @param {function} getPosition - position accessor @returns {object} - grid hash and cell dimension
[ "Project", "points", "into", "each", "cell", "return", "a", "hash", "table", "of", "cells" ]
a2010448b7f268bbd03617b812334c68a6b9e5b2
https://github.com/uber/deck.gl/blob/a2010448b7f268bbd03617b812334c68a6b9e5b2/modules/aggregation-layers/src/grid-layer/grid-aggregator.js#L46-L85
train
Calculates the grid hashing of points
[ 30522, 3853, 1035, 2685, 3406, 16523, 3593, 14949, 12053, 1006, 2685, 1027, 1031, 1033, 1010, 4442, 4697, 1010, 2131, 26994, 1007, 1063, 1013, 1013, 2424, 1996, 14965, 2415, 1997, 7099, 2685, 2292, 2474, 21246, 2378, 1027, 15579, 1025, 2292...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/odata/v4/_AnnotationHelperExpression.js
function (oPathValue) { // Note: it is safe to modify the caller's object here oPathValue.asExpression = true; oPathValue.complexBinding = false; return Expression.expression(oPathValue).then(function (oParameter) { return { result : "expression", type : "Edm.Boolean", value : "!" ...
javascript
function (oPathValue) { // Note: it is safe to modify the caller's object here oPathValue.asExpression = true; oPathValue.complexBinding = false; return Expression.expression(oPathValue).then(function (oParameter) { return { result : "expression", type : "Edm.Boolean", value : "!" ...
[ "function", "(", "oPathValue", ")", "{", "// Note: it is safe to modify the caller's object here", "oPathValue", ".", "asExpression", "=", "true", ";", "oPathValue", ".", "complexBinding", "=", "false", ";", "return", "Expression", ".", "expression", "(", "oPathValue", ...
Handling of "14.5.1 Comparison and Logical Operators": <code>edm:Not</code>. @param {object} oPathValue path and value information pointing to the parameter (see Expression object) @returns {sap.ui.base.SyncPromise} a sync promise which resolves with the result object or is rejected with an error
[ "Handling", "of", "14", ".", "5", ".", "1", "Comparison", "and", "Logical", "Operators", ":", "<code", ">", "edm", ":", "Not<", "/", "code", ">", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/odata/v4/_AnnotationHelperExpression.js#L600-L613
train
Returns an object with the type of the expression
[ 30522, 3853, 1006, 6728, 8988, 10175, 5657, 1007, 1063, 1013, 1013, 3602, 1024, 2009, 2003, 3647, 2000, 19933, 1996, 20587, 1005, 1055, 4874, 2182, 6728, 8988, 10175, 5657, 1012, 2004, 10288, 20110, 3258, 1027, 2995, 1025, 6728, 8988, 10175...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
moleculerjs/moleculer
examples/middlewares/index.js
middleware3
function middleware3() { return function mw3(handler) { return async function mw3(ctx) { broker.logger.info(chalk.cyan("mw3 before", ctx.action.name)); //return broker.Promise.resolve("data from mw3"); const res = await handler(ctx); broker.logger.info(chalk.cyan("mw3 after", ctx.action.name)); if (r...
javascript
function middleware3() { return function mw3(handler) { return async function mw3(ctx) { broker.logger.info(chalk.cyan("mw3 before", ctx.action.name)); //return broker.Promise.resolve("data from mw3"); const res = await handler(ctx); broker.logger.info(chalk.cyan("mw3 after", ctx.action.name)); if (r...
[ "function", "middleware3", "(", ")", "{", "return", "function", "mw3", "(", "handler", ")", "{", "return", "async", "function", "mw3", "(", "ctx", ")", "{", "broker", ".", "logger", ".", "info", "(", "chalk", ".", "cyan", "(", "\"mw3 before\"", ",", "c...
Async/await example
[ "Async", "/", "await", "example" ]
f95aadc2d61b0d0e3c643a43c3ed28bca6425cde
https://github.com/moleculerjs/moleculer/blob/f95aadc2d61b0d0e3c643a43c3ed28bca6425cde/examples/middlewares/index.js#L47-L64
train
Middleware for middleware 3
[ 30522, 3853, 2690, 8059, 2509, 1006, 1007, 1063, 2709, 3853, 12464, 2509, 1006, 28213, 1007, 1063, 2709, 2004, 6038, 2278, 3853, 12464, 2509, 1006, 14931, 2595, 1007, 1063, 20138, 1012, 8833, 4590, 1012, 18558, 1006, 16833, 1012, 22330, 231...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
facebook/relay
packages/relay-compiler/core/RelayCompilerError.js
createNonRecoverableUserError
function createNonRecoverableUserError( message: string, locations?: ?$ReadOnlyArray<Location>, nodes?: ?$ReadOnlyArray<ASTNode>, ): NonRecoverableUserError { let messageWithLocations = message; if (locations != null) { const printedLocations = printLocations(locations); messageWithLocations = p...
javascript
function createNonRecoverableUserError( message: string, locations?: ?$ReadOnlyArray<Location>, nodes?: ?$ReadOnlyArray<ASTNode>, ): NonRecoverableUserError { let messageWithLocations = message; if (locations != null) { const printedLocations = printLocations(locations); messageWithLocations = p...
[ "function", "createNonRecoverableUserError", "(", "message", ":", "string", ",", "locations", "?", ":", "?", "$ReadOnlyArray", "<", "Location", ">", ",", "nodes", "?", ":", "?", "$ReadOnlyArray", "<", "ASTNode", ">", ",", ")", ":", "NonRecoverableUserError", "...
Similar to createUserError but for errors that are *not* recoverable: the compiler should not continue to process other inputs because their validity can't be determined.
[ "Similar", "to", "createUserError", "but", "for", "errors", "that", "are", "*", "not", "*", "recoverable", ":", "the", "compiler", "should", "not", "continue", "to", "process", "other", "inputs", "because", "their", "validity", "can", "t", "be", "determined", ...
7fb9be5182b9650637d7b92ead9a42713ac30aa4
https://github.com/facebook/relay/blob/7fb9be5182b9650637d7b92ead9a42713ac30aa4/packages/relay-compiler/core/RelayCompilerError.js#L59-L74
train
Creates a non - recoverable user error.
[ 30522, 3853, 3443, 8540, 2890, 3597, 26061, 3468, 20330, 2121, 29165, 1006, 4471, 1024, 5164, 1010, 5269, 1029, 1024, 1029, 1002, 3191, 2239, 2135, 2906, 9447, 1026, 3295, 1028, 1010, 14164, 1029, 1024, 1029, 1002, 3191, 2239, 2135, 2906, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/thirdparty/sinon-server.js
extend
function extend(target /*, sources */) { var sources = Array.prototype.slice.call(arguments, 1), source, i, prop; for (i = 0; i < sources.length; i++) { source = sources[i]; for (prop in source) { if (source.hasOwnProperty(pro...
javascript
function extend(target /*, sources */) { var sources = Array.prototype.slice.call(arguments, 1), source, i, prop; for (i = 0; i < sources.length; i++) { source = sources[i]; for (prop in source) { if (source.hasOwnProperty(pro...
[ "function", "extend", "(", "target", "/*, sources */", ")", "{", "var", "sources", "=", "Array", ".", "prototype", ".", "slice", ".", "call", "(", "arguments", ",", "1", ")", ",", "source", ",", "i", ",", "prop", ";", "for", "(", "i", "=", "0", ";"...
/* Public: Extend target in place with all (own) properties from sources in-order. Thus, last source will override properties in previous sources. target - The Object to extend sources - Objects to copy properties from. Returns the extended target
[ "/", "*", "Public", ":", "Extend", "target", "in", "place", "with", "all", "(", "own", ")", "properties", "from", "sources", "in", "-", "order", ".", "Thus", "last", "source", "will", "override", "properties", "in", "previous", "sources", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/thirdparty/sinon-server.js#L531-L552
train
Extend target with sources
[ 30522, 3853, 7949, 1006, 4539, 1013, 1008, 1010, 4216, 1008, 1013, 1007, 1063, 13075, 4216, 1027, 9140, 1012, 8773, 1012, 14704, 1012, 2655, 1006, 9918, 1010, 1015, 1007, 1010, 3120, 1010, 1045, 1010, 17678, 1025, 2005, 1006, 1045, 1027, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/LiveDevelopment/LiveDevelopment.js
reconnect
function reconnect() { if (_loadAgentsPromise) { // Agents are already loading, so don't unload return _loadAgentsPromise; } unloadAgents(); // Clear any existing related documents before we reload the agents. // We need to recreate them for the reloaded...
javascript
function reconnect() { if (_loadAgentsPromise) { // Agents are already loading, so don't unload return _loadAgentsPromise; } unloadAgents(); // Clear any existing related documents before we reload the agents. // We need to recreate them for the reloaded...
[ "function", "reconnect", "(", ")", "{", "if", "(", "_loadAgentsPromise", ")", "{", "// Agents are already loading, so don't unload", "return", "_loadAgentsPromise", ";", "}", "unloadAgents", "(", ")", ";", "// Clear any existing related documents before we reload the agents.", ...
Unload and reload agents @return {jQuery.Promise} Resolves once the agents are loaded
[ "Unload", "and", "reload", "agents" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/LiveDevelopment/LiveDevelopment.js#L972-L989
train
Reconnects the agents and reloads the related documents.
[ 30522, 3853, 28667, 18256, 6593, 1006, 1007, 1063, 2065, 1006, 1035, 7170, 4270, 7666, 21572, 28732, 1007, 1063, 1013, 1013, 6074, 2024, 2525, 10578, 1010, 2061, 2123, 1005, 1056, 4895, 11066, 2709, 1035, 7170, 4270, 7666, 21572, 28732, 102...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SeleniumHQ/selenium
third_party/js/mozmill/shared-modules/sessionstore.js
undoClosedTab
function undoClosedTab(controller, event) { var count = sessionStoreService.getClosedTabCount(controller.window); switch (event.type) { case "menu": throw new Error("Menu gets build dynamically and cannot be accessed."); break; case "shortcut": var cmdKey = utils.getEntity(this.getDtds(),...
javascript
function undoClosedTab(controller, event) { var count = sessionStoreService.getClosedTabCount(controller.window); switch (event.type) { case "menu": throw new Error("Menu gets build dynamically and cannot be accessed."); break; case "shortcut": var cmdKey = utils.getEntity(this.getDtds(),...
[ "function", "undoClosedTab", "(", "controller", ",", "event", ")", "{", "var", "count", "=", "sessionStoreService", ".", "getClosedTabCount", "(", "controller", ".", "window", ")", ";", "switch", "(", "event", ".", "type", ")", "{", "case", "\"menu\"", ":", ...
Restores the tab which has been recently closed @param {MozMillController} controller MozMillController of the window to operate on @param {object} event Specifies the event to use to execute the command
[ "Restores", "the", "tab", "which", "has", "been", "recently", "closed" ]
38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd
https://github.com/SeleniumHQ/selenium/blob/38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd/third_party/js/mozmill/shared-modules/sessionstore.js#L259-L279
train
Undo a closed tab
[ 30522, 3853, 25672, 20464, 24768, 2696, 2497, 1006, 11486, 1010, 2724, 1007, 1063, 13075, 4175, 1027, 6521, 19277, 8043, 7903, 2063, 1012, 2131, 20464, 24768, 2696, 9818, 21723, 1006, 11486, 1012, 3332, 1007, 1025, 6942, 1006, 2724, 1012, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ColorlibHQ/AdminLTE
plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.js
getDepth
function getDepth(ancestor, descendant) { var ret = 0; while (descendant !== ancestor) { ret++; descendant = descendant.parentNode; if (!descendant) throw new Error("not a descendant of ancestor!"); } return ret; }
javascript
function getDepth(ancestor, descendant) { var ret = 0; while (descendant !== ancestor) { ret++; descendant = descendant.parentNode; if (!descendant) throw new Error("not a descendant of ancestor!"); } return ret; }
[ "function", "getDepth", "(", "ancestor", ",", "descendant", ")", "{", "var", "ret", "=", "0", ";", "while", "(", "descendant", "!==", "ancestor", ")", "{", "ret", "++", ";", "descendant", "=", "descendant", ".", "parentNode", ";", "if", "(", "!", "desc...
Provides the depth of ``descendant`` relative to ``ancestor``
[ "Provides", "the", "depth", "of", "descendant", "relative", "to", "ancestor" ]
19113c3cbc19a7afe0cfd3158d647064d2d30661
https://github.com/ColorlibHQ/AdminLTE/blob/19113c3cbc19a7afe0cfd3158d647064d2d30661/plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.js#L8719-L8728
train
Get depth of ancestor
[ 30522, 3853, 2131, 3207, 13876, 2232, 1006, 13032, 1010, 12608, 1007, 1063, 13075, 2128, 2102, 1027, 1014, 1025, 2096, 1006, 12608, 999, 1027, 1027, 13032, 1007, 1063, 2128, 2102, 1009, 1009, 1025, 12608, 1027, 12608, 1012, 6687, 3630, 3207...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
lib/jsdoc/ui5/plugin.js
collectShortcuts
function collectShortcuts(body) { function checkAssignment(name, valueNode) { if ( valueNode.type === Syntax.Literal ) { currentModule.localNames[name] = { value: valueNode.value }; debug("compile time constant found ", name, valueNode.value); } else if ( valueNode.type === Syntax.MemberExpression ) ...
javascript
function collectShortcuts(body) { function checkAssignment(name, valueNode) { if ( valueNode.type === Syntax.Literal ) { currentModule.localNames[name] = { value: valueNode.value }; debug("compile time constant found ", name, valueNode.value); } else if ( valueNode.type === Syntax.MemberExpression ) ...
[ "function", "collectShortcuts", "(", "body", ")", "{", "function", "checkAssignment", "(", "name", ",", "valueNode", ")", "{", "if", "(", "valueNode", ".", "type", "===", "Syntax", ".", "Literal", ")", "{", "currentModule", ".", "localNames", "[", "name", ...
Searches the given body for variable declarations that can be evaluated statically, either because they refer to known AMD modukle imports (e.g. shortcut varialbes) or because they have a (design time) constant value. @param {ASTNode} body AST node of a function body that shall be searched for shortcuts
[ "Searches", "the", "given", "body", "for", "variable", "declarations", "that", "can", "be", "evaluated", "statically", "either", "because", "they", "refer", "to", "known", "AMD", "modukle", "imports", "(", "e", ".", "g", ".", "shortcut", "varialbes", ")", "o...
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/lib/jsdoc/ui5/plugin.js#L289-L342
train
collects all the shortcut names
[ 30522, 3853, 17427, 27794, 12690, 2015, 1006, 2303, 1007, 1063, 3853, 4638, 12054, 24838, 1006, 2171, 1010, 3643, 3630, 3207, 1007, 1063, 2065, 1006, 3643, 3630, 3207, 1012, 2828, 1027, 1027, 1027, 20231, 1012, 18204, 1007, 1063, 2783, 5302...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
jgraph/mxgraph
javascript/mxClient.js
function(array, key, defaultValue) { var value = (array != null) ? array[key] : null; if (value == null) { value = defaultValue; } else if (value == mxConstants.NONE) { value = null; } return value; }
javascript
function(array, key, defaultValue) { var value = (array != null) ? array[key] : null; if (value == null) { value = defaultValue; } else if (value == mxConstants.NONE) { value = null; } return value; }
[ "function", "(", "array", ",", "key", ",", "defaultValue", ")", "{", "var", "value", "=", "(", "array", "!=", "null", ")", "?", "array", "[", "key", "]", ":", "null", ";", "if", "(", "value", "==", "null", ")", "{", "value", "=", "defaultValue", ...
Function: getColor Returns the color value for the given key in the given associative array or the given default value if the value is null. If the value is <mxConstants.NONE> then null is returned. Parameters: array - Associative array that contains the value for the key. key - Key whose value should be returned. d...
[ "Function", ":", "getColor" ]
33911ed7e055c17b74d0367f5f1f6c9ee4b4fd44
https://github.com/jgraph/mxgraph/blob/33911ed7e055c17b74d0367f5f1f6c9ee4b4fd44/javascript/mxClient.js#L3826-L3840
train
Returns the value of the specified key in the given array.
[ 30522, 3853, 1006, 9140, 1010, 3145, 1010, 12398, 10175, 5657, 1007, 1063, 13075, 3643, 1027, 1006, 9140, 999, 1027, 19701, 1007, 1029, 9140, 1031, 3145, 1033, 1024, 19701, 1025, 2065, 1006, 3643, 1027, 1027, 19701, 1007, 1063, 3643, 1027, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/material
src/components/menu/js/menuServiceProvider.js
onMenuKeyDown
function onMenuKeyDown(ev) { var handled; switch (ev.keyCode) { case $mdConstant.KEY_CODE.ESCAPE: opts.mdMenuCtrl.close(false, { closeAll: true }); handled = true; break; case $mdConstant.KEY_CODE.TAB: opts.mdMenuCtrl.cl...
javascript
function onMenuKeyDown(ev) { var handled; switch (ev.keyCode) { case $mdConstant.KEY_CODE.ESCAPE: opts.mdMenuCtrl.close(false, { closeAll: true }); handled = true; break; case $mdConstant.KEY_CODE.TAB: opts.mdMenuCtrl.cl...
[ "function", "onMenuKeyDown", "(", "ev", ")", "{", "var", "handled", ";", "switch", "(", "ev", ".", "keyCode", ")", "{", "case", "$mdConstant", ".", "KEY_CODE", ".", "ESCAPE", ":", "opts", ".", "mdMenuCtrl", ".", "close", "(", "false", ",", "{", "closeA...
************************************ internal functions ************************************
[ "************************************", "internal", "functions", "************************************" ]
84ac558674e73958be84312444c48d9f823f6684
https://github.com/angular/material/blob/84ac558674e73958be84312444c48d9f823f6684/src/components/menu/js/menuServiceProvider.js#L288-L335
train
A keydown event handler for the menu
[ 30522, 3853, 2006, 3549, 15851, 25688, 12384, 1006, 23408, 1007, 1063, 13075, 8971, 1025, 6942, 1006, 23408, 1012, 3145, 16044, 1007, 1063, 2553, 1002, 9108, 8663, 12693, 2102, 1012, 3145, 1035, 3642, 1012, 4019, 1024, 23569, 2015, 1012, 91...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/file/FileUtils.js
getFilenameWithoutExtension
function getFilenameWithoutExtension(filename) { var index = filename.lastIndexOf("."); return index === -1 ? filename : filename.slice(0, index); }
javascript
function getFilenameWithoutExtension(filename) { var index = filename.lastIndexOf("."); return index === -1 ? filename : filename.slice(0, index); }
[ "function", "getFilenameWithoutExtension", "(", "filename", ")", "{", "var", "index", "=", "filename", ".", "lastIndexOf", "(", "\".\"", ")", ";", "return", "index", "===", "-", "1", "?", "filename", ":", "filename", ".", "slice", "(", "0", ",", "index", ...
Get the file name without the extension. Returns "" if name starts with "." @param {string} filename File name of a file or directory, without preceding path @return {string} Returns the file name without the extension
[ "Get", "the", "file", "name", "without", "the", "extension", ".", "Returns", "if", "name", "starts", "with", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/file/FileUtils.js#L428-L431
train
Returns the filename without the last.
[ 30522, 3853, 2131, 8873, 20844, 4168, 24415, 5833, 10288, 29048, 1006, 5371, 18442, 1007, 1063, 13075, 5950, 1027, 5371, 18442, 1012, 2197, 22254, 10288, 11253, 1006, 1000, 1012, 1000, 1007, 1025, 2709, 5950, 1027, 1027, 1027, 1011, 1015, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
vuejs/vue-devtools
src/backend/index.js
processObservables
function processObservables (instance) { var obs = instance.$observables if (obs) { return Object.keys(obs).map(key => { return { type: 'observables', key, value: instance[key] } }) } else { return [] } }
javascript
function processObservables (instance) { var obs = instance.$observables if (obs) { return Object.keys(obs).map(key => { return { type: 'observables', key, value: instance[key] } }) } else { return [] } }
[ "function", "processObservables", "(", "instance", ")", "{", "var", "obs", "=", "instance", ".", "$observables", "if", "(", "obs", ")", "{", "return", "Object", ".", "keys", "(", "obs", ")", ".", "map", "(", "key", "=>", "{", "return", "{", "type", "...
Process vue-rx observable bindings. @param {Vue} instance @return {Array}
[ "Process", "vue", "-", "rx", "observable", "bindings", "." ]
4de4b86388453cd07f0c1bf967d43a4dd4b011c9
https://github.com/vuejs/vue-devtools/blob/4de4b86388453cd07f0c1bf967d43a4dd4b011c9/src/backend/index.js#L864-L877
train
Process the observers of an instance
[ 30522, 3853, 2832, 16429, 8043, 12423, 2015, 1006, 6013, 1007, 1063, 13075, 27885, 2015, 1027, 6013, 1012, 1002, 27885, 8043, 12423, 2015, 2065, 1006, 27885, 2015, 1007, 1063, 2709, 4874, 1012, 6309, 1006, 27885, 2015, 1007, 1012, 4949, 100...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Dogfalo/materialize
dist/js/materialize.js
Range
function Range(el, options) { _classCallCheck(this, Range); var _this72 = _possibleConstructorReturn(this, (Range.__proto__ || Object.getPrototypeOf(Range)).call(this, Range, el, options)); _this72.el.M_Range = _this72; /** * Options for the range * @member Range#options ...
javascript
function Range(el, options) { _classCallCheck(this, Range); var _this72 = _possibleConstructorReturn(this, (Range.__proto__ || Object.getPrototypeOf(Range)).call(this, Range, el, options)); _this72.el.M_Range = _this72; /** * Options for the range * @member Range#options ...
[ "function", "Range", "(", "el", ",", "options", ")", "{", "_classCallCheck", "(", "this", ",", "Range", ")", ";", "var", "_this72", "=", "_possibleConstructorReturn", "(", "this", ",", "(", "Range", ".", "__proto__", "||", "Object", ".", "getPrototypeOf", ...
Construct Range instance @constructor @param {Element} el @param {Object} options
[ "Construct", "Range", "instance" ]
1122efadad8f1433d404696f7613e3cc13fb83a4
https://github.com/Dogfalo/materialize/blob/1122efadad8f1433d404696f7613e3cc13fb83a4/dist/js/materialize.js#L12094-L12114
train
Construct a new Range instance
[ 30522, 3853, 2846, 1006, 3449, 1010, 7047, 1007, 1063, 1035, 2465, 9289, 29358, 11012, 1006, 2023, 1010, 2846, 1007, 1025, 13075, 1035, 2023, 2581, 2475, 1027, 1035, 2825, 8663, 3367, 6820, 16761, 13465, 14287, 1006, 2023, 1010, 1006, 2846,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/qunit/utils/ControlIterator.js
function(aControls, aControlsToTest, aExcludedControls, bIncludeNonRenderable, bIncludeNonInstantiable, fnCallback) { return new Promise(function(resolve, reject){ var iControlCountInLib = 0; var loop = function(i) { if (i < aControls.length) { var sControlName = aControls[i]; handleControl(sCon...
javascript
function(aControls, aControlsToTest, aExcludedControls, bIncludeNonRenderable, bIncludeNonInstantiable, fnCallback) { return new Promise(function(resolve, reject){ var iControlCountInLib = 0; var loop = function(i) { if (i < aControls.length) { var sControlName = aControls[i]; handleControl(sCon...
[ "function", "(", "aControls", ",", "aControlsToTest", ",", "aExcludedControls", ",", "bIncludeNonRenderable", ",", "bIncludeNonInstantiable", ",", "fnCallback", ")", "{", "return", "new", "Promise", "(", "function", "(", "resolve", ",", "reject", ")", "{", "var", ...
Calls the callback function for all controls in the given array, unless they are explicitly excluded
[ "Calls", "the", "callback", "function", "for", "all", "controls", "in", "the", "given", "array", "unless", "they", "are", "explicitly", "excluded" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/qunit/utils/ControlIterator.js#L380-L401
train
Handle control names
[ 30522, 3853, 1006, 9353, 12162, 13153, 2015, 1010, 9353, 12162, 13153, 16033, 22199, 1010, 29347, 2595, 20464, 13936, 8663, 13181, 4877, 1010, 8026, 20464, 12672, 8540, 7389, 4063, 3085, 1010, 8026, 20464, 12672, 8540, 7076, 5794, 10711, 3468...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
getinsomnia/insomnia
packages/insomnia-importers/src/importers/openapi3.js
importFolderItem
function importFolderItem(item, parentId) { return { parentId, _id: `__GRP_${requestGroupCount++}__`, _type: 'request_group', name: item.name || `Folder {requestGroupCount}`, description: item.description || '', }; }
javascript
function importFolderItem(item, parentId) { return { parentId, _id: `__GRP_${requestGroupCount++}__`, _type: 'request_group', name: item.name || `Folder {requestGroupCount}`, description: item.description || '', }; }
[ "function", "importFolderItem", "(", "item", ",", "parentId", ")", "{", "return", "{", "parentId", ",", "_id", ":", "`", "${", "requestGroupCount", "++", "}", "`", ",", "_type", ":", "'request_group'", ",", "name", ":", "item", ".", "name", "||", "`", ...
Return Insomnia folder / request group @param {Object} item - OpenAPI 3 endpoint schema @param {string} parentId - id of parent category @returns {Object}
[ "Return", "Insomnia", "folder", "/", "request", "group" ]
e24ce7f7b41246e700c4b9bdb6b34b6652ad589b
https://github.com/getinsomnia/insomnia/blob/e24ce7f7b41246e700c4b9bdb6b34b6652ad589b/packages/insomnia-importers/src/importers/openapi3.js#L144-L152
train
Import a folder item into a request group
[ 30522, 3853, 12324, 10371, 11124, 18532, 1006, 8875, 1010, 6687, 3593, 1007, 1063, 2709, 1063, 6687, 3593, 1010, 1035, 8909, 1024, 1036, 1035, 1035, 24665, 2361, 1035, 1002, 1063, 5227, 17058, 3597, 16671, 1009, 1009, 1065, 1035, 1035, 1036...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
TryGhost/Ghost
core/server/models/base/index.js
generateSlug
function generateSlug(Model, base, options) { var slug, slugTryCount = 1, baseName = Model.prototype.tableName.replace(/s$/, ''), // Look for a matching slug, append an incrementing number if so checkIfSlugExists, longSlug; checkIfSlugExists = function ch...
javascript
function generateSlug(Model, base, options) { var slug, slugTryCount = 1, baseName = Model.prototype.tableName.replace(/s$/, ''), // Look for a matching slug, append an incrementing number if so checkIfSlugExists, longSlug; checkIfSlugExists = function ch...
[ "function", "generateSlug", "(", "Model", ",", "base", ",", "options", ")", "{", "var", "slug", ",", "slugTryCount", "=", "1", ",", "baseName", "=", "Model", ".", "prototype", ".", "tableName", ".", "replace", "(", "/", "s$", "/", ",", "''", ")", ","...
### Generate Slug Create a string to act as the permalink for an object. @param {ghostBookshelf.Model} Model Model type to generate a slug for @param {String} base The string for which to generate a slug, usually a title or name @param {Object} options Options to pass to findOne @return {Promise(String)} Resolves to a ...
[ "###", "Generate", "Slug", "Create", "a", "string", "to", "act", "as", "the", "permalink", "for", "an", "object", "." ]
bb7bb55cf3e60af99ebbc56099928827b58461bc
https://github.com/TryGhost/Ghost/blob/bb7bb55cf3e60af99ebbc56099928827b58461bc/core/server/models/base/index.js#L1039-L1123
train
Generate a slug for a model
[ 30522, 3853, 19421, 7630, 2290, 1006, 2944, 1010, 2918, 1010, 7047, 1007, 1063, 13075, 23667, 1010, 23667, 11129, 3597, 16671, 1027, 1015, 1010, 2918, 18442, 1027, 2944, 1012, 8773, 1012, 2795, 18442, 1012, 5672, 1006, 1013, 1055, 1002, 101...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
TryGhost/Ghost
core/server/data/schema/commands.js
createTable
function createTable(table, transaction) { return (transaction || db.knex).schema.hasTable(table) .then(function (exists) { if (exists) { return; } return (transaction || db.knex).schema.createTable(table, function (t) { var columnKeys = _...
javascript
function createTable(table, transaction) { return (transaction || db.knex).schema.hasTable(table) .then(function (exists) { if (exists) { return; } return (transaction || db.knex).schema.createTable(table, function (t) { var columnKeys = _...
[ "function", "createTable", "(", "table", ",", "transaction", ")", "{", "return", "(", "transaction", "||", "db", ".", "knex", ")", ".", "schema", ".", "hasTable", "(", "table", ")", ".", "then", "(", "function", "(", "exists", ")", "{", "if", "(", "e...
https://github.com/tgriesser/knex/issues/1303 createTableIfNotExists can throw error if indexes are already in place
[ "https", ":", "//", "github", ".", "com", "/", "tgriesser", "/", "knex", "/", "issues", "/", "1303", "createTableIfNotExists", "can", "throw", "error", "if", "indexes", "are", "already", "in", "place" ]
bb7bb55cf3e60af99ebbc56099928827b58461bc
https://github.com/TryGhost/Ghost/blob/bb7bb55cf3e60af99ebbc56099928827b58461bc/core/server/data/schema/commands.js#L79-L93
train
create table if not exists
[ 30522, 3853, 3443, 10880, 1006, 2795, 1010, 12598, 1007, 1063, 2709, 1006, 12598, 1064, 1064, 16962, 1012, 14161, 10288, 1007, 1012, 8040, 28433, 1012, 2038, 10880, 1006, 2795, 1007, 1012, 2059, 1006, 3853, 1006, 6526, 1007, 1063, 2065, 100...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ReactiveX/rxjs
.make-helpers.js
createImportTargets
function createImportTargets(importTargets, targetName, targetDirectory) { const importMap = {}; for (const x in importTargets) { importMap['rxjs/' + x] = ('rxjs-compat/' + targetName + importTargets[x]).replace(/\.js$/, ''); } const outputData = ` "use strict" var path = require('path'); var dir = path.r...
javascript
function createImportTargets(importTargets, targetName, targetDirectory) { const importMap = {}; for (const x in importTargets) { importMap['rxjs/' + x] = ('rxjs-compat/' + targetName + importTargets[x]).replace(/\.js$/, ''); } const outputData = ` "use strict" var path = require('path'); var dir = path.r...
[ "function", "createImportTargets", "(", "importTargets", ",", "targetName", ",", "targetDirectory", ")", "{", "const", "importMap", "=", "{", "}", ";", "for", "(", "const", "x", "in", "importTargets", ")", "{", "importMap", "[", "'rxjs/'", "+", "x", "]", "...
Create a file that exports the importTargets object
[ "Create", "a", "file", "that", "exports", "the", "importTargets", "object" ]
1037a1d1e6b80c7218e7ffdf8c0d96a612653a4f
https://github.com/ReactiveX/rxjs/blob/1037a1d1e6b80c7218e7ffdf8c0d96a612653a4f/.make-helpers.js#L40-L59
train
Creates the importTargets object
[ 30522, 3853, 3443, 5714, 6442, 7559, 18150, 2015, 1006, 12324, 7559, 18150, 2015, 1010, 4539, 18442, 1010, 4539, 4305, 2890, 16761, 2100, 1007, 1063, 9530, 3367, 12324, 2863, 2361, 1027, 1063, 1065, 1025, 2005, 1006, 9530, 3367, 1060, 1999,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
postcss/autoprefixer
data/prefixes.js
f
function f (data, opts, callback) { data = unpack(data) if (!callback) { [callback, opts] = [opts, {}] } let match = opts.match || /\sx($|\s)/ let need = [] for (let browser in data.stats) { let versions = data.stats[browser] for (let version in versions) { let support = versions[versio...
javascript
function f (data, opts, callback) { data = unpack(data) if (!callback) { [callback, opts] = [opts, {}] } let match = opts.match || /\sx($|\s)/ let need = [] for (let browser in data.stats) { let versions = data.stats[browser] for (let version in versions) { let support = versions[versio...
[ "function", "f", "(", "data", ",", "opts", ",", "callback", ")", "{", "data", "=", "unpack", "(", "data", ")", "if", "(", "!", "callback", ")", "{", "[", "callback", ",", "opts", "]", "=", "[", "opts", ",", "{", "}", "]", "}", "let", "match", ...
Convert Can I Use data
[ "Convert", "Can", "I", "Use", "data" ]
24b28b6dbdc34a5e5800986e76f48cbaf9bbbc32
https://github.com/postcss/autoprefixer/blob/24b28b6dbdc34a5e5800986e76f48cbaf9bbbc32/data/prefixes.js#L18-L39
train
returns an array of all the browsers that are not supported by the specified filter
[ 30522, 3853, 1042, 1006, 2951, 1010, 23569, 2015, 1010, 2655, 5963, 1007, 1063, 2951, 1027, 4895, 23947, 1006, 2951, 1007, 2065, 1006, 999, 2655, 5963, 1007, 1063, 1031, 2655, 5963, 1010, 23569, 2015, 1033, 1027, 1031, 23569, 2015, 1010, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
apache/incubator-echarts
src/component/timeline/SliderTimelineView.js
giveSymbol
function giveSymbol(hostModel, itemStyleModel, group, opt, symbol, callback) { var color = itemStyleModel.get('color'); if (!symbol) { var symbolType = hostModel.get('symbol'); symbol = createSymbol(symbolType, -1, -1, 2, 2, color); symbol.setStyle('strokeNoScale', true); group....
javascript
function giveSymbol(hostModel, itemStyleModel, group, opt, symbol, callback) { var color = itemStyleModel.get('color'); if (!symbol) { var symbolType = hostModel.get('symbol'); symbol = createSymbol(symbolType, -1, -1, 2, 2, color); symbol.setStyle('strokeNoScale', true); group....
[ "function", "giveSymbol", "(", "hostModel", ",", "itemStyleModel", ",", "group", ",", "opt", ",", "symbol", ",", "callback", ")", "{", "var", "color", "=", "itemStyleModel", ".", "get", "(", "'color'", ")", ";", "if", "(", "!", "symbol", ")", "{", "var...
Create symbol or update symbol opt: basic position and event handlers
[ "Create", "symbol", "or", "update", "symbol", "opt", ":", "basic", "position", "and", "event", "handlers" ]
4d0ea095dc3929cb6de40c45748826e7999c7aa8
https://github.com/apache/incubator-echarts/blob/4d0ea095dc3929cb6de40c45748826e7999c7aa8/src/component/timeline/SliderTimelineView.js#L635-L690
train
This function is called by the symbol layer when the symbol is not found in the host model.
[ 30522, 3853, 3957, 24335, 14956, 1006, 3677, 5302, 9247, 1010, 5167, 27983, 5302, 9247, 1010, 2177, 1010, 23569, 1010, 6454, 1010, 2655, 5963, 1007, 1063, 13075, 3609, 1027, 5167, 27983, 5302, 9247, 1012, 2131, 1006, 1005, 3609, 1005, 1007,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
TryGhost/Ghost
core/server/api/v0.1/roles.js
modelQuery
function modelQuery(options) { return models.Role.findAll(options) .then((models) => { let roles = models.map((role) => { return role.toJSON(); }); if (options.permissions !== 'assign') { ...
javascript
function modelQuery(options) { return models.Role.findAll(options) .then((models) => { let roles = models.map((role) => { return role.toJSON(); }); if (options.permissions !== 'assign') { ...
[ "function", "modelQuery", "(", "options", ")", "{", "return", "models", ".", "Role", ".", "findAll", "(", "options", ")", ".", "then", "(", "(", "models", ")", "=>", "{", "let", "roles", "=", "models", ".", "map", "(", "(", "role", ")", "=>", "{", ...
### Model Query Make the call to the Model layer @param {Object} options @returns {Object} options
[ "###", "Model", "Query", "Make", "the", "call", "to", "the", "Model", "layer" ]
bb7bb55cf3e60af99ebbc56099928827b58461bc
https://github.com/TryGhost/Ghost/blob/bb7bb55cf3e60af99ebbc56099928827b58461bc/core/server/api/v0.1/roles.js#L41-L64
train
Returns a model query
[ 30522, 3853, 2944, 4226, 2854, 1006, 7047, 1007, 1063, 2709, 4275, 1012, 2535, 1012, 2424, 8095, 1006, 7047, 1007, 1012, 2059, 1006, 1006, 4275, 1007, 1027, 1028, 1063, 2292, 4395, 1027, 4275, 1012, 4949, 1006, 1006, 2535, 1007, 1027, 102...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.commons/src/sap/ui/commons/RoadMapRenderer.js
function(oRoadMap){ var iRTLFactor = getRTLFactor(); var jStepArea = oRoadMap.$("steparea"); var iScrollLeft = getScrollLeft(jStepArea); var jStartDelim = oRoadMap.$("Start"); jStartDelim.removeClass("sapUiRoadMapStartScroll").removeClass("sapUiRoadMapStartFixed"); jStartDelim.addClass(iRTLFactor * iScro...
javascript
function(oRoadMap){ var iRTLFactor = getRTLFactor(); var jStepArea = oRoadMap.$("steparea"); var iScrollLeft = getScrollLeft(jStepArea); var jStartDelim = oRoadMap.$("Start"); jStartDelim.removeClass("sapUiRoadMapStartScroll").removeClass("sapUiRoadMapStartFixed"); jStartDelim.addClass(iRTLFactor * iScro...
[ "function", "(", "oRoadMap", ")", "{", "var", "iRTLFactor", "=", "getRTLFactor", "(", ")", ";", "var", "jStepArea", "=", "oRoadMap", ".", "$", "(", "\"steparea\"", ")", ";", "var", "iScrollLeft", "=", "getScrollLeft", "(", "jStepArea", ")", ";", "var", "...
Refreshs the delimiters according to the current scroll state
[ "Refreshs", "the", "delimiters", "according", "to", "the", "current", "scroll", "state" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.commons/src/sap/ui/commons/RoadMapRenderer.js#L779-L794
train
Updates the end delimiter class
[ 30522, 3853, 1006, 20298, 4215, 2863, 2361, 1007, 1063, 13075, 20868, 19646, 7011, 16761, 1027, 2131, 5339, 10270, 18908, 2953, 1006, 1007, 1025, 13075, 1046, 13473, 19362, 5243, 1027, 20298, 4215, 2863, 2361, 1012, 1002, 1006, 1000, 3357, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
apache/incubator-echarts
src/component/marker/markerHelper.js
markerTypeCalculatorWithExtent
function markerTypeCalculatorWithExtent( mlType, data, otherDataDim, targetDataDim, otherCoordIndex, targetCoordIndex ) { var coordArr = []; var stacked = isDimensionStacked(data, targetDataDim /*, otherDataDim*/); var calcDataDim = stacked ? data.getCalculationInfo('stackResultDimension') ...
javascript
function markerTypeCalculatorWithExtent( mlType, data, otherDataDim, targetDataDim, otherCoordIndex, targetCoordIndex ) { var coordArr = []; var stacked = isDimensionStacked(data, targetDataDim /*, otherDataDim*/); var calcDataDim = stacked ? data.getCalculationInfo('stackResultDimension') ...
[ "function", "markerTypeCalculatorWithExtent", "(", "mlType", ",", "data", ",", "otherDataDim", ",", "targetDataDim", ",", "otherCoordIndex", ",", "targetCoordIndex", ")", "{", "var", "coordArr", "=", "[", "]", ";", "var", "stacked", "=", "isDimensionStacked", "(",...
return precision; }
[ "return", "precision", ";", "}" ]
4d0ea095dc3929cb6de40c45748826e7999c7aa8
https://github.com/apache/incubator-echarts/blob/4d0ea095dc3929cb6de40c45748826e7999c7aa8/src/component/marker/markerHelper.js#L58-L82
train
Returns an array of coordArr with the data for the given marker type
[ 30522, 3853, 12115, 13874, 9289, 19879, 4263, 24415, 10288, 6528, 2102, 1006, 19875, 13874, 1010, 2951, 1010, 2060, 2850, 17713, 5714, 1010, 4539, 2850, 17713, 5714, 1010, 2060, 3597, 8551, 22254, 10288, 1010, 4539, 3597, 8551, 22254, 10288, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
PrismJS/prism
scripts/utopia.js
function (element, contents, where) { if(contents || contents === 0) { if (_.type(contents) !== 'array') { contents = [contents]; } var firstChild = element.firstChild; for (var i=0; i<contents.length; i++) { var content = contents[i], child; switch(_.type(content)) { ...
javascript
function (element, contents, where) { if(contents || contents === 0) { if (_.type(contents) !== 'array') { contents = [contents]; } var firstChild = element.firstChild; for (var i=0; i<contents.length; i++) { var content = contents[i], child; switch(_.type(content)) { ...
[ "function", "(", "element", ",", "contents", ",", "where", ")", "{", "if", "(", "contents", "||", "contents", "===", "0", ")", "{", "if", "(", "_", ".", "type", "(", "contents", ")", "!==", "'array'", ")", "{", "contents", "=", "[", "contents", "]"...
Sets an element’s contents Contents could be: One or multiple (as an array) of the following: - An object literal that will be passed through Utopia.element.create - A string or number, which will become a text node - An existing DOM element
[ "Sets", "an", "element’s", "contents", "Contents", "could", "be", ":", "One", "or", "multiple", "(", "as", "an", "array", ")", "of", "the", "following", ":", "-", "An", "object", "literal", "that", "will", "be", "passed", "through", "Utopia", ".", "eleme...
acceb3b56f0e8362a7ef274dbd85b17611df2ec4
https://github.com/PrismJS/prism/blob/acceb3b56f0e8362a7ef274dbd85b17611df2ec4/scripts/utopia.js#L259-L299
train
Creates an element with contents
[ 30522, 3853, 1006, 5783, 1010, 8417, 1010, 2073, 1007, 1063, 2065, 1006, 8417, 1064, 1064, 8417, 1027, 1027, 1027, 1014, 1007, 1063, 2065, 1006, 1035, 1012, 2828, 1006, 8417, 1007, 999, 1027, 1027, 1005, 9140, 1005, 1007, 1063, 8417, 1027...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
chartjs/Chart.js
src/core/core.plugins.js
function(plugins) { var p = this._plugins; ([]).concat(plugins).forEach(function(plugin) { if (p.indexOf(plugin) === -1) { p.push(plugin); } }); this._cacheId++; }
javascript
function(plugins) { var p = this._plugins; ([]).concat(plugins).forEach(function(plugin) { if (p.indexOf(plugin) === -1) { p.push(plugin); } }); this._cacheId++; }
[ "function", "(", "plugins", ")", "{", "var", "p", "=", "this", ".", "_plugins", ";", "(", "[", "]", ")", ".", "concat", "(", "plugins", ")", ".", "forEach", "(", "function", "(", "plugin", ")", "{", "if", "(", "p", ".", "indexOf", "(", "plugin", ...
Registers the given plugin(s) if not already registered. @param {IPlugin[]|IPlugin} plugins plugin instance(s).
[ "Registers", "the", "given", "plugin", "(", "s", ")", "if", "not", "already", "registered", "." ]
f093c36574d290330ed623e60fbd070421c730d5
https://github.com/chartjs/Chart.js/blob/f093c36574d290330ed623e60fbd070421c730d5/src/core/core.plugins.js#L34-L43
train
Add a list of plugins to the cache
[ 30522, 3853, 1006, 13354, 7076, 1007, 1063, 13075, 1052, 1027, 2023, 1012, 1035, 13354, 7076, 1025, 1006, 1031, 1033, 1007, 1012, 9530, 11266, 1006, 13354, 7076, 1007, 1012, 18921, 6776, 1006, 3853, 1006, 13354, 2378, 1007, 1063, 2065, 1006...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/ui5loader.js
findMapForContext
function findMapForContext(sContext) { var p, mMap; if ( sContext != null ) { // maps are defined on module IDs, reduce URN to module ID sContext = urnToIDAndType(sContext).id; p = sContext.length; mMap = mMaps[sContext]; while ( p > 0 && mMap == null ) { p = sContext.lastIndexOf('/'); if ( p...
javascript
function findMapForContext(sContext) { var p, mMap; if ( sContext != null ) { // maps are defined on module IDs, reduce URN to module ID sContext = urnToIDAndType(sContext).id; p = sContext.length; mMap = mMaps[sContext]; while ( p > 0 && mMap == null ) { p = sContext.lastIndexOf('/'); if ( p...
[ "function", "findMapForContext", "(", "sContext", ")", "{", "var", "p", ",", "mMap", ";", "if", "(", "sContext", "!=", "null", ")", "{", "// maps are defined on module IDs, reduce URN to module ID", "sContext", "=", "urnToIDAndType", "(", "sContext", ")", ".", "id...
Find the most specific map config that matches the given context resource @param {string} sContext Resource name to be used as context @returns {Object<string,string>|undefined} Most specific map or <code>undefined</code>
[ "Find", "the", "most", "specific", "map", "config", "that", "matches", "the", "given", "context", "resource" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/ui5loader.js#L603-L620
train
Find the map for the given context
[ 30522, 3853, 2424, 2863, 14376, 2953, 8663, 18209, 1006, 8040, 28040, 18413, 1007, 1063, 13075, 1052, 1010, 21021, 2361, 1025, 2065, 1006, 8040, 28040, 18413, 999, 1027, 19701, 1007, 1063, 1013, 1013, 7341, 2024, 4225, 2006, 11336, 8909, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/base/SyncPromise.js
resolve
function resolve(vResult0) { var fnThen; if (vResult0 === that) { reject(new TypeError("A promise cannot be resolved with itself.")); return; } if (vResult0 instanceof SyncPromise) { if (vResult0.isFulfilled()) { resolve(vResult0.getResult()); return; } else if (vResult0.isRejecte...
javascript
function resolve(vResult0) { var fnThen; if (vResult0 === that) { reject(new TypeError("A promise cannot be resolved with itself.")); return; } if (vResult0 instanceof SyncPromise) { if (vResult0.isFulfilled()) { resolve(vResult0.getResult()); return; } else if (vResult0.isRejecte...
[ "function", "resolve", "(", "vResult0", ")", "{", "var", "fnThen", ";", "if", "(", "vResult0", "===", "that", ")", "{", "reject", "(", "new", "TypeError", "(", "\"A promise cannot be resolved with itself.\"", ")", ")", ";", "return", ";", "}", "if", "(", "...
/* @param {any} [vResult0] The thenable to wrap or the result to synchronously fulfill with
[ "/", "*" ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/base/SyncPromise.js#L122-L164
train
Resolve a promise
[ 30522, 3853, 10663, 1006, 27830, 2229, 11314, 2692, 1007, 1063, 13075, 1042, 3372, 10222, 1025, 2065, 1006, 27830, 2229, 11314, 2692, 1027, 1027, 1027, 2008, 1007, 1063, 15454, 1006, 2047, 2828, 2121, 29165, 1006, 1000, 1037, 4872, 3685, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
transloadit/uppy
packages/@uppy/companion/src/server/controllers/s3.js
abortMultipartUpload
function abortMultipartUpload (req, res, next) { // @ts-ignore The `uppy` property is added by middleware before reaching here. const client = req.uppy.s3Client const { uploadId } = req.params const { key } = req.query if (typeof key !== 'string') { return res.status(400).json({ error: 's3: t...
javascript
function abortMultipartUpload (req, res, next) { // @ts-ignore The `uppy` property is added by middleware before reaching here. const client = req.uppy.s3Client const { uploadId } = req.params const { key } = req.query if (typeof key !== 'string') { return res.status(400).json({ error: 's3: t...
[ "function", "abortMultipartUpload", "(", "req", ",", "res", ",", "next", ")", "{", "// @ts-ignore The `uppy` property is added by middleware before reaching here.", "const", "client", "=", "req", ".", "uppy", ".", "s3Client", "const", "{", "uploadId", "}", "=", "req",...
Abort a multipart upload, deleting already uploaded parts. Expected URL parameters: - uploadId - The uploadId returned from `createMultipartUpload`. Expected query parameters: - key - The object key in the S3 bucket. Response JSON: Empty.
[ "Abort", "a", "multipart", "upload", "deleting", "already", "uploaded", "parts", "." ]
7ae18bf992d544a64da998f033258ec09a3de275
https://github.com/transloadit/uppy/blob/7ae18bf992d544a64da998f033258ec09a3de275/packages/@uppy/companion/src/server/controllers/s3.js#L204-L225
train
Aborts a multipart upload
[ 30522, 3853, 11113, 11589, 12274, 7096, 11514, 8445, 6279, 11066, 1006, 2128, 4160, 1010, 24501, 1010, 2279, 1007, 1063, 1013, 1013, 1030, 24529, 1011, 8568, 1996, 1036, 2039, 7685, 1036, 3200, 2003, 2794, 2011, 2690, 8059, 2077, 4285, 2182...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
expressjs/express
examples/view-locals/index.js
count2
function count2(req, res, next) { User.count(function(err, count){ if (err) return next(err); res.locals.count = count; next(); }) }
javascript
function count2(req, res, next) { User.count(function(err, count){ if (err) return next(err); res.locals.count = count; next(); }) }
[ "function", "count2", "(", "req", ",", "res", ",", "next", ")", "{", "User", ".", "count", "(", "function", "(", "err", ",", "count", ")", "{", "if", "(", "err", ")", "return", "next", "(", "err", ")", ";", "res", ".", "locals", ".", "count", "...
this approach is much like the last however we're explicitly exposing the locals within each middleware note that this may not always work well, for example here we filter the users in the middleware, which may not be ideal for our application. so in that sense the previous example is more flexible with `req.users`.
[ "this", "approach", "is", "much", "like", "the", "last", "however", "we", "re", "explicitly", "exposing", "the", "locals", "within", "each", "middleware", "note", "that", "this", "may", "not", "always", "work", "well", "for", "example", "here", "we", "filter...
dc538f6e810bd462c98ee7e6aae24c64d4b1da93
https://github.com/expressjs/express/blob/dc538f6e810bd462c98ee7e6aae24c64d4b1da93/examples/view-locals/index.js#L84-L90
train
This is the function that is called when the user is not logged in
[ 30522, 3853, 4175, 2475, 1006, 2128, 4160, 1010, 24501, 1010, 2279, 1007, 1063, 5310, 1012, 4175, 1006, 3853, 1006, 9413, 2099, 1010, 4175, 1007, 1063, 2065, 1006, 9413, 2099, 1007, 2709, 2279, 1006, 9413, 2099, 1007, 1025, 24501, 1012, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
jgraph/mxgraph
javascript/mxClient.js
mxPanningHandler
function mxPanningHandler(graph) { if (graph != null) { this.graph = graph; this.graph.addMouseListener(this); // Handles force panning event this.forcePanningHandler = mxUtils.bind(this, function(sender, evt) { var evtName = evt.getProperty('eventName'); var me = evt.getProperty('event'); if ...
javascript
function mxPanningHandler(graph) { if (graph != null) { this.graph = graph; this.graph.addMouseListener(this); // Handles force panning event this.forcePanningHandler = mxUtils.bind(this, function(sender, evt) { var evtName = evt.getProperty('eventName'); var me = evt.getProperty('event'); if ...
[ "function", "mxPanningHandler", "(", "graph", ")", "{", "if", "(", "graph", "!=", "null", ")", "{", "this", ".", "graph", "=", "graph", ";", "this", ".", "graph", ".", "addMouseListener", "(", "this", ")", ";", "// Handles force panning event", "this", "."...
Copyright (c) 2006-2015, JGraph Ltd Copyright (c) 2006-2015, Gaudenz Alder Class: mxPanningHandler Event handler that pans and creates popupmenus. To use the left mousebutton for panning without interfering with cell moving and resizing, use <isUseLeftButton> and <isIgnoreCell>. For grid size steps while panning, us...
[ "Copyright", "(", "c", ")", "2006", "-", "2015", "JGraph", "Ltd", "Copyright", "(", "c", ")", "2006", "-", "2015", "Gaudenz", "Alder", "Class", ":", "mxPanningHandler" ]
33911ed7e055c17b74d0367f5f1f6c9ee4b4fd44
https://github.com/jgraph/mxgraph/blob/33911ed7e055c17b74d0367f5f1f6c9ee4b4fd44/javascript/mxClient.js#L70611-L70694
train
Internal function to handle panning events
[ 30522, 3853, 25630, 9739, 5582, 11774, 3917, 1006, 10629, 1007, 1063, 2065, 1006, 10629, 999, 1027, 19701, 1007, 1063, 2023, 1012, 10629, 1027, 10629, 1025, 2023, 1012, 10629, 1012, 5587, 27711, 29282, 6528, 2121, 1006, 2023, 1007, 1025, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/extensions/default/MDNDocs/main.js
getDocs
function getDocs(fileName) { if (!promiseCache[fileName]) { var result = new $.Deferred(); var path = ExtensionUtils.getModulePath(module, fileName), file = FileSystem.getFileForPath(path); FileUtils.readAsText(file) .done(function (text) { ...
javascript
function getDocs(fileName) { if (!promiseCache[fileName]) { var result = new $.Deferred(); var path = ExtensionUtils.getModulePath(module, fileName), file = FileSystem.getFileForPath(path); FileUtils.readAsText(file) .done(function (text) { ...
[ "function", "getDocs", "(", "fileName", ")", "{", "if", "(", "!", "promiseCache", "[", "fileName", "]", ")", "{", "var", "result", "=", "new", "$", ".", "Deferred", "(", ")", ";", "var", "path", "=", "ExtensionUtils", ".", "getModulePath", "(", "module...
Lazily loads JSON docs files. Returns a Promise the is resolved with the parsed Object, or rejected if the file is missing/corrupt. @param {string} fileName JSON file to load @return {!$.Promise}
[ "Lazily", "loads", "JSON", "docs", "files", ".", "Returns", "a", "Promise", "the", "is", "resolved", "with", "the", "parsed", "Object", "or", "rejected", "if", "the", "file", "is", "missing", "/", "corrupt", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/extensions/default/MDNDocs/main.js#L52-L79
train
Get the documentation from the file
[ 30522, 3853, 2131, 3527, 6169, 1006, 5371, 18442, 1007, 1063, 2065, 1006, 999, 4872, 3540, 5403, 1031, 5371, 18442, 1033, 1007, 1063, 13075, 2765, 1027, 2047, 1002, 1012, 13366, 28849, 2094, 1006, 1007, 1025, 13075, 4130, 1027, 5331, 21823,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
apache/incubator-echarts
src/visual/VisualMapping.js
function (option) { var mappingMethod = option.mappingMethod; var visualType = option.type; /** * @readOnly * @type {Object} */ var thisOption = this.option = zrUtil.clone(option); /** * @readOnly * @type {string} */ this.type = visualType; /** * @readOn...
javascript
function (option) { var mappingMethod = option.mappingMethod; var visualType = option.type; /** * @readOnly * @type {Object} */ var thisOption = this.option = zrUtil.clone(option); /** * @readOnly * @type {string} */ this.type = visualType; /** * @readOn...
[ "function", "(", "option", ")", "{", "var", "mappingMethod", "=", "option", ".", "mappingMethod", ";", "var", "visualType", "=", "option", ".", "type", ";", "/**\n * @readOnly\n * @type {Object}\n */", "var", "thisOption", "=", "this", ".", "option", "...
@param {Object} option @param {string} [option.type] See visualHandlers. @param {string} [option.mappingMethod] 'linear' or 'piecewise' or 'category' or 'fixed' @param {Array.<number>=} [option.dataExtent] [minExtent, maxExtent], required when mappingMethod is 'linear' @param {Array.<Object>=} [option.pieceList] [ {val...
[ "@param", "{", "Object", "}", "option", "@param", "{", "string", "}", "[", "option", ".", "type", "]", "See", "visualHandlers", ".", "@param", "{", "string", "}", "[", "option", ".", "mappingMethod", "]", "linear", "or", "piecewise", "or", "category", "o...
4d0ea095dc3929cb6de40c45748826e7999c7aa8
https://github.com/apache/incubator-echarts/blob/4d0ea095dc3929cb6de40c45748826e7999c7aa8/src/visual/VisualMapping.js#L57-L120
train
A single node of the cluster
[ 30522, 3853, 1006, 5724, 1007, 1063, 13075, 12375, 11368, 6806, 2094, 1027, 5724, 1012, 12375, 11368, 6806, 2094, 1025, 13075, 5107, 13874, 1027, 5724, 1012, 2828, 1025, 1013, 1008, 1008, 1008, 1030, 3191, 2239, 2135, 1008, 1030, 2828, 1063...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/odata/v4/lib/_AggregationHelper.js
aggregate
function aggregate(sAlias) { var oDetails = oAggregation.aggregate[sAlias], sAggregate = oDetails.name || sAlias, sGrandTotal = sAlias, sWith = oDetails.with; if (sWith) { if ((sWith === "average" || sWith === "countdistinct") && (oDetails.grandTotal || oDetails.subtotals)) { t...
javascript
function aggregate(sAlias) { var oDetails = oAggregation.aggregate[sAlias], sAggregate = oDetails.name || sAlias, sGrandTotal = sAlias, sWith = oDetails.with; if (sWith) { if ((sWith === "average" || sWith === "countdistinct") && (oDetails.grandTotal || oDetails.subtotals)) { t...
[ "function", "aggregate", "(", "sAlias", ")", "{", "var", "oDetails", "=", "oAggregation", ".", "aggregate", "[", "sAlias", "]", ",", "sAggregate", "=", "oDetails", ".", "name", "||", "sAlias", ",", "sGrandTotal", "=", "sAlias", ",", "sWith", "=", "oDetails...
/* Returns the corresponding part of the "aggregate" term for an aggregatable property, for example "AggregatableProperty with method as Alias". Processes min/max as a side effect. @param {string} sAlias - An aggregatable property name @returns {string} - Part of the "aggregate" term @throws {Error} If "average" or "c...
[ "/", "*", "Returns", "the", "corresponding", "part", "of", "the", "aggregate", "term", "for", "an", "aggregatable", "property", "for", "example", "AggregatableProperty", "with", "method", "as", "Alias", ".", "Processes", "min", "/", "max", "as", "a", "side", ...
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/odata/v4/lib/_AggregationHelper.js#L192-L225
train
Adds an aggregate to the aggregation
[ 30522, 3853, 9572, 1006, 16183, 7951, 1007, 1063, 13075, 24040, 22081, 1027, 1051, 8490, 17603, 12540, 1012, 9572, 1031, 16183, 7951, 1033, 1010, 7842, 13871, 2890, 5867, 1027, 24040, 22081, 1012, 2171, 1064, 1064, 16183, 7951, 1010, 22214, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
swimlane/ngx-datatable
release/utils/column-prop-getters.js
getterForProp
function getterForProp(prop) { if (prop == null) return emptyStringGetter; if (typeof prop === 'number') { return numericIndexGetter; } else { // deep or simple if (prop.indexOf('.') !== -1) { return deepValueGetter; } else { return...
javascript
function getterForProp(prop) { if (prop == null) return emptyStringGetter; if (typeof prop === 'number') { return numericIndexGetter; } else { // deep or simple if (prop.indexOf('.') !== -1) { return deepValueGetter; } else { return...
[ "function", "getterForProp", "(", "prop", ")", "{", "if", "(", "prop", "==", "null", ")", "return", "emptyStringGetter", ";", "if", "(", "typeof", "prop", "===", "'number'", ")", "{", "return", "numericIndexGetter", ";", "}", "else", "{", "// deep or simple"...
Returns the appropriate getter function for this kind of prop. If prop == null, returns the emptyStringGetter.
[ "Returns", "the", "appropriate", "getter", "function", "for", "this", "kind", "of", "prop", ".", "If", "prop", "==", "null", "returns", "the", "emptyStringGetter", "." ]
d7df15a070282a169524dba51d9572008b74804c
https://github.com/swimlane/ngx-datatable/blob/d7df15a070282a169524dba51d9572008b74804c/release/utils/column-prop-getters.js#L16-L31
train
Returns a getter function for the given property
[ 30522, 3853, 2131, 3334, 29278, 21572, 2361, 1006, 17678, 1007, 1063, 2065, 1006, 17678, 1027, 1027, 19701, 1007, 2709, 4064, 3367, 4892, 18150, 3334, 1025, 2065, 1006, 2828, 11253, 17678, 1027, 1027, 1027, 1005, 2193, 1005, 1007, 1063, 270...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/odata/v4/ODataUtils.js
function (sTimeOfDay) { var oTimeOfDay; if (rTimeOfDay.test(sTimeOfDay)) { if (sTimeOfDay.length > 12) { // "round" to millis: "HH:mm:ss.SSS" sTimeOfDay = sTimeOfDay.slice(0, 12); } oTimeOfDay = DateFormat.getTimeInstance({ pattern : "HH:mm:ss.SSS", strictParsing : true,...
javascript
function (sTimeOfDay) { var oTimeOfDay; if (rTimeOfDay.test(sTimeOfDay)) { if (sTimeOfDay.length > 12) { // "round" to millis: "HH:mm:ss.SSS" sTimeOfDay = sTimeOfDay.slice(0, 12); } oTimeOfDay = DateFormat.getTimeInstance({ pattern : "HH:mm:ss.SSS", strictParsing : true,...
[ "function", "(", "sTimeOfDay", ")", "{", "var", "oTimeOfDay", ";", "if", "(", "rTimeOfDay", ".", "test", "(", "sTimeOfDay", ")", ")", "{", "if", "(", "sTimeOfDay", ".", "length", ">", "12", ")", "{", "// \"round\" to millis: \"HH:mm:ss.SSS\"", "sTimeOfDay", ...
Parses an "Edm.TimeOfDay" value and returns the corresponding JavaScript <code>Date</code> value (UTC with a date value of "1970-01-01"). @param {string} sTimeOfDay The "Edm.TimeOfDay" value to parse @returns {Date} The JavaScript <code>Date</code> value @throws {Error} If the input cannot be parsed @public @since 1....
[ "Parses", "an", "Edm", ".", "TimeOfDay", "value", "and", "returns", "the", "corresponding", "JavaScript", "<code", ">", "Date<", "/", "code", ">", "value", "(", "UTC", "with", "a", "date", "value", "of", "1970", "-", "01", "-", "01", ")", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/odata/v4/ODataUtils.js#L173-L191
train
Converts a Edm. TimeOfDay value to a Date object
[ 30522, 3853, 1006, 2358, 14428, 11253, 10259, 1007, 1063, 13075, 27178, 14428, 11253, 10259, 1025, 2065, 1006, 19387, 14428, 11253, 10259, 1012, 3231, 1006, 2358, 14428, 11253, 10259, 1007, 1007, 1063, 2065, 1006, 2358, 14428, 11253, 10259, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
sass/node-sass
lib/extensions.js
getBinaryName
function getBinaryName() { var binaryName, variant, platform = process.platform; if (getArgument('--sass-binary-name')) { binaryName = getArgument('--sass-binary-name'); } else if (process.env.SASS_BINARY_NAME) { binaryName = process.env.SASS_BINARY_NAME; } else if (process.env.npm_config_sass_...
javascript
function getBinaryName() { var binaryName, variant, platform = process.platform; if (getArgument('--sass-binary-name')) { binaryName = getArgument('--sass-binary-name'); } else if (process.env.SASS_BINARY_NAME) { binaryName = process.env.SASS_BINARY_NAME; } else if (process.env.npm_config_sass_...
[ "function", "getBinaryName", "(", ")", "{", "var", "binaryName", ",", "variant", ",", "platform", "=", "process", ".", "platform", ";", "if", "(", "getArgument", "(", "'--sass-binary-name'", ")", ")", "{", "binaryName", "=", "getArgument", "(", "'--sass-binary...
Get binary name. If environment variable SASS_BINARY_NAME, .npmrc variable sass_binary_name or process argument --binary-name is provided, return it as is, otherwise make default binary name: {platform}-{arch}-{v8 version}.node @api public
[ "Get", "binary", "name", ".", "If", "environment", "variable", "SASS_BINARY_NAME", ".", "npmrc", "variable", "sass_binary_name", "or", "process", "argument", "--", "binary", "-", "name", "is", "provided", "return", "it", "as", "is", "otherwise", "make", "default...
0c1a49eefa37544d16041c5fe5b2e3d9168004b7
https://github.com/sass/node-sass/blob/0c1a49eefa37544d16041c5fe5b2e3d9168004b7/lib/extensions.js#L183-L210
train
Get binary name
[ 30522, 3853, 2131, 21114, 18143, 14074, 1006, 1007, 1063, 13075, 12441, 18442, 1010, 8349, 1010, 4132, 1027, 2832, 1012, 4132, 1025, 2065, 1006, 2131, 2906, 22850, 4765, 1006, 1005, 1011, 1011, 21871, 2015, 1011, 12441, 1011, 2171, 1005, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
GitbookIO/gitbook
lib/output/website/prepareResources.js
prepareResources
function prepareResources(output) { var plugins = output.getPlugins(); var options = output.getOptions(); var type = options.get('prefix'); var state = output.getState(); var context = Api.encodeGlobal(output); var result = Immutable.Map(); return Promise.forEach(plugins, function(plu...
javascript
function prepareResources(output) { var plugins = output.getPlugins(); var options = output.getOptions(); var type = options.get('prefix'); var state = output.getState(); var context = Api.encodeGlobal(output); var result = Immutable.Map(); return Promise.forEach(plugins, function(plu...
[ "function", "prepareResources", "(", "output", ")", "{", "var", "plugins", "=", "output", ".", "getPlugins", "(", ")", ";", "var", "options", "=", "output", ".", "getOptions", "(", ")", ";", "var", "type", "=", "options", ".", "get", "(", "'prefix'", "...
Prepare plugins resources, add all output corresponding type resources @param {Output} @return {Promise<Output>}
[ "Prepare", "plugins", "resources", "add", "all", "output", "corresponding", "type", "resources" ]
6c6ef7f4af32a2977e44dd23d3feb6ebf28970f4
https://github.com/GitbookIO/gitbook/blob/6c6ef7f4af32a2977e44dd23d3feb6ebf28970f4/lib/output/website/prepareResources.js#L13-L52
train
Prepare resources for a specific type
[ 30522, 3853, 7374, 6072, 8162, 9623, 1006, 6434, 1007, 1063, 13075, 13354, 7076, 1027, 6434, 1012, 2131, 24759, 15916, 7076, 1006, 1007, 1025, 13075, 7047, 1027, 6434, 1012, 2131, 7361, 9285, 1006, 1007, 1025, 13075, 2828, 1027, 7047, 1012,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/protractor
lib/clientsidescripts.js
function() { if (window.getAngularTestability) { if (rootSelector) { var testability = null; var el = document.querySelector(rootSelector); try{ testability = window.getAngularTestability(el); } catch(e){} if (testability) { ...
javascript
function() { if (window.getAngularTestability) { if (rootSelector) { var testability = null; var el = document.querySelector(rootSelector); try{ testability = window.getAngularTestability(el); } catch(e){} if (testability) { ...
[ "function", "(", ")", "{", "if", "(", "window", ".", "getAngularTestability", ")", "{", "if", "(", "rootSelector", ")", "{", "var", "testability", "=", "null", ";", "var", "el", "=", "document", ".", "querySelector", "(", "rootSelector", ")", ";", "try",...
Wait for Angular2 testability and then run test callback
[ "Wait", "for", "Angular2", "testability", "and", "then", "run", "test", "callback" ]
4f74a4ec753c97adfe955fe468a39286a0a55837
https://github.com/angular/protractor/blob/4f74a4ec753c97adfe955fe468a39286a0a55837/lib/clientsidescripts.js#L171-L211
train
This function is called when the app is stable
[ 30522, 3853, 1006, 1007, 1063, 2065, 1006, 3332, 1012, 2131, 5654, 7934, 22199, 8010, 1007, 1063, 2065, 1006, 6147, 12260, 16761, 1007, 1063, 13075, 3231, 8010, 1027, 19701, 1025, 13075, 3449, 1027, 6254, 1012, 23032, 11246, 22471, 2953, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
zloirock/core-js
packages/core-js/modules/es.string.match.js
function (regexp) { var res = maybeCallNative(nativeMatch, regexp, this); if (res.done) return res.value; var rx = anObject(regexp); var S = String(this); if (!rx.global) return regExpExec(rx, S); var fullUnicode = rx.unicode; rx.lastIndex = 0; var A = ...
javascript
function (regexp) { var res = maybeCallNative(nativeMatch, regexp, this); if (res.done) return res.value; var rx = anObject(regexp); var S = String(this); if (!rx.global) return regExpExec(rx, S); var fullUnicode = rx.unicode; rx.lastIndex = 0; var A = ...
[ "function", "(", "regexp", ")", "{", "var", "res", "=", "maybeCallNative", "(", "nativeMatch", ",", "regexp", ",", "this", ")", ";", "if", "(", "res", ".", "done", ")", "return", "res", ".", "value", ";", "var", "rx", "=", "anObject", "(", "regexp", ...
`RegExp.prototype[@@match]` method https://tc39.github.io/ecma262/#sec-regexp.prototype-@@match
[ "RegExp", ".", "prototype", "[" ]
fe7c8511a6d27d03a9b8e075b3351416aae95c58
https://github.com/zloirock/core-js/blob/fe7c8511a6d27d03a9b8e075b3351416aae95c58/packages/core-js/modules/es.string.match.js#L24-L45
train
Returns the matches of the given regexp.
[ 30522, 3853, 1006, 19723, 10288, 2361, 1007, 1063, 13075, 24501, 1027, 2672, 9289, 19666, 8082, 1006, 3128, 18900, 2818, 1010, 19723, 10288, 2361, 1010, 2023, 1007, 1025, 2065, 1006, 24501, 1012, 2589, 1007, 2709, 24501, 1012, 3643, 1025, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
summernote/summernote
src/js/base/core/lists.js
all
function all(array, pred) { for (let idx = 0, len = array.length; idx < len; idx++) { if (!pred(array[idx])) { return false; } } return true; }
javascript
function all(array, pred) { for (let idx = 0, len = array.length; idx < len; idx++) { if (!pred(array[idx])) { return false; } } return true; }
[ "function", "all", "(", "array", ",", "pred", ")", "{", "for", "(", "let", "idx", "=", "0", ",", "len", "=", "array", ".", "length", ";", "idx", "<", "len", ";", "idx", "++", ")", "{", "if", "(", "!", "pred", "(", "array", "[", "idx", "]", ...
returns true if all of the values in the array pass the predicate truth test.
[ "returns", "true", "if", "all", "of", "the", "values", "in", "the", "array", "pass", "the", "predicate", "truth", "test", "." ]
8dcafb8107453006b905ef697a529c42e76beb3f
https://github.com/summernote/summernote/blob/8dcafb8107453006b905ef697a529c42e76beb3f/src/js/base/core/lists.js#L54-L61
train
Returns true if all elements in array are true
[ 30522, 3853, 2035, 1006, 9140, 1010, 3653, 2094, 1007, 1063, 2005, 1006, 2292, 8909, 2595, 1027, 1014, 1010, 18798, 1027, 9140, 1012, 3091, 1025, 8909, 2595, 1026, 18798, 1025, 8909, 2595, 1009, 1009, 1007, 1063, 2065, 1006, 999, 3653, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
askmike/gekko
web/vue/public/vendor/humanize-duration.js
humanizer
function humanizer (passedOptions) { var result = function humanizer (ms, humanizerOptions) { var options = extend({}, result, humanizerOptions || {}) return doHumanization(ms, options) } return extend(result, { language: 'en', delimiter: ', ', spacer: ' ', conjunction: ...
javascript
function humanizer (passedOptions) { var result = function humanizer (ms, humanizerOptions) { var options = extend({}, result, humanizerOptions || {}) return doHumanization(ms, options) } return extend(result, { language: 'en', delimiter: ', ', spacer: ' ', conjunction: ...
[ "function", "humanizer", "(", "passedOptions", ")", "{", "var", "result", "=", "function", "humanizer", "(", "ms", ",", "humanizerOptions", ")", "{", "var", "options", "=", "extend", "(", "{", "}", ",", "result", ",", "humanizerOptions", "||", "{", "}", ...
You can create a humanizer, which returns a function with default parameters.
[ "You", "can", "create", "a", "humanizer", "which", "returns", "a", "function", "with", "default", "parameters", "." ]
0ce9ddd577fa8a22812c02331a494086758dfadf
https://github.com/askmike/gekko/blob/0ce9ddd577fa8a22812c02331a494086758dfadf/web/vue/public/vendor/humanize-duration.js#L20-L46
train
Humanization function
[ 30522, 3853, 2529, 17629, 1006, 2979, 7361, 9285, 1007, 1063, 13075, 2765, 1027, 3853, 2529, 17629, 1006, 5796, 1010, 2529, 17629, 7361, 9285, 1007, 1063, 13075, 7047, 1027, 7949, 1006, 1063, 1065, 1010, 2765, 1010, 2529, 17629, 7361, 9285,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
jgraph/mxgraph
javascript/mxClient.js
function(node) { var ds = mxUtils.getDocumentSize(); var left = parseInt(node.offsetLeft); var width = parseInt(node.offsetWidth); var offset = mxUtils.getDocumentScrollOrigin(node.ownerDocument); var sl = offset.x; var st = offset.y; var b = document.body; var d = document.documentElement; var ...
javascript
function(node) { var ds = mxUtils.getDocumentSize(); var left = parseInt(node.offsetLeft); var width = parseInt(node.offsetWidth); var offset = mxUtils.getDocumentScrollOrigin(node.ownerDocument); var sl = offset.x; var st = offset.y; var b = document.body; var d = document.documentElement; var ...
[ "function", "(", "node", ")", "{", "var", "ds", "=", "mxUtils", ".", "getDocumentSize", "(", ")", ";", "var", "left", "=", "parseInt", "(", "node", ".", "offsetLeft", ")", ";", "var", "width", "=", "parseInt", "(", "node", ".", "offsetWidth", ")", ";...
Function: fit Makes sure the given node is inside the visible area of the window. This is done by setting the left and top in the style.
[ "Function", ":", "fit" ]
33911ed7e055c17b74d0367f5f1f6c9ee4b4fd44
https://github.com/jgraph/mxgraph/blob/33911ed7e055c17b74d0367f5f1f6c9ee4b4fd44/javascript/mxClient.js#L3499-L3527
train
Updates the style of a node
[ 30522, 3853, 1006, 13045, 1007, 1063, 13075, 16233, 1027, 25630, 21823, 4877, 1012, 30524, 1012, 2131, 3527, 24894, 11187, 26775, 14511, 10050, 11528, 1006, 13045, 1012, 3954, 3527, 24894, 4765, 1007, 1025, 13075, 22889, 1027, 16396, 1012, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/thirdparty/datajs.js
function(namespaceURI, qualifiedName) { var dummy = document.createElement('dummy'); dummy.setAttributeNS(namespaceURI, qualifiedName, ''); var attr = dummy.attributes[0]; dummy.removeAttributeNode(attr); return attr; }
javascript
function(namespaceURI, qualifiedName) { var dummy = document.createElement('dummy'); dummy.setAttributeNS(namespaceURI, qualifiedName, ''); var attr = dummy.attributes[0]; dummy.removeAttributeNode(attr); return attr; }
[ "function", "(", "namespaceURI", ",", "qualifiedName", ")", "{", "var", "dummy", "=", "document", ".", "createElement", "(", "'dummy'", ")", ";", "dummy", ".", "setAttributeNS", "(", "namespaceURI", ",", "qualifiedName", ",", "''", ")", ";", "var", "attr", ...
##### BEGIN: MODIFIED BY SAP polyfill for document.createAttributeNS which was removed from Chrome 34 but will be added back in, see: http://datajs.codeplex.com/workitem/1272 https://code.google.com/p/chromium/issues/detail?id=347506 https://codereview.chromium.org/243333003
[ "#####", "BEGIN", ":", "MODIFIED", "BY", "SAP", "polyfill", "for", "document", ".", "createAttributeNS", "which", "was", "removed", "from", "Chrome", "34", "but", "will", "be", "added", "back", "in", "see", ":", "http", ":", "//", "datajs", ".", "codeplex"...
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/thirdparty/datajs.js#L970-L976
train
Get the attribute for a class
[ 30522, 3853, 1006, 3415, 15327, 9496, 1010, 4591, 18442, 1007, 1063, 13075, 24369, 1027, 6254, 1012, 3443, 12260, 3672, 1006, 1005, 24369, 1005, 1007, 1025, 24369, 1012, 2275, 19321, 3089, 8569, 25808, 1006, 3415, 15327, 9496, 1010, 4591, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
firebase/firebaseui-web
demo/public/app.js
function() { document.getElementById('user-signed-in').style.display = 'none'; document.getElementById('user-signed-out').style.display = 'block'; ui.start('#firebaseui-container', getUiConfig()); }
javascript
function() { document.getElementById('user-signed-in').style.display = 'none'; document.getElementById('user-signed-out').style.display = 'block'; ui.start('#firebaseui-container', getUiConfig()); }
[ "function", "(", ")", "{", "document", ".", "getElementById", "(", "'user-signed-in'", ")", ".", "style", ".", "display", "=", "'none'", ";", "document", ".", "getElementById", "(", "'user-signed-out'", ")", ".", "style", ".", "display", "=", "'block'", ";",...
Displays the UI for a signed out user.
[ "Displays", "the", "UI", "for", "a", "signed", "out", "user", "." ]
c10aa51e38aeb38dc63baa22b48cd6690c2be087
https://github.com/firebase/firebaseui-web/blob/c10aa51e38aeb38dc63baa22b48cd6690c2be087/demo/public/app.js#L154-L158
train
Display the user signed in and out UI
[ 30522, 3853, 1006, 1007, 1063, 6254, 1012, 2131, 12260, 3672, 3762, 3593, 1006, 1005, 5310, 1011, 2772, 1011, 1999, 1005, 1007, 1012, 2806, 1012, 4653, 1027, 1005, 3904, 1005, 1025, 6254, 1012, 2131, 12260, 3672, 3762, 3593, 1006, 1005, 5...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/thirdparty/jszip.js
function() { this.zip64EndOfCentralSize = this.reader.readInt(8); this.versionMadeBy = this.reader.readString(2); this.versionNeeded = this.reader.readInt(2); this.diskNumber = this.reader.readInt(4); this.diskWithCentralDirStart = this.reader.readInt(4); this.centralDirR...
javascript
function() { this.zip64EndOfCentralSize = this.reader.readInt(8); this.versionMadeBy = this.reader.readString(2); this.versionNeeded = this.reader.readInt(2); this.diskNumber = this.reader.readInt(4); this.diskWithCentralDirStart = this.reader.readInt(4); this.centralDirR...
[ "function", "(", ")", "{", "this", ".", "zip64EndOfCentralSize", "=", "this", ".", "reader", ".", "readInt", "(", "8", ")", ";", "this", ".", "versionMadeBy", "=", "this", ".", "reader", ".", "readString", "(", "2", ")", ";", "this", ".", "versionNeede...
Read the end of the Zip 64 central directory. Not merged with the method readEndOfCentral : The end of central can coexist with its Zip64 brother, I don't want to read the wrong number of bytes !
[ "Read", "the", "end", "of", "the", "Zip", "64", "central", "directory", ".", "Not", "merged", "with", "the", "method", "readEndOfCentral", ":", "The", "end", "of", "central", "can", "coexist", "with", "its", "Zip64", "brother", "I", "don", "t", "want", "...
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/thirdparty/jszip.js#L1739-L1766
train
Reads the ASN. 1 zip64 extent
[ 30522, 3853, 1006, 1007, 1063, 2023, 1012, 14101, 21084, 10497, 11253, 13013, 7941, 5332, 4371, 1027, 2023, 1012, 8068, 1012, 3191, 18447, 1006, 1022, 1007, 1025, 2023, 1012, 2544, 21565, 3762, 1027, 2023, 1012, 8068, 1012, 9631, 18886, 307...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
TryGhost/Ghost
core/server/apps/private-blogging/lib/middleware.js
isPrivateSessionAuth
function isPrivateSessionAuth(req, res, next) { if (!res.isPrivateBlog) { return res.redirect(urlService.utils.urlFor('home', true)); } let hash = req.session.token || '', salt = req.session.salt || '', isVerified = verifySessionHash(salt, hash); if ...
javascript
function isPrivateSessionAuth(req, res, next) { if (!res.isPrivateBlog) { return res.redirect(urlService.utils.urlFor('home', true)); } let hash = req.session.token || '', salt = req.session.salt || '', isVerified = verifySessionHash(salt, hash); if ...
[ "function", "isPrivateSessionAuth", "(", "req", ",", "res", ",", "next", ")", "{", "if", "(", "!", "res", ".", "isPrivateBlog", ")", "{", "return", "res", ".", "redirect", "(", "urlService", ".", "utils", ".", "urlFor", "(", "'home'", ",", "true", ")",...
This is here so a call to /private/ after a session is verified will redirect to home;
[ "This", "is", "here", "so", "a", "call", "to", "/", "private", "/", "after", "a", "session", "is", "verified", "will", "redirect", "to", "home", ";" ]
bb7bb55cf3e60af99ebbc56099928827b58461bc
https://github.com/TryGhost/Ghost/blob/bb7bb55cf3e60af99ebbc56099928827b58461bc/core/server/apps/private-blogging/lib/middleware.js#L109-L124
train
private session auth
[ 30522, 3853, 2003, 18098, 21466, 8583, 10992, 4887, 2705, 1006, 2128, 4160, 1010, 24501, 1010, 2279, 1007, 1063, 2065, 1006, 999, 24501, 1012, 2003, 18098, 21466, 16558, 8649, 1007, 1063, 2709, 24501, 1012, 2417, 7442, 6593, 1006, 24471, 48...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
ColorlibHQ/AdminLTE
bower_components/jvectormap/lib/world-map.js
function(markers){ var i; for (i = 0; i < markers.length; i++) { this.markers[ markers[i] ].element.remove(); delete this.markers[ markers[i] ]; }; }
javascript
function(markers){ var i; for (i = 0; i < markers.length; i++) { this.markers[ markers[i] ].element.remove(); delete this.markers[ markers[i] ]; }; }
[ "function", "(", "markers", ")", "{", "var", "i", ";", "for", "(", "i", "=", "0", ";", "i", "<", "markers", ".", "length", ";", "i", "++", ")", "{", "this", ".", "markers", "[", "markers", "[", "i", "]", "]", ".", "element", ".", "remove", "(...
Remove some markers from the map. @param {Array} markers Array of marker codes to be removed.
[ "Remove", "some", "markers", "from", "the", "map", "." ]
19113c3cbc19a7afe0cfd3158d647064d2d30661
https://github.com/ColorlibHQ/AdminLTE/blob/19113c3cbc19a7afe0cfd3158d647064d2d30661/bower_components/jvectormap/lib/world-map.js#L792-L799
train
Remove markers from the image
[ 30522, 3853, 1006, 16387, 1007, 1063, 13075, 1045, 1025, 2005, 1006, 1045, 1027, 1014, 1025, 1045, 1026, 16387, 1012, 3091, 1025, 1045, 1009, 1009, 1007, 1063, 2023, 1012, 16387, 1031, 16387, 1031, 1045, 1033, 1033, 1012, 5783, 1012, 6366, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/material
src/components/slider/slider.js
positionToPercent
function positionToPercent(position) { var offset = vertical ? sliderDimensions.top : sliderDimensions.left; var size = vertical ? sliderDimensions.height : sliderDimensions.width; var calc = (position - offset) / size; if (!vertical && $mdUtil.bidi() === 'rtl') { calc = 1 - calc; ...
javascript
function positionToPercent(position) { var offset = vertical ? sliderDimensions.top : sliderDimensions.left; var size = vertical ? sliderDimensions.height : sliderDimensions.width; var calc = (position - offset) / size; if (!vertical && $mdUtil.bidi() === 'rtl') { calc = 1 - calc; ...
[ "function", "positionToPercent", "(", "position", ")", "{", "var", "offset", "=", "vertical", "?", "sliderDimensions", ".", "top", ":", "sliderDimensions", ".", "left", ";", "var", "size", "=", "vertical", "?", "sliderDimensions", ".", "height", ":", "sliderDi...
Convert position on slider to percentage value of offset from beginning... @param position @returns {number}
[ "Convert", "position", "on", "slider", "to", "percentage", "value", "of", "offset", "from", "beginning", "..." ]
84ac558674e73958be84312444c48d9f823f6684
https://github.com/angular/material/blob/84ac558674e73958be84312444c48d9f823f6684/src/components/slider/slider.js#L645-L655
train
Convert a position in pixels to percent
[ 30522, 3853, 2597, 14399, 2121, 13013, 1006, 2597, 1007, 1063, 13075, 16396, 1027, 7471, 1029, 7358, 17080, 3549, 27466, 1012, 2327, 1024, 7358, 17080, 3549, 27466, 1012, 2187, 1025, 13075, 2946, 1027, 7471, 1029, 7358, 17080, 3549, 27466, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
cytoscape/cytoscape.js
dist/cytoscape.esm.js
zIndexSort
function zIndexSort(a, b) { var cy = a.cy(); var hasCompoundNodes = cy.hasCompoundNodes(); function getDepth(ele) { var style = ele.pstyle('z-compound-depth'); if (style.value === 'auto') { return hasCompoundNodes ? ele.zDepth() : 0; } else if (style.value === 'bottom') { return -1; ...
javascript
function zIndexSort(a, b) { var cy = a.cy(); var hasCompoundNodes = cy.hasCompoundNodes(); function getDepth(ele) { var style = ele.pstyle('z-compound-depth'); if (style.value === 'auto') { return hasCompoundNodes ? ele.zDepth() : 0; } else if (style.value === 'bottom') { return -1; ...
[ "function", "zIndexSort", "(", "a", ",", "b", ")", "{", "var", "cy", "=", "a", ".", "cy", "(", ")", ";", "var", "hasCompoundNodes", "=", "cy", ".", "hasCompoundNodes", "(", ")", ";", "function", "getDepth", "(", "ele", ")", "{", "var", "style", "="...
Elements are drawn in a specific order based on compound depth (low to high), the element type (nodes above edges), and z-index (low to high). These styles affect how this applies: z-compound-depth: May be `bottom | orphan | auto | top`. The first drawn is `bottom`, then `orphan` which is the same depth as the root ...
[ "Elements", "are", "drawn", "in", "a", "specific", "order", "based", "on", "compound", "depth", "(", "low", "to", "high", ")", "the", "element", "type", "(", "nodes", "above", "edges", ")", "and", "z", "-", "index", "(", "low", "to", "high", ")", "."...
ad2051b65e2243cfd953d8b24a8bf95bfa8559e5
https://github.com/cytoscape/cytoscape.js/blob/ad2051b65e2243cfd953d8b24a8bf95bfa8559e5/dist/cytoscape.esm.js#L10452-L10502
train
Sort the nodes in the core by the z - index.
[ 30522, 3853, 1062, 22254, 10288, 21748, 2102, 1006, 1037, 1010, 1038, 1007, 1063, 13075, 22330, 1027, 1037, 1012, 22330, 1006, 1007, 1025, 13075, 2038, 9006, 6873, 8630, 3630, 6155, 1027, 22330, 1012, 2038, 9006, 6873, 8630, 3630, 6155, 100...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/view/MainViewManager.js
traverseToNextViewByMRU
function traverseToNextViewByMRU(direction) { var file = getCurrentlyViewedFile(), paneId = getActivePaneId(), index = _.findIndex(_mruList, function (record) { return (record.file === file && record.paneId === paneId); }); return ViewUtils.traverseVi...
javascript
function traverseToNextViewByMRU(direction) { var file = getCurrentlyViewedFile(), paneId = getActivePaneId(), index = _.findIndex(_mruList, function (record) { return (record.file === file && record.paneId === paneId); }); return ViewUtils.traverseVi...
[ "function", "traverseToNextViewByMRU", "(", "direction", ")", "{", "var", "file", "=", "getCurrentlyViewedFile", "(", ")", ",", "paneId", "=", "getActivePaneId", "(", ")", ",", "index", "=", "_", ".", "findIndex", "(", "_mruList", ",", "function", "(", "reco...
Get the next or previous file in the MRU list. @param {!number} direction - Must be 1 or -1 to traverse forward or backward @return {?{file:File, paneId:string}} The File object of the next item in the traversal order or null if there aren't any files to traverse. May return current file if there are no other files to ...
[ "Get", "the", "next", "or", "previous", "file", "in", "the", "MRU", "list", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/view/MainViewManager.js#L933-L941
train
traverseToNextViewByMRU - traverses the MRU list to the next view
[ 30522, 3853, 20811, 5524, 18413, 8584, 3762, 2213, 6820, 1006, 3257, 1007, 1063, 13075, 5371, 1027, 2131, 10841, 14343, 20630, 8584, 2098, 8873, 2571, 1006, 1007, 1010, 6090, 7416, 2094, 1027, 2131, 19620, 9739, 7416, 2094, 1006, 1007, 1010...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
mui-org/material-ui
packages/material-ui-icons/builder.js
getComponentName
function getComponentName(destPath) { const splitregex = new RegExp(`[\\${path.sep}-]+`); const parts = destPath .replace('.js', '') .split(splitregex) .map(part => part.charAt(0).toUpperCase() + part.substring(1)); return parts.join(''); }
javascript
function getComponentName(destPath) { const splitregex = new RegExp(`[\\${path.sep}-]+`); const parts = destPath .replace('.js', '') .split(splitregex) .map(part => part.charAt(0).toUpperCase() + part.substring(1)); return parts.join(''); }
[ "function", "getComponentName", "(", "destPath", ")", "{", "const", "splitregex", "=", "new", "RegExp", "(", "`", "\\\\", "${", "path", ".", "sep", "}", "`", ")", ";", "const", "parts", "=", "destPath", ".", "replace", "(", "'.js'", ",", "''", ")", "...
Return Pascal-Cased component name. @param {string} destPath @returns {string} class name
[ "Return", "Pascal", "-", "Cased", "component", "name", "." ]
1555e52367835946382fbf2a8f681de71318915d
https://github.com/mui-org/material-ui/blob/1555e52367835946382fbf2a8f681de71318915d/packages/material-ui-icons/builder.js#L70-L79
train
Get component name from a file path
[ 30522, 3853, 2131, 9006, 29513, 3372, 18442, 1006, 4078, 25856, 8988, 1007, 1063, 9530, 3367, 3975, 2890, 3351, 2595, 1027, 2047, 19723, 10288, 2361, 1006, 1036, 1031, 1032, 1032, 1002, 1063, 4130, 1012, 19802, 1065, 1011, 1033, 1009, 1036,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
TryGhost/Ghost
core/server/services/url/utils.js
createUrl
function createUrl(urlPath, absolute, secure, trailingSlash) { urlPath = urlPath || '/'; absolute = absolute || false; var base; // create base of url, always ends without a slash if (absolute) { base = getBlogUrl(secure); } else { base = getSubdir(); } if (trailingSlas...
javascript
function createUrl(urlPath, absolute, secure, trailingSlash) { urlPath = urlPath || '/'; absolute = absolute || false; var base; // create base of url, always ends without a slash if (absolute) { base = getBlogUrl(secure); } else { base = getSubdir(); } if (trailingSlas...
[ "function", "createUrl", "(", "urlPath", ",", "absolute", ",", "secure", ",", "trailingSlash", ")", "{", "urlPath", "=", "urlPath", "||", "'/'", ";", "absolute", "=", "absolute", "||", "false", ";", "var", "base", ";", "// create base of url, always ends without...
## createUrl Simple url creation from a given path Ensures that our urls contain the subdirectory if there is one And are correctly formatted as either relative or absolute Usage: createUrl('/', true) -> http://my-ghost-blog.com/ E.g. /blog/ subdir createUrl('/welcome-to-ghost/') -> /blog/welcome-to-ghost/ Parameters: ...
[ "##", "createUrl", "Simple", "url", "creation", "from", "a", "given", "path", "Ensures", "that", "our", "urls", "contain", "the", "subdirectory", "if", "there", "is", "one", "And", "are", "correctly", "formatted", "as", "either", "relative", "or", "absolute", ...
bb7bb55cf3e60af99ebbc56099928827b58461bc
https://github.com/TryGhost/Ghost/blob/bb7bb55cf3e60af99ebbc56099928827b58461bc/core/server/services/url/utils.js#L180-L199
train
Creates a url from the given path
[ 30522, 3853, 3443, 3126, 2140, 1006, 24471, 14277, 8988, 1010, 7619, 1010, 5851, 1010, 12542, 14540, 11823, 1007, 1063, 24471, 14277, 8988, 1027, 24471, 14277, 8988, 1064, 1064, 1005, 1013, 1005, 1025, 7619, 1027, 7619, 1064, 1064, 6270, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/odata/AnnotationParser.js
function(oMetadata, oXMLDoc, sSourceUrl) { var mappingList = {}, schemaNodes, schemaNode, termNodes, oTerms, termNode, sTermType, annotationNodes, annotationNode, annotationTarget, annotationNamespace, annotation, propertyAnnotation, propertyAnnotationNodes, propertyAnnotationNode, sTermValue, targetAnnotation,...
javascript
function(oMetadata, oXMLDoc, sSourceUrl) { var mappingList = {}, schemaNodes, schemaNode, termNodes, oTerms, termNode, sTermType, annotationNodes, annotationNode, annotationTarget, annotationNamespace, annotation, propertyAnnotation, propertyAnnotationNodes, propertyAnnotationNode, sTermValue, targetAnnotation,...
[ "function", "(", "oMetadata", ",", "oXMLDoc", ",", "sSourceUrl", ")", "{", "var", "mappingList", "=", "{", "}", ",", "schemaNodes", ",", "schemaNode", ",", "termNodes", ",", "oTerms", ",", "termNode", ",", "sTermType", ",", "annotationNodes", ",", "annotatio...
Parses the given XML-document using the given ODataMetadata-object and returns a native JavaScript-object representation of it. @param {sap.ui.model.odata.ODataMetadata} oMetadata The metadata to be used for interpreting the annotation document @param {document} oXMLDoc The annotation document @param {string} [sSource...
[ "Parses", "the", "given", "XML", "-", "document", "using", "the", "given", "ODataMetadata", "-", "object", "and", "returns", "a", "native", "JavaScript", "-", "object", "representation", "of", "it", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/odata/AnnotationParser.js#L192-L417
train
Parses the XML document and returns a mapping list
[ 30522, 3853, 1006, 18168, 12928, 2850, 2696, 1010, 23060, 19968, 3527, 2278, 1010, 7020, 8162, 3401, 3126, 2140, 1007, 1063, 13075, 12375, 9863, 1027, 1063, 1065, 1010, 8040, 28433, 3630, 6155, 1010, 8040, 28433, 3630, 3207, 1010, 2744, 363...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SeleniumHQ/selenium
javascript/jsunit/app/xbDebug.js
xbDebugApplyFunction
function xbDebugApplyFunction(funcname, funcref, thisref, argumentsref) { var rv; if (!funcref) { alert('xbDebugApplyFunction: funcref is null'); } if (typeof(funcref.apply) != 'undefined') return funcref.apply(thisref, argumentsref); var applyexpr = 'thisref.xbDebug_orig_' + ...
javascript
function xbDebugApplyFunction(funcname, funcref, thisref, argumentsref) { var rv; if (!funcref) { alert('xbDebugApplyFunction: funcref is null'); } if (typeof(funcref.apply) != 'undefined') return funcref.apply(thisref, argumentsref); var applyexpr = 'thisref.xbDebug_orig_' + ...
[ "function", "xbDebugApplyFunction", "(", "funcname", ",", "funcref", ",", "thisref", ",", "argumentsref", ")", "{", "var", "rv", ";", "if", "(", "!", "funcref", ")", "{", "alert", "(", "'xbDebugApplyFunction: funcref is null'", ")", ";", "}", "if", "(", "typ...
emulate functionref.apply for IE mac and IE win < 5.5
[ "emulate", "functionref", ".", "apply", "for", "IE", "mac", "and", "IE", "win", "<", "5", ".", "5" ]
38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd
https://github.com/SeleniumHQ/selenium/blob/38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd/javascript/jsunit/app/xbDebug.js#L118-L146
train
This function is called by xbDebugApplyFunction to apply a function to a specific object
[ 30522, 3853, 1060, 2497, 3207, 8569, 3654, 9397, 2135, 11263, 27989, 1006, 4569, 2278, 18442, 1010, 4569, 16748, 2546, 1010, 2023, 2890, 2546, 1010, 9918, 2890, 2546, 1007, 1063, 13075, 27634, 1025, 2065, 1006, 999, 4569, 16748, 2546, 1007,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SheetJS/js-xlsx
xlsx.js
write_cs
function write_cs(data, name, opts, wb, rels) { return (name.slice(-4)===".bin" ? write_cs_bin : write_cs_xml)(data, opts, wb, rels); }
javascript
function write_cs(data, name, opts, wb, rels) { return (name.slice(-4)===".bin" ? write_cs_bin : write_cs_xml)(data, opts, wb, rels); }
[ "function", "write_cs", "(", "data", ",", "name", ",", "opts", ",", "wb", ",", "rels", ")", "{", "return", "(", "name", ".", "slice", "(", "-", "4", ")", "===", "\".bin\"", "?", "write_cs_bin", ":", "write_cs_xml", ")", "(", "data", ",", "opts", ",...
eslint-disable-next-line no-unused-vars
[ "eslint", "-", "disable", "-", "next", "-", "line", "no", "-", "unused", "-", "vars" ]
9a6d8a1d3d80c78dad5201fb389316f935279cdc
https://github.com/SheetJS/js-xlsx/blob/9a6d8a1d3d80c78dad5201fb389316f935279cdc/xlsx.js#L15123-L15125
train
write a single file
[ 30522, 3853, 4339, 1035, 20116, 1006, 2951, 1010, 2171, 1010, 23569, 2015, 1010, 25610, 1010, 2128, 4877, 1007, 1063, 2709, 1006, 2171, 1012, 14704, 1006, 1011, 1018, 1007, 1027, 1027, 1027, 1000, 1012, 8026, 1000, 1029, 4339, 1035, 20116, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/utils/ViewUtils.js
getElementClipSize
function getElementClipSize($view, elementRect) { var delta, clip = { top: 0, right: 0, bottom: 0, left: 0 }, viewOffset = $view.offset() || { top: 0, left: 0}; // Check if element extends below viewport delta = (elementRect.top + elementRect.height) - (viewOffset.top + ...
javascript
function getElementClipSize($view, elementRect) { var delta, clip = { top: 0, right: 0, bottom: 0, left: 0 }, viewOffset = $view.offset() || { top: 0, left: 0}; // Check if element extends below viewport delta = (elementRect.top + elementRect.height) - (viewOffset.top + ...
[ "function", "getElementClipSize", "(", "$view", ",", "elementRect", ")", "{", "var", "delta", ",", "clip", "=", "{", "top", ":", "0", ",", "right", ":", "0", ",", "bottom", ":", "0", ",", "left", ":", "0", "}", ",", "viewOffset", "=", "$view", ".",...
Determine how much of an element rect is clipped in view. @param {!DOMElement} $view - A jQuery scrolling container @param {!{top: number, left: number, height: number, width: number}} elementRect - rectangle of element's default position/size @return {{top: number, right: number, bottom: number, left: number}} amount...
[ "Determine", "how", "much", "of", "an", "element", "rect", "is", "clipped", "in", "view", "." ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/utils/ViewUtils.js#L313-L343
train
Get element clip size
[ 30522, 3853, 2131, 12260, 3672, 20464, 11514, 5332, 4371, 1006, 1002, 3193, 1010, 5783, 2890, 6593, 1007, 1063, 13075, 7160, 1010, 12528, 1027, 1063, 2327, 1024, 1014, 1010, 2157, 1024, 1014, 1010, 3953, 1024, 1014, 1010, 2187, 1024, 1014, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Dogfalo/materialize
docs/js/init.js
rgb2hex
function rgb2hex(rgb) { if (/^#[0-9A-F]{6}$/i.test(rgb)) { return rgb; } rgb = rgb.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/); if (rgb === null) { return 'N/A'; } function hex(x) { return ('0' + parseInt(x).toString(16)).slice(-2); } return '#' ...
javascript
function rgb2hex(rgb) { if (/^#[0-9A-F]{6}$/i.test(rgb)) { return rgb; } rgb = rgb.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/); if (rgb === null) { return 'N/A'; } function hex(x) { return ('0' + parseInt(x).toString(16)).slice(-2); } return '#' ...
[ "function", "rgb2hex", "(", "rgb", ")", "{", "if", "(", "/", "^#[0-9A-F]{6}$", "/", "i", ".", "test", "(", "rgb", ")", ")", "{", "return", "rgb", ";", "}", "rgb", "=", "rgb", ".", "match", "(", "/", "^rgb\\((\\d+),\\s*(\\d+),\\s*(\\d+)\\)$", "/", ")", ...
convert rgb to hex value string
[ "convert", "rgb", "to", "hex", "value", "string" ]
1122efadad8f1433d404696f7613e3cc13fb83a4
https://github.com/Dogfalo/materialize/blob/1122efadad8f1433d404696f7613e3cc13fb83a4/docs/js/init.js#L6-L22
train
Convert rgb to hex
[ 30522, 3853, 1054, 18259, 2475, 5369, 2595, 1006, 1054, 18259, 1007, 1063, 2065, 1006, 1013, 1034, 1001, 1031, 1014, 1011, 1023, 2050, 1011, 1042, 1033, 1063, 1020, 1065, 1002, 1013, 1045, 1012, 3231, 1006, 1054, 18259, 1007, 1007, 1063, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
chartjs/Chart.js
src/helpers/helpers.options.js
function(value) { var t, r, b, l; if (helpers.isObject(value)) { t = +value.top || 0; r = +value.right || 0; b = +value.bottom || 0; l = +value.left || 0; } else { t = r = b = l = +value || 0; } return { top: t, right: r, bottom: b, left: l, height: t + b, width: l + r }; ...
javascript
function(value) { var t, r, b, l; if (helpers.isObject(value)) { t = +value.top || 0; r = +value.right || 0; b = +value.bottom || 0; l = +value.left || 0; } else { t = r = b = l = +value || 0; } return { top: t, right: r, bottom: b, left: l, height: t + b, width: l + r }; ...
[ "function", "(", "value", ")", "{", "var", "t", ",", "r", ",", "b", ",", "l", ";", "if", "(", "helpers", ".", "isObject", "(", "value", ")", ")", "{", "t", "=", "+", "value", ".", "top", "||", "0", ";", "r", "=", "+", "value", ".", "right",...
Converts the given value into a padding object with pre-computed width/height. @param {number|object} value - If a number, set the value to all TRBL component, else, if and object, use defined properties and sets undefined ones to 0. @returns {object} The padding values (top, right, bottom, left, width, height) @since ...
[ "Converts", "the", "given", "value", "into", "a", "padding", "object", "with", "pre", "-", "computed", "width", "/", "height", "." ]
f093c36574d290330ed623e60fbd070421c730d5
https://github.com/chartjs/Chart.js/blob/f093c36574d290330ed623e60fbd070421c730d5/src/helpers/helpers.options.js#L66-L86
train
Returns an object with the top right bottom left height and width properties of the specified node.
[ 30522, 3853, 1006, 3643, 1007, 1063, 13075, 1056, 1010, 1054, 1010, 1038, 1010, 1048, 1025, 2065, 1006, 2393, 2545, 1012, 11163, 2497, 20614, 1006, 3643, 1007, 1007, 1063, 1056, 1027, 1009, 3643, 1012, 2327, 1064, 1064, 1014, 1025, 1054, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
goldfire/howler.js
examples/3d/js/camera.js
function() { var x, angle, ray; ctx.save(); for (var col=0; col<this.resolution; col++) { x = col / this.resolution - 0.5; angle = Math.atan2(x, this.focalLen); ray = game.map.cast(game.player, game.player.dir + angle, this.range); this.drawCol(col, ray, angle); } ctx.res...
javascript
function() { var x, angle, ray; ctx.save(); for (var col=0; col<this.resolution; col++) { x = col / this.resolution - 0.5; angle = Math.atan2(x, this.focalLen); ray = game.map.cast(game.player, game.player.dir + angle, this.range); this.drawCol(col, ray, angle); } ctx.res...
[ "function", "(", ")", "{", "var", "x", ",", "angle", ",", "ray", ";", "ctx", ".", "save", "(", ")", ";", "for", "(", "var", "col", "=", "0", ";", "col", "<", "this", ".", "resolution", ";", "col", "++", ")", "{", "x", "=", "col", "/", "this...
Based on the resolution, split the scene up and draw it column by column.
[ "Based", "on", "the", "resolution", "split", "the", "scene", "up", "and", "draw", "it", "column", "by", "column", "." ]
030db918dd8ce640afd57e172418472497e8f113
https://github.com/goldfire/howler.js/blob/030db918dd8ce640afd57e172418472497e8f113/examples/3d/js/camera.js#L54-L68
train
draw the image
[ 30522, 3853, 1006, 1007, 1063, 13075, 1060, 1010, 6466, 1010, 4097, 1025, 14931, 2595, 1012, 3828, 1006, 1007, 1025, 2005, 1006, 13075, 8902, 1027, 1014, 1025, 8902, 1026, 2023, 1012, 5813, 1025, 8902, 1009, 1009, 1007, 1063, 1060, 1027, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
aframevr/aframe
src/components/scene/screenshot.js
function (projection) { var isVREnabled = this.el.renderer.vr.enabled; var renderer = this.el.renderer; var params; // Disable VR. renderer.vr.enabled = false; params = this.setCapture(projection); this.renderCapture(params.camera, params.size, params.projection); // Trigger file downloa...
javascript
function (projection) { var isVREnabled = this.el.renderer.vr.enabled; var renderer = this.el.renderer; var params; // Disable VR. renderer.vr.enabled = false; params = this.setCapture(projection); this.renderCapture(params.camera, params.size, params.projection); // Trigger file downloa...
[ "function", "(", "projection", ")", "{", "var", "isVREnabled", "=", "this", ".", "el", ".", "renderer", ".", "vr", ".", "enabled", ";", "var", "renderer", "=", "this", ".", "el", ".", "renderer", ";", "var", "params", ";", "// Disable VR.", "renderer", ...
Maintained for backwards compatibility.
[ "Maintained", "for", "backwards", "compatibility", "." ]
24acc78a7299a4cdfe3ef617f4d40ddf6275c992
https://github.com/aframevr/aframe/blob/24acc78a7299a4cdfe3ef617f4d40ddf6275c992/src/components/scene/screenshot.js#L171-L183
train
Render the camera and size of the camera
[ 30522, 3853, 1006, 13996, 1007, 1063, 13075, 2003, 12229, 22966, 2094, 30524, 1025, 13075, 11498, 5244, 1025, 1013, 1013, 4487, 19150, 27830, 1012, 17552, 2121, 1012, 27830, 1012, 9124, 1027, 6270, 1025, 11498, 5244, 1027, 2023, 1012, 2275, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SAP/openui5
src/sap.ui.core/src/sap/ui/model/odata/type/Int.js
setConstraints
function setConstraints(oType, oConstraints) { var vNullable; oType.oConstraints = undefined; if (oConstraints) { vNullable = oConstraints.nullable; if (vNullable === false || vNullable === "false") { oType.oConstraints = {nullable : false}; } else if (vNullable !== undefined && vNullable !== true &...
javascript
function setConstraints(oType, oConstraints) { var vNullable; oType.oConstraints = undefined; if (oConstraints) { vNullable = oConstraints.nullable; if (vNullable === false || vNullable === "false") { oType.oConstraints = {nullable : false}; } else if (vNullable !== undefined && vNullable !== true &...
[ "function", "setConstraints", "(", "oType", ",", "oConstraints", ")", "{", "var", "vNullable", ";", "oType", ".", "oConstraints", "=", "undefined", ";", "if", "(", "oConstraints", ")", "{", "vNullable", "=", "oConstraints", ".", "nullable", ";", "if", "(", ...
Sets the constraints. @param {sap.ui.model.odata.type.Int} oType the type instance @param {object} [oConstraints] constraints, see {@link #constructor}
[ "Sets", "the", "constraints", "." ]
8a832fca01cb1cdf8df589788e0c5723e2a33c70
https://github.com/SAP/openui5/blob/8a832fca01cb1cdf8df589788e0c5723e2a33c70/src/sap.ui.core/src/sap/ui/model/odata/type/Int.js#L56-L69
train
Sets constraints for the given type
[ 30522, 3853, 2275, 8663, 20528, 18447, 2015, 1006, 27178, 18863, 1010, 1051, 8663, 20528, 18447, 2015, 1007, 1063, 13075, 1058, 11231, 4571, 3468, 1025, 27178, 18863, 1012, 1051, 8663, 20528, 18447, 2015, 1027, 6151, 28344, 1025, 2065, 1006, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SeleniumHQ/selenium
third_party/js/mozmill/shared-modules/downloads.js
getLocalFileFromNativePathOrUrl
function getLocalFileFromNativePathOrUrl(aPathOrUrl) { if (aPathOrUrl.substring(0,7) == "file://") { // if this is a URL, get the file from that let ioSvc = Cc["@mozilla.org/network/io-service;1"] .getService(Ci.nsIIOService); // XXX it's possible that using a null char-set here is bad...
javascript
function getLocalFileFromNativePathOrUrl(aPathOrUrl) { if (aPathOrUrl.substring(0,7) == "file://") { // if this is a URL, get the file from that let ioSvc = Cc["@mozilla.org/network/io-service;1"] .getService(Ci.nsIIOService); // XXX it's possible that using a null char-set here is bad...
[ "function", "getLocalFileFromNativePathOrUrl", "(", "aPathOrUrl", ")", "{", "if", "(", "aPathOrUrl", ".", "substring", "(", "0", ",", "7", ")", "==", "\"file://\"", ")", "{", "// if this is a URL, get the file from that", "let", "ioSvc", "=", "Cc", "[", "\"@mozill...
Get a local file from a native path or URL @param {string} aPathOrUrl Native path or URL of the file @see http://mxr.mozilla.org/mozilla-central/source/toolkit/mozapps/downloads/content/downloads.js#1309
[ "Get", "a", "local", "file", "from", "a", "native", "path", "or", "URL" ]
38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd
https://github.com/SeleniumHQ/selenium/blob/38d5e4440b2c866a78a1ccb2a18d9795a1bdeafd/third_party/js/mozmill/shared-modules/downloads.js#L386-L401
train
Get the local file from a native path or a URL
[ 30522, 3853, 2131, 4135, 9289, 8873, 2571, 19699, 5358, 19833, 3512, 15069, 2953, 3126, 2140, 1006, 9706, 8988, 2953, 3126, 2140, 1007, 1063, 2065, 1006, 9706, 8988, 2953, 3126, 2140, 1012, 4942, 3367, 4892, 1006, 1014, 1010, 1021, 1007, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
SheetJS/js-xlsx
xlsx.js
parse_themeElements
function parse_themeElements(data, themes, opts) { themes.themeElements = {}; var t; [ /* clrScheme CT_ColorScheme */ ['clrScheme', clrsregex, parse_clrScheme], /* fontScheme CT_FontScheme */ ['fontScheme', fntsregex, parse_fontScheme], /* fmtScheme CT_StyleMatrix */ ['fmtScheme', fmtsregex, parse_fmtS...
javascript
function parse_themeElements(data, themes, opts) { themes.themeElements = {}; var t; [ /* clrScheme CT_ColorScheme */ ['clrScheme', clrsregex, parse_clrScheme], /* fontScheme CT_FontScheme */ ['fontScheme', fntsregex, parse_fontScheme], /* fmtScheme CT_StyleMatrix */ ['fmtScheme', fmtsregex, parse_fmtS...
[ "function", "parse_themeElements", "(", "data", ",", "themes", ",", "opts", ")", "{", "themes", ".", "themeElements", "=", "{", "}", ";", "var", "t", ";", "[", "/* clrScheme CT_ColorScheme */", "[", "'clrScheme'", ",", "clrsregex", ",", "parse_clrScheme", "]",...
/* 20.1.6.10 themeElements CT_BaseStyles
[ "/", "*", "20", ".", "1", ".", "6", ".", "10", "themeElements", "CT_BaseStyles" ]
9a6d8a1d3d80c78dad5201fb389316f935279cdc
https://github.com/SheetJS/js-xlsx/blob/9a6d8a1d3d80c78dad5201fb389316f935279cdc/xlsx.js#L9475-L9491
train
Parse theme elements
[ 30522, 3853, 11968, 3366, 1035, 4323, 12260, 8163, 1006, 30524, 1012, 4323, 12260, 8163, 1027, 1063, 1065, 1025, 13075, 1056, 1025, 1031, 1013, 1008, 18856, 2869, 5403, 4168, 14931, 1035, 6087, 5403, 4168, 1008, 1013, 1031, 1005, 18856, 286...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
adobe/brackets
src/JSUtils/ScopeManager.js
handleTernCompletions
function handleTernCompletions(response) { var file = response.file, offset = response.offset, completions = response.completions, properties = response.properties, fnType = response.fnType, type = response.type, error = response.error, ...
javascript
function handleTernCompletions(response) { var file = response.file, offset = response.offset, completions = response.completions, properties = response.properties, fnType = response.fnType, type = response.type, error = response.error, ...
[ "function", "handleTernCompletions", "(", "response", ")", "{", "var", "file", "=", "response", ".", "file", ",", "offset", "=", "response", ".", "offset", ",", "completions", "=", "response", ".", "completions", ",", "properties", "=", "response", ".", "pro...
Handle the response from the tern node domain when it responds with the list of completions @param {{file: string, offset: {line: number, ch: number}, completions:Array.<string>, properties:Array.<string>}} response - the response from node domain
[ "Handle", "the", "response", "from", "the", "tern", "node", "domain", "when", "it", "responds", "with", "the", "list", "of", "completions" ]
d5d00d43602c438266d32b8eda8f8a3ca937b524
https://github.com/adobe/brackets/blob/d5d00d43602c438266d32b8eda8f8a3ca937b524/src/JSUtils/ScopeManager.js#L690-L712
train
Handle Tern completions
[ 30522, 3853, 5047, 16451, 9006, 10814, 9285, 1006, 3433, 1007, 1063, 13075, 5371, 1027, 3433, 1012, 5371, 1010, 16396, 1027, 3433, 1012, 16396, 1010, 6503, 2015, 1027, 3433, 1012, 6503, 2015, 1010, 5144, 1027, 3433, 1012, 5144, 1010, 1042, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
pagekit/vue-resource
dist/vue-resource.esm.js
root
function root (options$$1, next) { var url = next(options$$1); if (isString(options$$1.root) && !/^(https?:)?\//.test(url)) { url = trimEnd(options$$1.root, '/') + '/' + url; } return url; }
javascript
function root (options$$1, next) { var url = next(options$$1); if (isString(options$$1.root) && !/^(https?:)?\//.test(url)) { url = trimEnd(options$$1.root, '/') + '/' + url; } return url; }
[ "function", "root", "(", "options$$1", ",", "next", ")", "{", "var", "url", "=", "next", "(", "options$$1", ")", ";", "if", "(", "isString", "(", "options$$1", ".", "root", ")", "&&", "!", "/", "^(https?:)?\\/", "/", ".", "test", "(", "url", ")", "...
Root Prefix Transform.
[ "Root", "Prefix", "Transform", "." ]
fe268fa1d6053ede5f34aef9a11e1a424a70446c
https://github.com/pagekit/vue-resource/blob/fe268fa1d6053ede5f34aef9a11e1a424a70446c/dist/vue-resource.esm.js#L448-L457
train
Get the root url
[ 30522, 3853, 7117, 1006, 7047, 1002, 1002, 1015, 1010, 2279, 1007, 1063, 13075, 24471, 2140, 1027, 2279, 1006, 7047, 1002, 1002, 1015, 1007, 1025, 2065, 1006, 26354, 18886, 3070, 1006, 7047, 1002, 1002, 1015, 1012, 7117, 1007, 1004, 1004, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
angular/material
src/components/tooltip/tooltip.js
deregister
function deregister(type, handler, useCapture) { var handlers = listeners[type]; var index = handlers ? handlers.indexOf(handler) : -1; if (index > -1) { handlers.splice(index, 1); if (handlers.length === 0) { useCapture ? window.removeEventListener(type, globalEventHandler, true) : ...
javascript
function deregister(type, handler, useCapture) { var handlers = listeners[type]; var index = handlers ? handlers.indexOf(handler) : -1; if (index > -1) { handlers.splice(index, 1); if (handlers.length === 0) { useCapture ? window.removeEventListener(type, globalEventHandler, true) : ...
[ "function", "deregister", "(", "type", ",", "handler", ",", "useCapture", ")", "{", "var", "handlers", "=", "listeners", "[", "type", "]", ";", "var", "index", "=", "handlers", "?", "handlers", ".", "indexOf", "(", "handler", ")", ":", "-", "1", ";", ...
Removes an event handler from the service. @param {string} type Type of event handler. @param {!Function} handler The event handler itself. @param {boolean} useCapture Whether the event handler used event capturing.
[ "Removes", "an", "event", "handler", "from", "the", "service", "." ]
84ac558674e73958be84312444c48d9f823f6684
https://github.com/angular/material/blob/84ac558674e73958be84312444c48d9f823f6684/src/components/tooltip/tooltip.js#L470-L482
train
Deregisters a listener for a specific event type
[ 30522, 3853, 4315, 13910, 12911, 1006, 2828, 1010, 28213, 1010, 2224, 17695, 11244, 1007, 1063, 13075, 28213, 2015, 1027, 13810, 1031, 2828, 1033, 1025, 13075, 5950, 1027, 28213, 2015, 1029, 28213, 2015, 1012, 5950, 11253, 1006, 28213, 1007, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
nhn/tui.editor
src/js/wysiwygCommands/tableAddCol.js
getNumberOfCols
function getNumberOfCols(wwe) { const selectionMgr = wwe.componentManager.getManager('tableSelection'); const $selectedCells = selectionMgr.getSelectedCells(); let length = 1; if ($selectedCells.length > 0) { const maxLength = $selectedCells.get(0).parentNode.querySelectorAll('td, th').length; length =...
javascript
function getNumberOfCols(wwe) { const selectionMgr = wwe.componentManager.getManager('tableSelection'); const $selectedCells = selectionMgr.getSelectedCells(); let length = 1; if ($selectedCells.length > 0) { const maxLength = $selectedCells.get(0).parentNode.querySelectorAll('td, th').length; length =...
[ "function", "getNumberOfCols", "(", "wwe", ")", "{", "const", "selectionMgr", "=", "wwe", ".", "componentManager", ".", "getManager", "(", "'tableSelection'", ")", ";", "const", "$selectedCells", "=", "selectionMgr", ".", "getSelectedCells", "(", ")", ";", "let"...
get number of selected cols @param {WysiwygEditor} wwe - wysiwyg editor instance @returns {number} - number of selected cols @ignore
[ "get", "number", "of", "selected", "cols" ]
e75ab08c2a7ab07d1143e318f7cde135c5e3002e
https://github.com/nhn/tui.editor/blob/e75ab08c2a7ab07d1143e318f7cde135c5e3002e/src/js/wysiwygCommands/tableAddCol.js#L49-L60
train
Get number of cols
[ 30522, 3853, 2131, 19172, 5677, 11253, 25778, 2015, 1006, 11700, 1007, 1063, 9530, 3367, 4989, 24798, 2099, 1027, 11700, 1012, 6922, 24805, 4590, 1012, 2131, 24805, 4590, 1006, 1005, 7251, 12260, 7542, 1005, 1007, 1025, 9530, 3367, 1002, 34...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Dogfalo/materialize
extras/noUiSlider/nouislider.js
valueSet
function valueSet ( input, fireSetEvent ) { var values = asArray(input); var isInit = scope_Locations[0] === undefined; // Event fires by default fireSetEvent = (fireSetEvent === undefined ? true : !!fireSetEvent); values.forEach(setValue); // ...
javascript
function valueSet ( input, fireSetEvent ) { var values = asArray(input); var isInit = scope_Locations[0] === undefined; // Event fires by default fireSetEvent = (fireSetEvent === undefined ? true : !!fireSetEvent); values.forEach(setValue); // ...
[ "function", "valueSet", "(", "input", ",", "fireSetEvent", ")", "{", "var", "values", "=", "asArray", "(", "input", ")", ";", "var", "isInit", "=", "scope_Locations", "[", "0", "]", "===", "undefined", ";", "// Event fires by default", "fireSetEvent", "=", "...
Set the slider value.
[ "Set", "the", "slider", "value", "." ]
1122efadad8f1433d404696f7613e3cc13fb83a4
https://github.com/Dogfalo/materialize/blob/1122efadad8f1433d404696f7613e3cc13fb83a4/extras/noUiSlider/nouislider.js#L1878-L1910
train
Set the values of the handle
[ 30522, 3853, 5300, 3388, 1006, 7953, 1010, 8769, 12870, 15338, 1007, 1063, 13075, 5300, 1027, 17306, 11335, 2100, 1006, 7953, 1007, 1025, 13075, 2003, 5498, 2102, 1027, 9531, 1035, 5269, 1031, 1014, 1033, 1027, 1027, 1027, 6151, 28344, 1025...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
uber/deck.gl
modules/layers/src/solid-polygon-layer/polygon.js
copyFlatRing
function copyFlatRing(target, targetStartIndex, positions, size, srcStartIndex = 0, srcEndIndex) { srcEndIndex = srcEndIndex || positions.length; const srcLength = srcEndIndex - srcStartIndex; if (srcLength <= 0) { return targetStartIndex; } let targetIndex = targetStartIndex; for (let i = 0; i < srcLe...
javascript
function copyFlatRing(target, targetStartIndex, positions, size, srcStartIndex = 0, srcEndIndex) { srcEndIndex = srcEndIndex || positions.length; const srcLength = srcEndIndex - srcStartIndex; if (srcLength <= 0) { return targetStartIndex; } let targetIndex = targetStartIndex; for (let i = 0; i < srcLe...
[ "function", "copyFlatRing", "(", "target", ",", "targetStartIndex", ",", "positions", ",", "size", ",", "srcStartIndex", "=", "0", ",", "srcEndIndex", ")", "{", "srcEndIndex", "=", "srcEndIndex", "||", "positions", ".", "length", ";", "const", "srcLength", "="...
Copy a simple flat array into another flat array, closes the ring if needed. @param {Float64Array} target - destination @param {Number} targetStartIndex - index in the destination to start copying into @param {Array} positions - array of numbers @param {Number} size - size of a position, 2 (xy) or 3 (xyz) @param {Numbe...
[ "Copy", "a", "simple", "flat", "array", "into", "another", "flat", "array", "closes", "the", "ring", "if", "needed", "." ]
a2010448b7f268bbd03617b812334c68a6b9e5b2
https://github.com/uber/deck.gl/blob/a2010448b7f268bbd03617b812334c68a6b9e5b2/modules/layers/src/solid-polygon-layer/polygon.js#L117-L135
train
Copy a flat ring to a flat array
[ 30522, 3853, 6100, 10258, 4017, 4892, 1006, 4539, 1010, 7889, 7559, 7629, 3207, 2595, 1010, 4460, 1010, 2946, 1010, 5034, 6169, 7559, 7629, 3207, 2595, 1027, 1014, 1010, 5034, 23865, 30524, 5034, 14321, 3070, 2705, 1027, 5034, 23865, 22254,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...