misc(v2): make playground nicer (#1819)

* misc(v2): make code block nicer

* misc(v2): update changelog for code + playground

* misc(v2): update playground docs
This commit is contained in:
Yangshun Tay 2019-10-10 15:12:17 -07:00 committed by GitHub
parent ae678c9dad
commit 1c5a6ee244
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
13 changed files with 75 additions and 55 deletions

View file

@ -1,6 +1,5 @@
.codeBlock {
border-radius: 0;
font-size: inherit;
margin-bottom: 0;
overflow: hidden;
overflow-wrap: break-word;
@ -12,25 +11,24 @@
}
.codeBlockWrapper:hover > .copyButton {
bottom: calc(var(--ifm-pre-padding) - 2px);
visibility: visible;
opacity: 1;
}
.copyButton {
position: absolute;
right: var(--ifm-pre-padding);
bottom: calc(var(--ifm-pre-padding) - 4px);
padding: 4px 8px;
visibility: hidden;
opacity: 0;
transition: opacity 200ms ease-in-out, visibility 200ms ease-in-out,
bottom 200ms ease-in-out;
background: rgb(1, 22, 39);
border: 1px solid rgb(214, 222, 235);
border-radius: var(--ifm-global-radius);
outline: none;
color: rgb(214, 222, 235);
cursor: pointer;
line-height: 12px;
background: rgb(1, 22, 39);
color: rgb(214, 222, 235);
opacity: 0;
outline: none;
padding: 4px 8px;
position: absolute;
right: var(--ifm-pre-padding);
top: var(--ifm-pre-padding);
visibility: hidden;
transition: opacity 200ms ease-in-out, visibility 200ms ease-in-out,
bottom 200ms ease-in-out;
}