Issue #8677 by turegjorup: Added media properties to custom serialisation to middleware for screens