Fix loading of recommended methods

This commit is contained in:
adilallo
2026-05-26 09:03:18 -06:00
parent 2871df27b2
commit 8420ce42e3
11 changed files with 261 additions and 58 deletions
@@ -108,7 +108,8 @@ export function DecisionApproachesScreen() {
[da.methods, selectedIds, state.customMethodCardMetaById],
);
const { sampleCards, compactCardIds, methodById } = useMethodCardDeckOrdering(
const { sampleCards, compactCardIds, methodById, recommendationsReady } =
useMethodCardDeckOrdering(
"decisionApproaches",
mergedMethods,
selectedIds,
@@ -761,7 +762,11 @@ export function DecisionApproachesScreen() {
</div>
}
>
<div className="flex w-full min-w-0 flex-col items-stretch gap-6 py-0">
<div
className="flex w-full min-w-0 flex-col items-stretch gap-6 py-0"
aria-busy={!recommendationsReady}
>
{recommendationsReady ? (
<CardStack
cards={sampleCards}
selectedIds={selectedIds}
@@ -791,6 +796,7 @@ export function DecisionApproachesScreen() {
className="w-full"
headerLockupSize={mdUp ? "L" : "M"}
/>
) : null}
</div>
<Create