nfg_ui 0.14.3.2 → 0.14.5

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3d3aeb2863ebb5e5100185b2f2286981225b5842aec6fc1976799a4a8273939f
4
- data.tar.gz: af1ebabe3ebbeda89cc1e9548f97b3f0c24a71929cf4d862a7d8a049a2e1ac70
3
+ metadata.gz: d4bb269c1712ed02fcc8063dac8eebb57e54bb3f146b4004734600a0a5d66570
4
+ data.tar.gz: 9415238bb521eb17244238f0e26ef121bc4bd08032b446402bdf5eeddfdedb34
5
5
  SHA512:
6
- metadata.gz: 8d8c718e624b5a75a86d22a2f678d8a963854f4939257177c21926466b025cad0af6b3c1b1125db2169f6133619175f8ee9b2282aab050d31d96457b1339eb09
7
- data.tar.gz: 269f44a67a5a471fe7ef0593bb5abff1fb266001c38a58df5896c446cbdaa684cadece9d5ce878c986df3dbd414eddbbab2e5edcd3f527654d138ae97262ce57
6
+ metadata.gz: 784c9cdd392204b6383b729af9f206a9bbe1bf27f05b9f4cdce1f2adac279085edd2e2bf6103b096e3c01c6f8d9f1fc3c49a973252b070f9d5bd97439744ba30
7
+ data.tar.gz: 861b6d63ce011a46e0d37f8ad10bdc5666eb4f3ee3c8b73f3dde74b184b324422b2b8fb3ea158dba61e6eb254c3fc204e97c465dec35060167ab2222fa7f6cef
@@ -1064,7 +1064,7 @@ $breadcrumb-margin-bottom: $spacer;
1064
1064
 
1065
1065
  $breadcrumb-bg: transparent;
1066
1066
  $breadcrumb-divider-color: $border-color;
1067
- $breadcrumb-active-color: $text-muted;
1067
+ $breadcrumb-active-color: $body-color;
1068
1068
  // $breadcrumb-divider: quote("/") !default;
1069
1069
 
1070
1070
  // $breadcrumb-border-radius: $border-radius !default;
@@ -0,0 +1,21 @@
1
+ .breadcrumb-item {
2
+ color: $text-muted;
3
+ a {
4
+ color: $text-muted;
5
+ @include hover-focus() { text-decoration: underline; }
6
+ }
7
+ }
8
+
9
+
10
+ // Used on FP onboarders where there are two levels of navigation for steps
11
+ .breadcrumb {
12
+ &.nav-secondary {
13
+ .breadcrumb-item {
14
+ a { color: $primary; }
15
+ &.active { color: $body-color; }
16
+ + .breadcrumb-item {
17
+ &::before { content: '>'; }
18
+ }
19
+ }
20
+ }
21
+ }
@@ -16,8 +16,8 @@ $page-header-height-public: (($spacer * 6.75) + 1); // 21.7rem (adds 1px for wid
16
16
  min-height: $page-header-height;
17
17
  }
18
18
 
19
- // this renders as body.admin .page-header specifying when the view there is an admin logged in (includes top admin black bar)
20
- body.admin & {
19
+ // this renders as body.admin .page-header specifying when the view there is an admin logged in or on a donorcreatedproject (includes top admin black bar)
20
+ body.admin &, body.donorcreatedproject & {
21
21
  @include media-breakpoint-up(lg) { min-height: $page-header-height-admin; }
22
22
  }
23
23
  }
@@ -27,8 +27,10 @@ $page-header-height-public: (($spacer * 6.75) + 1); // 21.7rem (adds 1px for wid
27
27
  @include media-breakpoint-up(lg) {
28
28
  + .page-content { padding-top: $page-header-height; }
29
29
 
30
- // this renders as body.admin .page-header + .page-content specifying when the view there is an admin logged in (includes top admin black bar)
31
- body.admin & + .page-content { padding-top: $page-header-height-admin; }
30
+ // this renders as body.admin .page-header + .page-content specifying when the view there is an admin logged in or on a donorcreatedproject (includes top admin black bar)
31
+ body.admin &, body.donorcreatedproject & {
32
+ + .page-content { padding-top: $page-header-height-admin; }
33
+ }
32
34
 
33
35
  // this renders as body.nfg_ui_onboarder .page-header + .page-content specifying when the view is in a public onboarding status i.e. fundraiser onboarder in Fundraising Pages
34
36
  body.nfg_ui_onboarder & + .page-content { padding-top: $page-header-height-public; }
@@ -12,7 +12,27 @@ module NfgUi
12
12
  remote
13
13
  submit].freeze
14
14
 
15
+ # Link trait has some customizations because it outputs
16
+ # a button without button styles (useful for spacing)
17
+ # which makes it feel like the following SHOULD work:
18
+ # = ui.nfg :button, :link, :danger, icon: 'trash-o'
19
+ # Where it generates a link themed button that also has
20
+ # a color style.
15
21
  def link_trait
22
+ colors = NfgUi::Components::Traits::Theme::COLOR_TRAITS
23
+
24
+ # Check if we've got any color themes passed through in addition to :link
25
+ if traits.collect { |t| t.in?(colors) }.any? && traits.include?(:link)
26
+ # Grab and remove the theme color from traits so it
27
+ # doesn't override the :link theme
28
+ # and so that we can apply it to the css.
29
+ theme_color = traits.delete((traits & colors).first)
30
+
31
+ # Add the text styling to the button's CSS
32
+ options[:class] += " text-#{theme_color}"
33
+ end
34
+
35
+ # And finally, set the official theme as a link
16
36
  options[:theme] = :link
17
37
  end
18
38
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module NfgUi
4
- VERSION = '0.14.3.2'
4
+ VERSION = '0.14.5'
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.14.3.2
4
+ version: 0.14.5
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: 2022-05-27 00:00:00.000000000 Z
12
+ date: 2022-06-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bootstrap
@@ -508,6 +508,7 @@ files:
508
508
  - app/assets/stylesheets/nfg_ui/network_for_good/core/legacy_browser_support/plugins/_sticky_div.scss
509
509
  - app/assets/stylesheets/nfg_ui/network_for_good/core/nfg_theme/_alert.scss
510
510
  - app/assets/stylesheets/nfg_ui/network_for_good/core/nfg_theme/_badge.scss
511
+ - app/assets/stylesheets/nfg_ui/network_for_good/core/nfg_theme/_breadcrumb.scss
511
512
  - app/assets/stylesheets/nfg_ui/network_for_good/core/nfg_theme/_button-group.scss
512
513
  - app/assets/stylesheets/nfg_ui/network_for_good/core/nfg_theme/_buttons.scss
513
514
  - app/assets/stylesheets/nfg_ui/network_for_good/core/nfg_theme/_card.scss