Skip to content

Conversation

@AhyoungRyu
Copy link
Contributor

@AhyoungRyu AhyoungRyu commented Jun 10, 2016

What is this PR for?

Sometimes we want to share some docs title link as github markdown page does. This PR enables this feature also in Zeppelin documentation site.

What type of PR is it?

Improvement

Todos

  • - Add anchor.min.js under docs/assets/themes/zeppelin/js/
  • - Add integration js code to docs.js
  • - Disable default decoration below anchor icon

What is the Jira issue?

ZEPPELIN-990

How should this be tested?

  1. Apply this patch
  2. Build docs site using jekyll and browse localhost:4000
  3. Hover any titles in any docs

Screenshots (if appropriate)

anchor

Questions:

  • Does the licenses files need update? Yes
  • Is there breaking changes for older versions? No
  • Does this needs documentation? No

@Leemoonsoo
Copy link
Member

Cool! working well. LGTM

// Display anchor links when hovering over headers. For documentation of the
// configuration options, see the AnchorJS documentation.
anchors.options = {
placement: 'right'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@AhyoungRyu Thanks for the good feature can promote the references! This the feature that I needed :)
But If you don't mind can you consider to change placement to left side instead of right side?
Because considering the user experiences of anchors in other famous open source project documentation:

  • most of anchors tend to added at left side of header titles.
  • users are tend to start drag or read document from left to right so left anchor have more chance to be discovered fast.
  • It seems more clean and neat than right sided anchor.

https://github.com/bryanbraun/anchorjs
http://getbootstrap.com/getting-started/

@AhyoungRyu
Copy link
Contributor Author

AhyoungRyu commented Jun 12, 2016

@yoonjs2 Thanks for your suggestion and it makes sense indeed. I changed the placement right -> left as you said :)

@yoonjs2
Copy link
Contributor

yoonjs2 commented Jun 13, 2016

@AhyoungRyu Thank you for your consideration!

@Leemoonsoo
Copy link
Member

Thanks @AhyoungRyu for the great improvement.
Looks great and Merge if there're no more discussions.

// Scroll now too in case we had opened the page on a hash, but wait a bit because some browsers
// will try to do *their* initial scroll after running the onReady handler.
$(window).load(function() { setTimeout(function() { maybeScrollToHash(); }, 25); });
$(window).load(function() { setTimeout(function() { maybeScrollToHash(); }, 25); });
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:O

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@corneadoug I removed it :octocat:

@Leemoonsoo
Copy link
Member

Merging it into master

@asfgit asfgit closed this in 1826c74 Jun 13, 2016
asfgit pushed a commit that referenced this pull request Jun 15, 2016
…site

### What is this PR for?
Current Zeppelin documentation site is little bit hard to find a way for Zeppelin beginners. It will not easy  to improve this at a time, but I did the below as a start of this work.

