From 84e7597bc869e6040ec45135876487aee33334c2 Mon Sep 17 00:00:00 2001 From: Claudio Santos Date: Tue, 26 Jul 2022 23:17:22 -0400 Subject: [PATCH] ui improvements --- src/ui/options/options.css | 13 +++++++++++++ src/ui/options/options.js | 8 ++++++++ 2 files changed, 21 insertions(+) diff --git a/src/ui/options/options.css b/src/ui/options/options.css index 683de009..ffe71b9f 100644 --- a/src/ui/options/options.css +++ b/src/ui/options/options.css @@ -94,6 +94,19 @@ body { margin-right:auto; } +.domain:last-child { + border-bottom-left-radius: 10px; + border-bottom-right-radius: 10px; +} + +.animated { + transition: all 0.8s ease; +} + +.brightDomain { + color: red; +} + #row-default { background-color:#cad9f7; } diff --git a/src/ui/options/options.js b/src/ui/options/options.js index bba18aa3..fa5f9bf4 100644 --- a/src/ui/options/options.js +++ b/src/ui/options/options.js @@ -46,6 +46,14 @@ const fillRow = (row, domain) => { [...row.getElementsByClassName('default-option')].forEach(opt => opt.remove()) } + resetButton.addEventListener('click', () => { + row.classList.add('brightDomain') + setTimeout(() => row.classList.add('animated'), 0) + setTimeout(() => row.classList.remove('brightDomain'), 0) + setTimeout(() => row.classList.remove('animated'), 800) + + }); + const wireConfig = (config, updateInput, updateConfig) => { const input = row.getElementsByClassName(config).item(0)