Merge pull request #1132 from Ana06/all-events-links

Make the whole event panel clickable in all events
This commit is contained in:
Stella Rouzi 2016-08-11 13:20:46 +03:00 committed by GitHub
commit e34a1904e0
2 changed files with 47 additions and 39 deletions

View file

@ -63,12 +63,6 @@ background-image: -webkit-gradient(
color: rgb(185, 74, 72); color: rgb(185, 74, 72);
} }
a.unstyled-link {
text-decoration: none;
color: #333333;
outline: 0;
}
.program-dropdown, .schedule-dropdown{ .program-dropdown, .schedule-dropdown{
margin-left: 20%; margin-left: 20%;
margin-right: 20%; margin-right: 20%;
@ -175,6 +169,10 @@ td.no-padding{
display: inline-block; display: inline-block;
} }
.event-panel{
cursor: pointer;
}
.program-dropdown{ .program-dropdown{
margin-left: 20%; margin-left: 20%;
margin-right: 20%; margin-right: 20%;

View file

@ -1,5 +1,4 @@
%a.unstyled-link{href: url_for(conference_program_proposal_path(@conference.short_title, event.id))} .panel.panel-default.event-panel{ id: "link-#{event.id}" }
.panel.panel-default
.panel-body .panel-body
- if speaker = event.speakers.first - if speaker = event.speakers.first
= image_tag speaker.gravatar_url, :class => "img-circle pull-right all-speaker-pic", | = image_tag speaker.gravatar_url, :class => "img-circle pull-right all-speaker-pic", |
@ -31,3 +30,14 @@
%span.fa.fa-road %span.fa.fa-road
%span.label{ style: "background-color: #{event.track.color}; color: #{ contrast_color(event.track.color) }" } %span.label{ style: "background-color: #{event.track.color}; color: #{ contrast_color(event.track.color) }" }
= event.track.name = event.track.name
:javascript
$("#link-#{event.id}").click(function(e) {
var url = "#{url_for(conference_program_proposal_path(@conference.short_title, event.id))}";
if(e.ctrlKey)
window.open(url,'_blank');
else
window.location = url;
});