This is a key component of the bi-directional shift register. It can be simplified by bubble pushing.
Both the top and bottom block function as an OR gate.
Replace the OR gate with the three NAND gates.
The Double NOR (NAND) gates cancel giving the final result. This also converts it to an all NAND gate configuration as well as reducing the gate count by 2 per output.