Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
pix666 committed Dec 12, 2023
2 parents eab339a + 78c24a6 commit 49dc262
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 6 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Change Log

## [7.6.1](https://github.com/dldevinc/paper-admin/tree/v7.6.1) - 2023-12-12

### Bug Fixes

- The issue has been fixed where the dropzone remained in a highlighted state after dropping a file.

## [7.6.0](https://github.com/dldevinc/paper-admin/tree/v7.6.0) - 2023-12-07

### Features
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "paper-admin",
"version": "7.6.0",
"version": "7.6.1",
"description": "",
"type": "module",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion paper_admin/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
__version__ = "7.6.0"
__version__ = "7.6.1"
default_app_config = "paper_admin.apps.Config"
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
import "./paper-dropzone.scss";

const OVERLAY_CLASS = "paper-dropzone__overlay";
const OVERLAY_HIGHLIGHTED = "paper-dropzone__overlay--highlighted";


document.addEventListener(
"dragenter",
event => {
const dropzone = event.target.closest(".paper-dropzone");
if (dropzone) {
const overlay = dropzone.querySelector(".paper-dropzone__overlay");
overlay && overlay.classList.add("paper-dropzone__overlay--highlighted");
const overlay = dropzone.querySelector(`.${OVERLAY_CLASS}`);
overlay && overlay.classList.add(OVERLAY_HIGHLIGHTED);
}
},
true
Expand All @@ -17,8 +21,20 @@ document.addEventListener(
event => {
const dropzone = event.target.closest(".paper-dropzone");
if (dropzone) {
const overlay = dropzone.querySelector(".paper-dropzone__overlay");
overlay && overlay.classList.remove("paper-dropzone__overlay--highlighted");
const overlay = dropzone.querySelector(`.${OVERLAY_CLASS}`);
overlay && overlay.classList.remove(OVERLAY_HIGHLIGHTED);
}
},
true
);

document.addEventListener(
"drop",
event => {
const dropzone = event.target.closest(".paper-dropzone");
if (dropzone) {
const overlay = dropzone.querySelector(`.${OVERLAY_CLASS}`);
overlay && overlay.classList.remove(OVERLAY_HIGHLIGHTED);
}
},
true
Expand Down

0 comments on commit 49dc262

Please sign in to comment.