Skip to content

Commit 39ff000

Browse files
authored
Merge pull request #35 from rstudio/well-bg
well bg color should be themable via card-bg variable
2 parents 2b33aa8 + 84a2d03 commit 39ff000

File tree

6 files changed

+14
-4
lines changed

6 files changed

+14
-4
lines changed

R/layers.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,9 @@ bootstrap_javascript <- function(version, minified = TRUE) {
6969

7070
bs3compat_layer <- function() {
7171
sass_layer(
72-
defaults = sass_file(system.file("bs3compat", "_pre_variables.scss", package = "bootstraplib")),
72+
defaults = sass_file(system.file("bs3compat", "_defaults.scss", package = "bootstraplib")),
7373
declarations = sass_file(system.file("bs3compat", "_declarations.scss", package = "bootstraplib")),
74-
rules = sass_file(system.file("bs3compat", "_post_variables.scss", package = "bootstraplib")),
74+
rules = sass_file(system.file("bs3compat", "_rules.scss", package = "bootstraplib")),
7575
# Gyliphicon font files
7676
file_attachments = c(
7777
fonts = system.file("node_modules/bootstrap-sass/assets/fonts", package = "bootstraplib")

inst/bs3compat/_components_compat.scss

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
.well {
2-
@extend .bg-light; @extend .card; @extend .p-3;
2+
@extend .card;
3+
background-color: $well-bg;
4+
padding: map-get($spacers, 3);
35
}
46

57
.help-text, .help-block {

inst/bs3compat/_declarations.scss

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,9 @@ $default: null !default;
2121
}
2222

2323
$theme-colors: map-merge(("default": $default), $theme-colors);
24+
25+
26+
// Cards are white by default, but we want a smarter default for .well
27+
// that it appears similar to $light with no theming, but is also smart enough
28+
// to respond to changes in foreground color
29+
$well-bg: rgba($body-color, 0.1) !default;

inst/bs3compat/_shiny_misc.scss

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
// For verbatimTextOutput()
22
pre.shiny-text-output {
3-
@extend .bg-light; @extend .card; @extend .p-2;
3+
@extend .card;
4+
background-color: $well-bg;
5+
padding: map-get($spacers, 2);
46
}
57

68
// For code inside of showcase mode

0 commit comments

Comments
 (0)