mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-22 11:17:05 +02:00
feat: state passing
This commit is contained in:
1 parent
a0d6aecf7a
commit
fa489a665a
2 files changed
+28
-3
No files matched your search
@@ -30,5 +30,13 @@ export function BreakdownPreview() {
|
||||
export function BreakdownRenderer() {
|
||||
const { useState } = useEmbedStateCurry<typeof breakdownConfig>();
|
||||
|
||||
return useState('cardBodyBackgroundColor');
|
||||
return (
|
||||
<BreakdownEmbedWrapper>
|
||||
{useState('showTotal') && <BreakdownEmbedCard tank={null} />}
|
||||
|
||||
{tanks.slice(0, useState('listMaxTanks')).map((tank) => (
|
||||
<BreakdownEmbedCard key={tank.id} tank={tank} />
|
||||
))}
|
||||
</BreakdownEmbedWrapper>
|
||||
);
|
||||
}
|
||||
Reference in new issue
Block a user