nfg_ui 0.12.14 → 0.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (23) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_custom.scss +0 -1
  3. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_content_section.scss +12 -12
  4. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_free_trial.scss +2 -2
  5. data/app/assets/stylesheets/nfg_ui/network_for_good/core/_variables.scss +23 -21
  6. data/app/assets/stylesheets/nfg_ui/network_for_good/core/legacy_browser_support/nfg_theme/_carousel.scss +29 -1
  7. data/app/assets/stylesheets/nfg_ui/network_for_good/core/nfg_theme/custom/_redactor.scss +2 -2
  8. data/app/assets/stylesheets/nfg_ui/network_for_good/email/application.scss +17 -10
  9. data/app/assets/stylesheets/nfg_ui/network_for_good/email/foundation_emails/_button.scss +1 -55
  10. data/app/assets/stylesheets/nfg_ui/network_for_good/email/foundation_emails/_grid.scss +0 -12
  11. data/app/assets/stylesheets/nfg_ui/network_for_good/email/foundation_emails/_typography.scss +4 -155
  12. data/app/assets/stylesheets/nfg_ui/network_for_good/email/nfg_theme/_borders.scss +2 -2
  13. data/app/assets/stylesheets/nfg_ui/network_for_good/email/nfg_theme/_content_sections.scss +2 -2
  14. data/app/assets/stylesheets/nfg_ui/network_for_good/email/nfg_theme/_layout.scss +1 -1
  15. data/app/assets/stylesheets/nfg_ui/network_for_good/email/nfg_theme/_typography.scss +1 -1
  16. data/app/assets/stylesheets/nfg_ui/network_for_good/email/settings/_settings.scss +31 -31
  17. data/app/assets/stylesheets/nfg_ui/network_for_good/public/nfg_theme/_carousel.scss +179 -3
  18. data/lib/nfg_ui/bootstrap/components/carousel.rb +9 -1
  19. data/lib/nfg_ui/bootstrap/components/carousel_item.rb +15 -1
  20. data/lib/nfg_ui/components/patterns/carousel.rb +12 -15
  21. data/lib/nfg_ui/version.rb +1 -1
  22. metadata +4 -5
  23. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_redacted_text.scss +0 -32
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 60875d5aa3ea456c24da466c6a9c424697bf2ead1cafc1ea2fc75e98fbc8e485
4
- data.tar.gz: 7bc521886ce98d98619f3739493dd7efa2018f24309de68d641eae3b29f50398
3
+ metadata.gz: 8235aa4af7843ba006e8caae070d20f87561c6d39db6dda7acc0f86c5bb2a54f
4
+ data.tar.gz: b2cda42305a691eba3bfc4351851b1dd21d753b8b6e162f1bb7229036d5c1eb7
5
5
  SHA512:
6
- metadata.gz: d5a81f8a7c78e15e311efeaa54fe2563267390243a9d6e7c7c9f3c2e40e3331648ddd51d93c5c841223f54b411e83bad435b1f0c7b24e1d887b6bca0f95c50d9
7
- data.tar.gz: 1ff27c8b7276506d41987310bbc84618a4a9fe9fab5ccc86024e73db8be820d2f0e2a764c5862e8f134baab07112220ef3926dcbb1d5cd89a62896af6848ede5
6
+ metadata.gz: 0e9a5cc6430ecdef3e4090ff685d8455fd5ac6d6291052bca66e8715d7817484db14a014a635ff6b52f0350cb1a1cfdfb42b5a725d4e7cc8c030ea878fc0d81f
7
+ data.tar.gz: b94dd4c453cec22475b90ca00faf7cb6d19646c8e3e2386b037f38925fe78073eb73a73ce8e3642620feb69d3992690b554b6564d1ee5c2a2f0bab01872d1d8d
@@ -16,7 +16,6 @@
16
16
  @import 'custom/mailings';
17
17
  @import 'custom/page_header';
18
18
  @import 'custom/readmore';
19
- @import 'custom/redacted_text';
20
19
  @import 'custom/share_dropdown';
21
20
  @import 'custom/sortable';
22
21
  @import 'custom/status_indicator';
@@ -38,10 +38,10 @@
38
38
  bottom: 100%;
39
39
  margin-bottom: ($spacer * .5);
40
40
  min-width: 200px;
41
+ max-width: 100%;
41
42
  width: 430px;
42
43
  text-align: center;
43
44
  z-index: 120;
