Skip to content

Commit f747a6c

Browse files
committed
styling/Add basic responsive functionality
1 parent f8f5891 commit f747a6c

File tree

2 files changed

+18
-3
lines changed

2 files changed

+18
-3
lines changed

app/assets/stylesheets/base.scss

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,3 +41,19 @@ strong { font-weight: 500 }
4141
max-width: 1080px;
4242
// height: 100vh;
4343
}
44+
45+
#sidebar {
46+
width: 22%;
47+
48+
@media only screen and (min-device-width : 320px) and (max-device-width : 480px) {
49+
display: none;
50+
}
51+
}
52+
53+
#body {
54+
width: 78%;
55+
56+
@media only screen and (min-device-width : 320px) and (max-device-width : 480px) {
57+
width: 100%;
58+
}
59+
}

app/views/layouts/application.html.erb

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,10 @@
3939

4040
<div id="app">
4141
<div style="display: flex;">
42-
<div style="width: 22%;">
42+
<div id="sidebar">
4343
<%= render 'shared/sidebar' %>
4444
</div>
45-
<%# <div style="flex: 1; flex-basis: 25%; max-width: 25%;"></div> %>
46-
<div style="width: 78%;">
45+
<div id="body">
4746
<%= yield %>
4847
</div>
4948
</div>

0 commit comments

Comments
 (0)