@@ -15,17 +15,14 @@ import { CostCenterAggregator, type CostCenterResult } from './pipeline/aggregat
1515import { OrganizationAggregator , type OrganizationResult } from './pipeline/aggregators/organizationAggregator'
1616import { UserUsageAggregator , type UserUsageResult } from './pipeline/aggregators/userUsageAggregator'
1717import { runPipeline } from './pipeline/runPipeline'
18+ import { formatUsd } from './utils/format'
1819
1920type Status = 'idle' | 'processing' | 'done'
2021
2122type DatedMetric = {
2223 date : string
2324}
2425
25- function formatUsd ( n : number ) : string {
26- return `$ ${ n . toLocaleString ( undefined , { minimumFractionDigits : 2 , maximumFractionDigits : 2 } ) } `
27- }
28-
2926function formatAiu ( n : number ) : string {
3027 return n . toLocaleString ( undefined , { minimumFractionDigits : 0 , maximumFractionDigits : 3 } )
3128}
@@ -289,7 +286,7 @@ function App() {
289286 className = { `sidebar__item ${ activeView === 'overview' ? 'sidebar__item--active' : '' } ` }
290287 onClick = { ( ) => setActiveView ( 'overview' ) }
291288 >
292- < svg className = "sidebar__icon" viewBox = "0 0 24 24" fill = "none" stroke = "currentColor" strokeWidth = "1.5" strokeLinecap = "round" strokeLinejoin = "round" >
289+ < svg className = "sidebar__icon" viewBox = "0 0 24 24" fill = "none" stroke = "currentColor" strokeWidth = "1.5" strokeLinecap = "round" strokeLinejoin = "round" aria-hidden = "true" focusable = "false" >
293290 < rect x = "3" y = "3" width = "7" height = "7" rx = "1" />
294291 < rect x = "14" y = "3" width = "7" height = "7" rx = "1" />
295292 < rect x = "3" y = "14" width = "7" height = "7" rx = "1" />
@@ -304,7 +301,7 @@ function App() {
304301 disabled = { ! userUsage }
305302 onClick = { ( ) => setActiveView ( 'users' ) }
306303 >
307- < svg className = "sidebar__icon" viewBox = "0 0 24 24" fill = "none" stroke = "currentColor" strokeWidth = "1.5" strokeLinecap = "round" strokeLinejoin = "round" >
304+ < svg className = "sidebar__icon" viewBox = "0 0 24 24" fill = "none" stroke = "currentColor" strokeWidth = "1.5" strokeLinecap = "round" strokeLinejoin = "round" aria-hidden = "true" focusable = "false" >
308305 < circle cx = "12" cy = "8" r = "4" />
309306 < path d = "M20 21a8 8 0 1 0-16 0" />
310307 </ svg >
@@ -317,7 +314,7 @@ function App() {
317314 className = { `sidebar__item ${ activeView === 'models' ? 'sidebar__item--active' : '' } ` }
318315 onClick = { ( ) => setActiveView ( 'models' ) }
319316 >
320- < svg className = "sidebar__icon" viewBox = "0 0 24 24" fill = "none" stroke = "currentColor" strokeWidth = "1.5" strokeLinecap = "round" strokeLinejoin = "round" >
317+ < svg className = "sidebar__icon" viewBox = "0 0 24 24" fill = "none" stroke = "currentColor" strokeWidth = "1.5" strokeLinecap = "round" strokeLinejoin = "round" aria-hidden = "true" focusable = "false" >
321318 < path d = "M12 2L2 7l10 5 10-5-10-5Z" />
322319 < path d = "M2 17l10 5 10-5" />
323320 < path d = "M2 12l10 5 10-5" />
@@ -332,7 +329,7 @@ function App() {
332329 className = { `sidebar__item ${ activeView === 'orgs' ? 'sidebar__item--active' : '' } ` }
333330 onClick = { ( ) => setActiveView ( 'orgs' ) }
334331 >
335- < svg className = "sidebar__icon" viewBox = "0 0 24 24" fill = "none" stroke = "currentColor" strokeWidth = "1.5" strokeLinecap = "round" strokeLinejoin = "round" >
332+ < svg className = "sidebar__icon" viewBox = "0 0 24 24" fill = "none" stroke = "currentColor" strokeWidth = "1.5" strokeLinecap = "round" strokeLinejoin = "round" aria-hidden = "true" focusable = "false" >
336333 < rect x = "4" y = "3" width = "16" height = "18" rx = "1" />
337334 < path d = "M9 7h2M9 11h2M9 15h2M13 7h2M13 11h2M13 15h2" />
338335 </ svg >
@@ -346,7 +343,7 @@ function App() {
346343 className = { `sidebar__item ${ activeView === 'costCenters' ? 'sidebar__item--active' : '' } ` }
347344 onClick = { ( ) => setActiveView ( 'costCenters' ) }
348345 >
349- < svg className = "sidebar__icon" viewBox = "0 0 24 24" fill = "none" stroke = "currentColor" strokeWidth = "1.5" strokeLinecap = "round" strokeLinejoin = "round" >
346+ < svg className = "sidebar__icon" viewBox = "0 0 24 24" fill = "none" stroke = "currentColor" strokeWidth = "1.5" strokeLinecap = "round" strokeLinejoin = "round" aria-hidden = "true" focusable = "false" >
350347 < path d = "M12 3C8.5 3 6 5 6 7c0 2 2.5 4 6 4s6-2 6-4c0-2-2.5-4-6-4Z" />
351348 < path d = "M6 7v4c0 2 2.5 4 6 4s6-2 6-4V7" />
352349 < path d = "M6 11v4c0 2 2.5 4 6 4s6-2 6-4v-4" />
0 commit comments