/**
 * Set Div element padding top, right, bottom, left style.
 *
 * @param int      $top    Padding top value.
 * @param int|null $right  Padding right value.
 * @param int|null $bottom Padding bottom value.
 * @param int|null $left   Padding left value.
 *
 * @return self Returns instance of the Div element class.
 *
 * @access public
 */
public function p(int $top, ?int $right = null, ?int $bottom = null, ?int $left = null): self

Examples

Set padding style using fluent interface

use function Thermage\div;
use function Thermage\render;

// ...

render(
  div('Stay RAD!')->p(10)->bg('red')
);

Set padding style using magic method fluent interface

use function Thermage\div;
use function Thermage\render;

// ...

render(
  div('Stay RAD!')->p10()->bgRed()
);

Set padding style using magic classes pipeline

use function Thermage\div;
use function Thermage\render;

// ...

render(
  div('Stay RAD!', 'p-10 bg-red')
);
Terminal
$ php thermage.php
Stay RAD!