- The exclamation prefix (eg. "!shred") is only useful for abilities that are toggles, like shapeshift forms or autoattack. For regular abilities, it doesn't do anything.

- Conditions must come before the ability, so you have to write "[harm, stealth] Ravage" instead of "Ravage [harm, stealth]".

- As written, your macro will only ever show the Mangle icon. Better to use more sensible conditional ordering, and let the game show the icon of the ability that will actually be used when you activate the macro.

- You can't specify different conditions for each ability in a castsequence. You can only specify conditions for the whole sequence. In your case, though, I don't see any reason to use a castsequence, since there is no static rotation for cats, and none of those abilities (except Cenarion Ward) have cooldowns. Just use /cast; then you can specify the conditions for each ability.

Anyway, you have two options:

1. Split those into two buttons:

Code:

#showtooltip
/cast [stealth] Ravage; [help] Cenarion Ward; Mangle

Code:

#showtooltip
/cast [stealth] Ravage; Shred

Both will use Ravage if you are stealthed. If you're not stealthed, the first button will use Cenarion Ward if your target is friendly or Mangle otherwise, and the second button will use Shred. You don't need to explicitly specify [harm] since offensive abilities don't do anything if you don't have a hostile target; it's not like friendly spells where you'll get the annoying "glowing hand" cursor.