Skip to content

Commit 96c6172

Browse files
Merge pull request #225 from nothingworksinc/remove-outdated-docs
Add mobile menu + Remove some outdated docs
2 parents c20a69b + 58aa6ee commit 96c6172

File tree

9 files changed

+77
-238
lines changed

9 files changed

+77
-238
lines changed

docs/source/_assets/less/base.less

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
@tailwind reset;
22

33
html {
4-
font-size: 12px;
4+
font-size: 14px;
55

66
@media (min-width: 420px) {
77
font-size: 16px;
@@ -13,6 +13,7 @@ a {
1313
text-decoration: none;
1414
}
1515

16-
ol, ul {
16+
ol,
17+
ul {
1718
@apply .list-reset;
1819
}

docs/source/_assets/less/utilities.less

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,9 @@
22
background-color: #e3ebed;
33
}
44
.bg-gradient-brand {
5-
background-image: linear-gradient(to right, #2383ae, #6dd7b9);
5+
background-image: linear-gradient(to right, #2383ae, #6dd7b9);
6+
}
7+
8+
.\!hidden {
9+
display: none !important;
610
}

docs/source/_layouts/master.blade.php

Lines changed: 57 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,14 @@
2222
<link rel="stylesheet" href="{{ mix('/css/main.css') }}">
2323
<script src="https://code.jquery.com/jquery-3.2.1.min.js" integrity="sha256-hwg4gsxgFZhOsEEamdOYGBf13FyQuiTwlAQgxVSNgt4=" crossorigin="anonymous"></script>
2424
<script src="{{ mix('/js/nav.js') }}"></script>
25-
2625
</head>
27-
<body class="font-sans font-normal text-slate-darker leading-normal">
26+
<body data-sidebar-visible="true" class="font-sans font-normal text-slate-darker leading-normal">
2827
<div class="min-h-screen">
29-
<div class="fixed pin-y pin-l bg-smoke-light w-full max-w-xs flex-none border-r-2 border-smoke flex flex-col">
28+
<div id="sidebar" class="z-50 fixed pin-y pin-l overflow-y-scroll bg-smoke-light w-4/5 md:w-full md:max-w-xs flex-none border-r-2 border-smoke md:flex flex-col">
3029
<div class="border-b border-smoke flex-none p-8">
31-
<div class="text-center mb-8">
30+
<div class="hidden md:block text-center mb-8">
3231
<a href="/" class="inline-block">
33-
<svg class="h-8" viewBox="0 0 60 36" xmlns="http://www.w3.org/2000/svg"><defs><linearGradient x1="0%" y1="0%" y2="100%" id="a"><stop stop-color="#2383AE" offset="0%"></stop><stop stop-color="#6DD7B9" offset="100%"></stop></linearGradient></defs><path d="M15 12c2-8 7-12 15-12 12 0 13.5 9 19.5 10.5 4 1 7.5-.5 10.5-4.5-2 8-7 12-15 12-12 0-13.5-9-19.5-10.5-4-1-7.5.5-10.5 4.5zM0 30c2-8 7-12 15-12 12 0 13.5 9 19.5 10.5 4 1 7.5-.5 10.5-4.5-2 8-7 12-15 12-12 0-13.5-9-19.5-10.5-4-1-7.5.5-10.5 4.5z" fill="url(#a)" fill-rule="evenodd"></path></svg>
32+
<svg class="h-8" viewBox="0 0 60 36" xmlns="http://www.w3.org/2000/svg"><path d="M15 12c2-8 7-12 15-12 12 0 13.5 9 19.5 10.5 4 1 7.5-.5 10.5-4.5-2 8-7 12-15 12-12 0-13.5-9-19.5-10.5-4-1-7.5.5-10.5 4.5zM0 30c2-8 7-12 15-12 12 0 13.5 9 19.5 10.5 4 1 7.5-.5 10.5-4.5-2 8-7 12-15 12-12 0-13.5-9-19.5-10.5-4-1-7.5.5-10.5 4.5z" fill="url(#logoGradient)" fill-rule="evenodd"></path></svg>
3433
</a>
3534
</div>
3635
<div class="relative">
@@ -185,14 +184,64 @@
185184
</nav>
186185
</div>
187186
</div>
188-
<div class="ml-80">
189-
<div id="content" class="px-6 py-8 w-full max-w-xl mx-auto">
187+
<div class="md:ml-80">
188+
<div class="fixed w-full">
189+
<div class="pin-t bg-white md:hidden relative border-b border-dark h-12 flex items-center">
190+
<div class="js-open-sidebar absolute pin-l pin-y px-4 flex items-center">
191+
<svg class="h-4" fill="#777" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"><path d="M0 3h20v2H0V3zm0 6h20v2H0V9zm0 6h20v2H0v-2z"/></svg>
192+
</div>
193+
<div class="mx-auto inline-flex items-center">
194+
<svg class="h-4" viewBox="0 0 60 36" xmlns="http://www.w3.org/2000/svg">
195+
<path d="M15 12c2-8 7-12 15-12 12 0 13.5 9 19.5 10.5 4 1 7.5-.5 10.5-4.5-2 8-7 12-15 12-12 0-13.5-9-19.5-10.5-4-1-7.5.5-10.5 4.5zM0 30c2-8 7-12 15-12 12 0 13.5 9 19.5 10.5 4 1 7.5-.5 10.5-4.5-2 8-7 12-15 12-12 0-13.5-9-19.5-10.5-4-1-7.5.5-10.5 4.5z" fill="url(#logoGradient)" fill-rule="evenodd"></path>
196+
</svg>
197+
</div>
198+
<div class="js-close-sidebar">
199+
<div class="flex items-center absolute pin-r pin-y px-4">
200+
<svg class="h-4" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"><path d="M10 8.586L2.929 1.515 1.515 2.929 8.586 10l-7.071 7.071 1.414 1.414L10 11.414l7.071 7.071 1.414-1.414L11.414 10l7.071-7.071-1.414-1.414L10 8.586z"/></svg>
201+
</div>
202+
</div>
203+
</div>
204+
</div>
205+
<div id="content" class="px-6 py-16 md:py-8 w-full max-w-xl mx-auto">
190206
<div id="app">
191207
@yield('body')
192208
</div>
193-
<script src="{{ mix('/js/app.js') }}"></script>
209+
<script src="/js/app.js"></script>
210+
<script>
211+
anchors.options = { placement: 'left', class: 'text-slate-light' };
212+
anchors.add();
213+
214+
var closeSidebar = function () {
215+
$('#sidebar').addClass("hidden");
216+
$('.js-close-sidebar').addClass("hidden");
217+
}
218+
219+
$('.js-close-sidebar').on('click', function () {
220+
closeSidebar();
221+
});
222+
223+
$('.js-open-sidebar').on('click', function () {
224+
$('#sidebar').removeClass("hidden");
225+
$('.js-close-sidebar').removeClass("hidden");
226+
});
227+
228+
$(document).ready(function () {
229+
if ($(window).width() <= 767) {
230+
closeSidebar();
231+
}
232+
});
233+
</script>
194234
</div>
195235
</div>
196236
</div>
237+
238+
<svg>
239+
<defs>
240+
<linearGradient x1="0%" y1="0%" y2="100%" id="logoGradient">
241+
<stop stop-color="#2383AE" offset="0%"></stop>
242+
<stop stop-color="#6DD7B9" offset="100%"></stop>
243+
</linearGradient>
244+
</defs>
245+
</svg>
197246
</body>
198247
</html>

docs/source/docs/background-color.blade.md

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -248,20 +248,3 @@ Using the utilities in HTML:
248248
<div class="bg-slate"></div>
249249
<div class="bg-slate-light"></div>
250250
```
251-
252-
Using the utilities in Less:
253-
254-
```less
255-
div {
256-
.bg-white;
257-
.bg-smoke-lighter;
258-
.bg-smoke-light;
259-
.bg-smoke;
260-
261-
.bg-slate-darker;
262-
.bg-slate-dark;
263-
.bg-slate;
264-
.bg-slate-light;
265-
}
266-
```
267-

docs/source/docs/border-color.blade.md

Lines changed: 0 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -4,53 +4,3 @@ title: "Border Color"
44
---
55

66
# Border Color
7-
8-
<div class="subnav">
9-
<a class="subnav-link" href="#color">Color</a>
10-
<a class="subnav-link" href="#responsive">Responsive</a>
11-
</div>
12-
13-
<h2 id="colors">Colors</h2>
14-
15-
By default, borders use the `@default-border-color`. To override a border color, add one of the border color utilities.
16-
17-
```html
18-
<div class="border border-smoke-darker"></div>
19-
<div class="border border-smoke-dark"></div>
20-
<div class="border border-smoke"></div>
21-
22-
<div class="border border-white"></div>
23-
<div class="border border-smoke-lighter"></div>
24-
<div class="border border-smoke-light"></div>
25-
26-
<div class="border border-invisible"></div>
27-
```
28-
29-
```less
30-
div {
31-
.border-smoke-darker;
32-
.border-smoke-dark;
33-
.border-smoke;
34-
35-
.border-white;
36-
.border-smoke-lighter;
37-
.border-smoke-light;
38-
39-
.border-invisible;
40-
}
41-
```
42-
43-
The default border colors can also be modified using the following variables.
44-
45-
```less
46-
// Variable: Default:
47-
@border-smoke-darker: hsl(0, 0%, 82%);
48-
@border-smoke-dark: hsl(0, 0%, 90%);
49-
@border-smoke: hsl(0, 0%, 96%);
50-
51-
@border-white: hsl(0, 0%, 100%);
52-
@border-smoke-lighter: hsl(0, 0%, 60%);
53-
@border-smoke-light: hsl(0, 0%, 35%);
54-
55-
@default-border-color: @border-smoke-dark;
56-
```

docs/source/docs/fonts.blade.md

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -4,31 +4,3 @@ title: "Font Families"
44
---
55

66
# Font Families
7-
8-
<div class="subnav">
9-
<a class="subnav-link" href="#usage">Usage</a>
10-
<a class="subnav-link" href="#responsive">Responsive</a>
11-
<a class="subnav-link" href="#customizing">Customizing</a>
12-
</div>
13-
14-
```html
15-
<div class="font-sans"></div>
16-
<div class="font-serif"></div>
17-
<div class="font-mono"></div>
18-
```
19-
20-
```less
21-
div {
22-
.font-sans;
23-
.font-serif;
24-
.font-mono;
25-
}
26-
```
27-
28-
```less
29-
// Customize the font stack
30-
@font-family-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", Arial, sans-serif;
31-
@font-family-serif: Constantia, "Lucida Bright", Lucidabright, "Lucida Serif", Lucida, "DejaVu Serif", "Bitstream Vera Serif", "Liberation Serif", Georgia, serif;
32-
@font-family-mono: Consolas, "Andale font-mono WT", "Andale Mono", "Lucida Console", "Lucida Sans Typewriter", "DejaVu Sans Mono", "Bitstream Vera Sans Mono", "Liberation Mono", "Nimbus font-mono L", Monaco, "Courier New", Courier, monospace;
33-
@font-family-base: @font-family-sans;
34-
```

docs/source/docs/margin.blade.md

Lines changed: 4 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -47,43 +47,8 @@ The syntax below is combined to create a system for padding and margins. For exa
4747

4848
You can customize the margin and padding utilities using the `@sizing-scale` variable. Please note that the entire scale must be redefined. It's not possible to add a new value to the existing scale.
4949

50-
```less
51-
// The default sizing scale
52-
@sizing-scale:
53-
'1' 0.25rem,
54-
'2' 0.5rem,
55-
'3' 0.75rem,
56-
'4' 1rem,
57-
'6' 1.5rem,
58-
'8' 2rem,
59-
'12' 3rem,
60-
'16' 4rem,
61-
;
62-
```
63-
64-
By default the `@sizing-scale` is automatically applied to the margin, negative margin (pull) and padding scales. However, it's possible to customize each scale individually using the `@margin-scale`, `@pull-scale` and `@padding-scale` variables.
65-
66-
```less
67-
// Override the margin scale
68-
@margin-scale:
69-
'1' 0.25rem,
70-
'2' 0.5rem,
71-
// ...
72-
;
73-
74-
// Override the pull scale
75-
@pull-scale:
76-
'1' 0.25rem,
77-
'2' 0.5rem,
78-
// ...
79-
;
80-
81-
// Override the padding scale
82-
@padding-scale:
83-
'1' 0.25rem,
84-
'2' 0.5rem,
85-
// ...
86-
;
50+
```css
51+
// Scale customization here
8752
```
8853

8954
<h2 id="responsive">Responsive spacing utilities</h2>
@@ -96,10 +61,6 @@ The spacing utilities can also be used with [responsive](/docs/responsive-design
9661
<div class="pull-1 sm:pull-2 md:pull-3 lg:pull-4"></div>
9762
```
9863

99-
```less
100-
div {
101-
.screen(lg, {
102-
.mt-6;
103-
});
104-
}
64+
```css
65+
// Responsive example here
10566
```

docs/source/docs/negative-margin.blade.md

Lines changed: 4 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -45,45 +45,8 @@ The syntax below is combined to create a system for padding and margins. For exa
4545

4646
<h2 id="customizing">Customizing the spacing scale</h2>
4747

48-
You can customize the margin and padding utilities using the `@sizing-scale` variable. Please note that the entire scale must be redefined. It's not possible to add a new value to the existing scale.
49-
50-
```less
51-
// The default sizing scale
52-
@sizing-scale:
53-
'1' 0.25rem,
54-
'2' 0.5rem,
55-
'3' 0.75rem,
56-
'4' 1rem,
57-
'6' 1.5rem,
58-
'8' 2rem,
59-
'12' 3rem,
60-
'16' 4rem,
61-
;
62-
```
63-
64-
By default the `@sizing-scale` is automatically applied to the margin, negative margin (pull) and padding scales. However, it's possible to customize each scale individually using the `@margin-scale`, `@pull-scale` and `@padding-scale` variables.
65-
66-
```less
67-
// Override the margin scale
68-
@margin-scale:
69-
'1' 0.25rem,
70-
'2' 0.5rem,
71-
// ...
72-
;
73-
74-
// Override the pull scale
75-
@pull-scale:
76-
'1' 0.25rem,
77-
'2' 0.5rem,
78-
// ...
79-
;
80-
81-
// Override the padding scale
82-
@padding-scale:
83-
'1' 0.25rem,
84-
'2' 0.5rem,
85-
// ...
86-
;
48+
```css
49+
// Scale customization here
8750
```
8851

8952
<h2 id="responsive">Responsive spacing utilities</h2>
@@ -96,11 +59,6 @@ The spacing utilities can also be used with [responsive](/docs/responsive-design
9659
<div class="pull-1 sm:pull-2 md:pull-3 lg:pull-4"></div>
9760
```
9861

99-
```less
100-
div {
101-
.screen(lg, {
102-
.mt-6;
103-
});
104-
}
62+
```css
63+
// Responsive example here
10564
```
106-

0 commit comments

Comments
 (0)