Skip to content
This repository was archived by the owner on May 10, 2024. It is now read-only.

Commit f6ae548

Browse files
Cristian TraversoRoberto Ciccone
authored andcommitted
DESIGNER-1881 fix travis build
1 parent 6d8f763 commit f6ae548

7 files changed

Lines changed: 1024 additions & 682 deletions

.travis.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ before_script:
66
- npm install -g grunt-cli
77
- npm install -g bower
88
- bower update
9-
- node_modules/grunt-protractor-runner/node_modules/protractor/bin/webdriver-manager update
109
before_install:
1110
- "export DISPLAY=:99.0"
1211
- "sh -e /etc/init.d/xvfb start"

dist/scripts/api-designer-parser.js

Lines changed: 905 additions & 581 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/scripts/api-designer-parser.min.js

Lines changed: 61 additions & 58 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/scripts/api-designer-vendor.js

Lines changed: 41 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -51021,10 +51021,6 @@ block.list = replace(block.list)
5102151021
('def', '\\n+(?=' + block.def.source + ')')
5102251022
();
5102351023

51024-
block.blockquote = replace(block.blockquote)
51025-
('def', block.def)
51026-
();
51027-
5102851024
block._tag = '(?!(?:'
5102951025
+ 'a|em|strong|small|s|cite|q|dfn|abbr|data|time|code'
5103051026
+ '|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo'
@@ -51439,7 +51435,7 @@ var inline = {
5143951435
nolink: /^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/,
5144051436
strong: /^__([\s\S]+?)__(?!_)|^\*\*([\s\S]+?)\*\*(?!\*)/,
5144151437
em: /^\b_((?:[^_]|__)+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/,
51442-
code: /^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/,
51438+
code: /^(`+)([\s\S]*?[^`])\1(?!`)/,
5144351439
br: /^ {2,}\n(?!\s*$)/,
5144451440
del: noop,
5144551441
text: /^[\s\S]+?(?=[\\<!\[_*`]| {2,}\n|$)/
@@ -51560,9 +51556,11 @@ InlineLexer.prototype.output = function(src) {
5156051556
if (cap = this.rules.autolink.exec(src)) {
5156151557
src = src.substring(cap[0].length);
5156251558
if (cap[2] === '@') {
51563-
text = cap[1].charAt(6) === ':'
51559+
text = escape(
51560+
cap[1].charAt(6) === ':'
5156451561
? this.mangle(cap[1].substring(7))
51565-
: this.mangle(cap[1]);
51562+
: this.mangle(cap[1])
51563+
);
5156651564
href = this.mangle('mailto:') + text;
5156751565
} else {
5156851566
text = escape(cap[1]);
@@ -51643,7 +51641,7 @@ InlineLexer.prototype.output = function(src) {
5164351641
// code
5164451642
if (cap = this.rules.code.exec(src)) {
5164551643
src = src.substring(cap[0].length);
51646-
out += this.renderer.codespan(escape(cap[2], true));
51644+
out += this.renderer.codespan(escape(cap[2].trim(), true));
5164751645
continue;
5164851646
}
5164951647

@@ -51861,6 +51859,9 @@ Renderer.prototype.link = function(href, title, text) {
5186151859
return '';
5186251860
}
5186351861
}
51862+
if (this.options.baseUrl && !originIndependentUrl.test(href)) {
51863+
href = resolveUrl(this.options.baseUrl, href);
51864+
}
5186451865
var out = '<a href="' + href + '"';
5186551866
if (title) {
5186651867
out += ' title="' + title + '"';
@@ -51870,6 +51871,9 @@ Renderer.prototype.link = function(href, title, text) {
5187051871
};
5187151872

5187251873
Renderer.prototype.image = function(href, title, text) {
51874+
if (this.options.baseUrl && !originIndependentUrl.test(href)) {
51875+
href = resolveUrl(this.options.baseUrl, href);
51876+
}
5187351877
var out = '<img src="' + href + '" alt="' + text + '"';
5187451878
if (title) {
5187551879
out += ' title="' + title + '"';
@@ -52076,8 +52080,8 @@ function escape(html, encode) {
5207652080
}
5207752081

5207852082
function unescape(html) {
52079-
// explicitly match decimal, hex, and named HTML entities
52080-
return html.replace(/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/g, function(_, n) {
52083+
// explicitly match decimal, hex, and named HTML entities
52084+
return html.replace(/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig, function(_, n) {
5208152085
n = n.toLowerCase();
5208252086
if (n === 'colon') return ':';
5208352087
if (n.charAt(0) === '#') {
@@ -52101,6 +52105,30 @@ function replace(regex, opt) {
5210152105
};
5210252106
}
5210352107

52108+
function resolveUrl(base, href) {
52109+
if (!baseUrls[' ' + base]) {
52110+
// we can ignore everything in base after the last slash of its path component,
52111+
// but we might need to add _that_
52112+
// https://tools.ietf.org/html/rfc3986#section-3
52113+
if (/^[^:]+:\/*[^/]*$/.test(base)) {
52114+
baseUrls[' ' + base] = base + '/';
52115+
} else {
52116+
baseUrls[' ' + base] = base.replace(/[^/]*$/, '');
52117+
}
52118+
}
52119+
base = baseUrls[' ' + base];
52120+
52121+
if (href.slice(0, 2) === '//') {
52122+
return base.replace(/:[^]*/, ':') + href;
52123+
} else if (href.charAt(0) === '/') {
52124+
return base.replace(/(:\/*[^/]*)[^]*/, '$1') + href;
52125+
} else {
52126+
return base + href;
52127+
}
52128+
}
52129+
baseUrls = {};
52130+
originIndependentUrl = /^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;
52131+
5210452132
function noop() {}
5210552133
noop.exec = noop;
5210652134

@@ -52235,7 +52263,8 @@ marked.defaults = {
5223552263
smartypants: false,
5223652264
headerPrefix: '',
5223752265
renderer: new Renderer,
52238-
xhtml: false
52266+
xhtml: false,
52267+
baseUrl: null
5223952268
};
5224052269

5224152270
/**
@@ -84015,10 +84044,6 @@ exports.javascript = require('./javascript');
8401584044
};
8401684045

8401784046
function getRequest($event) {
84018-
if (!validateForm($scope.form)) {
84019-
return;
84020-
}
84021-
8402284047
var url;
8402384048
var context = $scope.context;
8402484049
var segmentContexts = resolveSegmentContexts($scope.resource.pathSegments, $scope.context.uriParameters.data());
@@ -84132,7 +84157,7 @@ exports.javascript = require('./javascript');
8413284157
authStrategy.authenticate().then(function(token) {
8413384158
token.sign(request);
8413484159
$scope.requestOptions = request.toOptions();
84135-
jQuery.ajax(request.toOptions()).then(
84160+
jQuery.ajax(Object.assign(request.toOptions(),{timeout:10000})).then(
8413684161
function(data, textStatus, jqXhr) { handleResponse(jqXhr); },
8413784162
function(jqXhr) { handleResponse(jqXhr); }
8413884163
);

dist/scripts/api-designer-vendor.min.js

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/scripts/api-designer.js

Lines changed: 11 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -73216,7 +73216,7 @@ if (!String.prototype.endsWith) {
7321673216
return file.path.slice(-5) !== '.meta';
7321773217
}
7321873218
function metaFile(file) {
73219-
return file.path.slice(-5) === '.meta';
73219+
return !notMetaFile(file);
7322073220
}
7322173221
function handleErrorFor(file) {
7322273222
return function markFileWithError(error) {
@@ -73337,29 +73337,23 @@ if (!String.prototype.endsWith) {
7333773337
return !t.isDirectory;
7333873338
});
7333973339
};
73340-
RamlDirectory.prototype.forEachChildDo = function forEachChildDo(action) {
73340+
RamlDirectory.prototype.forEachItemDo = function forEachItemDo(action, isMetaChildren) {
7334173341
// BFS
73342-
var queue = this.children.slice();
73342+
var queue = isMetaChildren ? this.metaChildren.slice() : this.children.slice();
7334373343
var current;
7334473344
while (queue.length > 0) {
7334573345
current = queue.shift();
7334673346
if (current.isDirectory) {
73347-
queue = queue.concat(current.children);
73347+
queue = queue.concat(isMetaChildren ? current.metaChildren : current.children);
7334873348
}
7334973349
action.call(current, current);
7335073350
}
7335173351
};
73352-
RamlDirectory.prototype.forEachMetaChildDo = function forEachMetaChildDo(action) {
73353-
// BFS
73354-
var queue = this.metaChildren.slice();
73355-
var current;
73356-
while (queue.length > 0) {
73357-
current = queue.shift();
73358-
if (current.isDirectory) {
73359-
queue = queue.concat(current.metaChildren);
73360-
}
73361-
action.call(current, current);
73362-
}
73352+
RamlDirectory.prototype.forEachChildDo = function forEachChildDo(action) {
73353+
this.forEachItemDo(action, false);
73354+
};
73355+
RamlDirectory.prototype.forEachMetaChildDo = function forEachChildDo(action) {
73356+
this.forEachItemDo(action, true);
7336373357
};
7336473358
RamlDirectory.prototype.sortChildren = function sortChildren() {
7336573359
this.children.sort(sortingFunction);
@@ -73414,10 +73408,7 @@ if (!String.prototype.endsWith) {
7341473408
directory.getDirectories().forEach(function (dir) {
7341573409
promises.push(service.removeDirectory(dir));
7341673410
});
73417-
directory.getFiles().forEach(function (file) {
73418-
promises.push(service.removeFile(file));
73419-
});
73420-
directory.getMetaFiles().forEach(function (file) {
73411+
directory.getFiles().concat(directory.getMetaFiles()).forEach(function (file) {
7342173412
promises.push(service.removeFile(file));
7342273413
});
7342373414
// remove this directory object from parent's children list
@@ -74359,7 +74350,7 @@ angular.module('ramlEditorApp').factory('ramlSuggest', [
7435974350
// }
7436074351
//move all child items
7436174352
localStorageHelper.forEach(function (entry) {
74362-
if (entry.path.toLowerCase() !== source.toLowerCase() && entry.path.indexOf(source) === 0) {
74353+
if (entry.path.toLowerCase() !== destination.toLowerCase() && entry.path.indexOf(source + '/') === 0) {
7436374354
var newPath = destination + entry.path.substring(source.length);
7436474355
localStorageHelper.remove(entry.path);
7436574356
entry.path = newPath;

dist/scripts/api-designer.min.js

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)