Commit 09cec853 by Torkel Ödegaard

Merge branch 'clipboard_js' of https://github.com/mtanda/grafana into mtanda-clipboard_js

parents deff24d2 d683b037
...@@ -72,6 +72,7 @@ export function grafanaAppDirective(playlistSrv, contextSrv) { ...@@ -72,6 +72,7 @@ export function grafanaAppDirective(playlistSrv, contextSrv) {
link: (scope, elem) => { link: (scope, elem) => {
var ignoreSideMenuHide; var ignoreSideMenuHide;
var body = $('body'); var body = $('body');
$.fn.modal.Constructor.prototype.enforceFocus = function() {}; // see https://github.com/zenorocha/clipboard.js/issues/155
// handle sidemenu open state // handle sidemenu open state
scope.$watch('contextSrv.sidemenu', newVal => { scope.$watch('contextSrv.sidemenu', newVal => {
......
...@@ -90,7 +90,6 @@ function (angular, _, $, require, config) { ...@@ -90,7 +90,6 @@ function (angular, _, $, require, config) {
module.directive('clipboardButton',function() { module.directive('clipboardButton',function() {
return function(scope, elem) { return function(scope, elem) {
require(['vendor/clipboard/dist/clipboard'], function(Clipboard) { require(['vendor/clipboard/dist/clipboard'], function(Clipboard) {
$.fn.modal.Constructor.prototype.enforceFocus = function() {}; // see https://github.com/zenorocha/clipboard.js/issues/155
scope.clipboard = new Clipboard(elem[0]); scope.clipboard = new Clipboard(elem[0]);
}); });
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment