Skip to content

Commit

Permalink
move transform to button.css
Browse files Browse the repository at this point in the history
  • Loading branch information
jonfriesen committed Aug 25, 2024
1 parent d84977e commit 9dc789f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
8 changes: 0 additions & 8 deletions src/content/content.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,6 @@ function injectOrUpdateButton(config) {
button.className = `copy-button ${selectedStyle}`
button.innerHTML = `<img src="${chrome.runtime.getURL(icon)}" alt="Copy Info">`

button.addEventListener('mouseenter', () => {
button.style.transform = 'scale(1.05)'
})

button.addEventListener('mouseleave', () => {
button.style.transform = 'scale(1)'
})

button.addEventListener('click', () => {
const siteConfig = siteConfigs[config.siteKey]
const pageConfig = siteConfig.pages[config.pageKey]
Expand Down
4 changes: 4 additions & 0 deletions src/styles/button.css
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,10 @@
border-color: var(--retro-success-border);
}

.copy-button:hover {
transform: scale(1.05);
}

/* Styles for popup */
.style-option {
display: inline-flex;
Expand Down

0 comments on commit 9dc789f

Please sign in to comment.