Last active
August 9, 2016 22:33
-
-
Save alexandreaquiles/9856c420ae098ffcc7ddfd6aa3031519 to your computer and use it in GitHub Desktop.
Template de cartão usando mustache.js
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script id="cartoes-template" type="text/x-mustache-template"> | |
<div class="cartao {{cartao.tipo}}" id="{{cartao.id}}" style="background-color: {{cartao.cor}}"> | |
<div class="opcoesDoCartao"> | |
<button class="opcoesDoCartao-opcao opcoesDoCartao-remove" data-cartao="{{cartao.id}}">Remover</button> | |
<div class="opcoesDoCartao-cores"> | |
{{#cores}} | |
<input type="radio" class="opcoesDoCartao-radioCor" name="corDoCartao-{{cartao.id}}" id="cor{{nome}}-{{cartao.id}}" value="{{codigo}}"> | |
<label class="opcoesDoCartao-opcao opcoesDoCartao-cor" for="cor{{nome}}-{{cartao.id}}" style="color: {{codigo}}">{{nome}}</label> | |
{{/cores}} | |
</div> | |
</div> | |
<p class="cartao-conteudo" contenteditable>{{cartao.conteudo}}</p> | |
</div> | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment