Permalink
Browse files

tweet

  • Loading branch information...
1 parent f35a56f commit 338c3208a8ba24b7e773277d0d668af793997868 @aehlke committed Feb 20, 2012
@@ -190,6 +190,10 @@ <h1 dojoType="dijit.InlineEditBox" autosave="false">
</div>
{% endif %}
<hr style="margin-top:4em">
+
+ <a href="https://twitter.com/share" class="twitter-share-button" data-text="{{ deck.name|escape }}" data-via="manabiSRS" data-hashtags="Japanese">Tweet</a>
+ <script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="//platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
+
<p>
<a href="{% url exported_deck_csv deck.id %}" class="weak" target="_blank">Export to CSV</a>
</p>
@@ -209,3 +213,4 @@ <h1 dojoType="dijit.InlineEditBox" autosave="false">
{% endif %}
{% endblock %}
+
@@ -164,7 +164,6 @@ dojo.declare('reviews.Session', null, {
// `undoStackUrl`
dojo.safeMixin(this, args);
-
// Initialize non-primitive props
this.cards = [];
this.currentCard = null;
@@ -174,7 +173,6 @@ dojo.declare('reviews.Session', null, {
this._resetQuestionTimer();
this._resetCardTimer();
-
this.cardsReviewedPending = [];
this.cardsReviewedPendingDef = []; //contains the Deferred objects for each pending review
@@ -161,7 +161,6 @@ reviews_ui.showCardBack = function(card) {
reviews_ui.reviewCard = function(grade) {
reviews_ui.session.reviewCurrentCard(grade).then(function(data) {
// Enable the Undo button (maybe should do this before the def?)
- _kmq.push(['record', 'Reviewed a card', {grade: grade}]);
reviews_undoReviewButton.set('disabled', false);
//FIXME anything go here?
});
@@ -334,6 +333,8 @@ reviews_ui.startSession = function(args) {
undoStackUrl: '/flashcards/api/next-cards-for-review/undo-stack/' // rest-review_undo_stack
};
+ _kmq.push(['record', 'Started review session', {deck: sessionArgs.deckId}]);
+
reviews_ui.session = new reviews.Session(sessionArgs);
reviews_ui.sessionStarted = true;
reviews_ui.sessionOverAfterCurrentCard = false;
@@ -362,7 +363,6 @@ reviews_ui.startSession = function(args) {
}
}, initialCardPrefetch));
});
-
};
reviews_ui.submitReviewOptionsDialog = function(earlyReview, learnMore) {

0 comments on commit 338c320

Please sign in to comment.