UNPKG

cream-and-sugar

Version:

A deliciously functional syntax for JavaScript with native support for JSX

701 lines (690 loc) 20 kB
html, html * { outline: none !important; } body { font-family: "Open Sans", sans-serif; font-size: 14px; font-weight: 300; } h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 { font-family: "Bitter", serif; font-weight: 700; } .logo { padding: 51px 0; display: inline-block; position: relative; cursor: pointer; z-index: 10; } @media screen and (max-width: 768px) { .logo { position: absolute; padding: 0; top: 35px; left: 40px; } } @media screen and (max-width: 550px) { .logo { padding: 0; top: 25px; left: 25px; } } .logo, .logo * { -webkit-transition: all 0.5s ease; -moz-transition: all 0.5s ease; transition: all 0.5s ease; } .logo .logo-line { display: block; width: 1px; height: 75px; position: absolute; background: rgba(255, 255, 255, 0.43); position: absolute; } @media screen and (max-width: 768px) { .logo .logo-line { height: 0; opacity: 0; } } .logo .logo-line.top-right { -webkit-transform: rotate(45deg); -moz-transform: rotate(45deg); transform: rotate(45deg); top: -10px; right: 56px; } @media screen and (max-width: 550px) { .logo .logo-line.top-right { right: 28px; top: -5px; } } .logo .logo-line.top-left { -webkit-transform: rotate(315deg); -moz-transform: rotate(315deg); transform: rotate(315deg); top: -10px; right: 138px; } @media screen and (max-width: 550px) { .logo .logo-line.top-left { top: -5px; right: 166px; } } .logo .logo-line.bottom-right { -webkit-transform: rotate(135deg); -moz-transform: rotate(135deg); transform: rotate(135deg); bottom: -10px; right: 56px; } @media screen and (max-width: 550px) { .logo .logo-line.bottom-right { right: 28px; bottom: -5px; } } .logo .logo-line.bottom-left { -webkit-transform: rotate(225deg); -moz-transform: rotate(225deg); transform: rotate(225deg); bottom: -10px; right: 138px; } @media screen and (max-width: 550px) { .logo .logo-line.bottom-left { bottom: -5px; right: 166px; } } .logo .logo-text { position: absolute; display: block; font-size: 9px; font-family: "Bitter", serif; font-weight: 400; text-align: center; width: 49px; letter-spacing: .5px; color: #ffffff; } @media screen and (max-width: 768px) { .logo .logo-text { opacity: 0; } } .logo .logo-text.top { top: 30px; right: 73px; } @media screen and (max-width: 550px) { .logo .logo-text.top { opacity: 0; top: 15px; } } .logo .logo-text.bottom { bottom: 30px; right: 73px; } @media screen and (max-width: 550px) { .logo .logo-text.bottom { opacity: 0; bottom: 15px; } } .nav { display: inline-block; width: 30px; height: 19px; position: absolute; cursor: pointer; top: 40px; right: 40px; z-index: 10; } @media screen and (max-width: 550px) { .nav { top: 33px; right: 30px; } } .nav, .nav * { -webkit-transition: all 0.5s ease; -moz-transition: all 0.5s ease; transition: all 0.5s ease; } .nav .line { width: 30px; height: 1px; background: #ffffff; position: absolute; } .nav .line.top { top: 0; left: 0; } .nav .line.middle { top: 9px; left: 0; } .nav .line.bottom { bottom: 0; left: 0; } .nav.open .line.top { -webkit-transform: rotate(225deg); -moz-transform: rotate(225deg); transform: rotate(225deg); top: 9px; } .nav.open .line.middle { left: 50%; width: 0; } .nav.open .line.bottom { -webkit-transform: rotate(315deg); -moz-transform: rotate(315deg); transform: rotate(315deg); bottom: 9px; } .download { -webkit-border-radius: 3px; -moz-border-radius: 3px; border-radius: 3px; width: 284px; height: 36px; border: 1px solid #ffffff; } .download .download-label { font-family: "Bitter", serif; color: #FBF4EC; font-weight: bold; margin-top: -38px; margin-bottom: 22px; display: block; line-height: 16px; font-size: 16px; letter-spacing: 2px; } .download .download-dropdown { float: left; display: block; height: 36px; width: 226px; border: 0; background: transparent; color: #ffffff; font-weight: 300; font-family: "Open Sans", sans-serif; letter-spacing: .5px; color: #FBF4EC; } .download .download-button { -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; float: left; display: block; height: 36px; width: 58px; background: #ffffff; color: #171717; font-weight: 600; text-align: center; padding-top: 10px; cursor: pointer; text-decoration: none; } #app { -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; -webkit-transition: padding 0.5s ease; -moz-transition: padding 0.5s ease; transition: padding 0.5s ease; position: absolute; left: 0; top: 0; width: 100%; height: 100%; background: url(../images/coffee-cup.jpg) right center no-repeat transparent; background-size: cover; color: #FBF4EC; padding: 40px; overflow: hidden; } @media screen and (max-width: 768px) { #app { overflow-y: auto; } } @media screen and (max-width: 550px) { #app { padding: 25px 25px; } } #app h1, #app h2, #app h3, #app h4, #app h5, #app h6, #app .h1, #app .h2, #app .h3, #app .h4, #app .h5, #app .h6 { color: #ffffff; } #app .home-content { position: absolute; left: 40px; bottom: 40px; width: 300px; opacity: 1; } #app .home-content, #app .home-content * { -webkit-transition: all 0.8s ease; -moz-transition: all 0.8s ease; transition: all 0.8s ease; } #app .home-content.hidden { bottom: -50%; opacity: 0; } #app .home-content .home-text { font-size: 14px; line-height: 2.3; font-weight: 300; color: #FBF4EC; margin-bottom: 95px; letter-spacing: .5px; } #app .code-sample { -webkit-transition: all 0.6s ease; -moz-transition: all 0.6s ease; transition: all 0.6s ease; opacity: .43; position: absolute; right: 40px; bottom: 40px; } #app .code-sample:hover { -webkit-transition: all 0.6s ease; -moz-transition: all 0.6s ease; transition: all 0.6s ease; opacity: 1; } @media screen and (max-width: 768px) { #app .code-sample { display: none; } } #app .code-sample pre code { font-family: "Fira Code", "Hasklig", consolas, monospace; font-size: 12px; line-height: 1.6; } #app .code-sample pre code .fn { color: #6AB5FA; } #app .code-sample pre code .num { color: #F2CB86; } #app .code-sample pre code .sym { color: #FF5D70; } #app .menu { background: rgba(0, 0, 0, 0.6); } #docs-app .menu { background: rgba(0, 0, 0, 0.85); } #app .menu, #docs-app .menu { position: fixed; top: 0; right: 0; width: 100%; height: 100%; z-index: 5; opacity: 1; color: #FBF4EC; overflow: hidden; } @media screen and (max-width: 768px) { #app .menu, #docs-app .menu { position: absolute; height: auto; padding-bottom: 100px; } } #app .menu, #app .menu *, #docs-app .menu, #docs-app .menu * { -webkit-transition: all 0.6s ease; -moz-transition: all 0.6s ease; transition: all 0.6s ease; } #app .menu .menu-inner, #docs-app .menu .menu-inner { -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; margin-left: 294px; margin-top: 30px; padding-left: 60px; } @media screen and (max-width: 768px) { #app .menu .menu-inner, #docs-app .menu .menu-inner { margin-left: 0; border-left: 0; margin-top: 100px; } } @media screen and (max-width: 550px) { #app .menu .menu-inner, #docs-app .menu .menu-inner { margin-top: 75px; } } #app .menu h1, #docs-app .menu h1 { font-size: 100px; margin: 0; color: #ffffff; line-height: 1.1; } @media screen and (max-width: 1190px) { #app .menu h1, #docs-app .menu h1 { font-size: 48px; } } @media screen and (max-width: 768px) { #app .menu h1, #docs-app .menu h1 { display: none; } } #app .menu h2, #docs-app .menu h2 { font-size: 30px; font-family: "Open Sans", sans-serif; font-weight: 300; margin: 0; color: #ffffff; line-height: 1.1; } @media screen and (max-width: 1190px) { #app .menu h2, #docs-app .menu h2 { font-size: 18px; margin-top: 10px; } } @media screen and (max-width: 768px) { #app .menu h2, #docs-app .menu h2 { display: none; } } #app .menu .row, #docs-app .menu .row { margin: 55px auto 95px -35px; } #app .menu .row:after, #docs-app .menu .row:after { content: ''; width: 100%; height: 1px; display: block; clear: both; } #app .menu .column, #docs-app .menu .column { float: left; width: 50%; max-width: 278px; } @media screen and (max-width: 550px) { #app .menu .column, #docs-app .menu .column { float: none; max-width: 100%; width: 100%; } } #app .menu .menu-link, #docs-app .menu .menu-link { display: block; vertical-align: middle; cursor: pointer; padding: 5px 0; letter-spacing: .5px; font-size: 14px; line-height: 1; text-decoration: none; color: #FBF4EC; } @media screen and (max-width: 550px) { #app .menu .menu-link, #docs-app .menu .menu-link { padding: 10px 0; } } #app .menu .menu-link, #app .menu .menu-link:before, #app .menu .menu-link *, #docs-app .menu .menu-link, #docs-app .menu .menu-link:before, #docs-app .menu .menu-link * { -webkit-transition: all 0.3s ease; -moz-transition: all 0.3s ease; transition: all 0.3s ease; } #app .menu .menu-link:before, #docs-app .menu .menu-link:before { display: inline-block; content: url(../images/arrow.svg); width: 35px; height: 20px; text-indent: -35px; overflow: hidden; vertical-align: middle; opacity: 0; } #app .menu .menu-link.active, #app .menu .menu-link:hover, #docs-app .menu .menu-link.active, #docs-app .menu .menu-link:hover { font-weight: 800; } #app .menu .menu-link.active, #app .menu .menu-link.active:before, #app .menu .menu-link.active *, #app .menu .menu-link:hover, #app .menu .menu-link:hover:before, #app .menu .menu-link:hover *, #docs-app .menu .menu-link.active, #docs-app .menu .menu-link.active:before, #docs-app .menu .menu-link.active *, #docs-app .menu .menu-link:hover, #docs-app .menu .menu-link:hover:before, #docs-app .menu .menu-link:hover * { -webkit-transition: all 0.3s ease; -moz-transition: all 0.3s ease; transition: all 0.3s ease; } #app .menu .menu-link.active:before, #app .menu .menu-link:hover:before, #docs-app .menu .menu-link.active:before, #docs-app .menu .menu-link:hover:before { opacity: .47; text-indent: -10px; } #app .menu .menu-link.active, #docs-app .menu .menu-link.active { cursor: default; } #app .menu .copyright, #docs-app .menu .copyright { color: #FBF4EC; font-size: 12px; opacity: .47; display: block; letter-spacing: .5px; position: absolute; left: 40px; bottom: 40px; width: 214px; text-align: center; } #app .menu.hidden, #docs-app .menu.hidden { opacity: 0; right: -100%; } #app .menu.hidden h1, #app .menu.hidden h2, #docs-app .menu.hidden h1, #docs-app .menu.hidden h2 { margin-left: -75%; } #app .menu.hidden .row, #docs-app .menu.hidden .row { margin-left: -65%; } #app .menu.hidden .download, #docs-app .menu.hidden .download { margin-left: -55%; } .docs { overflow-x: hidden; } .docs:after { content: ''; display: block; clear: both; width: 100%; height: 1px; } .docs h1, .docs h2, .docs h3, .docs h4, .docs h5, .docs h6, .docs .h1, .docs .h2, .docs .h3, .docs .h4, .docs .h5, .docs .h6 { margin: 0; line-height: 1.2; } @media screen and (max-width: 768px) { .docs h1, .docs h2, .docs h3, .docs h4, .docs h5, .docs h6, .docs .h1, .docs .h2, .docs .h3, .docs .h4, .docs .h5, .docs .h6 { line-height: 1.4; } } .docs h1, .docs .h1 { font-size: 52px; } .docs h2, .docs .h2 { font-size: 32px; } .docs h2.subhead, .docs .h2.subhead { font-family: "Open Sans", sans-serif; font-weight: 300; font-size: 18px; letter-spacing: 1px; margin-top: 5px; } .docs h3, .docs .h3 { font-size: 24px; } .docs h4, .docs .h4 { -webkit-transition: all 1s ease; -moz-transition: all 1s ease; transition: all 1s ease; font-family: "Fira Code", "Hasklig", consolas, monospace; font-weight: 400; font-size: 16px; position: relative; padding: 5px 0 5px 15px; margin-top: 2em; margin-bottom: 1em; opacity: 0; margin-left: -36px; background: #F8F6F8; } .docs h4:before, .docs .h4:before { content: ''; width: 5px; height: 100%; background: #171717; display: block; position: absolute; left: 0; bottom: 0; } .docs h4:after, .docs .h4:after { content: ''; width: 5px; height: 100%; background: #171717; display: block; position: absolute; right: 0; bottom: 0; } .docs h4.visible, .docs .h4.visible { -webkit-transition: all 1s ease; -moz-transition: all 1s ease; transition: all 1s ease; opacity: 1; margin-left: 0; } .docs h4 .bif, .docs .h4 .bif { font-weight: 700; color: #D12F52; } .docs h5, .docs .h5 { font-size: 14px; } .docs h6, .docs .h6 { font-size: 12px; text-transform: uppercase; font-family: "Open Sans", sans-serif; } .docs .branding { background: url(../images/coffee-cup.jpg) right center no-repeat transparent; background-size: cover; height: 100%; color: #FBF4EC; position: fixed; width: 294px; } @media screen and (max-width: 1190px) { .docs .branding { width: 100%; position: static; height: 100px; } } @media screen and (max-width: 550px) { .docs .branding { height: 66px; } } .docs .content { -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; margin: 0 0 0 294px; position: relative; padding: 40px calc((100% - 220px)/2) 50px 36px; color: #171717; line-height: 2.1; font-size: 13px; font-weight: 400; } @media screen and (max-width: 1190px) { .docs .content { margin: 0; padding: 50px 54% 50px 36px; } } @media screen and (max-width: 768px) { .docs .content { padding: 36px; } } .docs .content:before { content: ''; display: block; position: absolute; right: 0; top: 0; width: 50%; height: 100%; background: #F8F6F8; } @media screen and (max-width: 768px) { .docs .content:before { display: none; } } .docs .content a { color: #D12F52; text-decoration: none; cursor: pointer; position: relative; display: inline-block; white-space: nowrap; } .docs .content a:after { -webkit-transition: width 0.3s ease; -moz-transition: width 0.3s ease; transition: width 0.3s ease; content: ''; display: block; width: 0; height: 1px; background: #D12F52; position: absolute; right: 0; left: auto; bottom: 2px; } .docs .content a:hover:after { -webkit-transition: width 0.3s ease; -moz-transition: width 0.3s ease; transition: width 0.3s ease; width: 100%; left: 0; right: auto; } .docs .left-border { margin-bottom: 25px; position: relative; } .docs .left-border:before { content: ''; width: 5px; height: 100%; background: #D12F52; margin-left: -36px; display: block; position: absolute; } .docs blockquote { -webkit-border-radius: 3px; -moz-border-radius: 3px; border-radius: 3px; margin: 0 0 25px 0; position: relative; padding: 35px 25px 5px; font-weight: 400; background: #F8F6F8; overflow: hidden; font-style: italic; } .docs blockquote:before { content: ''; width: 5px; height: 100%; background: #D12F52; display: block; position: absolute; left: 0; top: 0; } .docs blockquote:after { -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; content: 'IMPORTANT NOTE'; font-style: normal; letter-spacing: .5px; font-weight: 700; font-family: "Bitter", serif; display: block; position: absolute; padding-left: 25px; padding-top: 3px; top: 0; left: 0; width: 100%; border-bottom: 1px dashed rgba(0, 0, 0, 0.06); background: rgba(0, 0, 0, 0.03); } .docs blockquote code { background: #ffffff !important; } .docs pre, .docs pre code { font-size: 13px; line-height: 1.4; display: block; } @media screen and (max-width: 1190px) { .docs pre, .docs pre code { font-size: 12px; } } .docs p code, .docs li code { -webkit-border-radius: 3px; -moz-border-radius: 3px; border-radius: 3px; background: #F8F6F8; border: 1px solid #f4f0f4; padding: 0 3px; font-size: 12px; white-space: nowrap; display: inline-block; margin-right: 1px; line-height: 1.9; font-variant-ligatures: none; } .docs code { font-family: "Fira Code", "Hasklig", consolas, monospace; } .docs pre { margin: 0 0 0 calc(100% + 72px); position: relative; height: 0; } @media screen and (max-width: 1190px) { .docs pre { margin: 0 0 0 115%; } } @media screen and (max-width: 768px) { .docs pre { margin: 0 -36px; height: auto; padding: 10px 36px 15px; background: #F8F6F8; border: 1px solid #ede8ed; } } .docs pre code { -webkit-transition: all 0.6s ease; -moz-transition: all 0.6s ease; transition: all 0.6s ease; padding-top: 1em; opacity: 0; margin-left: 25px; } .docs pre code.visible { -webkit-transition: all 0.6s ease; -moz-transition: all 0.6s ease; transition: all 0.6s ease; opacity: 1; margin-left: 0; } .docs .hljs { overflow-x: inherit; padding-left: 0; background: transparent; } .docs .hljs-comment { opacity: .5; } @media screen and (max-width: 550px) { .docs .nav { top: 25px; right: 25px; } } .docs .nav .line { background: #171717; } @media screen and (max-width: 1190px) { .docs .nav .line { background: #ffffff; } } .docs .nav.open .line { background: #ffffff; } .docs .logo { position: fixed; left: 40px; top: 40px; } @media screen and (max-width: 1190px) { .docs .logo { position: absolute; padding: 0; top: 35px; } } @media screen and (max-width: 550px) { .docs .logo { top: 15px; left: 25px; } } @media screen and (max-width: 1190px) { .docs .logo .logo-line { height: 0; opacity: 0; } } @media screen and (max-width: 1190px) { .docs .logo .logo-text { opacity: 0; } }