Refactor Summernote initialization for consistency and improved readability

This commit is contained in:
Rinjae
2025-12-30 21:37:37 +09:00
parent 9a1e73ec4f
commit a7fe811fb9
9 changed files with 320 additions and 144 deletions
@@ -109,26 +109,10 @@
var returnUrl = getReturnUrlForReturn();
var key = "${param.id}";
$('#responseDetail').summernote({
height: 200,
toolbar: [
['style', ['style']],
['font', ['bold', 'underline', 'clear']],
['color', ['color']],
['para', ['ul', 'ol', 'paragraph']],
['table', ['table']],
['insert', ['link']],
['view', ['codeview', 'help']]
],
callbacks: {
onInit: function () {
$('.note-editable').on('keydown', function (e) {
if (e.keyCode === 8) {
e.stopPropagation();
}
});
}
}
// Summernote 에디터 초기화 (이미지 붙여넣기 data-uri 방식, 리사이징 지원)
initSummernote('#responseDetail', {
placeholder: '여기에 답변을 입력하세요.',
height: 200
});
if (key) {