- Updated `docker-compose.yml` to include `ADMIN_PASSWORD` environment variable for enhanced security. - Modified `index.js` to allow checkout requests to capture user names and improved email notifications with detailed information. - Added a new endpoint to fetch books currently on loan, providing better tracking of borrowed items. - Implemented a `list_books_on_loan` function in `libraryManager.py` to display books on loan in a formatted table. - Updated `models.js` to include an `approved` column in the `Checkout` model for tracking approval status. - Enhanced the user interface in `public/index.html` with a dark mode toggle and improved checkout request handling. - Updated styles in `public/styles.css` to support dark mode and improve overall aesthetics.
201 lines
3.5 KiB
CSS
201 lines
3.5 KiB
CSS
#interactive.viewport {
|
|
position: relative;
|
|
width: 100%;
|
|
height: 400px;
|
|
overflow: hidden;
|
|
border: 2px solid #000;
|
|
background-color: #c0c0c0;
|
|
}
|
|
|
|
canvas.drawing, canvas.drawingBuffer {
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
}
|
|
|
|
#book-info {
|
|
margin-top: 20px;
|
|
font-family: 'Courier New', Courier, monospace;
|
|
background-color: #f0f0f0;
|
|
border: 1px solid #000;
|
|
padding: 10px;
|
|
}
|
|
|
|
#prompt {
|
|
display: none;
|
|
margin-top: 20px;
|
|
font-family: 'Courier New', Courier, monospace;
|
|
background-color: #f0f0f0;
|
|
border: 1px solid #000;
|
|
padding: 10px;
|
|
}
|
|
|
|
#prompt-message {
|
|
font-weight: bold;
|
|
font-family: 'Courier New', Courier, monospace;
|
|
color: #800000;
|
|
}
|
|
|
|
#book-title, #book-author, #book-desc {
|
|
margin-top: 10px;
|
|
font-size: 16px;
|
|
font-family: 'Courier New', Courier, monospace;
|
|
color: #800000;
|
|
}
|
|
body {
|
|
font-family: 'Courier New', Courier, monospace;
|
|
background-color: #ddd4b0;
|
|
color: #000;
|
|
margin: 0;
|
|
padding: 0;
|
|
}
|
|
|
|
h1 {
|
|
text-align: center;
|
|
color: #800000;
|
|
font-size: 24px;
|
|
margin-top: 20px;
|
|
}
|
|
|
|
#search-bar {
|
|
display: block;
|
|
margin: 20px auto;
|
|
width: 80%;
|
|
padding: 10px;
|
|
font-size: 16px;
|
|
border: 2px solid #000;
|
|
background-color: #f0f0f0;
|
|
}
|
|
|
|
body.dark-mode #search-bar {
|
|
background-color: #333;
|
|
color: #fff;
|
|
border-color: #444;
|
|
}
|
|
|
|
#dark-mode-toggle {
|
|
position: fixed;
|
|
top: 10px;
|
|
right: 10px;
|
|
width: 40px;
|
|
height: 40px;
|
|
background-color: rgba(255, 255, 255, 0.5);
|
|
border: none;
|
|
border-radius: 50%;
|
|
cursor: pointer;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
font-size: 18px;
|
|
transition: background-color 0.3s;
|
|
opacity: 0.7;
|
|
}
|
|
|
|
#dark-mode-toggle:hover {
|
|
background-color: rgba(255, 255, 255, 0.7);
|
|
opacity: 1;
|
|
}
|
|
|
|
body.dark-mode #dark-mode-toggle {
|
|
background-color: rgba(0, 0, 0, 0.5);
|
|
}
|
|
|
|
body.dark-mode #dark-mode-toggle:hover {
|
|
background-color: rgba(0, 0, 0, 0.7);
|
|
}
|
|
|
|
table {
|
|
width: 90%;
|
|
margin: 20px auto;
|
|
border-collapse: collapse;
|
|
background-color: #fff;
|
|
}
|
|
|
|
th, td {
|
|
border: 1px solid #000;
|
|
padding: 10px;
|
|
text-align: left;
|
|
font-size: 14px;
|
|
}
|
|
|
|
th {
|
|
background-color: #c0c0c0;
|
|
cursor: pointer;
|
|
}
|
|
|
|
th:hover {
|
|
background-color: #a0a0a0;
|
|
}
|
|
|
|
a {
|
|
color: #800000;
|
|
text-decoration: none;
|
|
}
|
|
|
|
a:hover {
|
|
text-decoration: underline;
|
|
}
|
|
|
|
#book-table-body tr:nth-child(even) {
|
|
background-color: #f0f0f0;
|
|
}
|
|
|
|
#book-table-body tr:nth-child(odd) {
|
|
background-color: #e0e0e0;
|
|
}
|
|
|
|
#book-table-body tr:hover {
|
|
background-color: #d0d0d0;
|
|
}
|
|
|
|
#book-info, #prompt, #book-title, #book-author, #book-desc, th, td, body {
|
|
font-size: 18px;
|
|
font-weight: bold;
|
|
}
|
|
|
|
#search-bar:focus {
|
|
outline-color: #800000;
|
|
outline-style: solid;
|
|
outline-width: 2px;
|
|
}
|
|
|
|
body.dark-mode {
|
|
background-color: #121212;
|
|
color: #ffffff;
|
|
}
|
|
|
|
body.dark-mode table {
|
|
background-color: #2b2b2b;
|
|
}
|
|
|
|
body.dark-mode th, body.dark-mode td {
|
|
border-color: #444;
|
|
}
|
|
|
|
body.dark-mode button {
|
|
background-color: #333;
|
|
color: #fff;
|
|
}
|
|
|
|
body.dark-mode th {
|
|
background-color: #3a3a3a;
|
|
}
|
|
|
|
body.dark-mode td {
|
|
background-color: #2b2b2b;
|
|
}
|
|
|
|
body.dark-mode #book-table-body tr:nth-child(even) {
|
|
background-color: #333;
|
|
}
|
|
|
|
body.dark-mode #book-table-body tr:nth-child(odd) {
|
|
background-color: #2b2b2b;
|
|
}
|
|
|
|
body.dark-mode #book-table-body tr:hover {
|
|
background-color: #444;
|
|
}
|
|
|
|
/* Add more styles as needed for other elements */
|