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

[docs] new example frame! #2489

Merged
merged 76 commits into from
May 14, 2018
Merged

[docs] new example frame! #2489

merged 76 commits into from
May 14, 2018

Conversation

giladgray
Copy link
Contributor

@giladgray giladgray commented May 12, 2018

slick container for examples puts options in a column on the right:

image

completely revamp CSS example renderer so it works like the React examples, with switches for every modifier:

image

next steps:

  • review examples carefully. let's fix any that look weird.

to do

  • Large buttons with icon only are broken--46px wide instead of 40px separate PR please
  • Tabs example produces console errors
  • Dialog prop table hasBackdrop throws Unknown @tag: internal
  • “Loading column” select in Table example too wide that's just flex
  • DatePicker example is oversized
  • ensureElement doesn't work with fragments (seen in NIS example)
  • Move Usage with popovers markup to example frame not in this pr

@@ -53,79 +53,6 @@ $dark-example-background-color: $dark-content-background-color;
}
}

.view-example-source {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

all this moved to _examples.scss below

}


[data-modifier] > code {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

i think these styles aren't used now?

Copy link
Contributor

Choose a reason for hiding this comment

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

I think you're right, the ones from the code snippets are handled elsewhere

@blueprint-bot
Copy link

enable use of Set and Map in typescript (missing lib)

Preview: documentation | landing | table

@giladgray
Copy link
Contributor Author

@llorca time to review all examples carefully! i pushed fixes for most everything but I'm sure there are still loose ends.

@blueprint-bot
Copy link

small changes to Label, Navbar, NIS styles to support new usage

Preview: documentation | landing | table

padding-left: $pt-grid-size * 4;
padding-top: $pt-grid-size * 4;
padding-right: $pt-grid-size * 2;
padding-bottom: $pt-grid-size * 2;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

yo i added this for a reason... see comment above.

@@ -42,6 +42,42 @@
}
}

#{example("HotkeyTester")} {
.docs-hotkey-tester {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

either class or example(), def don't need both (redundant)

@@ -42,6 +42,23 @@
}
}

#{example("HotkeyPiano")} {
.docs-hotkey-piano-example {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

there's already code for this in another file. please merge.

@@ -33,7 +33,7 @@ example, `[2, 0]` represents the first child (`0`) of the third top-level node (

@### Instance methods

<div class="docs-interface-name">Tree</div>
<div class="@ns-monospace-text">Tree</div>
Copy link
Contributor Author

Choose a reason for hiding this comment

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

use backticks. Tree. should be a code element.

Copy link
Contributor

Choose a reason for hiding this comment

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

I don't want a code tho. I want a large text monospace element, without the border. Also <code> always enforces 12px so can't be combined with .pt-text-large :(

"table": $forest5,
"timezone": $vermilion5,
"labs": $indigo5,
"resources": $orange5,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

would prefer merging with the other map so it's "table": (bg, fg)

@blueprint-bot
Copy link

move custom example styles to _examples

Preview: documentation | landing | table

@blueprint-bot
Copy link

refactor package color variables in nav

Preview: documentation | landing | table

@blueprint-bot
Copy link

css examples: checkbox instead of switch, ignore modifier description

Preview: documentation | landing | table

@blueprint-bot
Copy link

fix docs-example sizing (see overflow-ellipsis in typography)

Preview: documentation | landing | table

@blueprint-bot
Copy link

lint

Preview: documentation | landing | table

@llorca
Copy link
Contributor

llorca commented May 14, 2018

re:

“Loading column” select in Table example too wide that's just flex

right, but it's still ugly and it'd like to give it an appropriate size. should just modify that specific select with custom example styles?

@giladgray
Copy link
Contributor Author

@llorca no this is a general problem with any example that puts its options underneath (see all Tables and DRP). i think we should not worry about it just yet and address in follow ups.

@blueprint-bot
Copy link

hide props marked `@internal`

Preview: documentation | landing | table

@blueprint-bot
Copy link

bring pack CSS modifier description

Preview: documentation | landing | table

Gilad Gray added 2 commits May 14, 2018 15:29
unwrap control group examples (cuz they have no internal margin)
@blueprint-bot
Copy link

bring back padding around examples unwrap control group examples (cuz they have no internal margin)

Preview: documentation | landing | table

@giladgray giladgray merged commit 710dfec into develop May 14, 2018
@giladgray giladgray deleted the gg/example-frame branch May 14, 2018 22:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants