Methods And Props
Last updated
Last updated
You can add props in simplert
component, example :
You can call available methods in simplert
with this.$refs.simplert.someMethod()
, example :
Copyright © 2017 by Irfan Maulana
Attribute
Value Type
Default Value
Description
:useRadius
Boolean
true
Setting useRadius to true will make Simplert's message box and buttons have rounded corners
:useIcon
Boolean
true
true : will use SweatAlert icon based on type
, false : not use icon
ref
String
-
child reference, read here
Method Name
Parameter
Description
closeOverlay
-
close overlay and simplert (internal method : do not call)
justCloseSimplert
-
close simplert without fired onClose
method
whenConfirm
-
fired onConfirm
and close simplert popup
closeSimplert
-
close simplert popup
openSimplert
Object
open simplert popup with predifined object passed
Property
Type - Default
Description
title
string - empty
Title of alert
message
string - empty
Message of alert
type
string - 'info'
Type of icon will used
customClass
string - empty
Adding extra class in parent simplert
customIconUrl
string - empty
Using custom icon instead of default
customCloseBtnText
string - empty
Using custom text in button close
customCloseBtnClass
string - empty
Change default class in button close
onClose
func - undefined
Function will fired when close button clicked
useConfirmBtn
boolean - false
Using two button with close and confirm
customConfirmBtnText
string - empty
Using custom text in button confirm
customConfirmBtnClass
string - empty
Change default class in button confirm
onConfirm
func - undefined
Function will fired when confirm button clicked
disableOverlayClick
string - empty
Prevent click overlay will close alert
hideAllButton
boolean - false
Hide both button close and confirm
onOpen
func - undefined
Function will fired when open alert
showXclose
boolean - false
Show X close button in right corner of alert