In a direct democracy it can't be vague generalizations that the actual rulers, who are distinct from the electorate, get to choose whether and how to apply and whether or not the electorate can reconsider it, because if there are actual rulers distinct from the electorate it's not a direct democracy.
There is no pure direct democracy at scale. You're still going to delegate authority to people doing things, and rely on their expert opinions when it comes to what to vote on.
But in any case, in a direct democracy, if enough people want to vote on something, they can, regardless of how stupid it is. That would include Brexit etc.
If that split is over something with no middle ground, that every person considers more important than everything else put together (including survival of the democracy), then it quite simply doesn't.
Otherwise, if it's to survive, it does so by compromise, tradeoffs, bargaining, and leaving many people at least a little unhappy but not enough people unhappy enough to dismantle the system.
Brexit is not a failure of direct democracy.