44
- @include media-breakpoint-down(xs) { max-width: 100%; }
45
45
  &[data-for='header_text'] {
46
46
  top: 100%;
47
47
  bottom: auto;
@@ -55,24 +55,24 @@
55
55
  z-index: 100;
56
56
  a {
57
57
  display: inline-block;
58
- padding: $btn-padding-y $btn-padding-x;
59
- font-size: $btn-font-size;
60
- line-height: $btn-line-height;
61
- color: $body-color;
58
+ padding: $btn-padding-y $btn-padding-x !important;
59
+ font-size: $btn-font-size !important;
60
+ line-height: $btn-line-height !important;
61
+ color: $body-color !important;
62
62
  text-align: center;
63
- background-color: $white;
63
+ background-color: $white !important;
64
64
  border: $border-width solid $border-color;
65
65
  border-bottom: 0;
66
- text-decoration: none;
66
+ text-decoration: none !important;
67
67
  border-radius: $btn-border-radius $btn-border-radius 0 0;
68
- @include hover-focus-active {
69
- color: $white;
70
- background: $primary;
68
+ &:hover, &:focus, &:active {
69
+ color: $white !important;
70
+ background: $primary !important;
71
71
  }
72
72
  i.fa { margin-right: ($spacer * .25); }
73
73
  &.cs-html-editor-save {
74
- color: $white;
75
- background-color: $primary;
74
+ color: $white !important;
75
+ background-color: $primary !important;
76
76
  }
77
77
  + a[class^='cs-html-editor-'] { margin-left: ($spacer * .25); }
78
78
  }
@@ -1,7 +1,7 @@
1
1
  // Free trial styles for DMS
2
2
 
3
3
  // Height of banner
4
- $free_trial_banner_height: 6.2rem;
4
+ $free_trial_banner_height: 7.4rem;
5
5
 
6
6
  // Styles for container elements when body tag is using .has-free-trial
7
7
  body.has-free-trial.nfg_ui {
@@ -15,7 +15,7 @@ body.has-free-trial.nfg_ui {
15
15
  @include media-breakpoint-up(xl) {
16
16
  .site-nav {
17
17
  top: $free_trial_banner_height;
18
- height: calc(100% - 62px);
18
+ height: calc(100% - 74px);
19
19
  }
20
20
  .full_width_layout { padding-top: ($spacer * 3); }
21
21
  .container-wrap { padding-top: ($spacer * 2) + $free_trial_banner_height; }
@@ -5,7 +5,7 @@
5
5
 
6
6
  // Color system
7
7
 
8
- $white: #fff;
8
+ $white: #ffffff;
9
9
  $gray-100: #F3F6F8;
10
10
  $gray-200: #E2E7EA;
11
11
  $gray-300: #C9CED1;
@@ -15,7 +15,7 @@ $gray-600: #70787C;
15
15
  $gray-700: #5B6367; // not used in our theme
16
16
  $gray-800: #313A3E;
17
17
  $gray-900: #1D262B;
18
- $black: #000;
18
+ $black: #000000;
19
19
 
20
20
  // $grays: () !default;
21
21
  // stylelint-disable-next-line scss/dollar-variable-default
@@ -296,7 +296,7 @@ $font-family-sans-serif: "Open Sans", "Helvetica Neue", Arial, sans-serif;
296
296
  // stylelint-enable value-keyword-case
297
297
 
298
298
  $font-size-base: 1.6rem; // Root font size is 62.5% to make calculations to REM 10 point based
299
- // $font-size-lg: ($font-size-base * 1.25) !default;
299
+ $font-size-lg: ($font-size-base * 1.25);
300
300
  $font-size-sm: ($font-size-base * .875);
301
301
 
302
302
  // $font-weight-lighter: lighter !default;
@@ -403,8 +403,8 @@ $table-dark-color: theme-color("light");
403
403
  $input-btn-padding-y: .7rem;
404
404
  $input-btn-padding-x: ($spacer * .25) + ($spacer * .125);
405
405
  // $input-btn-font-family: null !default;
406
- // $input-btn-font-size: $font-size-base !default;
407
- // $input-btn-line-height: $line-height-base !default;
406
+ $input-btn-font-size: $font-size-base;
407
+ $input-btn-line-height: $line-height-base;
408
408
 
409
409
  $input-btn-focus-width: ($spacer * .125);
410
410
  $input-btn-focus-color: transparentize($primary, 0.8);
@@ -430,8 +430,8 @@ $input-btn-padding-x-lg: ($spacer * .75) - ($spacer * .125);
430
430
  $btn-padding-y: ($input-btn-padding-y + .1rem);
431
431
  $btn-padding-x: ($spacer * .5);
432
432
  // $btn-font-family: $input-btn-font-family !default;
433
- // $btn-font-size: $input-btn-font-size !default;
434
- // $btn-line-height: $input-btn-line-height !default;
433
+ $btn-font-size: $input-btn-font-size;
434
+ $btn-line-height: $input-btn-line-height;
435
435
 
436
436
  $btn-padding-y-sm: ($input-btn-padding-y-sm + .1rem);
437
437
  // $btn-padding-x-sm: $input-btn-padding-x-sm !default;
@@ -695,13 +695,13 @@ $form-validation-states: map-merge(
695
695
  // Warning: Avoid customizing these values. They're used for a bird's eye view
696
696
  // of components dependent on the z-axis and are designed to all work together.
697
697
 
698
- // $zindex-dropdown: 1000 !default;
699
- // $zindex-sticky: 1020 !default;
700
- // $zindex-fixed: 1030 !default;
701
- // $zindex-modal-backdrop: 1040 !default;
702
- // $zindex-modal: 1050 !default;
703
- // $zindex-popover: 1060 !default;
704
- // $zindex-tooltip: 1070 !default;
698
+ $zindex-dropdown: 1000;
699
+ $zindex-sticky: 1020;
700
+ $zindex-fixed: 1030;
701
+ $zindex-modal-backdrop: 1040;
702
+ $zindex-modal: 1050;
703
+ $zindex-popover: 1060;
704
+ $zindex-tooltip: 1070;
705
705
 
706
706
 
707
707
  // Navs
@@ -1072,10 +1072,10 @@ $breadcrumb-active-color: $text-muted;
1072
1072
 
1073
1073
  // Carousel
1074
1074
 
1075
- // $carousel-control-color: $white !default;
1076
- // $carousel-control-width: 15% !default;
1077
- $carousel-control-opacity: .3;
1078
- // $carousel-control-hover-opacity: .9 !default;
1075
+ $carousel-control-color: $white;
1076
+ $carousel-control-width: ($spacer * 1.5);
1077
+ $carousel-control-opacity: .5;
1078
+ $carousel-control-hover-opacity: .9;
1079
1079
  // $carousel-control-transition: opacity .15s ease !default;
1080
1080
 
1081
1081
  $carousel-indicator-width: ($spacer * .5);
@@ -1088,10 +1088,12 @@ $carousel-indicator-transition: $text-muted;
1088
1088
  // $carousel-caption-width: 70% !default;
1089
1089
  // $carousel-caption-color: $white !default;
1090
1090
 
1091
- // $carousel-control-icon-width: 20px !default;
1091
+ $carousel-control-icon-width: $spacer;
1092
1092
 
1093
- // $carousel-control-prev-icon-bg: str-replace(url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='#{$carousel-control-color}' viewBox='0 0 8 8'%3e%3cpath d='M5.25 0l-4 4 4 4 1.5-1.5-2.5-2.5 2.5-2.5-1.5-1.5z'/%3e%3c/svg%3e"), "#", "%23") !default;
1094
- // $carousel-control-next-icon-bg: str-replace(url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='#{$carousel-control-color}' viewBox='0 0 8 8'%3e%3cpath d='M2.75 0l-1.5 1.5 2.5 2.5-2.5 2.5 1.5 1.5 4-4-4-4z'/%3e%3c/svg%3e"), "#", "%23") !default;
1093
+ // $carousel-control-prev-icon-bg: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' fill='#{$carousel-control-color}' width='8' height='8' viewBox='0 0 8 8'><path d='M5.25 0l-4 4 4 4 1.5-1.5L4.25 4l2.5-2.5L5.25 0z'/></svg>") !default;
1094
+ // $carousel-control-next-icon-bg: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' fill='#{$carousel-control-color}' width='8' height='8' viewBox='0 0 8 8'><path d='M2.75 0l-1.5 1.5L3.75 4l-2.5 2.5L2.75 8l4-4-4-4z'/></svg>") !default;
1095
+ $carousel-control-prev-icon-bg: '\f0d9';
1096
+ $carousel-control-next-icon-bg: '\f0da';
1095
1097
 
1096
1098
  // $carousel-transition-duration: .6s !default;
1097
1099
  // $carousel-transition: transform $carousel-transition-duration ease-in-out !default; // Define transform transition first if using multiple transitions (e.g., `transform 2s ease, opacity .5s ease-out`)
@@ -1,3 +1,5 @@
1
+ $carousel-thumbnail-size: ($spacer * 2.5); // 80px
2
+
1
3
  .carousel-item { -ms-flex-align: center; }
2
4
 
3
5
  // Left/right controls for nav
@@ -15,4 +17,30 @@
15
17
  display: -ms-flexbox;
16
18
  -ms-flex-pack: center;
17
19
  li { -ms-flex: 0 1 auto; }
18
- }
20
+ }
21
+
22
+
23
+ // Carousels that have a fixed aspect ratio height
24
+ .carousel-fixed-height {
25
+ .carousel-item {
26
+ display: -ms-flexbox;
27
+ -ms-flex-align: center;
28
+ -ms-flex-pack: center;
29
+ }
30
+ }
31
+
32
+
33
+ // Carousels that use image thumbnails for indicators
34
+ .carousel-has-thumbnails {
35
+ .carousel-indicators {
36
+ @include media-breakpoint-down(lg) {
37
+ -ms-flex-pack: start;
38
+ }
39
+ li {
40
+ @include media-breakpoint-down(lg) {
41
+ -ms-flex-negative: 0;
42
+ -ms-flex-preferred-size: $carousel-thumbnail-size;
43
+ }
44
+ }
45
+ }
46
+ }
@@ -45,7 +45,7 @@
45
45
  &.re-icon {
46
46
  .body-text { font-family: Arial, Helvetica, Verdana, Tahoma, sans-serif !important; }
47
47
  }
48
- @include hover-focus-active {
48
+ &:hover, &:focus, &:active {
49
49
  color: $white !important;
50
50
  background-color: $primary;
51
51
  }
@@ -72,7 +72,7 @@ body.modal-open {
72
72
  z-index: $zindex-modal + 1 !important;
73
73
  a[class^="redactor-dropdown-"] {
74
74
  color: $body-color;
75
- @include hover-focus-active {
75
+ &:hover, &:focus, &:active {
76
76
  color: $white;
77
77
  background-color: $primary;
78
78
  }
@@ -1,10 +1,19 @@
1
+ //** Email Styles **//
2
+
3
+ // Variables from core
4
+ @import 'nfg_ui/network_for_good/core/variables';
5
+
6
+ // Redactor styles
7
+ @import 'nfg_ui/network_for_good/core/nfg_theme/custom/redactor.scss';
8
+ @import 'nfg_ui/network_for_good/admin/nfg_theme/custom/content_section.scss';
9
+
10
+ // Foundation email styles
1
11
  @import "settings/settings";
2
12
  @import "foundation-emails";
3
13
  @import "foundation_emails/alignment";
4
14
  @import "foundation_emails/button";
5
15
  @import "foundation_emails/typography";
6
16
 
7
-
8
17
  // NFG Theme specific
9
18
  @import "nfg_theme/backgrounds";
10
19
  @import "nfg_theme/borders";
@@ -16,21 +25,19 @@
16
25
  @import "nfg_theme/text_colors";
17
26
  @import "nfg_theme/typography";
18
27
 
19
-
20
28
  // App Utilities
21
29
  // i18n translation missing visual to help find missing t('')s...
22
- .translation_missing{
23
- background-color: #ec5840;
30
+ .translation_missing {
31
+ background-color: $danger;
24
32
  display: inline-block;
25
- border: solid 3px darken(#ec5840, 15%);
26
- padding:10px;
27
- color:#fff;
33
+ border: solid 3px darken($danger, 15%);
34
+ padding: 10px;
35
+ color: #fff;
28
36
  position: relative;
29
-
30
- &:before{
37
+ &:before {
31
38
  content: "Translation Missing:";
32
39
  position: absolute;
33
- background-color: darken(#ec5840, 15%);
40
+ background-color: darken($danger, 15%);
34
41
  display: inline-block;
35
42
  width: 110px;
36
43
  left: 50%;
@@ -2,60 +2,6 @@
2
2
  // zurb.com/ink/
3
3
  // Licensed under MIT Open Source
4
4
 
5
- ////
6
- /// @group button
7
- ////
8
-
9
- // /// Padding inside buttons at various sizes.
10
- // /// @type Map
11
- // $button-padding: (
12
- // tiny: 4px 8px 4px 8px,
13
- // small: 5px 10px 5px 10px,
14
- // default: 8px 16px 8px 16px,
15
- // large: 10px 20px 10px 20px,
16
- // ) !default;
17
-
18
- // /// Font sizes of buttons at various sizes.
19
- // /// @type Map
20
- // $button-font-size: (
21
- // tiny: 10px,
22
- // small: 12px,
23
- // default: 16px,
24
- // large: 20px,
25
- // ) !default;
26
-
27
- // /// Text color of buttons.
28
- // /// @type Color
29
- // $button-color: $white !default;
30
-
31
- // /// Text color of buttons with a light background.
32
- // /// @type Color
33
- // $button-color-alt: $medium-gray !default;
34
-
35
- // /// Font weight of buttons.
36
- // /// @type Weight
37
- // $button-font-weight: bold !default;
38
-
39
- // /// Margin around buttons.
40
- // /// @type List
41
- // $button-margin: 0 0 $global-margin 0 !default;
42
-
43
- // /// Background color of buttons.
44
- // /// @type Color
45
- // $button-background: $primary-color !default;
46
-
47
- // /// Border around buttons.
48
- // /// @type Border
49
- // $button-border: 2px solid $button-background !default;
50
-
51
- // /// Border radius of buttons. Not supported by all email clients.
52
- // /// @type Number
53
- // $button-radius: $global-radius !default;
54
-
55
- // /// Border radius of rounded buttons. Not supported by all email clients.
56
- // /// @type Number
57
- // $button-rounded: $global-rounded !default;
58
-
59
5
  table.button {
60
6
  // width: auto;
61
7
  // margin: $button-margin;
@@ -157,7 +103,7 @@ table.button.inverse {
157
103
  td {
158
104
  background: transparent;
159
105
  color: $white;
160
- border: 1px solid $white;
106
+ border: $border-width solid $white;
161
107
  }
162
108
  a {
163
109
  color: $white;
@@ -6,18 +6,6 @@
6
6
  /// @group grid
7
7
  ////
8
8
 
9
- /// Default number of columns for an email.
10
- /// @type Number
11
- // $grid-column-count: 12 !default;
12
-
13
- /// Default padding for the bottom of a column.
14
- /// @type Number
15
- // $column-padding-bottom: $global-padding !default;
16
-
17
- /// Default border radius for the container. Use a px value
18
- /// @type Number
19
- // $container-radius: 0 !default;
20
-
21
9
  // For viewing email in browser
22
10
  @media only screen {
23
11
  html {
@@ -1,158 +1,6 @@
1
- // // Foundation for Emails by ZURB
2
- // // zurb.com/ink/
3
- // // Licensed under MIT Open Source
4
-
5
- // ////
6
- // /// @group typography
7
- // ////
8
-
9
- /// Global font color.
10
- /// @type Color
11
- $global-font-color: #313A3E;
12
-
13
- // /// Global font family.
14
- // /// @type Font
15
- // $body-font-family: Helvetica, Arial, sans-serif !default;
16
-
17
- // /// Global font weight.
18
- // /// @type Keyword
19
- // $global-font-weight: normal !default;
20
-
21
- // /// Header color
22
- // /// @type Color
23
- // $header-color: inherit !default;
24
-
25
- /// Global line height.
26
- /// @type Number
27
- $global-line-height: 1.4;
28
-
29
- /// Font size of body text.
30
- /// @type Number
31
- $global-font-size: 14px;
32
-
33
- /// Line height of body text.
34
- /// @type Number
35
- $body-line-height: 1.5;
36
-
37
- // /// Font family of headings.
38
- // /// @type List
39
- // $header-font-family: $body-font-family !default;
40
-
41
- // /// Font family of headings.
42
- // /// @type List
43
- $header-font-weight: bold;
44
-
45
- /// Font size of `<h1>` elements.
46
- /// @type Number
47
- $h1-font-size: 30px;
48
-
49
- /// Font size of `<h2>` elements.
50
- /// @type Number
51
- $h2-font-size: 27px;
52
-
53
- /// Font size of `<h3>` elements.
54
- /// @type Number
55
- $h3-font-size: 24px;
56
-
57
- /// Font size of `<h4>` elements.
58
- /// @type Number
59
- $h4-font-size: 20px;
60
-
61
- /// Font size of `<h5>` elements.
62
- /// @type Number
63
- $h5-font-size: 17px;
64
-
65
- /// Font size of `<h6>` elements.
66
- /// @type Number
67
- $h6-font-size: 14px;
68
-
69
- /// Margin bottom of `<h1>` through `<h6>` elements.
70
- /// @type Number
71
- $header-margin-bottom: 0;
72
-
73
- /// Margin bottom of paragraphs.
74
- /// @type Number
75
- $paragraph-margin-bottom: 0;
76
-
77
- // /// Default font size for `<small>`.
78
- // /// @type Number
79
- $small-font-size: 12px;
80
-
81
- // /// Color of `<small>` elements when placed inside headers.
82
- // /// @type Color
83
- // $small-font-color: $medium-gray !default;
84
-
85
- // /// Font size of lead paragraphs.
86
- // /// @type Number
87
- // $lead-font-size: $global-font-size * 1.25 !default;
88
-
89
- // /// Line height of lead paragraphs.
90
- // /// @type Number
91
- // $lead-line-height: 160% !default;
92
-
93
- // /// Padding inside paragraphs.
94
- // /// @type Number
95
- // $text-padding: 10px !default;
96
-
97
- // /// Default line height for subheaders.
98
- // /// @type Number
99
- // $subheader-lineheight: 1.4 !default;
100
-
101
- // /// Default font color for subheaders.
102
- // /// @type Color
103
- // $subheader-color: $dark-gray !default;
104
-
105
- // /// Default font weight for subheaders.
106
- // /// @type String
107
- // $subheader-font-weight: $global-font-weight !default;
108
-
109
- // /// Default top margin for subhheaders.
110
- // /// @type Number
111
- // $subheader-margin-top: 4px !default;
112
-
113
- // /// Default bottom margin for subheaders.
114
- // /// @type Number
115
- // $subheader-margin-bottom: 8px !default;
116
-
117
- /// Maximum width of a divider.
118
- /// @type Number
119
- $hr-width: 100% !default;
120
-
121
- /// Default border for a divider.
122
- /// @type List
123
- $hr-border: 1px solid $medium-gray;
124
-
125
- /// Default margin for a divider.
126
- /// @type Number | List
127
- $hr-margin: $global-gutter auto;
128
-
129
- // /// Text decoration for anchors.
130
- // /// @type Keyword
131
- // $anchor-text-decoration: none !default;
132
-
133
- // /// Text color of anchors.
134
- // /// @type Color
135
- $anchor-color: $primary-color;
136
-
137
- // /// Text color of anchors to visited links.
138
- // /// @type Color
139
- $anchor-color-visited: $anchor-color;
140
-
141
- // /// Text color of anchors on hover.
142
- // /// @type Color
143
- $anchor-color-hover: lighten($primary-color, 10%);
144
-
145
- // /// Text color of active anchors.
146
- // /// @type Color
147
- // $anchor-color-active: $anchor-color-hover !default;
148
-
149
- // /// Default font size for statistic numbers.
150
- // /// @type Number
151
- // $stat-font-size: 40px !default;
152
-
153
- // /// Removing the iOS telephone and address styling
154
- // /// @type Boolean
155
- // $remove-ios-blue: true !default;
1
+ // Foundation for Emails by ZURB
2
+ // zurb.com/ink/
3
+ // Licensed under MIT Open Source
156
4
 
157
5
  body,
158
6
  table.body,
@@ -354,6 +202,7 @@ span.preheader {
354
202
  }
355
203
 
356
204
  ul, ol{
205
+ margin-top: 0;
357
206
  margin-bottom: $paragraph-margin-bottom;
358
207
  }
359
208
 
@@ -1,2 +1,2 @@
1
- .border { border: solid 1px $medium-gray; }
2
- .border-top { border-top: solid 1px $medium-gray; }
1
+ .border { border: $border-width solid $border-color; }
2
+ .border-top { border-top: $border-width solid $border-color; }
@@ -1,8 +1,8 @@
1
1
  // Styles specific for content section links
2
2
  .cs-edit, .cs-rm-group, .cs-add-group {
3
- padding: 4px 6px !important;
3
+ padding: 0.5rem 0.8rem !important;
4
4
  font-weight: $bold-font-weight;
5
- font-size: 12px !important;
5
+ font-size: 14px !important;
6
6
  line-height: 1;
7
7
  }
8
8
 
@@ -19,7 +19,7 @@
19
19
  th.column {
20
20
  padding-top: 12px;
21
21
  padding-bottom: 12px;
22
- border-top: 1px solid $medium-gray;
22
+ border-top: $border-width solid $border-color;
23
23
  }
24
24
  }
25
25
 
@@ -3,4 +3,4 @@
3
3
  .text-warning { color: $warning-color; }
4
4
  .text-alert { color: $alert-color; }
5
5
  .text-white { color: $white; }
6
- .text-muted { color: #8c8c8c; }
6
+ .text-muted { color: $secondary-color; }
@@ -16,25 +16,25 @@
16
16
  // 1. Global
17
17
  // ---------
18
18
 
19
- $primary-color: #25aceb;
20
- $secondary-color: #70787C;
21
- $success-color: #59bf22;
22
- $warning-color: #ffaa00;
23
- $alert-color: #ff6d33;
24
- $light-gray: #F3F6F8;
25
- $medium-gray: #C9CED1;
26
- $dark-gray: #313A3E;
27
- $black: #000000;
28
- $white: #ffffff;
29
- $pre-color: #ff6908;
19
+ $primary-color: $primary;
20
+ $secondary-color: $gray-600;
21
+ $success-color: $success;
22
+ $warning-color: $warning;
23
+ $alert-color: $danger;
24
+ $light-gray: $gray-100;
25
+ $medium-gray: $gray-300;
26
+ $dark-gray: $gray-800;
27
+ $black: $black;
28
+ $white: $white;
29
+ $pre-color: $gray-800;
30
30
  $global-width: 580px;
31
31
  $global-width-small: 100%;
32
32
  $global-gutter: 24px;
33
- $body-background: $light-gray;
33
+ $body-background: $body-bg;
34
34
  $container-background: $white;
35
35
  $global-padding: 12px;
36
36
  $global-margin: 12px;
37
- $global-radius: 3px;
37
+ $global-radius: $border-radius;
38
38
  $global-rounded: 500px;
39
39
  $global-breakpoint: $global-width + $global-gutter;
40
40
 
@@ -57,19 +57,19 @@ $block-grid-gutter: $global-gutter;
57
57
  $global-font-color: $dark-gray;
58
58
  $body-font-family: Helvetica, Arial, sans-serif;
59
59
  $global-font-weight: normal;
60
- $bold-font-weight: 500;
60
+ $bold-font-weight: $font-weight-bold;
61
61
  $header-color: inherit;
62
- $global-line-height: 1.5;
63
- $global-font-size: 14px;
62
+ $global-line-height: $line-height-base;
63
+ $global-font-size: 16px;
64
64
  $body-line-height: $global-line-height;
65
65
  $header-font-family: Helvetica, Arial, sans-serif;
66
66
  $header-font-weight: $bold-font-weight;
67
- $h1-font-size: 30px;
68
- $h2-font-size: 27px;
69
- $h3-font-size: 24px;
70
- $h4-font-size: 20px;
71
- $h5-font-size: 17px;
72
- $h6-font-size: 14px;
67
+ $h1-font-size: 40px;
68
+ $h2-font-size: 32px;
69
+ $h3-font-size: 28px;
70
+ $h4-font-size: 24px;
71
+ $h5-font-size: 20px;
72
+ $h6-font-size: 16px;
73
73
  $header-margin-bottom: 12px;
74
74
  $paragraph-margin-bottom: 12px;
75
75
  $small-font-size: 80%;
@@ -83,7 +83,7 @@ $subheader-font-weight: $global-font-weight;
83
83
  $subheader-margin-top: 4px;
84
84
  $subheader-margin-bottom: 8px;
85
85
  $hr-width: $global-width;
86
- $hr-border: 1px solid $medium-gray;
86
+ $hr-border: $border-width solid $border-color;
87
87
  $hr-margin: 24px auto;
88
88
  $anchor-text-decoration: underline;
89
89
  $anchor-color: $primary-color;
@@ -102,10 +102,10 @@ $button-padding: (
102
102
  large: 10px 12px 10px 12px,
103
103
  );
104
104
  $button-font-size: (
105
- tiny: 12px,
105
+ tiny: 14px,
106
106
  small: 14px,
107
- default: 15px,
108
- large: 17px,
107
+ default: 16px,
108
+ large: 20px,
109
109
  );
110
110
  $button-color: $white;
111
111
  $button-color-alt: $medium-gray;
@@ -123,11 +123,11 @@ $callout-background: #e5f5fd;
123
123
  $callout-background-fade: 88%;
124
124
  $callout-padding: 12px;
125
125
  $callout-margin-bottom: $global-margin;
126
- $callout-border: 1px solid $primary-color;
127
- $callout-border-secondary: 1px solid $secondary-color;
128
- $callout-border-success: 1px solid $success-color;
129
- $callout-border-warning: 1px solid $warning-color;
130
- $callout-border-alert: 1px solid $alert-color;
126
+ $callout-border: $border-width solid $primary-color;
127
+ $callout-border-secondary: $border-width solid $secondary-color;
128
+ $callout-border-success: $border-width solid $success-color;
129
+ $callout-border-warning: $border-width solid $warning-color;
130
+ $callout-border-alert: $border-width solid $alert-color;
131
131
 
132
132
  // 7. Menu
133
133
  // -------
@@ -1,9 +1,185 @@
1
+ $carousel-fixed-height: (3 / 4); // 4:3 aspect ratio
2
+ $carousel-thumbnail-size: ($spacer * 2.5); // 80px
3
+
4
+ //
5
+ // Left/right controls for nav
6
+ //
7
+ .carousel-control-prev-icon,
8
+ .carousel-control-next-icon {
9
+ position: absolute;
10
+ top: 50%;
11
+ right: 0;
12
+ left: 0;
13
+ width: 100%;
14
+ background: none;
15
+ background-image: none;
16
+ &::before, &::after {
17
+ position: absolute;
18
+ top: -($carousel-control-icon-width * .5);
19
+ left: ($spacer * .25);
20
+ display: block;
21
+ margin: auto;
22
+ width: $carousel-control-icon-width;
23
+ height: $carousel-control-icon-width;
24
+ content: '';
25
+ }
26
+ &::before {
27
+ background-color: $white;
28
+ border-radius: 50%;
29
+ z-index: 1;
30
+ box-shadow: $box-shadow-sm;
31
+ }
32
+ &::after {
33
+ font-family: "FontAwesome";
34
+ font-size: $font-size-lg;
35
+ line-height: $carousel-control-icon-width;
36
+ color: $body-color;
37
+ text-align: center;
38
+ z-index: 10;
39
+ }
40
+ }
41
+ .carousel-control-prev-icon {
42
+ &:after {
43
+ padding-right: 2px;
44
+ content: $carousel-control-prev-icon-bg;
45
+ }
46
+ }
47
+ .carousel-control-next-icon {
48
+ &:after {
49
+ padding-left: 2px;
50
+ content: $carousel-control-next-icon-bg;
51
+ }
52
+ }
53
+
54
+
1
55
  // Optional indicator pips
2
56
  //
3
- // Add an unordered list with the following class and add a list item for each
57
+ // Add an ordered list with the following class and add a list item for each
4
58
  // slide your carousel holds.
5
-
6
59
  .carousel-indicators {
7
- bottom: 0;
8
60
  li { border-radius: 50%; }
9
61
  }
62
+
63
+
64
+ // Carousels that have a fixed aspect ratio height
65
+ .carousel-fixed-height {
66
+ width: 100%;
67
+ .carousel-inner {
68
+ &::before {
69
+ display: block;
70
+ content: "";
71
+ width: 100%;
72
+ padding-top: $carousel-fixed-height * 100%;
73
+ }
74
+ }
75
+ .carousel-item {
76
+ position: absolute;
77
+ top: 0;
78
+ right: 0;
79
+ bottom: 0;
80
+ left: 0;
81
+ display: flex;
82
+ justify-content: center;
83
+ align-items: center;
84
+ float: none; // overrides BS carousel defaults
85
+ margin-right: 0; // overrides BS carousel defaults
86
+ width: 100%;
87
+ height: 100%;
88
+ text-align: center;
89
+ overflow: hidden;
90
+ @include transition($transition-fade);
91
+ &.active.carousel-item-left,
92
+ &.active.carousel-item-right {
93
+ @include transition($transition-fade); // overrides BS carousel defaults
94
+ }
95
+ img { // keeps image scaled proportionally
96
+ width: auto !important;
97
+ min-width: 0px !important;
98
+ max-width: 100%;
99
+ height: 100% !important;
100
+ max-height: 100%;
101
+ margin: auto;
102
+ }
103
+ }
104
+ }
105
+
106
+
107
+ // Carousels that use image thumbnails for indicators
108
+ .carousel-has-thumbnails {
109
+ @include media-breakpoint-up(lg) { padding-left: ($spacer * 3.5); }
110
+ .carousel-inner {
111
+ border: $border-width solid $border-color;
112
+ border-radius: $border-radius;
113
+ }
114
+ .carousel-indicators {
115
+ margin: 0;
116
+ @include media-breakpoint-down(lg) {
117
+ justify-content: flex-start;
118
+ position: relative;
119
+ right: auto;
120
+ bottom: auto;
121
+ left: auto;
122
+ margin-top: ($spacer * .5);
123
+ width: 100%;
124
+ height: $carousel-thumbnail-size;
125
+ overflow-x: auto;
126
+ overflow-y: hidden;
127
+ @include clearfix();
128
+ }
129
+ @include media-breakpoint-up(lg) {
130
+ display: block;
131
+ position: absolute;
132
+ top: 0;
133
+ bottom: 0;
134
+ right: auto;
135
+ left: 0;
136
+ width: auto;
137
+ height: 100%;
138
+ margin-top: 0;
139
+ overflow-y: auto;
140
+ }
141
+ li {
142
+ position: relative;
143
+ width: $carousel-thumbnail-size;
144
+ height: $carousel-thumbnail-size;
145
+ text-indent: 0;
146
+ text-align: center;
147
+ background-color: transparent;
148
+ border-top: none;
149
+ border-bottom: none;
150
+ box-sizing: border-box;
151
+ border-radius: $border-radius;
152
+ overflow: hidden;
153
+ opacity: .4;
154
+ @include media-breakpoint-down(lg) {
155
+ flex-shrink: 0;
156
+ flex-basis: $carousel-thumbnail-size;
157
+ margin: 0 ($spacer * .25) 0 0;
158
+ }
159
+ @include media-breakpoint-up(lg) { margin: 0 0 ($spacer * .25); }
160
+ &::before {
161
+ display: block;
162
+ content: "";
163
+ width: 100%;
164
+ padding-top: $carousel-fixed-height * 100%;
165
+ }
166
+ &.active {
167
+ border: $border-width solid $border-color;
168
+ opacity: 1;
169
+ }
170
+ img { // keeps image scaled proportionally
171
+ position: absolute;
172
+ top: 0;
173
+ right: 0;
174
+ bottom: 0;
175
+ left: 0;
176
+ width: auto !important;
177
+ min-width: 0px !important;
178
+ max-width: 100%;
179
+ height: 100% !important;
180
+ max-height: 100%;
181
+ margin: auto;
182
+ }
183
+ }
184
+ }
185
+ }
@@ -6,6 +6,11 @@ module NfgUi
6
6
  # Bootstrap Carousel Component
7
7
  # https://getbootstrap.com/docs/4.1/components/carousel/
8
8
  class Carousel < NfgUi::Bootstrap::Components::Base
9
+ # Turn on or off auto scrolling carousel
10
+ def auto
11
+ options.fetch(:auto, true)
12
+ end
13
+
9
14
  def component_family
10
15
  :carousel
11
16
  end
@@ -15,7 +20,10 @@ module NfgUi
15
20
  end
16
21
 
17
22
  def data
18
- super.merge!(ride: 'carousel')
23
+ # false on auto means that the carousel should not automatically rotate.
24
+ data_val = auto == false ? { interval: 'false' } : { ride: 'carousel' }
25
+
26
+ super.merge!(**data_val)
19
27
  end
20
28
 
21
29
  def indicators
@@ -16,10 +16,23 @@ module NfgUi
16
16
  :carousel
17
17
  end
18
18
 
19
+ def data
20
+ return super unless interval
21
+ super.merge!(interval: interval)
22
+ end
23
+
19
24
  def image
20
25
  options.fetch(:image, nil)
21
26
  end
22
27
 
28
+ # manually pass in an interval numerical value
29
+ # which translates to miliseconds between carousel item
30
+ # slide transitions.
31
+ # ex: interval: 5000
32
+ def interval
33
+ options[:interval] || nil
34
+ end
35
+
23
36
  def label
24
37
  options.fetch(:label, nil)
25
38
  end
@@ -41,7 +54,8 @@ module NfgUi
41
54
  def non_html_attribute_options
42
55
  super.push(:image,
43
56
  :caption,
44
- :label)
57
+ :label,
58
+ :interval)
45
59
  end
46
60
  end
47
61
  end
@@ -13,26 +13,23 @@ module NfgUi
13
13
 
14
14
  def render
15
15
  content_tag(:div, html_options) do
16
- content_tag(:div, class: carousel_inner_css_classes) do
17
- concat((block_given? ? yield : body))
18
- if controls
19
- concat(NfgUi::Components::Elements::CarouselControl.new({ control: :next, carousel: "##{id}" }, view_context).render)
20
- concat(NfgUi::Components::Elements::CarouselControl.new({ control: :prev, carousel: "##{id}" }, view_context).render)
21
- end
22
- if indicators > 0
23
- concat(NfgUi::Components::Elements::CarouselIndicators.new({ count: indicators, carousel: "##{id}" }, view_context).render)
16
+ concat(
17
+ content_tag(:div, class: 'carousel-inner') do
18
+ concat((block_given? ? yield : body))
24
19
  end
20
+ )
21
+ if controls
22
+ concat(NfgUi::Components::Elements::CarouselControl.new({ control: :next, carousel: "##{id}" }, view_context).render)
23
+ concat(NfgUi::Components::Elements::CarouselControl.new({ control: :prev, carousel: "##{id}" }, view_context).render)
24
+ end
25
+ if indicators > 0
26
+ concat(NfgUi::Components::Elements::CarouselIndicators.new({ count: indicators, carousel: "##{id}" }, view_context).render)
25
27
  end
26
28
  end
27
29
  end
28
30
 
29
- private
30
-
31
- def carousel_inner_css_classes
32
- [
33
- 'carousel-inner',
34
- ('pb-3' if indicators > 0)
35
- ].join(' ').squish
31
+ def non_html_attribute_options
32
+ super.push(:auto)
36
33
  end
37
34
  end
38
35
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module NfgUi
4
- VERSION = '0.12.14'
4
+ VERSION = '0.13.0'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nfg_ui
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.12.14
4
+ version: 0.13.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jonathan Roehm
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2021-09-23 00:00:00.000000000 Z
12
+ date: 2021-10-20 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bootstrap
@@ -149,14 +149,14 @@ dependencies:
149
149
  requirements:
150
150
  - - ">="
151
151
  - !ruby/object:Gem::Version
152
- version: 1.11.4
152
+ version: 1.12.5
153
153
  type: :runtime
154
154
  prerelease: false
155
155
  version_requirements: !ruby/object:Gem::Requirement
156
156
  requirements:
157
157
  - - ">="
158
158
  - !ruby/object:Gem::Version
159
- version: 1.11.4
159
+ version: 1.12.5
160
160
  - !ruby/object:Gem::Dependency
161
161
  name: browser
162
162
  requirement: !ruby/object:Gem::Requirement
@@ -446,7 +446,6 @@ files:
446
446
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_mailings.scss
447
447
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_page_header.scss
448
448
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_readmore.scss
449
- - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_redacted_text.scss
450
449
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_share_dropdown.scss
451
450
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_sortable.scss
452
451
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_status_indicator.scss
@@ -1,32 +0,0 @@
1
- // Empty state blocker with blokk font-family replacement
2
-
3
- // Import redacted-style "blokk" font for empty states
4
- // Needs to be outside of the namespace for valid CSS output (particularly important for Internet Explorer)
5
- @font-face {
6
- font-family: 'BLOKK';
7
- src: asset-url('admin/blokk/BLOKKNeue-Regular.eot');
8
- src: asset-url('admin/blokk/BLOKKNeue-Regular.eot?#iefix') format('embedded-opentype'),
9
- asset-url('admin/blokk/BLOKKNeue-Regular.woff2') format('woff2'),
10
- asset-url('admin/blokk/BLOKKNeue-Regular.woff') format('woff'),
11
- asset-url('admin/blokk/BLOKKNeue-Regular.otf') format('opentype'),
12
- asset-url('admin/blokk/BLOKKNeue-Regular.ttf') format('truetype'),
13
- asset-url('admin/blokk/BLOKKNeue-Regular.svg#BLOKKRegular') format('svg');
14
- font-weight: normal;
15
- font-style: normal;
16
- }
17
- @media screen and (-webkit-min-device-pixel-ratio:0) {
18
- @font-face {
19
- font-family: 'BLOKK';
20
- src: asset-url('admin/blokk/BLOKKNeue-Regular.svg') format('svg');
21
- }
22
- }
23
-
24
- $redacted-font-family: "BLOKK";
25
-
26
- // Overlay styles
27
- .redacted-text {
28
- font-family: $redacted-font-family !important;
29
- letter-spacing: -3px;
30
- word-spacing: -3px;
31
- .card-img-overlay { background: none; }
32
- }