diff --git a/frontend/src/lib/components/policy/PolicyCard.svelte b/frontend/src/lib/components/policy/PolicyCard.svelte
index 7619458..113999e 100644
--- a/frontend/src/lib/components/policy/PolicyCard.svelte
+++ b/frontend/src/lib/components/policy/PolicyCard.svelte
@@ -509,10 +509,10 @@
flex-shrink: 0;
align-items: center;
- width: 2.125rem;
- height: 1.25rem;
+ width: 2.25rem;
+ height: 1.375rem;
padding: 0.125rem;
- border-radius: 0.625rem;
+ border-radius: 0.6875rem;
background-color: var(--color-borders-input);
@@ -524,8 +524,8 @@
}
.knob {
- width: 1rem;
- height: 1rem;
+ width: 1.125rem;
+ height: 1.125rem;
border-radius: 50%;
background-color: var(--color-white);
diff --git a/frontend/src/lib/components/policy/PolicyEditor.svelte b/frontend/src/lib/components/policy/PolicyEditor.svelte
index fcf17ce..ceb7685 100644
--- a/frontend/src/lib/components/policy/PolicyEditor.svelte
+++ b/frontend/src/lib/components/policy/PolicyEditor.svelte
@@ -107,9 +107,11 @@
}
function reveal(node: HTMLElement) {
- requestAnimationFrame(() => {
+ const observer = new ResizeObserver(() => {
node.parentElement?.scrollIntoView({ block: "nearest" });
});
+ observer.observe(node);
+ return () => observer.disconnect();
}
function draftBefore(rule: PolicyRule): boolean {
@@ -237,13 +239,21 @@
{/if}
-