。
She made the same mistake she'd made before.
Literal
She [topic-は] before [with-と] same mistake [object-を] did.
~と同じ is the basic comparative-equivalence frame — 'the same as X.' The と here is the 'compared with' particle, distinct from the と of accompaniment. 間違いをする ('make a mistake') is one of two productive frames; 間違える (the verb on its own) and ミスをする (with the loanword) cover similar ground. Repeating 'the same mistake' implies a learning failure, often used as gentle critique.