Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation #928

Merged
merged 33 commits into from
Apr 3, 2017
Merged

Documentation #928

merged 33 commits into from
Apr 3, 2017

Conversation

themadcreator
Copy link
Contributor

This is the final PR in the tree of branches created to overhaul blueprint documentation.

  • @blueprintjs/docs now converted to npm publishable package that renders documentalist-generated docs using a simple and extensible <Documentation> react component.
  • Converted blueprint docs for http://blueprintjs.com/docs to use this new package and documentation rendering approach. All the blueprint-specific documentation has been moved to /packages/docs-site
  • Gulp scripts and circle config updated to generate new documentation.

giladgray and others added 30 commits March 1, 2017 14:49
* convert all packages

* script to convert scss docs to md files

* remove Weights, convert to `@#+`

* add pages for common files

* add `@page` roots

* 4-space md files (mostly for source)

* remove some `parent` front matters

* remove docs from .scss except markup & modifiers
* all files should start with `@#`
depth is computed at layout time

* split controls.md into three files
so they all show up in nav

* textarea gets its own file
…ocumentalist

Conflicts:
	packages/core/src/components/button/_button.scss
	packages/core/src/components/forms/_file-upload.scss
	packages/core/src/components/forms/_input.scss
	packages/core/src/components/forms/_numeric-input.scss
	packages/core/src/components/popover/_popover.scss
	packages/core/src/components/tag/_tag.scss
	packages/core/src/components/tree/_tree.scss
	packages/datetime/src/_daterangepicker.scss
- 🎆 replace KSS with Documentalist
- 🔨 replace both `docs-interfaces` and `docs-kss` gulp tasks with `docs-json`
- ♻️ refactor docs app to use DM: on its way to being a sweet React theme
  - write a bunch of tag handlers
  - delete `Section` component entirely, replaced with minimal `Page` SFC
  - best scrollspy implementation yet! it's smooth as silk and never glitches out (only known issue is short final sections are hard to highlight)
- 🌲 generate layout tree (for nav) in gulp task
  - requires some nasty rewriting of references 😢
  - but hey it works really well!
…ocumentalist

Conflicts:
	packages/core/src/components/tabs/_tabs.scss
	packages/datetime/src/_datepicker.scss
	packages/datetime/src/_daterangepicker.scss
	packages/docs/src/common/resolveDocs.ts
	packages/docs/src/common/resolveExample.tsx
	packages/docs/src/components/section.tsx
_really_ deprecate Tabs components
otherwise scrolling up is damn near impossible!
already migrated to markdown in docs/
decided simplest approach was a mostly empty root `progress` page
that links to the other three.
decided not to create two child pages so Single Slider is on the
root Sliders page. not sure about this pattern...
* update scss & md docs files
- **scss files:** make them all valid KSS blocks again by adding header and reference.
references are now reflective of the CSS class being documented.
- **md files:** add `@css reference` tags in all the CSS API sections
* documentalist@0.0.3
* css tag handler brings back markup & modifiers!
* ♻️ major refactor to sections.scss
a new function `reference()` to target these new KSS examples. refactored as many selectors as I could, and removed a bunch of obsolete ones.

