Alt Text for Image

2. Block

Are the containers in which an Element is being enclosed to make it more easy to handle.

To make Elements more generic to handle we need to wrap them in a kind of container (or wrapper) – in MPS this is called a ‘Block’.

It’s in a way the less exciting pattern – but a very important one – as we are able to approach all the Elements in a more generic way. These are the building blocks of Partials and part of the MPS core.

Designers won’t notice any difference as a button will be a button – and are a part of the Principles phase.

For developers this pattern is more interesting as all the different HTML Elements can be accessed as a generic Block – they are part of the Model (library).

Code Example

<?php

   // BLOCK: ELEMENT WRAPPER
   // Version: 1.0

    mps_element($block_content, $type, $id);

Tags: <section>

Note: n.a.

Social Share Buttons and Icons powered by Ultimatelysocial