1
0
Fork 0
mirror of https://github.com/documize/community.git synced 2025-08-09 07:25:23 +02:00

Merge branch 'master' into github-extension

This commit is contained in:
Elliott Stoneham 2016-07-05 15:26:25 +01:00
commit ede91fa58a
5 changed files with 149 additions and 139 deletions

View file

@ -1,47 +1,57 @@
{ {
"css": { "css": {
"indent_size": 4, "indent_size": 4,
"allowed_file_extensions": ["css", "scss", "sass", "less"] "indent_level": 0,
}, "indent_with_tabs": true,
"html": { "allowed_file_extensions": ["css", "scss", "sass", "less"],
"indent_size": 4, "max_preserve_newlines": 2
"indent_char": " ", },
"preserve_newlines": true, "html": {
"wrap_line_length": 0, "indent_size": 4,
"indent_handlebars": true, "indent_level": 0,
"indent_inner_html": false, "indent_with_tabs": true,
"indent_scripts": "keep" "preserve_newlines": true,
}, "max_preserve_newlines": 2,
"hbs": { "wrap_line_length": 0,
"indent_size": 4, "indent_handlebars": true,
"indent_char": " ", "indent_inner_html": false,
"preserve_newlines": true, "indent_scripts": "keep"
"wrap_line_length": 0 },
}, "hbs": {
"js": { "indent_size": 4,
"indent_size": 4, "indent_level": 0,
"indent_char": " ", "indent_with_tabs": true,
"preserve_newlines": true, "max_preserve_newlines": 2,
"wrap_line_length": 0, "preserve_newlines": true,
"break_chained_methods": false, "wrap_line_length": 0
"indent_with_tabs": false, },
"max_preserve_newlines": 2, "js": {
"jslint_happy": true, "indent_size": 4,
"brace_style": "collapse-preserve-inline", "indent_level": 0,
"space_after_anon_function": false, "indent_with_tabs": true,
"keep_function_indentation": false, "preserve_newlines": true,
"space_before_conditional": true "wrap_line_length": 0,
}, "break_chained_methods": false,
"sql": { "max_preserve_newlines": 2,
"indent_size": 4, "jslint_happy": true,
"indent_char": " ", "brace_style": "collapse-preserve-inline",
"indent_level": 0, "keep_function_indentation": false,
"indent_with_tabs": false "space_after_anon_function": false,
}, "space_before_conditional": true,
"_default": { "space_in_empty_paren": false,
"indent_size": 4, "space_in_paren": false
"indent_char": " ", },
"preserve_newlines": true, "sql": {
"wrap_line_length": 0 "indent_size": 4,
} "indent_level": 0,
"indent_with_tabs": true
},
"_default": {
"indent_size": 4,
"indent_level": 0,
"indent_with_tabs": true,
"preserve_newlines": true,
"max_preserve_newlines": 2,
"wrap_line_length": 0
}
} }

View file

