-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make web working without assets (#93)
* Make web working without assets * Proper indentation * Update changelog
- Loading branch information
Showing
10 changed files
with
170 additions
and
163 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
<script> | ||
document.addEventListener('DOMContentLoaded', function() { | ||
const migrationActions = document.querySelectorAll('.migration-action'); | ||
|
||
migrationActions.forEach(button => { | ||
button.addEventListener('click', function(event) { | ||
const originalText = button.value; | ||
button.value = 'Loading...'; | ||
disableButtons(); | ||
|
||
fetch(event.target.form.action, { | ||
method: 'POST' | ||
}) | ||
.then(response => { | ||
if (response.ok) { | ||
window.location.reload(); | ||
} else { | ||
throw new Error('Network response was not ok.'); | ||
} | ||
}) | ||
.catch(error => { | ||
console.error('There has been a problem with your fetch operation:', error); | ||
enableButtons(); | ||
button.value = originalText; | ||
}); | ||
|
||
event.preventDefault(); | ||
}); | ||
}); | ||
|
||
function disableButtons() { | ||
migrationActions.forEach(button => { | ||
button.disabled = true; | ||
}); | ||
} | ||
|
||
function enableButtons() { | ||
migrationActions.forEach(button => { | ||
button.disabled = false; | ||
}); | ||
} | ||
}); | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,116 @@ | ||
<style> | ||
body { | ||
margin: 8px; | ||
background-color: #fff; | ||
color: #333; | ||
} | ||
|
||
body, p, td { | ||
font-family: helvetica, verdana, arial, sans-serif; | ||
font-size: 13px; | ||
line-height: 18px; | ||
} | ||
|
||
h2 { | ||
padding-left: 10px; | ||
} | ||
|
||
table { | ||
margin: 0; | ||
border-collapse: collapse; | ||
|
||
thead tr { | ||
border-bottom: 2px solid #ddd; | ||
} | ||
|
||
tbody { | ||
.migration-row.phantom { | ||
background-color: #fff3f3; | ||
} | ||
|
||
.migration-row.normal { | ||
background-color: #ffffff; | ||
} | ||
|
||
.migration-row:nth-child(odd).phantom { | ||
background-color: #ffe6e6; | ||
} | ||
|
||
.migration-row:nth-child(odd).normal { | ||
background-color: #f9f9f9; | ||
} | ||
} | ||
|
||
td { | ||
padding: 14px 30px; | ||
} | ||
} | ||
|
||
.top-buttons { | ||
margin: 8px; | ||
display: flex; | ||
align-items: center; | ||
|
||
.top-button { | ||
background-color: #ddd; | ||
} | ||
} | ||
|
||
.button, .top-button { | ||
font-weight: bold; | ||
color: #000; | ||
border: none; | ||
padding: 5px 10px; | ||
text-align: center; | ||
text-decoration: none; | ||
display: inline-block; | ||
margin: 0 2px; | ||
cursor: pointer; | ||
border-radius: 4px; | ||
transition: background-color 0.3s; | ||
background: none; | ||
} | ||
|
||
.button:hover, .top-button:hover { | ||
color: #fff; | ||
background-color: #000; | ||
} | ||
|
||
.button:disabled, .button:hover:disabled { | ||
background-color: transparent; | ||
color: #666; | ||
cursor: not-allowed; | ||
} | ||
|
||
.button-container { | ||
display: flex; | ||
} | ||
|
||
pre { | ||
background-color: #f7f7f7; | ||
padding: 10px; | ||
border: 1px solid #ddd; | ||
} | ||
|
||
.truncate-text { | ||
max-width: 200px; | ||
overflow: hidden; | ||
text-overflow: ellipsis; | ||
} | ||
|
||
.flash { | ||
padding: 10px; | ||
margin-bottom: 10px; | ||
border-radius: 5px; | ||
} | ||
|
||
.flash.notice { | ||
background-color: #d4edda; | ||
color: #155724; | ||
} | ||
|
||
.flash.alert { | ||
background-color: #f8d7da; | ||
color: #721c24; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters