import panel as pn pn.extension() pn.pane.Alert('## Alert\nThis is a warning!') text = ( "This is a **{alert_type}** alert with [an example link]" "(https://panel.holoviz.org/). Give it a click if you like." ) pn.Column(*[ pn.pane.Alert(text.format(alert_type=at), alert_type=at) for at in pn.pane.Alert.param.alert_type.objects], sizing_mode="stretch_width" ).servable() text = """ ### Well done! Aww yeah, you successfully read this important alert message. This example text is going to run a bit longer so that you can see how spacing within an alert works with this kind of content.
Did you notice the use of the divider? """ pn.pane.Alert(text, alert_type="success")