mirror of
https://github.com/JanGross/quicknotes.git
synced 2025-11-30 23:37:16 +01:00
Restore shares navigation
This commit is contained in:
56
js/script.js
56
js/script.js
@@ -563,30 +563,8 @@ View.prototype = {
|
||||
|
||||
$('#app-navigation ul').html(html);
|
||||
|
||||
// show all notes
|
||||
$('#all-notes').click(function () {
|
||||
$('.notes-grid').isotope({ filter: '*'});
|
||||
/* Create a new note */
|
||||
|
||||
var oldColorTool = $('#app-navigation .circle-toolbar.icon-checkmark');
|
||||
$.each(oldColorTool, function(i, oct) {
|
||||
$(oct).removeClass('icon-checkmark');
|
||||
});
|
||||
$('#app-navigation .any-color').addClass('icon-checkmark');
|
||||
});
|
||||
|
||||
$('#shared-with-you').click(function () {
|
||||
$('.notes-grid').isotope({ filter: function() {
|
||||
return $(this).children().hasClass('shared');
|
||||
} });
|
||||
});
|
||||
|
||||
$('#shared-by-you').click(function () {
|
||||
$('.notes-grid').isotope({ filter: function() {
|
||||
return $(this).children().hasClass('shareowner');
|
||||
} });
|
||||
});
|
||||
|
||||
// create a new note
|
||||
var self = this;
|
||||
$('#new-note').click(function () {
|
||||
var fakenote = {
|
||||
@@ -611,6 +589,38 @@ View.prototype = {
|
||||
});
|
||||
});
|
||||
|
||||
/* Show all notes */
|
||||
|
||||
$('#all-notes').click(function () {
|
||||
$('.notes-grid').isotope({ filter: '*'});
|
||||
|
||||
var oldColorTool = $('#app-navigation .circle-toolbar.icon-checkmark');
|
||||
$.each(oldColorTool, function(i, oct) {
|
||||
$(oct).removeClass('icon-checkmark');
|
||||
});
|
||||
$('#app-navigation .any-color').addClass('icon-checkmark');
|
||||
});
|
||||
|
||||
/* Shares Navigation */
|
||||
|
||||
$('#shared-folder').click(function () {
|
||||
$(this).toggleClass("open");
|
||||
});
|
||||
|
||||
$('#shared-with-you').click(function (event) {
|
||||
event.stopPropagation();
|
||||
$('.notes-grid').isotope({ filter: function() {
|
||||
return $(this).children().hasClass('shared');
|
||||
} });
|
||||
});
|
||||
|
||||
$('#shared-by-you').click(function (event) {
|
||||
event.stopPropagation();
|
||||
$('.notes-grid').isotope({ filter: function() {
|
||||
return $(this).children().hasClass('shareowner');
|
||||
} });
|
||||
});
|
||||
|
||||
/* Colors Navigation */
|
||||
|
||||
$('#colors-folder').click(function () {
|
||||
|
||||
Reference in New Issue
Block a user