From 22f66d042d3f57d32dc71e162e793b1a58d38c95 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ph=E1=BA=A1m=20Tr=C3=AD=20Trung?= Date: Tue, 29 Dec 2020 21:23:45 +0700 Subject: [PATCH] fix issue that custom buttons can't be mapped attributes from selector (#134) Co-authored-by: trung.pham --- src/confirmation.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/confirmation.js b/src/confirmation.js index c21de44..76ff9c7 100644 --- a/src/confirmation.js +++ b/src/confirmation.js @@ -354,7 +354,7 @@ class Confirmation extends Popover { .addClass(BTN_CLASS_BASE) .addClass(button.class || `${BTN_CLASS_DEFAULT} btn-secondary`) .html(button.label || '') - .attr(button.attr || {}); + .attr(button.attr || (button.cancel ? {} : self.config._attributes)); if (button.iconClass || button.iconContent) { btn.prepend($('')