Skip to content

Commit

Permalink
Подготовка к защите проекта
Browse files Browse the repository at this point in the history
  • Loading branch information
lenapokrovskaya committed Jan 21, 2025
1 parent dd788c4 commit 9ed2fda
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions js/form-validation.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,4 +75,5 @@ pristine.addValidator(hashtagsInputElement, validatesHashtagWithRegex, 'Введ
pristine.addValidator(hashtagsInputElement, validatesHashtagRepeats, 'Хэштеги повторяются');
pristine.addValidator(descriptionInutElement, validatesCommentLength, `Длина комментария больше ${MAX_COMMENT_LENGTH} символов`);


export {setUserFormSubmit, resetValidator};
1 change: 0 additions & 1 deletion js/modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ const renderModal = (posts) => {
const currentPictureElement = evt.target.closest('.picture');
if (currentPictureElement) {
evt.preventDefault();
//Находим элемент из массива постов с таким же id как у текущего элемента
const foundedPictureByIdElement = posts.find((picture) => picture.id === Number(currentPictureElement.getAttribute('data-picture-id')));
renderBigPicture(foundedPictureByIdElement);
openModal();
Expand Down
1 change: 1 addition & 0 deletions js/upload-photo-form.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ function closeUploadForm() {
bodyElement.classList.remove('modal-open');
document.removeEventListener('keydown', onDocumentKeydown);
buttonUploadCancelElement.removeEventListener('click', onCloseButtonClick);
imgUploadFormElement.removeEventListener('submit', setUserFormSubmit);
resetPhotoEditor();
resetValidator();
}
Expand Down

0 comments on commit 9ed2fda

Please sign in to comment.