Repository: incubator-zeppelin
Updated Branches:
  refs/heads/master 42d927116 -> 706755a35


ZEPPELIN-269 : Adding Notifications Service for Zeppelin

### Adding Notifications Service for Zeppelin
 - [x] Notifications feature added
  - [x] UI-Notifications component added
- [x] Zeppelin notifications can be configured
- [x] Different level of notification
    *  ngToast.danger('message')
    *   ngToast.warning('message')
    *   ngToast.info('message')
    *   ngToast.success('message')

## Screen shots
![screenshot from 2015-08-28 23 45 
41](https://cloud.githubusercontent.com/assets/1180128/9553799/116e685e-4ddf-11e5-95c3-3fd1fc31b8cd.png)

Author: madhuka <[email protected]>
Author: Damien Corneau <[email protected]>

Closes #263 from Madhuka/errormsg-services and squashes the following commits:

6d5cf4d [madhuka] Merge pull request #1 from corneadoug/change/errorMsgDirective
3ece1eb [Damien Corneau] configure and style ngToast
460d364 [Damien Corneau] Remove angular-ui-notification for ngToast
35d7469 [madhuka] fixing hover, delay time and cleaning error msg
9b131f2 [madhuka] using bower to update
a0baf57 [madhuka] Adding Error Msg and Notifications feature


Project: http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/repo
Commit: 
http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/commit/706755a3
Tree: http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/tree/706755a3
Diff: http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/diff/706755a3

Branch: refs/heads/master
Commit: 706755a35dd8cb5614842bfeeede3e72b4a8e9a4
Parents: 42d9271
Author: madhuka <[email protected]>
Authored: Tue Sep 1 13:42:50 2015 +0530
Committer: Lee moon soo <[email protected]>
Committed: Wed Sep 2 20:10:57 2015 -0700

----------------------------------------------------------------------
 zeppelin-web/bower.json                         |  3 ++-
 zeppelin-web/src/app/app.js                     | 11 ++++++++--
 zeppelin-web/src/app/home/home.css              | 22 ++++++++++++++++++++
 .../src/assets/styles/looknfeel/default.css     |  2 +-
 zeppelin-web/src/index.html                     |  3 +++
 zeppelin-web/test/karma.conf.js                 |  1 +
 6 files changed, 38 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/blob/706755a3/zeppelin-web/bower.json
----------------------------------------------------------------------
diff --git a/zeppelin-web/bower.json b/zeppelin-web/bower.json
index b5b439a..04bdbf8 100644
--- a/zeppelin-web/bower.json
+++ b/zeppelin-web/bower.json
@@ -25,7 +25,8 @@
     "angular-xeditable": "0.1.8",
     "highlightjs": "~8.4.0",
     "lodash": "~3.9.3",
-    "angular-filter": "~0.5.4"
+    "angular-filter": "~0.5.4",
+    "ngtoast": "~1.5.5"
   },
   "devDependencies": {
     "angular-mocks": "1.3.8"

http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/blob/706755a3/zeppelin-web/src/app/app.js
----------------------------------------------------------------------
diff --git a/zeppelin-web/src/app/app.js b/zeppelin-web/src/app/app.js
index 6dfa8e5..28a84e0 100644
--- a/zeppelin-web/src/app/app.js
+++ b/zeppelin-web/src/app/app.js
@@ -30,7 +30,8 @@ angular.module('zeppelinWebApp', [
     'angular.filter',
     'monospaced.elastic',
     'puElasticInput',
-    'xeditable'
+    'xeditable',
+    'ngToast'
   ])
   .filter('breakFilter', function() {
     return function (text) {
@@ -39,7 +40,7 @@ angular.module('zeppelinWebApp', [
       }
     };
   })
-  .config(function ($routeProvider) {
+  .config(function ($routeProvider, ngToastProvider) {
     $routeProvider
       .when('/', {
         templateUrl: 'app/home/home.html',
@@ -60,4 +61,10 @@ angular.module('zeppelinWebApp', [
       .otherwise({
         redirectTo: '/'
       });
+  
+    ngToastProvider.configure({
+      dismissButton: true,
+      dismissOnClick: false,
+      timeout: 6000
+    });
   });

http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/blob/706755a3/zeppelin-web/src/app/home/home.css
----------------------------------------------------------------------
diff --git a/zeppelin-web/src/app/home/home.css 
b/zeppelin-web/src/app/home/home.css
index 5d5e115..c42b469 100644
--- a/zeppelin-web/src/app/home/home.css
+++ b/zeppelin-web/src/app/home/home.css
@@ -285,6 +285,28 @@ kbd {
   min-height: 400px;
 }
 
+/* ngToast style */
+
+.ng-toast .alert {
+  color: white !important;
+  border: none !important;
+}
+
+.ng-toast .alert-danger {
+  background-color: #A94442 !important;
+}
+
+.ng-toast .alert-warning {
+  background-color: #CE9532 !important;
+}
+
+.ng-toast .alert-info {
+  background-color: #589EC1 !important;
+}
+
+.ng-toast .alert-success {
+  background-color: #428443 !important;
+}
 
 /*
 temporary fix for bootstrap issue 
(https://github.com/twbs/bootstrap/issues/5865)

http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/blob/706755a3/zeppelin-web/src/assets/styles/looknfeel/default.css
----------------------------------------------------------------------
diff --git a/zeppelin-web/src/assets/styles/looknfeel/default.css 
b/zeppelin-web/src/assets/styles/looknfeel/default.css
index 8aeee95..56db526 100644
--- a/zeppelin-web/src/assets/styles/looknfeel/default.css
+++ b/zeppelin-web/src/assets/styles/looknfeel/default.css
@@ -64,4 +64,4 @@ body {
 .executionTime,
 .nv-controlsWrap {
   display:block;
-}
\ No newline at end of file
+}

http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/blob/706755a3/zeppelin-web/src/index.html
----------------------------------------------------------------------
diff --git a/zeppelin-web/src/index.html b/zeppelin-web/src/index.html
index 90b3f0a..9e41b30 100644
--- a/zeppelin-web/src/index.html
+++ b/zeppelin-web/src/index.html
@@ -42,6 +42,7 @@ limitations under the License.
     <link rel="stylesheet" 
href="bower_components/ng-sortable/dist/ng-sortable.css" />
     <link rel="stylesheet" 
href="bower_components/angular-xeditable/dist/css/xeditable.css" />
     <link rel="stylesheet" 
href="bower_components/highlightjs/styles/github.css" />
+    <link rel="stylesheet" href="bower_components/ngtoast/dist/ngToast.css" />
     <!-- endbower -->
     <link rel="stylesheet" 
href="bower_components/jquery-ui/themes/base/all.css" />
     <!-- endbuild -->
@@ -60,6 +61,7 @@ limitations under the License.
     <!--[if lt IE 7]>
 <p class="browsehappy">You are using an <strong>outdated</strong> browser. 
Please <a href="http://browsehappy.com/";>upgrade your browser</a> to improve 
your experience.</p>
 <![endif]-->
+    <toast></toast>
     <div ng-include src="'components/navbar/navbar.html'"></div>
     <!-- Add your site or application content here -->
     <div id="main" class="container">
@@ -112,6 +114,7 @@ limitations under the License.
     <script src="bower_components/highlightjs/highlight.pack.js"></script>
     <script src="bower_components/lodash/lodash.js"></script>
     <script 
src="bower_components/angular-filter/dist/angular-filter.min.js"></script>
+    <script src="bower_components/ngtoast/dist/ngToast.js"></script>
     <!-- endbower -->
     <!-- endbuild -->
     <!-- build:js({.tmp,src}) scripts/scripts.js -->

http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/blob/706755a3/zeppelin-web/test/karma.conf.js
----------------------------------------------------------------------
diff --git a/zeppelin-web/test/karma.conf.js b/zeppelin-web/test/karma.conf.js
index ffbc996..d76f72c 100644
--- a/zeppelin-web/test/karma.conf.js
+++ b/zeppelin-web/test/karma.conf.js
@@ -53,6 +53,7 @@ module.exports = function(config) {
       'bower_components/highlightjs/highlight.pack.js',
       'bower_components/lodash/lodash.js',
       'bower_components/angular-filter/dist/angular-filter.min.js',
+      'bower_components/ngtoast/dist/ngToast.js',
       'bower_components/angular-mocks/angular-mocks.js',
       // endbower
       'src/app/app.js',

Reply via email to