Skip to content

Commit

Permalink
styled about me
Browse files Browse the repository at this point in the history
  • Loading branch information
enterteg committed Mar 28, 2016
1 parent 95d6628 commit 9dd0c7b
Show file tree
Hide file tree
Showing 19 changed files with 60,250 additions and 19 deletions.
Binary file added app/assets/images/domi2.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
74 changes: 69 additions & 5 deletions app/assets/stylesheets/posts.sass
Original file line number Diff line number Diff line change
Expand Up @@ -63,16 +63,79 @@ section
article.about
max-width: 80%
margin: 0 auto
.photos
justify-content: center
align-items: center
display: flex
padding: 20px 0px

.icon
height: 50px
width: 50px
img
margin: 0px
width: 100%
height: 100%
opacity: 0.4
cursor: pointer
&:hover
opacity: 0.8

&#gmail
position: relative
&:after
opacity: 0
content: ''
display: block
width: 0px
height: 0px
position: absolute
bottom: -15px
left: 15px
border-bottom: 10px solid rgba(250,50,150,0.7)
border-right: 10px solid transparent
border-left: 10px solid transparent
.mail
opacity: 0
color: white
padding: 10px 20px
font-size: 1.3rem
position: relative
top: 15px
left: -40px
display: inline-block
background-color: rgba(250,50,150,0.7)

&:hover
&:after
opacity: 1
.mail
opacity: 1
.portrait
width: 35%
margin: 0px 10%
img
width: 100%
box-shadow: 0px 0px 30px rgba(0,0,0,0.2)
border-radius: 50%

#map_photo
height: 0px
position: relative
top: -150px
z-index: -10
opacity: 0.1
.desc
padding: 30px
font-size: 1.3rem
padding: 0px 10px
font-size: 1.6rem
line-height: 1.6
.post
max-width: 700px
margin: 50px auto 80px
font-family: 'Raleway'
position: relative
&.sample
padding: 35px 65px 25px
padding: 35px 65px 0px
max-width: 620px
box-shadow: 0px 0px 50px rgba(0,0,0,0.05)
z-index: 10
Expand Down Expand Up @@ -130,11 +193,12 @@ section
margin-right: 10px
article
font-family: 'Roboto'
padding: 20px 0px
padding: 10px 20px 10px 0px
font-weight: 300
text-align: justify
line-height: 1.4
font-size: 1.1rem
font-size: 1.15rem

.pagination
text-align: center
padding: 10px 0px
Expand Down
6 changes: 3 additions & 3 deletions app/assets/stylesheets/public.sass
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,13 @@ hr
font-size: 1.3rem
display: inline
margin: 0px 2px
padding: 3px 5px
padding: 8px 5px
border-top: 0px solid white
+transition(0.5s border)
&:hover
position: relative
cursor: pointer
border-top: 30px solid rgba(150,0,200,0.1)
border-top: 30px solid rgba(250,0,100,0.45)
.admin
float: right
line-height: $top_menu_height
Expand Down Expand Up @@ -107,7 +107,7 @@ hr
padding: 5px
outline: none
border: 0px solid black
border-bottom: 1px solid rgba(0,0,0,1)
border-bottom: 1px solid rgba(0,0,0,0.8)
background: white

&:focus
Expand Down
2 changes: 1 addition & 1 deletion app/controllers/public_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def life
end

def about
@post = Post.find(1).includes(:photos)
@post = Post.includes(:photos).find(1)
end

def search
Expand Down
2 changes: 1 addition & 1 deletion app/views/layouts/application.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
%title Blog
= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track' => true
= javascript_include_tag 'application', 'data-turbolinks-track' => true
%link{:href => "https://fonts.googleapis.com/css?family=Raleway:200|Roboto:100", :rel => "stylesheet", :type => "text/css"}/
%link{:href => "https://fonts.googleapis.com/css?family=Raleway:200|Roboto:100,300", :rel => "stylesheet", :type => "text/css"}/
= csrf_meta_tags
%body
%header
Expand Down
28 changes: 21 additions & 7 deletions app/views/public/about.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,27 @@
%section
%article.about
.header= @post.title

.photos
= link_to 'https://www.facebook.com/dominika.jagiela?ref=ts&fref=ts' do
.icon= image_tag 'fb-icon.png'
- if @post.photos.any?
.portrait= image_tag @post.photos.first.photo.url
.icon#gmail
= image_tag 'gmail-icon.png'
.mail= '[email protected]'

#map_photo
= image_tag 'map.jpg'
.desc
= @post.desc.html_safe

= link_to :back do
.button.edit back
- if current_user
= link_to edit_post_path(@post) do
.button.edit edit
= link_to @post, method: 'delete', data: {confirm: 'Are you sure?'} do
.button.edit destroy
= link_to :back do
.button.edit back
- if current_user
= link_to edit_post_path(@post) do
.button.edit edit
= link_to @post, method: 'delete', data: {confirm: 'Are you sure?'} do
.button.edit destroy


2 changes: 1 addition & 1 deletion app/views/session/new.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
= text_field_tag :login, '', autofocus: true
.input
= label_tag :password
= password_field_tag :password
= password_field_tag :password, '',autocomplete: 'off'
.submit
= submit_tag 'Log in'

Large diffs are not rendered by default.

Loading

0 comments on commit 9dd0c7b

Please sign in to comment.