Skip to content

Commit

Permalink
new: We use simple fade animation on dialog open, instead of slide down
Browse files Browse the repository at this point in the history
dev: Code cleanup
  • Loading branch information
lscambo13 committed Jan 4, 2024
1 parent 9ef22c5 commit 0e78777
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 23 deletions.
14 changes: 7 additions & 7 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
});
}
</script> -->
<link rel="manifest" href="manifest.json?v=1703602562286">
<link rel="icon" type="image/x-icon" href="./favicon.ico?v=1703602562286">
<link rel="manifest" href="manifest.json?v=1703602562287">
<link rel="icon" type="image/x-icon" href="./favicon.ico?v=1703602562287">
<title>Search &bull; Casa Mia</title>
<meta name="theme-color" content="black">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
Expand All @@ -29,10 +29,10 @@
rel="stylesheet" />
<link rel="stylesheet" href="./icons.css" />
<link rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css?v=1703602562286">
<link rel="stylesheet" href="./animations.css?v=1703602562286">
<link rel="stylesheet" href="./style.css?v=1703602562286" />
<script src="./index.js?v=1703602562286" type="module"></script>
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css?v=1703602562287">
<link rel="stylesheet" href="./animations.css?v=1703602562287">
<link rel="stylesheet" href="./style.css?v=1703602562287" />
<script src="./index.js?v=1703602562287" type="module"></script>
</head>

<body>
Expand All @@ -47,7 +47,7 @@
<div class="header-right-block">WEATHER</div>
</div>
<div id="wrap" class="startup_slide_down">
<div class="flex-main-container-vertical">
<div id="flex-main-container-vertical" class="flex-main-container-vertical">
<div id="home-widget-container"><i id="left-arrow" class="arrows fa fa-caret-left"></i>
<div class="home-widget">
<div id="main-heading-slider" class="nowrap disable-select">
Expand Down
1 change: 0 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ import {
applyPreferences,
askCustomDomain,
askCustomText,
focusSearchBar,
loadDropdownPositions,
loadSelectedWidgetStyle,
scrollToBottom,
Expand Down
4 changes: 0 additions & 4 deletions js_modules/custom_bookmarks.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,17 +96,13 @@ export function downloadBookmarks(filename, text) {
'data:text/plain;charset=utf-8,' + encodeURIComponent(text),
);
element.setAttribute('download', filename);

element.style.display = 'none';
document.body.appendChild(element);

element.click();

document.body.removeChild(element);
}

export function editBookmark(event) {
// console.log('click ' + event.target.parentNode.id);
event.preventDefault();
event.stopPropagation();
const targetElement = event.target.parentNode;
Expand Down
8 changes: 0 additions & 8 deletions js_modules/utils/alertDialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,16 +77,8 @@ const showAlertDialog = (

const promise = new Promise((resolve, reject) => {
alertModalContainer.style.alignItems = 'center';
// alertModalContainer.style.paddingBlockStart = '0em';
alertModalContainer.style.opacity = '1';

// const rejectModal = () => {
// // modalCancelButton.removeEventListener('click', rejectModal);
// // alertModalContainer.remove();
// // document.body.style.overflow = 'auto';
// reject(Error(null));
// };

const resolveModal = () => {
modalCancelButton.removeEventListener('click', resolveModal);
if (tickBox[0]) {
Expand Down
2 changes: 1 addition & 1 deletion js_modules/utils/blurLevel.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ export function blurLevel(int) {
.setProperty('--blur-one-em', `blur(${int}em)`);
document.documentElement.style
.setProperty('--blur-one-px', `blur(${int}px)`);
}
}
2 changes: 1 addition & 1 deletion js_modules/utils/inputDialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ const showInputDialog = (
if (!cancelButtonName) modalCancelButton.style.display = 'none';

const promise = new Promise((resolve, reject) => {
modalContainer.style.paddingBlockStart = '4em';
// modalContainer.style.paddingBlockStart = '4em';
modalContainer.style.opacity = '1';

const rejectModal = () => {
Expand Down
2 changes: 1 addition & 1 deletion style.css
Original file line number Diff line number Diff line change
Expand Up @@ -1042,7 +1042,7 @@ input::-webkit-search-cancel-button:hover {
justify-content: center;
padding-block-start: 2em;
opacity: 0;
transition: 125ms;
transition: 200ms;
}

.modal {
Expand Down

0 comments on commit 0e78777

Please sign in to comment.