Explorar o código

Commit 11.3: Add private button.

Frederic G. MARAND %!s(int64=8) %!d(string=hai) anos
pai
achega
41a14bd9fa
Modificáronse 1 ficheiros con 11 adicións e 0 borrados
  1. 11 0
      simple-todos.html

+ 11 - 0
simple-todos.html

@@ -37,6 +37,17 @@
   <li class="{{#if checked}}checked{{/if}}">
     <button class="delete">&times;</button>
     <input type="checkbox" checked="{{checked}}" class="toggle-checked" />
+
+    {{#if isOwner}}
+      <button class="toggle-private">
+        {{#if private}}
+          Private
+        {{else}}
+          Public
+        {{/if}}
+      </button>
+    {{/if}}
+
     <span class="text"><strong>{{username}}</strong> - {{text}}</span>
   </li>
 </template>