1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | 1× 1× 1× 1× 1× 1× 46× 45× 1× 47× 47× 3× 44× 1× 50× | "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.add = add; exports.remove = remove; exports.count = count; var modals = []; function add(element) { if (modals.indexOf(element) === -1) { modals.push(element); } } function remove(element) { var index = modals.indexOf(element); if (index === -1) { return; } modals.splice(index, 1); } function count() { return modals.length; } |