public SweetAlert Type(SweetAlertType type)
 {
     if (type != SweetAlertType.Default)
     {
         Attributes["type"] = string.Format("'{0}'", type.ToString().ToLower());
     }
     SetScript();
     return(this);
 }
Esempio n. 2
0
 public static extern void Show(string title, string mesage, SweetAlertType type);
Esempio n. 3
0
 public static SweetAlertBs SweetAlertBs(string message, string title = "پیغام", SweetAlertType type = SweetAlertType.Default)
 {
     return(new SweetAlertBs().Text(message).Title(title).Type(type));
 }
 public static SweetAlert SweetAlert(this HtmlHelper helper, string message, string title = "پیغام", SweetAlertType type = SweetAlertType.Default)
 {
     return(new SweetAlert(helper).Text(message).Title(title).Type(type));
 }
Esempio n. 5
0
 /// <summary>
 /// Display a message
 /// </summary>
 /// <param name="title">The modal header title</param>
 /// <param name="message">The message to be displayed</param>
 /// <param name="messageType">Define the icon to be used</param>
 /// <returns>Operation result</returns>
 public async ValueTask DoDisplayMessage(string title, string message, SweetAlertType messageType)
 {
     await js.InvokeVoidAsync("Swal.fire", title, message, messageType.ToString());
 }
Esempio n. 6
0
 public static extern void Show(string title, string mesage, SweetAlertType type);
Esempio n. 7
0
        public void SweetAlert(string message, SweetAlertType notificationType)
        {
            var msg = "swal('" + notificationType.ToString().ToUpper() + "', '" + message + "','" + notificationType + "')" + "";

            TempData["notification"] = msg;
        }