Skip to content

Commit

Permalink
package 18.06.17
Browse files Browse the repository at this point in the history
  • Loading branch information
nightwing committed Jun 18, 2017
1 parent 784ffa8 commit 0b01260
Show file tree
Hide file tree
Showing 345 changed files with 30,188 additions and 14,456 deletions.
8 changes: 8 additions & 0 deletions ChangeLog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
2017.06.18 Version 1.2.7

* Added Support for arrow keys on external IPad keyboard (Emanuele Tamponi)
* added match counter to searchbox extension

- implemented higlighting of multiline strings in yaml mode (Maxim Trushin)
- improved haml syntax highlighter (Andrés Álvarez)

2016.12.03 Version 1.2.6

* Fixed IME handling on new Chrome
Expand Down
54 changes: 40 additions & 14 deletions demo/kitchen-sink/demo.js
Original file line number Diff line number Diff line change
Expand Up @@ -867,8 +867,10 @@ define("ace/test/mockrenderer",["require","exports","module"], function(require,
"use strict";

var MockRenderer = exports.MockRenderer = function(visibleRowCount) {
this.container = document.createElement("div");
this.scroller = document.createElement("div");
if (typeof document == "object") {
this.container = document.createElement("div");
this.scroller = document.createElement("div");
}
this.visibleRowCount = visibleRowCount || 20;

this.layerConfig = {
Expand Down Expand Up @@ -1307,6 +1309,7 @@ var supportedModes = {
Glsl: ["glsl|frag|vert"],
Gobstones: ["gbs"],
golang: ["go"],
GraphQLSchema: ["gql"],
Groovy: ["groovy"],
HAML: ["haml"],
Handlebars: ["hbs|handlebars|tpl|mustache"],
Expand Down Expand Up @@ -1355,6 +1358,7 @@ var supportedModes = {
Perl: ["pl|pm"],
pgSQL: ["pgsql"],
PHP: ["php|phtml|shtml|php3|php4|php5|phps|phpt|aw|ctp|module"],
Pig: ["pig"],
Powershell: ["ps1"],
Praat: ["praat|praatscript|psc|proc"],
Prolog: ["plg|prolog"],
Expand Down Expand Up @@ -2000,6 +2004,7 @@ var themeData = [
["Clouds Midnight" ,"clouds_midnight" , "dark"],
["Cobalt" ,"cobalt" , "dark"],
["Gruvbox" ,"gruvbox" , "dark"],
["Green on Black" ,"gob" , "dark"],
["idle Fingers" ,"idle_fingers" , "dark"],
["krTheme" ,"kr_theme" , "dark"],
["Merbivore" ,"merbivore" , "dark"],
Expand Down Expand Up @@ -5349,7 +5354,9 @@ dom.importCssString(".normal-mode .ace_cursor{\
}
}
if (bestMatch.keys.slice(-11) == '<character>') {
inputState.selectedCharacter = lastChar(keys);
var character = lastChar(keys);
if (/<C-.>/.test(character)) return {type: 'none'};
inputState.selectedCharacter = character;
}
return {type: 'full', command: bestMatch};
},
Expand Down Expand Up @@ -8607,6 +8614,8 @@ dom.importCssString(".normal-mode .ace_cursor{\
cm.setCursor(cm.getCursor().line, cm.getCursor().ch-1);
cm.setOption('keyMap', 'vim');
cm.setOption('disableInput', true);

lastChange.overwrite = cm.state.overwrite;
cm.toggleOverwrite(false); // exit replace mode if we were in it.
insertModeChangeRegister.setText(lastChange.changes.join(''));
CodeMirror.signal(cm, "vim-mode-change", {mode: "normal"});
Expand Down Expand Up @@ -8817,7 +8826,7 @@ dom.importCssString(".normal-mode .ace_cursor{\
if (macroModeState.lastInsertModeChanges.changes.length > 0) {
repeat = !vim.lastEditActionCommand ? 1 : repeat;
var changeObject = macroModeState.lastInsertModeChanges;
repeatInsertModeChanges(cm, changeObject.changes, repeat);
repeatInsertModeChanges(cm, changeObject.changes, repeat, changeObject.overwrite);
}
}
vim.inputState = vim.lastEditInputState;
Expand All @@ -8839,7 +8848,7 @@ dom.importCssString(".normal-mode .ace_cursor{\
macroModeState.isPlaying = false;
}

function repeatInsertModeChanges(cm, changes, repeat) {
function repeatInsertModeChanges(cm, changes, repeat, overwrite) {
function keyHandler(binding) {
if (typeof binding == 'string') {
CodeMirror.commands[binding](cm);
Expand Down Expand Up @@ -8868,7 +8877,11 @@ dom.importCssString(".normal-mode .ace_cursor{\
CodeMirror.lookupKey(change.keyName, 'vim-insert', keyHandler);
} else {
var cur = cm.getCursor();
cm.replaceRange(change, cur, cur);
var end = cur;
if (overwrite && !/\n/.test(change)) {
end = offsetCursor(cur, 0, change.length);
}
cm.replaceRange(change, cur, end);
}
}
}
Expand Down Expand Up @@ -10963,12 +10976,9 @@ var Autocomplete = function() {
};

this.blurListener = function(e) {
if (e.relatedTarget && e.relatedTarget.nodeName == "A" && e.relatedTarget.href) {
window.open(e.relatedTarget.href, "_blank");
}
var el = document.activeElement;
var text = this.editor.textInput.getElement();
var fromTooltip = e.relatedTarget && e.relatedTarget == this.tooltipNode;
var fromTooltip = e.relatedTarget && this.tooltipNode.contains(e.relatedTarget);
var container = this.popup && this.popup.container;
if (el != text && el.parentNode != container && !fromTooltip
&& el != this.tooltipNode && e.relatedTarget != text
Expand Down Expand Up @@ -11049,7 +11059,6 @@ var Autocomplete = function() {
var session = editor.getSession();
var pos = editor.getCursorPosition();

var line = session.getLine(pos.row);
var prefix = util.getCompletionPrefix(editor);

this.base = session.doc.createAnchor(pos.row, pos.column - prefix.length);
Expand All @@ -11061,10 +11070,8 @@ var Autocomplete = function() {
completer.getCompletions(editor, session, pos, prefix, function(err, results) {
if (!err && results)
matches = matches.concat(results);
var pos = editor.getCursorPosition();
var line = session.getLine(pos.row);
callback(null, {
prefix: prefix,
prefix: util.getCompletionPrefix(editor),
matches: matches,
finished: (--total === 0)
});
Expand Down Expand Up @@ -11177,6 +11184,7 @@ var Autocomplete = function() {
this.tooltipNode.style.pointerEvents = "auto";
this.tooltipNode.tabIndex = -1;
this.tooltipNode.onblur = this.blurListener.bind(this);
this.tooltipNode.onclick = this.onTooltipClick.bind(this);
}

var tooltipNode = this.tooltipNode;
Expand Down Expand Up @@ -11213,6 +11221,18 @@ var Autocomplete = function() {
if (el.parentNode)
el.parentNode.removeChild(el);
};

this.onTooltipClick = function(e) {
var a = e.target;
while (a && a != this.tooltipNode) {
if (a.nodeName == "A" && a.href) {
a.rel = "noreferrer";
a.target = "_blank";
break;
}
a = a.parentNode;
}
}

}).call(Autocomplete.prototype);

Expand Down Expand Up @@ -12100,6 +12120,7 @@ var showHScrollEl = document.getElementById("show_hscroll");
var showVScrollEl = document.getElementById("show_vscroll");
var animateScrollEl = document.getElementById("animate_scroll");
var softTabEl = document.getElementById("soft_tab");
var navigateWithinSoftTabEl = document.getElementById("navigate_within_soft_tab");
var behavioursEl = document.getElementById("enable_behaviours");

fillDropdown(docEl, doclist.all);
Expand Down Expand Up @@ -12169,6 +12190,7 @@ function updateUIEditorOptions() {
saveOption(showHScrollEl, editor.renderer.getHScrollBarAlwaysVisible());
saveOption(animateScrollEl, editor.getAnimatedScroll());
saveOption(softTabEl, session.getUseSoftTabs());
saveOption(navigateWithinSoftTabEl, session.getNavigateWithinSoftTabs());
saveOption(behavioursEl, editor.getBehavioursEnabled());
}

Expand Down Expand Up @@ -12263,6 +12285,10 @@ bindCheckbox("soft_tab", function(checked) {
env.editor.session.setUseSoftTabs(checked);
});

bindCheckbox("navigate_within_soft_tab", function(checked) {
env.editor.session.setNavigateWithinSoftTabs(checked);
});

bindCheckbox("enable_behaviours", function(checked) {
env.editor.setBehavioursEnabled(checked);
});
Expand Down
23 changes: 21 additions & 2 deletions demo/kitchen-sink/docs/css.css
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,29 @@

@keyframes blink {
0%, 40% {
opacity: 0;
opacity: 0; /*
*/
opacity: 1
}

40.5%, 100% {
opacity: 1
}
}
}

@document url(http://c9.io/), url-prefix(http://ace.c9.io/build/),
domain(c9.io), regexp("https:.*") /**/
{
/**/
img[title]:before
{
content: attr(title) "\AImage \
retrieved from"
attr(src); /*
*/
white-space: pre;
display: block;
background: url(asdasd); "err
}
}

73 changes: 73 additions & 0 deletions demo/kitchen-sink/docs/graphqlschema.gql
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
# Main Schema
schema {
query: Query;
}

scalar Date;

# Simple type to contain all scalar types
type AllTypes {
# Field Description for String
testString: String;
# Field Description for Int
testInt: Int;
# Field Description for ID
testID: ID;
# Field Description for Boolean
testBoolean: Boolean;
# Field Description for Float
testFloat: Float;
}

interface ISearchable {
searchPreview: String!;
}

union ProductTypes = Movie | Book;

# Testing enum
enum MovieGenere {
ACTION
COMEDY
THRILLER
DRAMA
}

# Testing Input
input SearchByGenere {
before: Date;
after: Date;
genere: MovieGenere!;
}

# Testing Interface
type Movie implements ISearchable {
id: ID!;
searchPreview: String!;
rentPrice: Float;
publishDate: Date;
genere: MovieGenere;
cast: [String];
}

# Testing Interface
type Book implements ISearchable {
id: ID!;
searchPreview: String!;
price: Float;
publishDate: Date;
authors: [String];
}

type Query {
testString: String;
testDate; Date;
allTypes: AllTypes;
allProducts: [ProductTypes];

# searches only movies by genere with sophisticated argument
searchMovieByGenere(searchObject: SearchByGenere!): [Movie];

# Searchs all products by text string
searchProduct(text: String!): [ISearchable];
}
65 changes: 52 additions & 13 deletions demo/kitchen-sink/docs/haml.haml
Original file line number Diff line number Diff line change
@@ -1,22 +1,46 @@
!!!5

# <!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7" lang="en"> <![endif]-->
# <!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8" lang="en"> <![endif]-->
# <!--[if IE 8]> <html class="no-js lt-ie9" lang="en"> <![endif]-->
# <!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
/[if IE]
%a{ :href => 'http://www.mozilla.com/en-US/firefox/' }
%h1 Get Firefox

-# This is a HAML comment. It will not show in the output HTML

-#
This is a HAML multiline comment
This won't be displayed
Nor will this
Nor will this.

/ This is a HTML comment. It will be rendered as HTML

/
%p This doesn't render...
%div
%h1 Because it's commented out!

.row
.col-md-6

.col-md-6


#users.row.green
#articles{:style => "border: 5px;"}
#lists.list-inline

%div#todos.bg-green{:id => "#{@item.type}_#{@item.number}", :class => '#{@item.type} #{@item.urgency}', :phoney => `asdasdasd`}

/adasdasdad
%div{:id => "#{@item.type}_#{@item.number}", :class => '#{@item.type} #{@item.urgency}', :phoney => `asdasdasd`}
/ file: app/views/movies/index.html.haml
\d

%ads:{:bleh => 33}
%p==ddd==
%p
Date/Time:
- now = DateTime.now
- now = DateTime.now
%strong= now
= if now DateTime.parse("December 31, 2006")
= if now DateTime.parse("December 31, 2006")
= "Happy new " + "year!"

%sfd.dfdfg
#content
.title
Expand All @@ -29,8 +53,23 @@
%div.article.title Blah
%div.article.date 2006-11-05
%div.article.entry
Neil Patrick Harris
Neil Patrick Harris

%div[@user, :greeting]
%bar[290]/
==Hello!==
%bar[290]

/ This is a comment

/ This is another comment with line break above

.row
.col-md-6
.col-md-6

.col-md-6

.row
.col-md-6


.col-md-6
9 changes: 9 additions & 0 deletions demo/kitchen-sink/docs/pig.pig
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
A = load 'mobydick.txt';
B = foreach A generate flatten(TOKENIZE((chararray)$0)) as word;
C = filter B by word matches '\\w+';
D = group C by word;
E = foreach D generate COUNT(C) as count, group as word;
F = order E by count desc;
-- one comment
/* another comment */
dump F;
Loading

0 comments on commit 0b01260

Please sign in to comment.