Skip to content

Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS

sort app quality category breakdown by ascending score

[._.]/ Adam Eivy95600888484c
diff --git a/client/src/components/apps/AppQuality.jsx b/client/src/components/apps/AppQuality.jsx
index 58a6a9d12f..010d0d671a 100644
--- a/client/src/components/apps/AppQuality.jsx
+++ b/client/src/components/apps/AppQuality.jsx
@@ -14,6 +14,9 @@ export default function AppQuality({ app, detail = false }) {
return { search: next.toString(), hash: '#quality-runner' };
};
const score = quality?.score;
+ const sortedCategories = quality?.categories
+ ? [...quality.categories].sort((a, b) => (a.score ?? Infinity) - (b.score ?? Infinity))
+ : [];
const hasAssessments = quality?.categories?.some(category => category.assessedAt);
const unscoredLabel = hasAssessments ? 'Quality: no qualifying score' : 'Quality: not assessed';
const label = quality?.unavailable ? 'Quality unavailable'
@@ -67,7 +70,7 @@ export default function AppQuality({ app, detail = false }) {
<h4 className="text-sm font-medium mb-2">Category breakdown</h4>
<table className="w-full text-sm text-left">
<thead className="text-gray-400 sticky top-0 bg-port-card"><tr><th className="py-2 pr-3">Category</th><th className="pr-3">Score</th><th>Evidence</th></tr></thead>
- <tbody>{quality.categories.map(category => (
+ <tbody>{sortedCategories.map(category => (
<Fragment key={category.id}><tr className={`border-t border-port-border align-top${score != null && category.score != null && category.coverage !== 'not-applicable' && category.score < score ? ' bg-port-warning/10' : ''}`}>
<th scope="row" className="py-2 pr-3 font-medium">{category.label}<Link className="block text-xs font-normal text-port-accent hover:underline" to={`/cos/schedule?task=${encodeURIComponent(category.id)}`} aria-label={`${category.label} runner`}>Runner settings</Link></th>
<td className="py-2 pr-3 whitespace-nowrap">{category.score == null ? '—' : `${category.score}/100`}</td>
diff --git a/client/src/components/apps/AppQuality.test.jsx b/client/src/components/apps/AppQuality.test.jsx
index 24b19def6b..19efeb7827 100644
--- a/client/src/components/apps/AppQuality.test.jsx
+++ b/client/src/components/apps/AppQuality.test.jsx
@@ -64,6 +64,19 @@ it('makes the category actions look like distinct clickable controls', async ()
expect(screen.getByRole('link', { name: 'View audit run for Security' })).toHaveClass('inline-flex', 'border', 'bg-port-bg/40', 'rounded');
});
+it('orders the category breakdown from lowest score to highest, with unscored categories last', async () => {
+ const app = { id: 'example', quality: { categories: [
+ { id: 'ux', label: 'UX', score: 80, coverage: 'broad' },
+ { id: 'security', label: 'Security', score: 20, coverage: 'broad' },
+ { id: 'perf', label: 'Perf', score: null, coverage: 'unavailable' },
+ { id: 'tests', label: 'Tests', score: 60, coverage: 'broad' },
+ ] } };
+ render(<MemoryRouter><AppQuality app={app} detail /></MemoryRouter>);
+ await screen.findByText(/No scored assessments/);
+ const rowLabels = screen.getAllByRole('row').slice(1).map(row => within(row).queryByRole('rowheader')?.textContent);
+ expect(rowLabels.filter(Boolean)).toEqual(['SecurityRunner settings', 'TestsRunner settings', 'UXRunner settings', 'PerfRunner settings']);
+});
+
it('opens the shared runner beside unavailable category evidence while preserving URL filters', async () => {
const app = { id: 'example', quality: { categories: [
{ id: 'security', label: 'Security', score: null, coverage: 'unavailable' },