Do you have a re-entry permit in your passport ?
It appears that you were stamped in until the end of your current Non B visa extension of stay with you having a Thai work permit.
Let's see if others have a helpful reply. As it's now after midnight of a new day in Thailand, and you are flying this day.
What is your passport nation ?
If you have ended work in Thailand...I assume that you did not cancel your work permit not have told Thai Immigration that you are no longer employed.
That's a problem for you.
My advice is ... NOT 🚫 LEAVE THAILAND as planned.
Let's see what our Moderator
@ ************
s says in the morning.