mirror of
https://github.com/willmiao/ComfyUI-Lora-Manager.git
synced 2026-03-25 15:15:44 -03:00
Add settings links to modals; update click handler for Lora modal
This commit is contained in:
@@ -1251,6 +1251,73 @@ body.modal-open {
|
|||||||
max-width: 500px;
|
max-width: 500px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Settings Links */
|
||||||
|
.settings-links {
|
||||||
|
margin-top: var(--space-3);
|
||||||
|
padding-top: var(--space-2);
|
||||||
|
border-top: 1px solid var(--lora-border);
|
||||||
|
display: flex;
|
||||||
|
gap: var(--space-2);
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.settings-link {
|
||||||
|
width: 36px;
|
||||||
|
height: 36px;
|
||||||
|
border-radius: 50%;
|
||||||
|
background: var(--card-bg);
|
||||||
|
border: 1px solid var(--border-color);
|
||||||
|
color: var(--text-color);
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
cursor: pointer;
|
||||||
|
transition: all 0.2s ease;
|
||||||
|
text-decoration: none;
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.settings-link:hover {
|
||||||
|
background: var(--lora-accent);
|
||||||
|
color: white;
|
||||||
|
transform: translateY(-2px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.settings-link i {
|
||||||
|
font-size: 1.1em;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Tooltip styles */
|
||||||
|
.settings-link::after {
|
||||||
|
content: attr(title);
|
||||||
|
position: absolute;
|
||||||
|
bottom: calc(100% + 8px);
|
||||||
|
left: 50%;
|
||||||
|
transform: translateX(-50%);
|
||||||
|
background: rgba(0, 0, 0, 0.8);
|
||||||
|
color: white;
|
||||||
|
padding: 4px 8px;
|
||||||
|
border-radius: 4px;
|
||||||
|
font-size: 0.8em;
|
||||||
|
white-space: nowrap;
|
||||||
|
opacity: 0;
|
||||||
|
visibility: hidden;
|
||||||
|
transition: opacity 0.2s, visibility 0.2s;
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.settings-link:hover::after {
|
||||||
|
opacity: 1;
|
||||||
|
visibility: visible;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Responsive adjustment */
|
||||||
|
@media (max-width: 480px) {
|
||||||
|
.settings-links {
|
||||||
|
flex-wrap: wrap;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.api-key-input {
|
.api-key-input {
|
||||||
position: relative;
|
position: relative;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|||||||
@@ -54,8 +54,8 @@ export class ModalManager {
|
|||||||
isOpen: false
|
isOpen: false
|
||||||
});
|
});
|
||||||
|
|
||||||
// Only add click outside handler if it's not the download modal
|
// Only add click outside handler if it's the lora modal
|
||||||
if (id !== 'downloadModal') {
|
if (id == 'loraModal') {
|
||||||
config.element.addEventListener('click', (e) => {
|
config.element.addEventListener('click', (e) => {
|
||||||
if (e.target === config.element) {
|
if (e.target === config.element) {
|
||||||
this.closeModal(id);
|
this.closeModal(id);
|
||||||
|
|||||||
@@ -99,5 +99,14 @@
|
|||||||
<div class="modal-actions">
|
<div class="modal-actions">
|
||||||
<button class="primary-btn" onclick="settingsManager.saveSettings()">Save</button>
|
<button class="primary-btn" onclick="settingsManager.saveSettings()">Save</button>
|
||||||
</div>
|
</div>
|
||||||
|
<!-- Add the new links section -->
|
||||||
|
<div class="settings-links">
|
||||||
|
<a href="https://github.com/willmiao/ComfyUI-Lora-Manager" target="_blank" class="settings-link" title="GitHub Repository">
|
||||||
|
<i class="fab fa-github"></i>
|
||||||
|
</a>
|
||||||
|
<a href="https://github.com/willmiao/ComfyUI-Lora-Manager/issues/new" target="_blank" class="settings-link" title="Report Issue">
|
||||||
|
<i class="fas fa-bug"></i>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
Reference in New Issue
Block a user