gov-uk-dashboards 26.22.0__py3-none-any.whl → 26.23.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,6 +2,8 @@
2
2
 
3
3
  from dash import html
4
4
 
5
+ from gov_uk_dashboards.constants import BANNER_STYLE, ERROR_MESSAGE_BANNER_STYLE
6
+
5
7
 
6
8
  def message_banner(category, message, style=None):
7
9
  """
@@ -30,3 +32,21 @@ def message_banner(category, message, style=None):
30
32
  className="change-log-banner govuk-!-margin-bottom-2",
31
33
  style=style,
32
34
  )
35
+
36
+
37
+ def get_warning_banner(banner_text: str) -> html.Div:
38
+ """Returns warning banner with banner_text displayed.
39
+
40
+ Args:
41
+ banner_text (str): Text to display on warning banner.
42
+ """
43
+ return html.Div(
44
+ [
45
+ message_banner(
46
+ "UPDATE",
47
+ html.Span(banner_text),
48
+ style=ERROR_MESSAGE_BANNER_STYLE,
49
+ )
50
+ ],
51
+ style=BANNER_STYLE,
52
+ )
@@ -44,3 +44,17 @@ NOTIFICATION_STYLE_RED = {"borderColor": "#d4351c", "backgroundColor": "#d4351c"
44
44
  NOTIFICATION_STYLE_ORANGE = {"borderColor": "#f47738", "backgroundColor": "#f47738"}
45
45
  NOTIFICATION_STYLE_YELLOW = {"borderColor": "#ffdd00", "backgroundColor": "#ffdd00"}
46
46
  NOTIFICATION_STYLE_GREEN = {"borderColor": "#00703c", "backgroundColor": "#00703c"}
47
+
48
+ BANNER_STYLE = {
49
+ "display": "flex",
50
+ "visibility": "visible",
51
+ "margin": "-10px -15px 0px -15px",
52
+ }
53
+
54
+ ERROR_MESSAGE_BANNER_STYLE = {
55
+ "width": "100%",
56
+ "paddingLeft": "30px",
57
+ "paddingRight": "30px",
58
+ "justifyContent": "left",
59
+ "backgroundColor": "#FFDD00",
60
+ }
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: gov_uk_dashboards
3
- Version: 26.22.0
3
+ Version: 26.23.0
4
4
  Summary: Provides access to functionality common to creating a data dashboard.
5
5
  Author: Department for Levelling Up, Housing and Communities
6
6
  Description-Content-Type: text/markdown
@@ -1,6 +1,6 @@
1
1
  gov_uk_dashboards/__init__.py,sha256=OqwrcJmNWlyzGe8wEy_lkIgRihjvdtSYhcx43TEvpVU,1281
2
2
  gov_uk_dashboards/colours.py,sha256=ju_2FIeTARqG4BQo_2jIwo6trD5yOc8ulhaVj7KJ8hw,2858
3
- gov_uk_dashboards/constants.py,sha256=rafzpVstCpzg2_tp61EhLYQ0dic5NfNiP6uehuNime0,1522
3
+ gov_uk_dashboards/constants.py,sha256=xsBbONNbsrmTfj2tD8VScmtlwB0ymQ1AfaxDXSJ7kWs,1807
4
4
  gov_uk_dashboards/log_kpi.py,sha256=xDhb-ex16MfQ1RHQF99huv2FNRu5EKM30bIXYqCnd6g,1023
5
5
  gov_uk_dashboards/symbols.py,sha256=Ca7kWylg5iLzYyninqsk7FPvefz1qvz8UEKmB1VYcxY,425
6
6
  gov_uk_dashboards/template.html,sha256=npP-IeycCFNjOAxf56Yuha4FfpatwPXVYFQRkm84Bnc,1875
@@ -43,7 +43,7 @@ gov_uk_dashboards/assets/topojson/world_110m.json,sha256=11kV6qMchw32uXLJ5buGkQG
43
43
  gov_uk_dashboards/components/__init__.py,sha256=2Ks6SdhCpNwXwoTCD-xLBxk3YJ1FJcLACkiSKLP5YN8,188
44
44
  gov_uk_dashboards/components/dash/__init__.py,sha256=ItzNnUm3bkqsOUh4I92H4H4gTZVnQJTYftxDreSEYfY,4707
45
45
  gov_uk_dashboards/components/dash/apply_and_reset_filters_buttons.py,sha256=qx7cI5cE-600mE-d6cu9CrLGnkpM13CJmReQQnC2UZw,674
46
- gov_uk_dashboards/components/dash/banners.py,sha256=0wvzRSLT2ABUHxNEJ9khHWXDpB5TVyqhfj4uN0Jxm3E,959
46
+ gov_uk_dashboards/components/dash/banners.py,sha256=TPtpNAsYoxalCEQ97Ao8bUERTePHYOA5LOQAWm-f5OY,1470
47
47
  gov_uk_dashboards/components/dash/card.py,sha256=8uu2HOX5jBwfbvs3TuicN2rrLtbtJc9CXr6mpskAUUI,421
48
48
  gov_uk_dashboards/components/dash/card_full_width.py,sha256=KnpkB3krgLxp1MoqEZazx3xTncj6rDpeM1n2NLC2gB4,413
49
49
  gov_uk_dashboards/components/dash/collapsible_panel.py,sha256=6A90xiTLU0b5e4jaWcisTbsf_82nRBvGapbyETd5m70,1192
@@ -121,8 +121,8 @@ gov_uk_dashboards/lib/testing_functions/barchart_data_test_assertions.py,sha256=
121
121
  gov_uk_dashboards/lib/testing_functions/data_test_assertions.py,sha256=1Icy7NZXw6hI_-7QAUaHqjjPKViY0jcFEASlk6Ul2tg,4162
122
122
  gov_uk_dashboards/lib/testing_functions/data_test_helper_functions.py,sha256=JoptoXJORuIdrhweVlp9fhX-ew2GtIkctIotpHWBQDQ,9635
123
123
  gov_uk_dashboards/lib/testing_functions/timeseries_data_test_assertions.py,sha256=SJa3WLgFqf7Y1W0sxsOew_-4m3689cjynRjoCyBK5WQ,1240
124
- gov_uk_dashboards-26.22.0.dist-info/licenses/LICENSE,sha256=GDiD7Y2Gx7JucPV1JfVySJeah-qiSyBPdpJ6RHCEHTc,1126
125
- gov_uk_dashboards-26.22.0.dist-info/METADATA,sha256=byWf5hlyvYPktP90O6fgWBT2ajF9M-lnDCrfumMYJ2g,5903
126
- gov_uk_dashboards-26.22.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
127
- gov_uk_dashboards-26.22.0.dist-info/top_level.txt,sha256=gPaN1P3-H3Rgi2me6tt-fX_cxo19CZfA4PjlZPjGRpo,18
128
- gov_uk_dashboards-26.22.0.dist-info/RECORD,,
124
+ gov_uk_dashboards-26.23.0.dist-info/licenses/LICENSE,sha256=GDiD7Y2Gx7JucPV1JfVySJeah-qiSyBPdpJ6RHCEHTc,1126
125
+ gov_uk_dashboards-26.23.0.dist-info/METADATA,sha256=WFFsOytCRQkFGsmcgXBepjbYpuBijAPT4KmpYikqQzc,5903
126
+ gov_uk_dashboards-26.23.0.dist-info/WHEEL,sha256=qELbo2s1Yzl39ZmrAibXA2jjPLUYfnVhUNTlyF1rq0Y,92
127
+ gov_uk_dashboards-26.23.0.dist-info/top_level.txt,sha256=gPaN1P3-H3Rgi2me6tt-fX_cxo19CZfA4PjlZPjGRpo,18
128
+ gov_uk_dashboards-26.23.0.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (80.9.0)
2
+ Generator: setuptools (80.10.1)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5