Commit
·
73a4307
1
Parent(s):
bb32549
- src/App.tsx +19 -19
src/App.tsx
CHANGED
@@ -141,7 +141,7 @@ const App: React.FC = () => {
|
|
141 |
return (
|
142 |
<Card className="w-full max-w-6xl mx-auto">
|
143 |
<CardHeader>
|
144 |
-
<CardTitle>LLM Pricing
|
145 |
</CardHeader>
|
146 |
<CardContent>
|
147 |
<div className="mb-4">
|
@@ -380,15 +380,15 @@ const App: React.FC = () => {
|
|
380 |
comparisonModelData.inputPrice
|
381 |
)
|
382 |
) < 0
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
|
391 |
-
|
392 |
}`}
|
393 |
>
|
394 |
{`${item.provider}:${item.name}` === comparisonModel
|
@@ -406,15 +406,15 @@ const App: React.FC = () => {
|
|
406 |
comparisonModelData.outputPrice
|
407 |
)
|
408 |
) < 0
|
409 |
-
|
410 |
-
|
411 |
-
|
412 |
-
|
413 |
-
|
414 |
-
|
415 |
-
|
416 |
-
|
417 |
-
|
418 |
}`}
|
419 |
>
|
420 |
{`${item.provider}:${item.name}` === comparisonModel
|
|
|
141 |
return (
|
142 |
<Card className="w-full max-w-6xl mx-auto">
|
143 |
<CardHeader>
|
144 |
+
<CardTitle>LLM Pricing Calculator</CardTitle>
|
145 |
</CardHeader>
|
146 |
<CardContent>
|
147 |
<div className="mb-4">
|
|
|
380 |
comparisonModelData.inputPrice
|
381 |
)
|
382 |
) < 0
|
383 |
+
? 'bg-green-100'
|
384 |
+
: parseFloat(
|
385 |
+
calculateComparison(
|
386 |
+
item.inputPrice,
|
387 |
+
comparisonModelData.inputPrice
|
388 |
+
)
|
389 |
+
) > 0
|
390 |
+
? 'bg-red-100'
|
391 |
+
: ''
|
392 |
}`}
|
393 |
>
|
394 |
{`${item.provider}:${item.name}` === comparisonModel
|
|
|
406 |
comparisonModelData.outputPrice
|
407 |
)
|
408 |
) < 0
|
409 |
+
? 'bg-green-100'
|
410 |
+
: parseFloat(
|
411 |
+
calculateComparison(
|
412 |
+
item.outputPrice,
|
413 |
+
comparisonModelData.outputPrice
|
414 |
+
)
|
415 |
+
) > 0
|
416 |
+
? 'bg-red-100'
|
417 |
+
: ''
|
418 |
}`}
|
419 |
>
|
420 |
{`${item.provider}:${item.name}` === comparisonModel
|