The legislature by general law may provide that any person who violates an order for emergency protection issued by a judge or magistrate after an arrest for an offense involving family violence or who violates an active protective order rendered by a court in a family violence case, including a temporary ex parte order that has been served on the person, or who engages in conduct that constitutes an offense involving the violation of an order described by this section may be taken into custody and, pending trial or other court proceedings, denied release on bail if following a hearing a judge or magistrate in this state determines by a preponderance of the evidence that the person violated the order or engaged in the conduct constituting the offense.