diff --git a/app/app/styles/view/document/content.scss b/app/app/styles/view/document/content.scss
index cae06a19..db22909b 100644
--- a/app/app/styles/view/document/content.scss
+++ b/app/app/styles/view/document/content.scss
@@ -44,7 +44,7 @@
> .action {
float: right;
- vertical-align: text-top;
+ margin-top: -8px;
@extend .cursor-pointer;
display: none;
color: $color-stroke;
diff --git a/app/app/styles/widget/widget-dropdown.scss b/app/app/styles/widget/widget-dropdown.scss
index 77b6c59e..df6427c9 100644
--- a/app/app/styles/widget/widget-dropdown.scss
+++ b/app/app/styles/widget/widget-dropdown.scss
@@ -37,7 +37,7 @@
> .dropdown-dialog {
@extend .clearfix;
- .content {
+ .content {
> p {
margin: 7px 0;
font-size: 0.9em;
@@ -48,7 +48,7 @@
}
}
- > .actions {
+ .actions {
margin-top: 15px;
float: right;
}
diff --git a/app/app/templates/components/dropdown-dialog.hbs b/app/app/templates/components/dropdown-dialog.hbs
index 32495728..1bc2256d 100644
--- a/app/app/templates/components/dropdown-dialog.hbs
+++ b/app/app/templates/components/dropdown-dialog.hbs
@@ -1,21 +1,23 @@
-
- {{yield}}
-
-
- {{#if showCancel}}
-
- cancel
-
- {{/if}}
- {{#if hasSecondButton}}
-
+
+
diff --git a/app/app/templates/components/folder/folders-list.hbs b/app/app/templates/components/folder/folders-list.hbs
index 773ca38a..09a4cacf 100644
--- a/app/app/templates/components/folder/folders-list.hbs
+++ b/app/app/templates/components/folder/folders-list.hbs
@@ -9,7 +9,7 @@
{{/dropdown-dialog}}
diff --git a/app/vendor/mousetrap.js b/app/vendor/mousetrap.js
index 8986af74..5a56da3a 100644
--- a/app/vendor/mousetrap.js
+++ b/app/vendor/mousetrap.js
@@ -1,6 +1,6 @@
/*global define:false */
/**
- * Copyright 2015 Craig Campbell
+ * Copyright 2016 Craig Campbell
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -17,11 +17,16 @@
* Mousetrap is a simple keyboard shortcut library for Javascript with
* no external dependencies
*
- * @version 1.5.2
+ * @version 1.6.0
* @url craig.is/killing/mice
*/
(function(window, document, undefined) {
+ // Check if mousetrap is used inside browser, if not, return
+ if (!window) {
+ return;
+ }
+
/**
* mapping of special keycodes to their corresponding keys
*
@@ -151,7 +156,13 @@
* loop through to map numbers on the numeric keypad
*/
for (i = 0; i <= 9; ++i) {
- _MAP[i + 96] = i;
+
+ // This needs to use a string cause otherwise since 0 is falsey
+ // mousetrap will never fire for numpad 0 pressed as part of a keydown
+ // event.
+ //
+ // @see https://github.com/ccampbell/mousetrap/pull/258
+ _MAP[i + 96] = i.toString();
}
/**
@@ -983,6 +994,18 @@
return self._handleKey.apply(self, arguments);
};
+ /**
+ * allow custom key mappings
+ */
+ Mousetrap.addKeycodes = function(object) {
+ for (var key in object) {
+ if (object.hasOwnProperty(key)) {
+ _MAP[key] = object[key];
+ }
+ }
+ _REVERSE_MAP = null;
+ };
+
/**
* Init the global mousetrap functions
*
@@ -1018,4 +1041,4 @@
return Mousetrap;
});
}
-}) (window, document);
+}) (typeof window !== 'undefined' ? window : null, typeof window !== 'undefined' ? document : null);