ForgeComposants
fr

Composants

j-Approve

jComponent 20 · jcomponent@20 component Exemple chargé avec jComponent 20
  • singleton
  • Travailler avec Bootstrap
  • prend en charge le mode sombre
  • Modèle

Configuration :

  • cancel {String} un étiquette pour le bouton d'annulation (defaut: Cancel)
  • NEW: style {Number} changement de style (supporté style 1 (defaut) et 2)

Méthodes :

  • component.show(message, approve_button_label, [cancel_button_label], callback, [callback_cancel])

Utilisation :

SETTER('approve/show', message, 'Yes', function() {

});

Un style simple de boutons

// "Remove" button will be with Font-Awesome icon called: "trash-o"
SETTER('approve/show', 'Are you sure you want to remove selected item?', ':trash-o: Remove', REMOVE_FUNCTION);

// "Confirm" button will be "green" with Font-Awesome icon called: "checked-circle"
SETTER('approve/show', 'Are you sure you want to confirm selected items?', ':checked-circle: Confirm #2BA433', REMOVE_FUNCTION);

Utilisez-le avec <ui-component name="approve">. Lorsque le composant n'est pas encore chargé, jComponent le télécharge lors de la première utilisation depuis l'adresse dans DEF.fallback (le CDN Componentator par défaut). Auteur : Peter Širka. Source : le référentiel de composants Componentator, licence MIT.

example.html
<ui-component name="approve"></ui-component>

<script>
	SETTER(true, 'approve/show', 'Do you want to remove React/Vue/Angular.js from your device?', ':check-circle: OK', function() {
		alert('Thank you for using of jComponent library');
	});
</script>