docs changes:
* move checkbox "Inline controls" section
* bring back button-group page, unwrap control-group markup
* update typography docs for kss
* run all packages through Documentalist (easy glob change 👍)
* index.md page for each package, _nav in docs
* update nesting in datetime docs
* title in styleguide
* change default page
* fix Table links, rename page to just Table
* move color aliases table styles to live with its family
this solves the overscroll issue we had previously (cuz page doesn't change) while also ensuring that the active section is always visible when the page loads.
sidebar scrolls the active _page_ into view so you can see the entire layout, rather than just the active section!
* add data-page-id to Page to give all Table examples a fixed height
* BaseExample requires id prop, adds data-example-id attribute
IBaseExample interface re-used in docs example renderer.
BaseExample is the .kss-example, reducing element count by 1!
* move .docs-overlay-example-transition styles all to _examples
* sass example($name) function generates selector for react examples
* InputGroupExample uses flex box utility classes
* ContextMenuExample simpler render makes for simpler styles
* remove now unused section-name() and section-id() functions
…ocumentalist

Conflicts:
	packages/core/src/components/forms/_numeric-input.scss
	packages/docs/src/styles/_sections.scss
* delete unused _markup.scss file
* remove unused kss- things in html
* wholesale rename .kss-* => .docs-*
* merge the slider pages by omitting JavaScript API
a daring play by ggray just lists the two components and takes advantage of documentalist's support for multiple tags per section!

* move components usage instructions to styleguide
they relate to all the packages so belong in a shared location, not inside Core Components.
now the Core package is completely empty...

* remove redundant UI icons heading in Icons as it was the only subheading.
also refine the example a bit, using some handlebars!
* nav layout code moves to MarkdownPlugin
but must configure all plugins manually now
* support IHeadingTag with single "heading" renderer
TagRenderer receives ITag as first argument to support this polymorphism.
use type in renderer definition to avoid redeclaring each argument.
deconstruct and rename `value` as needed for minimal churn and maximal clarity.
* refactor to support `route` property
* IBlock field rename
* documentalist@0.0.5
* documentalist@0.0.6: now with options
use .d.ts files for typescript info, like we used to (shaves about 2s off runtime)
* nav only expands active route, not all pages
* split docs package into `docs` and `docs-site`

`docs` is the documentalist theme.
`docs-site` is the blueprint-specific content for our docs site.
write reusable tag renderers for the common tags.
this is by no means finished, just a good place to start committing

* move BaseExample into `docs` package

* move typings around

* fix docs-site webpack compile errors!

* fix sass compile errors

* require react ^15.3 so we can use PureComponent
instead of pure-render-decorator

* clean up docs common files

- move ClickToCopy to docs-site cuz it's not used in docs
- rename to propsStore.ts
- delete unused PureComponent

* move FocusStyleManager call into Styleguide componentDidMount

so consumer doesn't have to set it.
also fix typings of setHotkeysDialogProps with Partial<>.

* fix html paths

* fix broken import (forgot to save)

* rename Styleguide to Documentation

* copyright headers

* move docs-site files into same structure as docs

components / styles / tags.
tags export maps of files for reactDocs and reactExample

* Documentation navbarLeft/Right props

BlueprintDocs component wraps Documentation with added themeName state. all theme logic moves to `docs-site` custom code.

* make some Documentation props optional

* remove theme from docs

* enable strictNullChecks in docs and docs-site!!

* move docs md file, rename styleguide.md to blueprint.md

* Update to documentalist 0.0.7

* move .d.ts and README around

* move normalize.css import to docs-site.scss

until we include it in blueprint.css itself!

* fix some small build errors

* add project files

* update links to docs-site

* Add top comment block to interface table tag renderer

* export BaseExample from docs package, refactor example imports

* fix CONTRIBUTING docs path

* Null check when naving to section

* Lint

* Add docs-site artifact

* Fix gulp watch task

* minor polish
…ocumentalist

Conflicts:
	packages/docs/package.json
	packages/docs/src/styles/_sections.scss
* markdownify Text and DateRangeInput docs

* fix all the links i could find
@blueprint-bot
Copy link

[DM] update docs files and links (#927)

Preview: documentation | table
Coverage: core | datetime

@llorca
Copy link
Contributor

llorca commented Mar 31, 2017

Small issue in trees:
image

Text component doesn't render its example and has a nav issue:
image
image

@themadcreator
Copy link
Contributor Author

Looks like some of the styles like [data-section-name="Trees"] are missing (causing that first issue)

@blueprint-bot
Copy link

Fix text navbar issue

Preview: documentation | table
Coverage: core | datetime

@blueprint-bot
Copy link

Fix tree example styles

Preview: documentation | table
Coverage: core | datetime

@themadcreator themadcreator requested a review from llorca April 3, 2017 20:51
@themadcreator themadcreator merged commit f565570 into master Apr 3, 2017
@themadcreator themadcreator deleted the feature/documentalist branch April 3, 2017 21:04
@giladgray giladgray mentioned this pull request Apr 4, 2017
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