HappenApps / Quiver

Quiver documentation and issue tracker
2.26k stars 109 forks source link

Feature Request: Nested cells, cell folding, cell navigation #365

Open ntoombs19 opened 8 years ago

ntoombs19 commented 8 years ago

The cell concept is brilliantly simple but at times, too limiting. If I could nest these cells, each with their own properties, it would really help me stay organized. In addition to this, you could add cell folding to hide specific cells containing other cells, and cell navigation displaying the hierarchy of cells for quick navigation.

dkarter commented 8 years ago

If you are using the code cell it contains a folding feature. Otherwise this sounds rather complicated to implement UI-wise. I wouldn't want the app to be clunky and brittle. Ultimately I'm speculating based on my experience with developing OS X apps. It may be possible.

I hope it's not coming off as trying to shut down your idea. It's totally valid and I understand where you're coming from. Personally, I prefer to organize content by individual markdown notes w/ titles and notebooks. Also consider @ylian is already working on nested notebooks #2, maybe this will give you what you are looking for? What are your thoughts?

elbie-x commented 8 years ago

Seems to me that cell nesting could indeed get messy quickly, @dkarter, but I'm would definitely second the suggestion for cell folding -- the fancy navigation UI might not even be necessary, so long as one could fold and unfold all cells in a note en masse.

ntoombs19 commented 8 years ago

Cell nesting for me would be useful even if limited to a single level of nesting. I am often working on a single section and have to break up my cells to insert a code cell. I can't see folding being a super useful feature without nesting. Otherwise, folding one section of content (say, divided by an h1), could require folding three or more separate cells if divided by one or more cells of a different type. dividing notebooks into folders is a great way to organize notebooks of a particular type but that does nothing to organize the content within the notes. I think the cell navigation aspect of my feature request could be implemented after cell nesting/folding was implemented if UI implementation was the biggest concern.

ylian commented 8 years ago

My opinion is that cells are super powerful, but also adds complexity. I don't intend to make it more complex at the moment.

JMichaelTX commented 8 years ago

I don't intend to make it more complex at the moment.

I agree. :+1: Let's get the basics all fleshed out first.

jokerlee commented 7 years ago

for me code cells nested in a markdown cell is quite useful, there are too many cells in a code tutorials.

ntoombs19 commented 7 years ago

You can already add code to a markdown cell with the following syntax

     ```php
         //Some code here
kimaldis commented 7 years ago

You're using HTML for al your preview, Ylian. Is it completely off the wall to suggest that if you added Javascript we could figure out our own folding using, say, jQuery?

kimaldis commented 7 years ago

What do you know, it looks like Javascript is already possible. At least in Markdown cells. It's a little shy on feedback when there's code errors and I can't get jQuery.click() to work but hey, look:

<div id="poo">
xxxzzz
</div>

<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script>
<script>
    var div = document.getElementById('poo');
    jQuery( "#poo" ).html( "sss" );
    jQuery( "#poo" ).click(function() {
              this.html( "clicked");
      });
      div.innerHTML = div.innerHTML + 'Extrass stuff';
</script>
ylian commented 7 years ago

@kimaldis That's not intended and may be removed soon.

kimaldis commented 7 years ago

that's a shame. I can see it being useful