feat: pattern convergence UI — thematic filter, signal direction, conviction score

TradeIdeas.tsx:
- THEMATIC_CATEGORIES const (8 catégories: géopolitique, macro_monétaire, technique,
  commodités_supply, risk_off, flux_saisonnier, géo_économique, crédit_stress)
- SIGNAL_DIR map (bullish ▲ vert / bearish ▼ rouge / volatility ⟷ violet / neutral ↔ gris)
- TradeItem interface: + category, signalDirection, convictionScore, convictionBonus,
  convergenceCount, convergencePartners
- useMemo: double filter (asset_class + thematic category); sort by conviction_score;
  populate new fields from pattern + scoreInfo
- Toolbar: thematic filter row (violet) séparé du filtre asset_class (bleu)
- TradeCard: category badge violet, signal direction arrow, conviction badge ⟳+N,
  convergence banner quand count > 0
- TradeRow: score column shows conviction_score + ⟳+N bonus; direction arrow;
  category chip abrégé dans le nom pattern

useApi.ts: useUpdateCycleConfig type extended with weekend_cycle_enabled + weekend_cycle_times

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
OpenSquared
2026-06-21 20:31:55 +02:00
parent 952e326590
commit f8a0a6d023
2 changed files with 116 additions and 36 deletions

View File

@@ -322,7 +322,7 @@ export const useCycleHistory = (limit = 20) =>
export const useUpdateCycleConfig = () => {
const qc = useQueryClient()
return useMutation({
mutationFn: (cfg: { enabled?: boolean; interval_hours?: number; similarity_threshold?: number; min_ev_threshold?: number; min_score_threshold?: number; journal_retention_days?: number; maturity_threshold_pct?: number }) =>
mutationFn: (cfg: { enabled?: boolean; interval_hours?: number; similarity_threshold?: number; min_ev_threshold?: number; min_score_threshold?: number; journal_retention_days?: number; maturity_threshold_pct?: number; weekend_cycle_enabled?: boolean; weekend_cycle_times?: string }) =>
api.post('/cycle/config', cfg).then(r => r.data),
onSuccess: () => qc.invalidateQueries({ queryKey: ['cycle-status'] }),
})