currency api notice

This commit is contained in:
whilb 2025-09-01 20:30:45 -07:00
parent 5ec3a6006f
commit 1f8cfcee86

View file

@ -107,10 +107,28 @@ export default {
cursor: pointer; cursor: pointer;
transition: background 0.2s; transition: background 0.2s;
`; `;
fetchBtn.addEventListener('mouseenter', () => fetchBtn.style.background = 'var(--accent-hover)'); fetchBtn.addEventListener('mouseenter', () => fetchBtn.style.opacity = '0.9');
fetchBtn.addEventListener('mouseleave', () => fetchBtn.style.background = 'var(--accent)'); fetchBtn.addEventListener('mouseleave', () => fetchBtn.style.opacity = '1');
ui.append(fetchBtn); ui.append(fetchBtn);
// External API notice
const noticeDiv = document.createElement('div');
noticeDiv.style.cssText = `
margin: 10px 0;
padding: 12px;
background: var(--k-bg);
border: 1px solid var(--border);
border-radius: 6px;
font-size: 13px;
color: var(--muted);
line-height: 1.4;
`;
noticeDiv.innerHTML = `
<strong>External API Notice:</strong> Updating exchange rates requires an external call to exchangerate-api.com.
Your browser will make a request to fetch the latest rates. Your IP address will be visible to the API provider.
`;
ui.append(noticeDiv);
const out = document.createElement('div'); const out = document.createElement('div');
out.className = 'result'; out.className = 'result';
out.style.cssText = ` out.style.cssText = `