write-tweet.html 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <!--
  2. Generated template for the WriteTweetPage page.
  3. See http://ionicframework.com/docs/components/#navigation for more info on
  4. Ionic pages and navigation.
  5. -->
  6. <ion-header>
  7. <ion-navbar>
  8. <ion-title>Write a new tweet</ion-title>
  9. </ion-navbar>
  10. </ion-header>
  11. <ion-content padding>
  12. <form [formGroup]="tweet" (ngSubmit)="submitTweet()">
  13. <ion-item class="padding-0">
  14. <ion-label color="primary" stacked>Your tweet</ion-label>
  15. <ion-textarea type="text" formControlName="text" maxlength="140" [attr.rows]="4"></ion-textarea>
  16. </ion-item>
  17. <div class="actions">
  18. <span class="progress">
  19. <svg width="20" height="20" class="progress-circle">
  20. <circle class="background-stroke" cx="10" cy="10" r="8"></circle>
  21. <circle class="progress-stroke" cx="10" cy="10" r="8" transform="rotate(-90, 10, 10)" [style.strokeDashoffset]="tweetCharProgress"></circle>
  22. </svg>
  23. <span class="progress-stats">{{ (tweet.value.text).length }}/140</span>
  24. </span>
  25. <span class="network-switch">
  26. <ion-icon name="logo-twitter"></ion-icon>
  27. <ion-toggle checked="false" formControlName="p2p" color="dark"></ion-toggle>
  28. <ion-icon name="glasses"></ion-icon>
  29. </span>
  30. <button ion-button type="submit" [disabled]="!tweet.valid" class="submit-tweet">tweet!</button>
  31. </div>
  32. </form>
  33. </ion-content>