buttonId ?? 'confirm_' . $this->_invocation; if (null === ($buttonClass = $this->buttonClass)) { if ($this->buttonLink) { $buttonClass = 'btn btn-link'; } else { $buttonClass = 'btn btn-default'; } } if ($this->buttonIcon && $this->buttonLabel) { $buttonClass .= ' icon-link'; } $buttonAttrs = [ 'id' => $buttonId, 'class' => "$buttonClass dropdown-toggle", 'data-toggle' => 'dropdown', 'aria-expanded' => 'false', 'aria-haspopup' => 'true', ]; if ($link = $this->buttonLink) { $buttonAttrs['href'] = $link; } else { $buttonAttrs['type'] = 'submit'; } if ($name = $this->buttonName) { $buttonAttrs['name'] = $name; } // Allow label with or without icon, or a raw html one: if ($this->buttonIcon && $this->buttonLabel) { $buttonLabelHtml = $this->icon($this->buttonIcon, 'icon-link__icon') . ' ' . '' . $this->transEsc($this->buttonLabel) . ''; } else { $buttonLabelHtml = $this->buttonLabelHtml ?? $this->transEsc($this->buttonLabel); } $ulAttrs = [ 'class' => 'dropdown-menu', 'role' => 'menu', 'aria-labelledby' => $buttonId, ]; $confirmAttrs = [ 'class' => 'dropdown-item', 'href' => '#', ]; if ($id = $this->confirmId) { $confirmAttrs['id'] = $id; } if ($title = $this->confirmTitle) { $confirmAttrs['title'] = $this->translate($title); } if ($class = $this->confirmClass) { $confirmAttrs['class'] .= " $class"; } if ($href = $this->confirmLink) { $confirmAttrs['href'] = $href; } if ($this->clearAccountCache) { $confirmAttrs['data-clear-account-cache'] = ''; } $cancelAttrs = [ 'class' => 'dropdown-item', 'href' => '#', ]; if ($id = $this->cancelId) { $cancelAttrs['id'] = $id; } if ($title = $this->cancelTitle) { $cancelAttrs['title'] = $this->translate($title); } if ($class = $this->cancelClass) { $cancelAttrs['class'] .= " $class"; } if ($this->ignoreLightbox) { $buttonAttrs['data-lightbox-ignore'] = ''; $confirmAttrs['data-lightbox-ignore'] = ''; $cancelAttrs['data-lightbox-ignore'] = ''; } ?>
buttonLink): ?> htmlAttributes($buttonAttrs)?>> htmlAttributes($buttonAttrs)?>> htmlAttributes($ulAttrs)?>> header): ?>
  • transEsc($this->header)?>
  • htmlAttributes($confirmAttrs)?>>confirmLabelHtml ?? $this->transEsc('confirm_dialog_yes')?>
  • htmlAttributes($cancelAttrs)?>>cancelLabelHtml ?? $this->transEsc('confirm_dialog_no')?>