@@ -195,7 +195,8 @@ <h1 class="name float-start">Name</h1>
195
195
< button id ="btnRollback " class ="btn btn-sm btn-light bg-white border border-secondary me-2 "
196
196
title ="Rollback to this revision "> < i class ="bi-arrow-repeat "> </ i > < span > Rollback</ span >
197
197
</ button >
198
- < button id ="btnTest " class ="btn btn-sm btn-light bg-white border border-secondary me-2 display-none "
198
+ < button id ="btnTest "
199
+ class ="btn btn-sm btn-light bg-white border border-secondary me-2 display-none "
199
200
title ="Run tests for this chart "> < i class ="bi-check-circle "> </ i > < span > Run tests</ span >
200
201
</ button >
201
202
< button id ="btnUninstall " class ="btn btn-sm btn-light bg-white border border-secondary "
@@ -478,5 +479,47 @@ <h5 class="modal-title" id="ModalLabel">Session Ended</h5>
478
479
< script src ="static/actions.js "> </ script >
479
480
< script src ="static/scripts.js "> </ script >
480
481
482
+ <!-- BANNER START -->
483
+ < a id ="banner "
484
+ href ="https://helm-dashboard-survey.komodor.com/ "
485
+ class ="display-none position-absolute top-0 start-50 translate-middle-x bg-primary text-light rounded px-2 mt-1 text-decoration-none py-1 "> Help
486
+ shaping the future by participating in user survey < b class ="bi-x-lg "> </ b > </ a >
487
+ < script >
488
+ function setCookie ( name , value , days ) {
489
+ let expires = "" ;
490
+ if ( days ) {
491
+ const date = new Date ( ) ;
492
+ date . setTime ( date . getTime ( ) + ( days * 24 * 60 * 60 * 1000 ) ) ;
493
+ expires = "; expires=" + date . toUTCString ( ) ;
494
+ }
495
+ document . cookie = name + "=" + ( value || "" ) + expires + "; path=/" ;
496
+ }
497
+
498
+ function getCookie ( name ) {
499
+ const nameEQ = name + "=" ;
500
+ const ca = document . cookie . split ( ';' ) ;
501
+ for ( let i = 0 ; i < ca . length ; i ++ ) {
502
+ const c = ca [ i ] . trim ( ) ;
503
+ if ( c . indexOf ( nameEQ ) === 0 ) {
504
+ return c . substring ( nameEQ . length , c . length )
505
+ }
506
+ }
507
+ return null ;
508
+ }
509
+
510
+ const cookie = getCookie ( "hideBanner" ) ;
511
+ if ( cookie == null ) {
512
+ console . log ( "show" )
513
+ $ ( "#banner" ) . show ( )
514
+ }
515
+
516
+ $ ( "#banner b" ) . click ( function ( evt ) {
517
+ evt . preventDefault ( )
518
+ setCookie ( "hideBanner" , "1" , 365 ) ;
519
+ $ ( "#banner" ) . hide ( )
520
+ } )
521
+ </ script >
522
+ <!-- /BANNER END -->
523
+
481
524
</ body >
482
525
</ html >
0 commit comments