File tree Expand file tree Collapse file tree 4 files changed +37
-0
lines changed Expand file tree Collapse file tree 4 files changed +37
-0
lines changed Original file line number Diff line number Diff line change
1
+ var v1AlertContainer = document . getElementById ( 'dbc-v1-alert-container' ) ;
2
+
3
+ if ( ! window . localStorage . getItem ( 'dbc-v1-alert-seen' ) ) {
4
+ v1AlertContainer . setAttribute ( 'style' , 'display:block' ) ;
5
+ }
6
+
7
+ $ ( '#dbc-v1-alert' ) . on ( 'closed.bs.alert' , function ( ) {
8
+ console . log ( 'triggered' ) ;
9
+ window . localStorage . setItem ( 'dbc-v1-alert-seen' , 'true' ) ;
10
+ v1AlertContainer . setAttribute ( 'style' , 'display:none' ) ;
11
+ } ) ;
Original file line number Diff line number Diff line change 6
6
</ head >
7
7
< body >
8
8
{% block header %}{% endblock %}
9
+ {% include "partials/v1-alert.html" %}
9
10
{% block body %}{% endblock %}
10
11
{% block scripts %}{% include "partials/scripts.html" %}{% endblock %}
11
12
</ body >
Original file line number Diff line number Diff line change 13
13
integrity ="sha384-w1Q4orYjBQndcko6MimVbzY0tgp4pWB4lZ7lr30WKz0vr/aWKhXdBNmNb5D92v7s "
14
14
crossorigin ="anonymous "
15
15
> </ script >
16
+ < script src ="/static/js/v1-alert.js "> </ script >
16
17
< script src ="/static/js/highlight.min.js "> </ script >
17
18
< script >
18
19
hljs . configure ( { ignoreUnescapedHTML : true } ) ;
Original file line number Diff line number Diff line change
1
+ < div id ="dbc-v1-alert-container " style ="display:none " class ="mt-3 px-5 ">
2
+ < div
3
+ id ="dbc-v1-alert "
4
+ class ="alert alert-warning alert-dismissible mx-auto "
5
+ style ="max-width:1000px; "
6
+ role ="alert "
7
+ >
8
+ < i > dash-bootstrap-components</ i > version 1 is in beta! Please check
9
+ < a
10
+ href ="https://community.plotly.com/t/dash-bootstrap-components-v1-beta-release-available/56526 "
11
+ class ="alert-link "
12
+ > the announcement post</ a
13
+ >
14
+ on the Plotly forum for more information, and the
15
+ < a class ="alert-link " href ="https://dbc-v1.herokuapp.com/migration-guide "
16
+ > migration guide</ a
17
+ >
18
+ in the preview documentation for information on breaking changes, and how to
19
+ continue to use version 0 if you're not ready to upgrade.
20
+ < button type ="button " class ="close " data-dismiss ="alert " aria-label ="Close ">
21
+ < span aria-hidden ="true "> ×</ span >
22
+ </ button >
23
+ </ div >
24
+ </ div >
You can’t perform that action at this time.
0 commit comments