You own shares but the total number of shares is not fixed.
Say you own 20,000 shares out of 100,000 shares and you own 20% of the company, they issue another 9,900,000 shares 10 min befores selling the company and you now own 0.2%.
Not many, but much less relevant than the following two questions: how many dilution clauses allow something like this to happen, and how quickly would an employee find out once it did?
Usually it's common shares that are affected. If your company sells for $15 million, but $20 million was invested with 1x preference, there's not enough money to pay out investors, let alone common. It doesn't require dirty tricks like issuing more shares, and happens reasonably often.
In cases like the above, investors will often agree to take even less and allow some of the money to go directly to employees as retention bonuses. It's still sometimes better for them to get some rather than no money back.