You mentioned slavery. What drives the Jedi's crusade against slavery if not compassion, love, and care for those enslaved? On one hand the Tython Jedi say one thing in their code and advocate one thing in their code and YET they act against what they're saying in their code. They act with love, compassion, mercy, and kindness. While at the same time teaching against it....
Well, it is compassion/love/care for the slaves which makes them decide to go against slavery. But after they made this decision, they put this emotions aside to reach their goal. Imagine they would only oppose slavery when they felt like it.
A real world example on a smaller scale: Imagine there is a language you like and would like to learn. At the beginning you are driven by emotions (like for the language), but after some time of learing, this will go away. Now you have to continue with discipline. When you finally speak the language, you will be satisfied, of course. (Maybe learning a language is a bad example, but it is like this with a lot of things.)
So Jedi start doing good because they care, but they continue doing good independent of these emotions.
Sith, btw, work differently. I think Darth Ruin realized this when he said: "There is no passion, there is solely obsession." You see very few Sith with genuine passion, but many obsessed with power, immortality etc.
There's no need to outright ban something like love.
And it isn't outright banned. Later on, in the female Consular romance, the Consular explains: If a Jedi is trustworthy and has shown good judgement, relationships are tolerated (though not encouraged).
Remember, this is a time in which it is not unlikely that some Sith capture and torture your lover to turn you to the dark side. It is not unreasonable for Jedi to permit romance only to those who have learned enough to deal with such things.