7777 color : red;
7878 }
7979
80- </ style >
80+ .input-group-btn : last-child > .btn : not (: last-child ): not (.dropdown-toggle ) {
81+ border-top-right-radius : 4px ;
82+ border-bottom-right-radius : 4px ;
83+ }
84+
85+ </ style >
8186</ head >
8287< body ng-app ="test " ng-controller ="TestCtrl " ng-cloak >
8388 < nav class ="navbar navbar-default ">
103108 < div class ="input-group " ng-show ="navbarMode === 'saved' && savedGistData.url && !error ">
104109 < div class ="input-group-addon "> Link</ div >
105110 < input type ="text " class ="form-control " value ="{{savedGistData.url}} ">
106- < span class ="input-group-btn ">
107- < button class ="btn btn-default copy " type ="button "> < span class ="glyphicon glyphicon-copy " aria-hidden ="true "> </ span > </ button >
111+ < span ng-if =" hasFlash " class ="input-group-btn ">
112+ < button tooltip-trigger =" focus " tooltip-placement =" right " tooltip =' Copied to clipboard ' clip-copy =" savedGistData.url " class ="btn btn-default copy " type ="button "> < span class ="glyphicon glyphicon-copy " aria-hidden ="true "> </ span > </ button >
108113 </ span >
109114 </ div >
110115
111116 < div class ="input-group " ng-show ="navbarMode === 'saved' && savedGistData.data.html_url && !error ">
112117 < div class ="input-group-addon "> Gist</ div >
113118 < input type ="text " class ="form-control " value ="{{savedGistData.data.html_url}} ">
114- < span class ="input-group-btn ">
115- < button class ="btn btn-default copy " type ="button "> < span class ="glyphicon glyphicon-copy " aria-hidden ="true "> </ span > </ button >
119+ < span ng-if =" hasFlash " class ="input-group-btn ">
120+ < button tooltip-trigger =" focus " tooltip-placement =" right " tooltip =' Copied to clipboard ' clip-copy =" savedGistData.data.html_url " class ="btn btn-default copy " type ="button "> < span class ="glyphicon glyphicon-copy " aria-hidden ="true "> </ span > </ button >
116121 </ span >
117122 </ div >
118123
@@ -165,13 +170,25 @@ <h3>Schema</h3>
165170 </ p >
166171 </ div >
167172</ div >
173+
174+ < script type ="text/ng-template " id ="template/tooltip/tooltip-popup.html ">
175+ < div class = "tooltip {{placement}} {{class}}" ng-class = "{ in: isOpen(), fade: animation() }" >
176+ < div class = "tooltip-arrow" > </ div >
177+ < div class = "tooltip-inner" ng-bind = "content" > </ div >
178+ </ div >
179+ </ script >
180+
168181< script type ="text/javascript " src ="//code.jquery.com/jquery-2.1.1.min.js "> </ script >
169182< script type ="text/javascript " src ="//cdn.jsdelivr.net/g/jquery.ui@1.10 "> </ script >
170- < script type ="text/javascript " src ="//cdnjs.cloudflare.com/ajax/libs/moment.js/2.10.2/moment.min.js "> </ script >
171183< script type ="text/javascript " src ="../bower_components/tv4/tv4.js "> </ script >
172184< script type ="text/javascript " src ="../bower_components/ace-builds/src-min-noconflict/ace.js "> </ script >
173185< script type ="text/javascript " src ="../bower_components/angular/angular.min.js "> </ script >
174186< script type ="text/javascript " src ="../bower_components/angular-sanitize/angular-sanitize.min.js "> </ script >
187+ < script type ="text/javascript " src ="//cdnjs.cloudflare.com/ajax/libs/moment.js/2.10.2/moment.min.js "> </ script >
188+ < script type ="text/javascript " src ="//cdnjs.cloudflare.com/ajax/libs/zeroclipboard/2.2.0/ZeroClipboard.min.js "> </ script >
189+ < script type ="text/javascript " src ="//cdnjs.cloudflare.com/ajax/libs/ng-clip/0.2.6/ng-clip.min.js "> </ script >
190+ < script type ="text/javascript " src ="//cdnjs.cloudflare.com/ajax/libs/swfobject/2.2/swfobject.js "> </ script >
191+ < script type ="text/javascript " src ="//cdnjs.cloudflare.com/ajax/libs/angular-ui-bootstrap/0.12.1/ui-bootstrap.min.js "> </ script >
175192<!-- <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.21/angular.min.js"></script> -->
176193<!-- <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.21/angular-sanitize.min.js"></script> -->
177194
@@ -198,7 +215,11 @@ <h3>Schema</h3>
198215//
199216// To test the tinymce addon, uncomment the files above and inject 'tx-tinymce' below.
200217/*global alert*/
201- angular . module ( 'test' , [ 'schemaForm' , 'ui.ace' ] ) . controller ( 'TestCtrl' , function ( $scope , $http , $location ) {
218+ var app = angular . module ( 'test' , [ 'schemaForm' , 'ui.ace' , 'ngClipboard' , 'ui.bootstrap.tooltip' ] ) ;
219+ app . config ( [ 'ngClipProvider' , function ( ngClipProvider ) {
220+ ngClipProvider . setPath ( '//cdnjs.cloudflare.com/ajax/libs/zeroclipboard/2.2.0/ZeroClipboard.swf' ) ;
221+ } ] ) ;
222+ app . controller ( 'TestCtrl' , function ( $scope , $http , $location ) {
202223
203224 $scope . tests = [
204225 //{ name: "Simple", data: 'data/simple.json' },
@@ -213,6 +234,7 @@ <h3>Schema</h3>
213234 ] ;
214235
215236 $scope . navbarMode = 'default' ;
237+ $scope . hasFlash = swfobject . hasFlashPlayerVersion ( '9' ) ;
216238
217239 // Load data from gist.
218240 if ( $location . path ( ) . length > 4 ) {
0 commit comments