|
|
@ -65,6 +65,10 @@ export default class PopupElement { |
|
|
|
if(buttons && buttons.length) { |
|
|
|
if(buttons && buttons.length) { |
|
|
|
const buttonsDiv = document.createElement('div'); |
|
|
|
const buttonsDiv = document.createElement('div'); |
|
|
|
buttonsDiv.classList.add('popup-buttons'); |
|
|
|
buttonsDiv.classList.add('popup-buttons'); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(buttons.length === 2) { |
|
|
|
|
|
|
|
buttonsDiv.classList.add('popup-buttons-row'); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
const buttonsElements = buttons.map(b => { |
|
|
|
const buttonsElements = buttons.map(b => { |
|
|
|
const button = document.createElement('button'); |
|
|
|
const button = document.createElement('button'); |
|
|
|