From d9155da176372303bb88e1e1da3568475771cc05 Mon Sep 17 00:00:00 2001 From: Michael Ball Date: Tue, 7 Jan 2020 02:26:32 -0800 Subject: [PATCH 1/9] fix typo --- app/views/conferences/_lodging.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/conferences/_lodging.haml b/app/views/conferences/_lodging.haml index 68a81548..f5ba0789 100644 --- a/app/views/conferences/_lodging.haml +++ b/app/views/conferences/_lodging.haml @@ -37,7 +37,7 @@ .caption %h3.text-center - if lodging.website_link.present? - = link_to(loding.website_link, lodiging.name) + = link_to(lodging.website_link, lodiging.name) - else = lodging.name - if lodging.description.present? From bea9f79544c429077a6dfd8938fe4a3312e8ecc5 Mon Sep 17 00:00:00 2001 From: Michael Ball Date: Tue, 7 Jan 2020 02:31:38 -0800 Subject: [PATCH 2/9] ARRRGHHH, another typo...same line... --- app/views/conferences/_lodging.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/conferences/_lodging.haml b/app/views/conferences/_lodging.haml index f5ba0789..a776a37e 100644 --- a/app/views/conferences/_lodging.haml +++ b/app/views/conferences/_lodging.haml @@ -37,7 +37,7 @@ .caption %h3.text-center - if lodging.website_link.present? - = link_to(lodging.website_link, lodiging.name) + = link_to(lodging.website_link, lodging.name) - else = lodging.name - if lodging.description.present? From 1bcf1b8f0608ed33c5ca55ffe410dcbd643b1546 Mon Sep 17 00:00:00 2001 From: Michael Ball Date: Tue, 7 Jan 2020 02:47:33 -0800 Subject: [PATCH 3/9] dumb...fix order of link_to args --- app/views/conferences/_lodging.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/conferences/_lodging.haml b/app/views/conferences/_lodging.haml index a776a37e..55a286db 100644 --- a/app/views/conferences/_lodging.haml +++ b/app/views/conferences/_lodging.haml @@ -37,7 +37,7 @@ .caption %h3.text-center - if lodging.website_link.present? - = link_to(lodging.website_link, lodging.name) + = link_to(lodging.name, lodging.website_link) - else = lodging.name - if lodging.description.present? From 16d2d8c4f0807e54ba3106e1927f560c711b3b84 Mon Sep 17 00:00:00 2001 From: Michael Ball Date: Tue, 7 Jan 2020 15:38:00 -0800 Subject: [PATCH 4/9] Cleanup CSS ordering, fix coloring for navdropdowns --- app/assets/stylesheets/application.css | 13 +++++++------ app/assets/stylesheets/osem-navbar.scss | 11 +++++++++-- app/assets/stylesheets/strap-on.scss | 4 ++-- 3 files changed, 18 insertions(+), 10 deletions(-) diff --git a/app/assets/stylesheets/application.css b/app/assets/stylesheets/application.css index 567fa050..0b80bc19 100644 --- a/app/assets/stylesheets/application.css +++ b/app/assets/stylesheets/application.css @@ -2,6 +2,13 @@ *= require strap-on *= require formtastic-bootstrap *= require dataTables/bootstrap/3/jquery.dataTables.bootstrap + *= require selectize + *= require selectize.bootstrap3 + *= require bootstrap-select + *= require bootstrap-markdown + *= require bootstrap-datetimepicker + *= require leaflet + *= require osem *= require osem-rating *= require osem-schedule @@ -10,15 +17,9 @@ *= require osem-splash *= require font-awesome *= require osem-fonts - *= require bootstrap-markdown - *= require bootstrap-datetimepicker - *= require leaflet *= require bootstrap3-switch *= require osem-payments *= require osem-navbar - *= require selectize - *= require selectize.bootstrap3 *= require mastodon - *= require bootstrap-select *= require conferences */ diff --git a/app/assets/stylesheets/osem-navbar.scss b/app/assets/stylesheets/osem-navbar.scss index 1bdeb223..2f6458be 100644 --- a/app/assets/stylesheets/osem-navbar.scss +++ b/app/assets/stylesheets/osem-navbar.scss @@ -1,4 +1,6 @@ @import "breakpoints.scss"; +$navbar-default-link-color: #FFF; + .nav-osem { border: none; @include breakpoint(xs) { @@ -31,8 +33,13 @@ .dropdown-menu { min-width: 225px; } - .navbar-default .navbar-nav>.open>a, .navbar-default .navbar-nav>.open>a:hover, .navbar-default .navbar-nav>.open>a:focus { - color: #FFF; + + &.navbar-default { + .navbar-nav > .open > a { + &:hover, &:focus { + color: $navbar-default-link-color; + } + } } .navbar-brand img { diff --git a/app/assets/stylesheets/strap-on.scss b/app/assets/stylesheets/strap-on.scss index da70029d..0a9c3908 100644 --- a/app/assets/stylesheets/strap-on.scss +++ b/app/assets/stylesheets/strap-on.scss @@ -1,8 +1,8 @@ $navbar-default-bg: #0C3559; $navbar-default-link-active-bg: rgb(8,8,8); $navbar-default-border: 1px solid #d4d4d4; -$navbar-default-color: #ffffff; -$navbar-default-link-color: #ffffff; +$navbar-default-color: #FFF; +$navbar-default-link-color: #FFF; $navbar-default-link-hover-color: #F2E205; @import 'bootstrap-datetimepicker'; From bff830ec55aa1eeaeda9620dda1bcafffd5039b1 Mon Sep 17 00:00:00 2001 From: Michael Ball Date: Tue, 7 Jan 2020 15:38:17 -0800 Subject: [PATCH 5/9] Support markdown in more fields --- app/views/admin/event_types/_form.html.haml | 5 +++-- app/views/admin/event_types/index.html.haml | 2 +- app/views/proposals/new.html.haml | 6 +++--- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/app/views/admin/event_types/_form.html.haml b/app/views/admin/event_types/_form.html.haml index 29fac398..49b82478 100644 --- a/app/views/admin/event_types/_form.html.haml +++ b/app/views/admin/event_types/_form.html.haml @@ -8,10 +8,11 @@ = @event_type.title .row .col-md-12 - = semantic_form_for(@event_type, url: (@event_type.new_record? ? admin_conference_program_event_types_path : admin_conference_program_event_type_path(@conference.short_title, @event_type))) do |f| + - form_url = (@event_type.new_record? ? admin_conference_program_event_types_path : admin_conference_program_event_type_path(@conference.short_title, @event_type)) + = semantic_form_for(@event_type, url: form_url) do |f| = f.input :title, input_html: { autofocus: true } = f.input :length, input_html: {size: 3, type: 'number', step: @event_type.program.schedule_interval, min: @event_type.program.schedule_interval} - = f.input :description + = f.input :description, as: :text, hint: markdown_hint, input_html: { rows: 5, data: { provide: 'markdown-editable' } } = f.input :minimum_abstract_length, input_html: {size: 3} = f.input :maximum_abstract_length, input_html: {size: 3} = f.input :color, input_html: { size: 6, type: 'color' } diff --git a/app/views/admin/event_types/index.html.haml b/app/views/admin/event_types/index.html.haml index 4d3c27b8..e18cceeb 100644 --- a/app/views/admin/event_types/index.html.haml +++ b/app/views/admin/event_types/index.html.haml @@ -20,7 +20,7 @@ %td = event_type.title %td - = event_type.description + = markdown(event_type.description) %td = event_type.length Minutes diff --git a/app/views/proposals/new.html.haml b/app/views/proposals/new.html.haml index 7885f990..bab6eebd 100644 --- a/app/views/proposals/new.html.haml +++ b/app/views/proposals/new.html.haml @@ -7,7 +7,7 @@ - if @program.cfp.description.present? .row .col-md-12 - = markdown(@program.cfp.description) + = markdown(@program.cfp.description, escape_html=false) .row .col-md-12 = render partial: 'encouragement_text' @@ -43,10 +43,10 @@ - @program.event_types.each do |event_type| %span{ class: 'help-block event_event_type_id collapse', id: "#{event_type.id}-help" } - = event_type.description + = markdown(event_type.description) = f.input :abstract, required: true, input_html: { rows: 5, data: { provide: 'markdown-editable' } }, - hint: markdown_hint('[Tips to improve your presentations.](http://blog.hubspot.com/blog/tabid/6307/bid/5975/10-Rules-to-Instantly-Improve-Your-Presentations.aspx)') + hint: markdown_hint %p You have used From 2c9645895e095775b3789e36d42d6a49af17dd4f Mon Sep 17 00:00:00 2001 From: Michael Ball Date: Tue, 7 Jan 2020 15:47:10 -0800 Subject: [PATCH 6/9] Make the edit form not so wide. --- app/views/admin/event_types/_form.html.haml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/admin/event_types/_form.html.haml b/app/views/admin/event_types/_form.html.haml index 49b82478..91533877 100644 --- a/app/views/admin/event_types/_form.html.haml +++ b/app/views/admin/event_types/_form.html.haml @@ -7,7 +7,7 @@ Event Type = @event_type.title .row - .col-md-12 + .col-md-8 - form_url = (@event_type.new_record? ? admin_conference_program_event_types_path : admin_conference_program_event_type_path(@conference.short_title, @event_type)) = semantic_form_for(@event_type, url: form_url) do |f| = f.input :title, input_html: { autofocus: true } From 7553c15e5e3cec25fa359a1d83c732031d50afce Mon Sep 17 00:00:00 2001 From: Michael Ball Date: Tue, 7 Jan 2020 16:06:51 -0800 Subject: [PATCH 7/9] CSS tweaks... --- app/assets/stylesheets/osem.scss | 3 ++- app/views/conferences/_header.haml | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/app/assets/stylesheets/osem.scss b/app/assets/stylesheets/osem.scss index c48be11d..55632cec 100644 --- a/app/assets/stylesheets/osem.scss +++ b/app/assets/stylesheets/osem.scss @@ -7,9 +7,10 @@ html { body { /* Margin bottom by 2 times the footer height */ - margin-bottom: 60px; + margin-bottom: 85px; /* Margin bottom by navbar height */ padding-top: 60px; + font-size: 16px; } #content { diff --git a/app/views/conferences/_header.haml b/app/views/conferences/_header.haml index 23d6b4eb..cb45bb5e 100644 --- a/app/views/conferences/_header.haml +++ b/app/views/conferences/_header.haml @@ -2,14 +2,14 @@ #banner{ style: ("background-image: url(#{conference.picture_url})" if conference.picture_url) } .container .row - .col-md-8.col-md-offset-2#header + .col-md-6.col-md-offset-3#header .row -# - if conference.picture? -# .col-md-4 -# = image_tag(conference.picture_url, -# class: 'img-responsive img-center', -# id: 'splash-logo') - .col-md-8.col-md-offset-2 + .col-md-8 %h1 = conference.title.html_safe %h3 From 9a811b4a6cde3c87ea0b9b445fe653154cc37cdb Mon Sep 17 00:00:00 2001 From: Michael Ball Date: Tue, 7 Jan 2020 16:16:18 -0800 Subject: [PATCH 8/9] Update lodging styling. Add description for venu when map is shown. --- app/views/conferences/_lodging.haml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/views/conferences/_lodging.haml b/app/views/conferences/_lodging.haml index 55a286db..2088721d 100644 --- a/app/views/conferences/_lodging.haml +++ b/app/views/conferences/_lodging.haml @@ -5,6 +5,10 @@ - cache [venue, lodgings, '#splash#lodging'] do %section#lodging .container + - if venue.location? and venue.description.present? + .row + .col-md-8.col-md-offset-2 + = markdown(venue.description, escape_html=false) .row .col-md-12.text-center %h2 @@ -17,7 +21,7 @@ .row.row-centered - lodgings.order(created_at: :asc).each do |lodging| - .col-md-4.col-sm-4.col-centered.col-top + .col-md-6.col-sm-4.col-centered.col-top .thumbnail - if lodging.picture? - if lodging.website_link.present? From 722bd8c008e8f2ed3df5a37c507602d6ed2768a2 Mon Sep 17 00:00:00 2001 From: Michael Ball Date: Tue, 7 Jan 2020 16:21:15 -0800 Subject: [PATCH 9/9] Move the venue description to below the map. --- app/views/conferences/_lodging.haml | 4 ---- app/views/conferences/_venue.haml | 5 +++++ 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/app/views/conferences/_lodging.haml b/app/views/conferences/_lodging.haml index 2088721d..7306b962 100644 --- a/app/views/conferences/_lodging.haml +++ b/app/views/conferences/_lodging.haml @@ -5,10 +5,6 @@ - cache [venue, lodgings, '#splash#lodging'] do %section#lodging .container - - if venue.location? and venue.description.present? - .row - .col-md-8.col-md-offset-2 - = markdown(venue.description, escape_html=false) .row .col-md-12.text-center %h2 diff --git a/app/views/conferences/_venue.haml b/app/views/conferences/_venue.haml index fbdcde48..69c5cd31 100644 --- a/app/views/conferences/_venue.haml +++ b/app/views/conferences/_venue.haml @@ -5,6 +5,11 @@ %section#venue - if venue.location? = render '/conferences/venue_map', venue: venue + - if venue.description.present? + .container + .row + .col-md-8.col-md-offset-2 + = markdown(venue.description, escape_html=false) - else - cache [venue, commercial, '#splash#venue'] do .container