Parent, children e modifier são definidos através do atributo class, cada um com seus prefixos('#' para parent, '.' para children e ':' para modifier)
Elemento principal de um módulo(ex: slider, navigation, searchbox)
| /** | |
| * Reset | |
| */ | |
| * { | |
| margin: 0; | |
| padding: 0; | |
| } | |
| /** | |
| * General mixins |
| <?php | |
| $image = new image; | |
| $image->load('http://.../url.jpg'); | |
| // Redimensiona para no minimo 200x200, proporcionalmente | |
| $image->width = 200; | |
| $image->height = 200; | |
| $image->maintain_ratio = true; |
| <?php | |
| $common = new PagarMe_TransactionCommon; | |
| $common->setCardnumber(); | |
| $common->setCardCvv(); | |
| // -> setWathever(); | |
| // ... | |
| $card_hash = $common->generateCardHash(); |
| <!doctype html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <title></title> | |
| <style type="text/css"> | |
| .\#slider { | |
| background: red; | |
| height: 500px; | |
| } |
| <?php | |
| class Produtos extends MY_Controller | |
| { | |
| public function __construct() | |
| { | |
| parent::__construct('main'); | |
| } | |
| /** |
| <div class="wrapper"> | |
| <section class="breadcrumb"> | |
| <?php echo $breadcrumb; ?> | |
| </section> | |
| <div class="clear"></div> | |
| <section class="sidebar"> | |
| <h3><?php echo $pagina->titulo->valor; ?></h3> | |
| <?php if(count($categorias = $parent->childrens(1,1))){ ?> | |
| <ul> |
| return $.class({ | |
| extends: ['Path/To/ClassToExtend1', 'Path/To/ClassToExtend2'], | |
| implements: ['Path/To/ClassToImplement1'], | |
| fields: { | |
| id: { | |
| type: 'int', | |
| label: '#ID', | |
| }, | |
| images: { |
| ./modules | |
| ./moduleName | |
| ./Controller | |
| ./ControllerName.php | |
| ./Model | |
| Model.php | |
| ./modules | |
| {{ define modules }} | |
| ./assets | |
| ./views |
| <?php | |
| class String | |
| { | |
| protected $value; | |
| public function __construct($value = '') | |
| { | |
| $this->setValue($value); | |
| } |