mirror of
https://github.com/FoggedLens/iD.git
synced 2026-05-15 13:38:26 +02:00
Add flash
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
iD.flash = function() {
|
||||
var modal = iD.modal();
|
||||
|
||||
modal.select('.modal').classed('modal-alert', true);
|
||||
|
||||
modal.select('.content')
|
||||
.classed('modal-section', true)
|
||||
.append('div')
|
||||
.attr('class', 'description');
|
||||
|
||||
modal.on('click.flash', function() { modal.remove(); });
|
||||
|
||||
d3.timer(function() {
|
||||
modal.remove();
|
||||
return true;
|
||||
}, 1000);
|
||||
|
||||
return modal;
|
||||
};
|
||||
Reference in New Issue
Block a user