Log out of Plasma, then log in on a TTY. Restore the last backup of ~/.config/plasma-org.kde.plasma.desktop-appletsrc from before when you made the changes. Now log back in and your taskbar will be back as it was.
You need to log out to do this, otherwise the running session will save itself in that file when you next log out, so your restoration won’t work.
To add … you can either add a spacer or similar between the task manager and your system tray OR configure the icons-only-task-manager to enable “Fill free space” (to push the system tray to the right hand side).