mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-03 21:15:42 +02:00
[ticket/12542] Add initial drag-n-drop animation
PHPBB3-12542
This commit is contained in:
parent
0bc352ea7e
commit
46a789de5c
@ -1232,6 +1232,14 @@ phpbb.applyCodeEditor = function(textarea) {
|
||||
});
|
||||
};
|
||||
|
||||
phpbb.applyDragNDrop = function(textarea) {
|
||||
$('html').on('dragenter dragover', function () {
|
||||
$(textarea).addClass('drag-n-drop');
|
||||
}).on('dragleave dragout dragend drop', function() {
|
||||
$(textarea).removeClass('drag-n-drop');
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* List of classes that toggle dropdown menu,
|
||||
* list of classes that contain visible dropdown menu
|
||||
|
@ -355,6 +355,7 @@ function getCaretPosition(txtarea) {
|
||||
textarea = doc.forms[form_name].elements[text_name];
|
||||
|
||||
phpbb.applyCodeEditor(textarea);
|
||||
phpbb.applyDragNDrop(textarea);
|
||||
});
|
||||
})(jQuery);
|
||||
|
||||
|
@ -977,6 +977,10 @@ fieldset.quick-login input.inputbox {
|
||||
color: #333333;
|
||||
}
|
||||
|
||||
#message-box textarea.drag-n-drop {
|
||||
outline-color: rgba(17, 163, 234, 0.7);
|
||||
}
|
||||
|
||||
/* Input field styles
|
||||
---------------------------------------- */
|
||||
.inputbox {
|
||||
|
@ -243,6 +243,9 @@ fieldset.submit-buttons input {
|
||||
max-width: 100%;
|
||||
font-size: 1.2em;
|
||||
resize: vertical;
|
||||
outline: 3px dashed transparent;
|
||||
outline-offset: -4px;
|
||||
transition: .5s;
|
||||
}
|
||||
|
||||
/* Emoticons panel */
|
||||
|
Loading…
x
Reference in New Issue
Block a user