Skip to content

Commit e4814fd

Browse files
leovanportellaa
authored andcommitted
fix: alert style name in widget
1 parent 5d7b7be commit e4814fd

File tree

1 file changed

+6
-1
lines changed
  • src/ydata_profiling/report/presentation/flavours/widget

1 file changed

+6
-1
lines changed

src/ydata_profiling/report/presentation/flavours/widget/alerts.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,15 @@ def render(self) -> widgets.GridBox:
2929
)
3030
)
3131
)
32+
33+
style_name = styles[type_name]
34+
if style_name not in ('primary', 'success', 'info', 'warning', 'danger'):
35+
style_name = ''
36+
3237
items.append(
3338
Button(
3439
description=type_name.replace("_", " ").capitalize(),
35-
button_style=styles[type_name],
40+
button_style=style_name,
3641
disabled=True,
3742
)
3843
)

0 commit comments

Comments
 (0)