Skip to content

Commit

Permalink
Merge pull request #698 from cul-it/rmc-legacy-theme
Browse files Browse the repository at this point in the history
Add RMC legacy theme to include modified version of original  masthead images
  • Loading branch information
ebtoner authored Dec 2, 2024
2 parents c7a4f7f + 20690c5 commit a5d1854
Show file tree
Hide file tree
Showing 6 changed files with 46 additions and 2 deletions.
1 change: 1 addition & 0 deletions app/assets/config/manifest.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@
//= link application_dr-joyce-brothers.css
//= link application_blackprint.css
//= link application_example.css
//= link application_rmc-legacy.css
//= link openseadragon-assets.js
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 0 additions & 1 deletion app/assets/stylesheets/application_dr-joyce-brothers.scss
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ body, header {

.background-container {
background-position: center;
filter: none;
height: 180px;
border: none;

Expand Down
39 changes: 39 additions & 0 deletions app/assets/stylesheets/application_rmc-legacy.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
@import 'base';

// Theme designed to include a modified version of the original RMC masthead image in larger screen sizes

.masthead {
.site-title-container {
@media (min-width: breakpoint-max('md')) {
// For larger screen sizes, hide title text (except for screen readers)
height: 180px;
.site-title {
@include sr-only;
}
.site-title-wrapper {
background: none;
}

}
}

.background-container {
// Center masthead image
background-position: center;
border: none;
height: 180px;

@media (max-width: breakpoint-max('md')) {
// For smaller screen sizes, zoom in on solid background color on left side of modified RMC masthead image
background-position: left;
background-size: 600% 100%;
}
}

.background-container-gradient {
@media (min-width: breakpoint-max('md')) {
// For larger screen sizes, remove background image gradient
display: none;
}
}
}
5 changes: 5 additions & 0 deletions app/assets/stylesheets/exhibits/_header.scss
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,11 @@ header {
}
}

// Remove default blur filter
.image-masthead .background-container {
filter: blur(0);
}

// Utilities navbar
// --------------------
.navbar-toggler {
Expand Down
2 changes: 1 addition & 1 deletion config/initializers/spotlight_initializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@
# 'my-local-config': ->(context) { context.my_custom_data_path(context.current_exhibit) }
# }

default_themes = %w[default example]
default_themes = %w[default example rmc-legacy]
custom_themes = %w[dr-joyce-brothers blackprint]
Spotlight::Engine.config.exhibit_themes = default_themes + custom_themes

Expand Down

0 comments on commit a5d1854

Please sign in to comment.