@ -12,80 +12,80 @@
import Ember from 'ember'; import Ember from 'ember';
export default Ember.Component.extend({ export default Ember.Component.extend({
drop: null, drop: null,
cancelLabel: "Close", cancelLabel: "Close",
actionLabel: "Save", actionLabel: "Save",
tip: "Short and concise title for the page", tip: "Short and concise title for the page",
busy: false, busy: false,
didRender() { didRender() {
let self = this; let self = this;
Mousetrap.bind('esc', function() { Mousetrap.bind('esc', function () {
self.send('onCancel'); self.send('onCancel');
return false; return false;
}); });
Mousetrap.bind(['ctrl+s', 'command+s'], function() { Mousetrap.bind(['ctrl+s', 'command+s'], function () {
self.send('onAction'); self.send('onAction');
return false; return false;
}); });
$("#page-title").removeClass("error"); $("#page-title").removeClass("error");
}, },
willDestroyElement() { willDestroyElement() {
let drop = this.get('drop'); let drop = this.get('drop');
if (is.not.null(drop)) { if (is.not.null(drop)) {
drop.destroy(); drop.destroy();
} }
}, },
actions: { actions: {
onCancel() { onCancel() {
if (this.attrs.isDirty() !== null && this.attrs.isDirty()) { if (this.attrs.isDirty() !== null && this.attrs.isDirty()) {
$(".discard-edits-dialog").css("display", "block"); $(".discard-edits-dialog").css("display", "block");
let drop = new Drop({ let drop = new Drop({
target: $("#editor-cancel")[0], target: $("#editor-cancel")[0],
content: $(".cancel-edits-dialog")[0], content: $(".cancel-edits-dialog")[0],
classes: 'drop-theme-basic', classes: 'drop-theme-basic',
position: "bottom right", position: "bottom right",
openOn: "always", openOn: "always",
tetherOptions: { tetherOptions: {
offset: "5px 0", offset: "5px 0",
targetOffset: "10px 0" targetOffset: "10px 0"
}, },
remove: false remove: false
}); });
this.set('drop', drop); this.set('drop', drop);
return; return;
} }
this.attrs.onCancel(); this.attrs.onCancel();
}, },
onAction() { onAction() {
if (this.get('busy')) { if (this.get('busy')) {
return; return;
} }
if (is.empty(this.get('page.title'))) { if (is.empty(this.get('page.title'))) {
$("#page-title").addClass("error").focus(); $("#page-title").addClass("error").focus();
return; return;
} }
this.attrs.onAction(this.get('page.title')); this.attrs.onAction(this.get('page.title'));
}, },
keepEditing() { keepEditing() {
let drop = this.get('drop'); let drop = this.get('drop');
drop.close(); drop.close();
}, },
discardEdits() { discardEdits() {
this.attrs.onCancel(); this.attrs.onCancel();
} }
} }
}); });

View file

@ -1,32 +1,32 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
{{content-for 'head'}} {{content-for 'head'}}
<meta charset="utf-8"> <meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Documize</title> <title>Documize</title>
<meta property="dbname" content="{{.DBname}}" /> <meta property="dbname" content="{{.DBname}}" />
<meta property="dbhash" content="{{.DBhash}}" /> <meta property="dbhash" content="{{.DBhash}}" />
<meta name="author" content="Documize" /> <meta name="author" content="Documize" />
<meta name="description" content="Documize"> <meta name="description" content="Documize">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" /> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<link rel="shortcut icon" href="/favicon.ico?v=1.1" /> <link rel="shortcut icon" href="/favicon.ico?v=1.1" />
<link rel="icon" type="image/png" href="/favicon-32x32.png?v=1.1" sizes="32x32" /> <link rel="icon" type="image/png" href="/favicon-32x32.png?v=1.1" sizes="32x32" />
<link rel="stylesheet" href="assets/vendor.css"> <link rel="stylesheet" href="assets/vendor.css">
<link rel="stylesheet" href="assets/documize.css"> {{content-for 'head-footer'}} <link rel="stylesheet" href="assets/documize.css"> {{content-for 'head-footer'}}
</head> </head>
<body> <body>
{{content-for 'body'}} {{content-for 'body'}}
<script src="assets/vendor.js"></script> <script src="assets/vendor.js"></script>
<script src="assets/documize.js"></script> <script src="assets/documize.js"></script>
<script src="codemirror/lib/codemirror.js"></script> <script src="codemirror/lib/codemirror.js"></script>
<script src="codemirror/mode/meta.js"></script> <script src="codemirror/mode/meta.js"></script>
<script src="codemirror/addon/mode/loadmode.js"></script> <script src="codemirror/addon/mode/loadmode.js"></script>
<script src="codemirror/addon/runmode/runmode.js"></script> <script src="codemirror/addon/runmode/runmode.js"></script>
<script src="codemirror/addon/runmode/colorize.js"></script> <script src="codemirror/addon/runmode/colorize.js"></script>
{{content-for 'body-footer'}} {{content-for 'body-footer'}}
</body> </body>
</html> </html>

View file

@ -30,7 +30,7 @@ const (
// AppVersion does what it says // AppVersion does what it says
// Versioning scheme major.minor where "minor" is optional // Versioning scheme major.minor where "minor" is optional
// e.g. 1, 2, 3, 4.1, 4.2, 5, 6, 7, 7.1, 8, 9, 10, ..... 127, 127.1, 128 // e.g. 1, 2, 3, 4.1, 4.2, 5, 6, 7, 7.1, 8, 9, 10, ..... 127, 127.1, 128
AppVersion = "12.9" AppVersion = "13.1"
) )
var port, certFile, keyFile, forcePort2SSL string var port, certFile, keyFile, forcePort2SSL string