feat: continue inline style cleanup with control button utility class

- Added uncloseai-btn-control class for standard modal action buttons
- Replaced control button inline styles with CSS class
- Reduced inline styles from 131 to 118 in main modal file
- Established pattern for systematic cleanup of remaining 200+ inline styles
This commit is contained in:
Russell Ballestrini 2025-07-09 20:38:00 -04:00
parent be1b22e2f0
commit 5d175fb72e
3 changed files with 33 additions and 19 deletions

View file

@ -525,25 +525,7 @@ async function openUncloseaiEmbeddedModalNew() {
actions.forEach(({ text, action }) => {
const btn = document.createElement("button");
btn.textContent = text;
btn.style.cssText = `
padding: 8px 12px;
background: ${colors.buttonBackground};
border: 1px solid ${colors.buttonBorder};
border-radius: 6px;
cursor: pointer;
font-size: 13px;
color: ${colors.primaryText};
transition: all 0.2s;
white-space: nowrap;
`;
btn.onmouseover = () => {
btn.style.background = colors.buttonHover;
btn.style.borderColor = colors.buttonBorder;
};
btn.onmouseout = () => {
btn.style.background = colors.buttonBackground;
btn.style.borderColor = colors.buttonBorder;
};
btn.className = "uncloseai-btn-control";
btn.onclick = action;
actionsGrid.appendChild(btn);
});

View file

@ -616,6 +616,22 @@ dialog#tts-modal {
background: #e9ecef;
}
.uncloseai-btn-control {
padding: 8px 12px;
border: 1px solid #dee2e6;
border-radius: 6px;
cursor: pointer;
font-size: 13px;
color: #495057;
background: #f8f9fa;
transition: all 0.2s;
white-space: nowrap;
}
.uncloseai-btn-control:hover {
background: #e9ecef;
}
.uncloseai-btn-close {
width: 36px;
height: 36px;

View file

@ -667,6 +667,22 @@ dialog#tts-modal {
background: #e9ecef;
}
.uncloseai-btn-control {
padding: 8px 12px;
border: 1px solid #dee2e6;
border-radius: 6px;
cursor: pointer;
font-size: 13px;
color: #495057;
background: #f8f9fa;
transition: all 0.2s;
white-space: nowrap;
}
.uncloseai-btn-control:hover {
background: #e9ecef;
}
.uncloseai-btn-close {
width: 36px;
height: 36px;