textcircle.html 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. <head>
  2. <title>textcircle</title>
  3. </head>
  4. <body>
  5. {{> navbar }}
  6. <div class="container top-margin">
  7. <div class="row">
  8. <div class="col-md-12">
  9. {{> docMeta }}
  10. </div>
  11. </div>
  12. <div class="row">
  13. <div class="col-md-12">
  14. {{> editingUsers }}
  15. </div>
  16. </div>
  17. <div class="row">
  18. <div class="col-md-6">
  19. {{> editor}}
  20. </div>
  21. <div class="col-md-6">
  22. {{> viewer }}
  23. </div>
  24. </div>
  25. </div>
  26. </body>
  27. <template name="navbar">
  28. <nav class="navbar navbar-default navbar-fixed-top">
  29. <div class="container">
  30. <a class="navbar-brand" href="#">TextCircle</a><!-- nav title -->
  31. <ul class="nav navbar-nav">
  32. <li>
  33. <a href="#" class="js-add-doc">
  34. <span class="glyphicon glyphicon-plus" aria-hidden="true"></span>
  35. New document
  36. </a>
  37. </li>
  38. <!-- drop down list -->
  39. <li role="presentation" class="dropdown">
  40. <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
  41. Documents <span class="caret"></span>
  42. </a>
  43. <ul class="dropdown-menu">
  44. {{#each documents }}
  45. <li><a href="#" class="js-load-doc">{{ title }}</a></li>
  46. {{/each}}
  47. </ul>
  48. </li>
  49. <!-- end drop down list -->
  50. </ul>
  51. <p class="navbar-text navbar-right">
  52. {{> loginButtons align="right" }}
  53. </p>
  54. </div><!-- /nav container -->
  55. </nav><!-- /nav -->
  56. </template>
  57. <template name="editor">
  58. <h2>doc id: {{ docid }}</h2>
  59. {{> sharejsCM docid=docid onRender=config id="editor" }}
  60. </template>
  61. <template name="viewer">
  62. <iframe id="viewer_iframe">
  63. </iframe>
  64. </template>
  65. <template name="docMeta">
  66. {{#with document }}
  67. <span class="h1">{{> editableText collection="documents" field="title" }}</span>
  68. {{#if canEdit }}
  69. <div class="checkbox">
  70. <label>
  71. <input type="checkbox" class="js-tog-private" checked="{{ isPrivate }}"/>Private
  72. </label>
  73. </div>
  74. {{/if}}
  75. {{/with}}
  76. </template>
  77. <template name="editingUsers">
  78. Editors:
  79. {{#each users }}
  80. <span class="label label-success">{{firstname}}</span>
  81. {{/each}}
  82. </template>