Skip to content

Agent Zero AI framework

Refine skills modal toggle styling

Alessandroecb80d387633
diff --git a/plugins/_skills/webui/config-store.js b/plugins/_skills/webui/config-store.js
index d47beaba1..10136f3a9 100644
--- a/plugins/_skills/webui/config-store.js
+++ b/plugins/_skills/webui/config-store.js
@@ -110,26 +110,6 @@ window.createSkillsConfigModel = (context, config) => ({
return this.selectedSkills.length;
},
- get selectedCountLabel() {
- return `${this.selectedCount} / ${this.maxActiveSkills}`;
- },
-
- get hiddenCount() {
- return this.catalog.filter((skill) => this.isHidden(skill)).length;
- },
-
- get visibleCount() {
- return Math.max(0, this.catalog.length - this.hiddenCount);
- },
-
- get visibilityCountLabel() {
- return `${this.visibleCount} visible / ${this.hiddenCount} hidden`;
- },
-
- get currentCountLabel() {
- return this.mode === "visible" ? this.visibilityCountLabel : this.selectedCountLabel;
- },
-
get catalogMap() {
const byKey = new Map();
for (const skill of this.catalog) {
diff --git a/plugins/_skills/webui/config.html b/plugins/_skills/webui/config.html
index 469ddde3b..09afa6635 100644
--- a/plugins/_skills/webui/config.html
+++ b/plugins/_skills/webui/config.html
@@ -28,16 +28,17 @@
<div class="skills-mode-toggle" role="tablist" aria-label="Skills mode">
<button
type="button"
- class="button"
+ class="skills-mode-button"
:class="{ 'is-active': mode === 'visible' }"
@click="setMode('visible')"
>
<span class="icon material-symbols-outlined">visibility</span>
Visible
</button>
+ <span class="skills-mode-separator" aria-hidden="true">/</span>
<button
type="button"
- class="button"
+ class="skills-mode-button"
:class="{ 'is-active': mode === 'pinned' }"
@click="setMode('pinned')"
>
@@ -47,7 +48,6 @@
</div>
<div class="skills-actions">
- <span class="skills-count" x-text="currentCountLabel"></span>
<button type="button" class="button" @click="loadCatalog()" :disabled="loadingCatalog || mutatingChat">
<span class="icon material-symbols-outlined">refresh</span>
Refresh
@@ -188,30 +188,44 @@
.skills-mode-toggle {
display: flex;
align-items: center;
- gap: 0.35rem;
+ gap: 0.45rem;
flex: 0 0 auto;
- border: 1px solid var(--color-border);
- border-radius: 0.5rem;
- background: var(--color-bg-primary);
- padding: 0.2rem;
}
- .skills-mode-toggle .button {
+ .skills-mode-button {
+ display: inline-flex;
+ align-items: center;
+ gap: 0.35rem;
+ padding: 0;
border: none;
background: transparent;
- min-height: 2rem;
+ min-height: 0;
+ color: var(--color-text-secondary);
+ font: inherit;
+ font-weight: 650;
+ cursor: pointer;
+ transition: color 0.15s ease, opacity 0.15s ease;
}
- .skills-mode-toggle .button.is-active {
- background: color-mix(in srgb, var(--color-primary) 14%, var(--color-bg-primary));
- color: var(--color-primary);
+ .skills-mode-button:hover {
+ color: var(--color-text);
+ filter: none;
+ box-shadow: none;
}
- .skills-count {
+ .skills-mode-button.is-active {
+ color: var(--color-text);
+ }
+
+ .skills-mode-button:focus-visible {
+ outline: none;
+ color: var(--color-text);
+ }
+
+ .skills-mode-separator {
color: var(--color-text-secondary);
- font-size: var(--font-size-small);
- font-weight: 600;
- white-space: nowrap;
+ font-weight: 500;
+ user-select: none;
}
.skills-help,