diff --git a/src/features/background/options/Custom.jsx b/src/features/background/options/Custom.jsx index 1950c792..80c2479a 100644 --- a/src/features/background/options/Custom.jsx +++ b/src/features/background/options/Custom.jsx @@ -9,11 +9,10 @@ import { MdFolder, } from 'react-icons/md'; import { addCustomImage, getCustomImages, deleteCustomImage } from 'utils/indexedDB'; - import { Tooltip, Button } from 'components/Elements'; import Modal from 'react-modal'; - import CustomURLModal from './CustomURLModal'; +import { motion, AnimatePresence } from 'framer-motion'; export default class CustomSettings extends PureComponent { getMessage = (text, obj) => variables.getMessage(text, obj || {}); @@ -123,50 +122,71 @@ export default class CustomSettings extends PureComponent {
- {this.state.customBackground.length > 0 ? ( -
- {this.state.customBackground.map((image, index) => ( -
- {'Custom - + {this.state.customBackground.length > 0 ? ( + + {this.state.customBackground.map((image, index) => ( + -
- ))} -
- ) : ( -
-
- - - {variables.getMessage('settings:sections.background.source.drop_to_upload')} - - - {variables.getMessage('settings:sections.background.source.formats', { - list: 'jpeg, png, webp, webm, gif, mp4, webm, ogg', - })} - -
-
- )} + + )} +
{ diff --git a/src/features/background/scss/index.scss b/src/features/background/scss/index.scss index c09143e5..646318eb 100644 --- a/src/features/background/scss/index.scss +++ b/src/features/background/scss/index.scss @@ -75,7 +75,15 @@ } } -.dropzone.dragging { - border: 2px dashed #007bff; - background-color: rgba(0, 123, 255, 0.1); +.dropzone { + border: 2px dashed transparent; + background-color: transparent; + transition: + border 0.3s ease-in-out, + background-color 0.3s ease-in-out; + + &.dragging { + border: 2px dashed #007bff; + background-color: rgba(0, 123, 255, 0.1); + } }