1. Restructured dropdown menu and added each category names
2. Added a overview list(with short description) to first page of website (index.md) so that people can look through the overall contents in Zeppelin website at a glance. (as [Apache Spark](http://spark.apache.org/docs/latest/#where-to-go-from-here) and [Apache Mesos](http://mesos.apache.org/documentation/latest/) does)

Please see the attached screenshot images :)

### What type of PR is it?
Improvement & Documentation

### Todos
* [x] - Change outdated screenshot images
* [x] - Combine `text.md`, `table.md` and `html.md` to `basicdisplaysystem.md`
* [x] - Fix dead link in `virtual_machine.md`
* [x] - Improve dropdown menu and reorder
* [x] - Improve first page(`index.md`)
* [x] - Combine with #995 after it is merged into master

### What is the Jira issue?
[ZEPPELIN-996](https://issues.apache.org/jira/browse/ZEPPELIN-996)

### How should this be tested?
1. Apply this patch and [build the docs website with jekyll](https://github.com/apache/zeppelin/tree/master/docs#build-documentation)
2. Check the first page(index.html) and dropdown menu

### Screenshots (if appropriate)
 - Dropdown menu
![dropdown](https://cloud.githubusercontent.com/assets/10060731/16061421/b44f8034-3241-11e6-88fd-43aa5031b453.gif)

 - First page
<img width="717" alt="screen shot 2016-06-14 at 1 28 58 pm" src="https://cloud.githubusercontent.com/assets/10060731/16058631/3ab2cb6c-3234-11e6-95f4-180290df3d02.png">
<img width="694" alt="screen shot 2016-06-14 at 1 29 11 pm" src="https://cloud.githubusercontent.com/assets/10060731/16058639/43d68918-3234-11e6-921c-28436bfca33d.png">
<img width="649" alt="screen shot 2016-06-14 at 1 29 39 pm" src="https://cloud.githubusercontent.com/assets/10060731/16058650/501ec6d6-3234-11e6-9292-53ae84acc18a.png">
<img width="684" alt="screen shot 2016-06-14 at 1 29 57 pm" src="https://cloud.githubusercontent.com/assets/10060731/16058643/4637c8f2-3234-11e6-9b12-a233906f4c8b.png">
<img width="650" alt="screen shot 2016-06-14 at 1 30 12 pm" src="https://cloud.githubusercontent.com/assets/10060731/16058655/56c5af22-3234-11e6-8d29-9b7937728948.png">
<img width="636" alt="screen shot 2016-06-14 at 1 30 22 pm" src="https://cloud.githubusercontent.com/assets/10060731/16058656/58d1187e-3234-11e6-9171-ab7390b4a526.png">

### Questions:
* Does the licenses files need update? No
* Is there breaking changes for older versions? No
* Does this needs documentation? No

Author: AhyoungRyu <fbdkdud93@hanmail.net>

Closes #1004 from AhyoungRyu/ZEPPELIN-996 and squashes the following commits:

1dbf805 [AhyoungRyu] Add 'Apache' before 'Zeppelin'
6153a50 [AhyoungRyu] Remove useless dash
61a5ad6 [AhyoungRyu] Revert to Text -> HTML -> Table in navbar
1886f8c [AhyoungRyu] Fix indentation
af70939 [AhyoungRyu] Apply scrollable menu to 'more' tab & fix UI issue
2654d92 [AhyoungRyu] Combine overflow-x & overflow-y to overflow
904acd6 [AhyoungRyu] Resize dropdown menu maxheight
6e62e31 [AhyoungRyu] Change dynamicform image
230c670 [AhyoungRyu] Revert to Text -> HTML -> Table
ad53799 [AhyoungRyu] Adjust image size
c75c3a0 [AhyoungRyu] Add HDFS logo to available interpreter image
6a2f40b [AhyoungRyu] Address @bzz feedback
649a14d [AhyoungRyu] Address @coureadoug feedback
67cff3a [AhyoungRyu] Add all documentation list with short description to first page
ce4b122 [AhyoungRyu] Limit image width
6ff4db6 [AhyoungRyu] Improve dropdown menu and reorder menus
61da430 [AhyoungRyu] Fix dead link in virtual_machine.md
6251558 [AhyoungRyu] Change 'Zeppelin Configuration' section placement so that it can be separated
4eecab8 [AhyoungRyu] Combine text.md, html.md, table.md
4d021af [AhyoungRyu] Delete outdated images and add new images
asfgit pushed a commit that referenced this pull request Sep 14, 2016
### What is this PR for?
I applied header anchor to Zeppelin's docs website with #995 . It'll be good if `gh-pages` also has this header anchor.

### What type of PR is it?
Improvement

### What is the Jira issue?
[ZEPPELIN-990](https://issues.apache.org/jira/browse/ZEPPELIN-990)

### How should this be tested?
Run this branch locally as described in [here](http://zeppelin.apache.org/contribution/documentation.html) and hover the mouse over any titles.

### Screenshots (if appropriate)
![anchor](https://cloud.githubusercontent.com/assets/10060731/18375911/495a7782-7695-11e6-9be9-ee79a0c03829.gif)

### Questions:
* Does the licenses files need update? no
* Is there breaking changes for older versions? no
* Does this needs documentation? no

Author: AhyoungRyu <fbdkdud93@hanmail.net>

Closes #1418 from AhyoungRyu/gh-page/headerAnchor and squashes the following commits:

54b06f9 [AhyoungRyu] Remove duplicated window.location.hash
c27fc99 [AhyoungRyu] Fix scroll position
cd41c2f [AhyoungRyu] Add header anchor to gh-pages branch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants