nfg_ui 0.10.5 → 0.10.6

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 (33) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/fonts/product_icons/IcoMoon-product-icons.eot +0 -0
  3. data/app/assets/fonts/product_icons/IcoMoon-product-icons.svg +35 -0
  4. data/app/assets/fonts/product_icons/IcoMoon-product-icons.ttf +0 -0
  5. data/app/assets/fonts/product_icons/IcoMoon-product-icons.woff +0 -0
  6. data/app/assets/fonts/product_icons/product-icons-icomoon.zip +0 -0
  7. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/_variables.scss +3 -3
  8. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/application.scss +3 -1
  9. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_alert.scss +17 -1
  10. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_button-group.scss +21 -0
  11. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_custom.scss +2 -1
  12. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_dropdown.scss +14 -1
  13. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_forms.scss +9 -0
  14. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_grid.scss +52 -0
  15. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_modal.scss +6 -0
  16. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_nav.scss +82 -0
  17. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_navbar.scss +94 -1
  18. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_free_trial.scss +52 -0
  19. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_icomoon.scss +33 -0
  20. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_interaction.scss +1 -1
  21. data/app/assets/stylesheets/nfg_ui/network_for_good/public/legacy_browser_support/nfg_theme/_nav.scss +7 -0
  22. data/app/assets/stylesheets/nfg_ui/network_for_good/public/plugins/_datetimepicker.scss +3 -0
  23. data/app/assets/stylesheets/nfg_ui/network_for_good/public/plugins/_select2.scss +2 -3
  24. data/app/assets/stylesheets/nfg_ui/network_for_good/public/plugins/_turbolinks.scss +6 -0
  25. data/app/assets/stylesheets/nfg_ui/network_for_good/public/plugins/_twitter_typeahead.scss +44 -0
  26. data/lib/nfg_ui/components/elements/nav_link.rb +7 -1
  27. data/lib/nfg_ui/components/patterns/page_header.rb +15 -2
  28. data/lib/nfg_ui/components/traits/icon.rb +13 -1
  29. data/lib/nfg_ui/components/utilities/resource_themeable.rb +6 -4
  30. data/lib/nfg_ui/version.rb +1 -1
  31. metadata +14 -5
  32. data/app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_product_icons.scss +0 -45
  33. data/app/models/nfg_ui/application_record.rb +0 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7e6fb7eaae723d2726e41b01347417d802c085b5e47ed58446b7051f3d0cf55b
4
- data.tar.gz: d65dcb67b6a57ac37503717c69a8cd5963dec852a95beb46ee17933f2b14c5d8
3
+ metadata.gz: 01a76c6faab975ddfc09854c5d444ed19e4b5d7be26fcda75aa2cdc51ea202b5
4
+ data.tar.gz: 3ac42aa0bc08ea79061855b822b0e0c0d59f6e1c0f7e977284cb1dab150f08b6
5
5
  SHA512:
6
- metadata.gz: bb9925852e4f5daf3ef6d42bac3ba4e4b1fc2580a139ff12458b822439832a8ed19a8fb69509d06fd6667513fb3569b2248bbb599479754d0f8cf0f5cbe8af2d
7
- data.tar.gz: ef6aecf55597415d8dd1c4e3e9137dbd782ddef98c1511867e5fd7777d6e3bf8fc2c741d3877d4f6a61ea3e97837da853de6bf994d96bdddcf6c539f8bf7fda6
6
+ metadata.gz: bbf3b10543ba1920e656cdc3ea6a88d3ba880f51977743c76f196b2302d24bc4136a5d7c8096cd72f0a6f686e58748c3f1db0e8213b9e5132048a4a7899867e5
7
+ data.tar.gz: f689e701c3eb39745f027ae0eb2cd1ffa4cc8762df626f4f2049c15b7f7978e4f218617d13c75b045472921ee4346203d1616bd8f1b2520458c5fc01a609975e
@@ -0,0 +1,35 @@
1
+ <?xml version="1.0" standalone="no"?>
2
+ <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
3
+ <svg xmlns="http://www.w3.org/2000/svg">
4
+ <metadata>
5
+ <json>
6
+ <![CDATA[
7
+ {
8
+ "fontFamily": "IcoMoon---Ultimate",
9
+ "fontURL": "http://icomoon.io/#icons",
10
+ "designer": "Keyamoon",
11
+ "designerURL": "http://keyamoon.com",
12
+ "license": "Custom",
13
+ "licenseURL": "http://icomoon.io/#icons#license",
14
+ "version": "Version 1.0",
15
+ "majorVersion": 0,
16
+ "fontId": "IcoMoon---Ultimate",
17
+ "psName": "IcoMoon---Ultimate",
18
+ "subFamily": "Regular",
19
+ "fullName": "IcoMoon---Ultimate",
20
+ "description": "Font generated by IcoMoon."
21
+ }
22
+ ]]>
23
+ </json>
24
+ </metadata>
25
+ <defs>
26
+ <font id="IcoMoon---Ultimate" horiz-adv-x="1024">
27
+ <font-face units-per-em="1024" ascent="960" descent="-64" />
28
+ <missing-glyph horiz-adv-x="1024" />
29
+ <glyph unicode="&#x20;" d="" />
30
+ <glyph unicode="&#xe199;" glyph-name="product-fundraising-coach" data-tags="user, profile, avatar, person, talk, member, employee, job, official" d="M320 768c0 106.039 85.961 192 192 192s192-85.961 192-192c0-106.039-85.961-192-192-192s-192 85.961-192 192zM768.078 512h-35.424l-199.104-404.244 74.45 372.244-96 96-96-96 74.45-372.244-199.102 404.244h-35.424c-127.924 0-127.924-85.986-127.924-192v-320h768v320c0 106.014 0 192-127.922 192z" />
31
+ <glyph unicode="&#xe466;" glyph-name="sso-disbursements" data-tags="table, wysiwyg" d="M0 896v-896h1024v896h-1024zM384 320v192h256v-192h-256zM640 256v-192h-256v192h256zM640 768v-192h-256v192h256zM320 768v-192h-256v192h256zM64 512h256v-192h-256v192zM704 512h256v-192h-256v192zM704 576v192h256v-192h-256zM64 256h256v-192h-256v192zM704 64v192h256v-192h-256z" />
32
+ <glyph unicode="&#xe683;" glyph-name="sso-donation-pages" data-tags="cash, money, payment" d="M947.2-51.2h-921.6c-14.138 0-25.6 11.461-25.6 25.6v512c0 14.138 11.462 25.6 25.6 25.6h921.6c14.139 0 25.6-11.462 25.6-25.6v-512c0-14.139-11.461-25.6-25.6-25.6zM51.2 0h870.4v460.8h-870.4v-460.8zM588.8 256h-179.2v51.2h179.2c14.139 0 25.6 11.461 25.6 25.6s-11.461 25.6-25.6 25.6h-76.8v25.6c0 14.139-11.462 25.6-25.6 25.6s-25.6-11.461-25.6-25.6v-25.6h-76.8c-14.138 0-25.6-11.461-25.6-25.6v-102.4c0-14.139 11.462-25.6 25.6-25.6h179.2v-51.2h-179.2c-14.138 0-25.6-11.461-25.6-25.6s11.462-25.6 25.6-25.6h76.8v-25.6c0-14.139 11.462-25.6 25.6-25.6s25.6 11.461 25.6 25.6v25.6h76.8c14.139 0 25.6 11.461 25.6 25.6v102.4c0 14.139-11.461 25.6-25.6 25.6zM896 563.2h-819.2c-14.138 0-25.6 11.462-25.6 25.6s11.462 25.6 25.6 25.6h819.2c14.139 0 25.6-11.462 25.6-25.6s-11.461-25.6-25.6-25.6zM844.8 665.6h-716.8c-14.138 0-25.6 11.462-25.6 25.6s11.462 25.6 25.6 25.6h716.8c14.139 0 25.6-11.462 25.6-25.6s-11.461-25.6-25.6-25.6z" />
33
+ <glyph unicode="&#xe6ba;" glyph-name="sso-dms" data-tags="pie-chart, statistics" d="M435.2-51.2c-116.246 0-225.534 45.269-307.733 127.467s-127.467 191.488-127.467 307.733c0 116.246 45.269 225.534 127.467 307.733s191.486 127.467 307.733 127.467c14.138 0 25.6-11.462 25.6-25.6v-384h384c14.139 0 25.6-11.461 25.6-25.6 0-116.245-45.269-225.534-127.467-307.733s-191.488-127.467-307.733-127.467zM409.6 767.157c-199.842-13.226-358.4-180.026-358.4-383.157 0-211.739 172.262-384 384-384 203.131 0 369.931 158.558 383.157 358.4h-383.157c-14.138 0-25.6 11.461-25.6 25.6v383.157zM947.2 460.8h-409.6c-14.139 0-25.6 11.462-25.6 25.6v409.6c0 14.138 11.461 25.6 25.6 25.6 116.245 0 225.534-45.269 307.733-127.467s127.467-191.486 127.467-307.733c0-14.138-11.461-25.6-25.6-25.6zM563.2 512h357.557c-12.664 191.374-166.184 344.891-357.557 357.557v-357.557z" />
34
+ <glyph unicode="&#xe900;" glyph-name="sso-donatenow" data-tags="money" horiz-adv-x="1097" d="M438.857 292.571h219.429v54.857h-73.143v256h-65.143l-84.571-78.286 44-45.714c13.714 12 22.286 18.286 31.429 32.571h1.143v-164.571h-73.143v-54.857zM731.429 438.857c0-104-62.857-237.714-182.857-237.714s-182.857 133.714-182.857 237.714 62.857 237.714 182.857 237.714 182.857-133.714 182.857-237.714zM1024 292.571v292.571c-80.571 0-146.286 65.714-146.286 146.286h-658.286c0-80.571-65.714-146.286-146.286-146.286v-292.571c80.571 0 146.286-65.714 146.286-146.286h658.286c0 80.571 65.714 146.286 146.286 146.286zM1097.143 768v-658.286c0-20-16.571-36.571-36.571-36.571h-1024c-20 0-36.571 16.571-36.571 36.571v658.286c0 20 16.571 36.571 36.571 36.571h1024c20 0 36.571-16.571 36.571-36.571z" />
35
+ </font></defs></svg>
@@ -700,9 +700,9 @@ $nav-tabs-link-active-color: $body-color;
700
700
  $nav-tabs-link-active-bg: transparent;
701
701
  $nav-tabs-link-active-border-color: $primary;
702
702
 
703
- // $nav-pills-border-radius: $border-radius !default;
704
- // $nav-pills-link-active-color: $component-active-color !default;
705
- // $nav-pills-link-active-bg: $component-active-bg !default;
703
+ $nav-pills-border-radius: 0;
704
+ $nav-pills-link-active-color: $white;
705
+ $nav-pills-link-active-bg: darken(#006D9D, 10%);
706
706
 
707
707
  $nav-divider-color: $border-color;
708
708
  $nav-divider-margin-y: 0;
@@ -18,8 +18,10 @@
18
18
  @import 'nfg_ui/network_for_good/public/plugins/datepicker';
19
19
  @import 'nfg_ui/network_for_good/public/plugins/datetimepicker';
20
20
  @import 'nfg_ui/network_for_good/public/plugins/intercom'; // only in admin layouts
21
- @import 'nfg_ui/network_for_good/public/plugins/sticky_div';
22
21
  @import 'nfg_ui/network_for_good/public/plugins/select2';
22
+ @import 'nfg_ui/network_for_good/public/plugins/sticky_div';
23
+ @import 'nfg_ui/network_for_good/public/plugins/turbolinks';
24
+ @import 'nfg_ui/network_for_good/public/plugins/twitter_typeahead';
23
25
 
24
26
  // Legacy browser support
25
27
  @import 'nfg_ui/network_for_good/public/legacy_browser_support/application';
@@ -1,2 +1,18 @@
1
1
  // Custom type color
2
- .alert { color: $body-color; }
2
+ .alert {
3
+ color: $body-color;
4
+ a {
5
+ text-decoration: underline;
6
+ &:hover, &:active { text-decoration: none; }
7
+ }
8
+ }
9
+ .alert-success a { color: $success; }
10
+ .alert-info a { color: $info; }
11
+ .alert-warning a { color: $warning; }
12
+ .alert-danger, .alert-error {
13
+ a { color: $danger; }
14
+ }
15
+ .alert-gray, .alert-notice,
16
+ .alert-light, .alert-dark {
17
+ a { color: inherit; }
18
+ }
@@ -20,3 +20,24 @@
20
20
  > .btn:not(:first-child),
21
21
  > .btn-group:not(:first-child) > .btn { @include border-top-radius($btn-border-radius); }
22
22
  }
23
+
24
+ // Buttons on quick add modal in DMS
25
+ .btn-group-quick-add {
26
+ .col-4 {
27
+ &:nth-child(1n) { border-left: $border-width solid $border-color; }
28
+ @include media-breakpoint-down(sm) {
29
+ &:first-child { border-left: none; }
30
+ }
31
+ @include media-breakpoint-up(sm) {
32
+ &:nth-child(3n+1) { border-left: none; }
33
+ &:nth-child(1n+4) { border-top: $border-width solid $border-color; }
34
+ }
35
+ .btn-link {
36
+ padding-top: $spacer;
37
+ padding-bottom: $spacer;
38
+ width: 100%;
39
+ height: 100%;
40
+ @include hover-focus { background-color: $body-bg; }
41
+ }
42
+ }
43
+ }
@@ -8,13 +8,14 @@
8
8
  @import 'custom/custom_receipt_language';
9
9
  @import 'custom/device_preview';
10
10
  @import 'custom/email_preview';
11
+ @import 'custom/free_trial';
12
+ @import 'custom/icomoon';
11
13
  @import 'custom/illustration';
12
14
  @import 'custom/interaction';
13
15
  @import 'custom/mobile';
14
16
  @import 'custom/nav_step';
15
17
  @import 'custom/overlay_blocker';
16
18
  @import 'custom/page_header';
17
- @import 'custom/product_icons';
18
19
  @import 'custom/redactor';
19
20
  @import 'custom/share_dropdown';
20
21
  @import 'custom/social_share';
@@ -21,4 +21,17 @@
21
21
 
22
22
 
23
23
  // Sizing
24
- .dropdown-menu-md { min-width: ($spacer * 12); }
24
+ .dropdown-menu-md { min-width: ($spacer * 12); }
25
+
26
+
27
+ // Styles for wider "My Tools" dropdown in top nav
28
+ #my_tools_dropdown {
29
+ @include media-breakpoint-down(sm) { max-width: 100vw; }
30
+ .media {
31
+ div {
32
+ &:first-child { width: 60px; }
33
+ &:last-child { width: 38px; }
34
+ }
35
+ .media-body { width: 240px; }
36
+ }
37
+ }
@@ -1,3 +1,7 @@
1
+ .form-control {
2
+ &[readonly] { background-color: $input-bg; }
3
+ }
4
+
1
5
  // Required styles
2
6
  label {
3
7
  font-weight: $font-weight-bold;
@@ -10,6 +14,11 @@ label {
10
14
  padding-right: ($spacer * .25);
11
15
  }
12
16
  }
17
+ .required, abbr[title='required'] {
18
+ color: $danger;
19
+ cursor: default;
20
+ border-bottom: none;
21
+ }
13
22
  }
14
23
 
15
24
  textarea.form-control { min-height: ($spacer * 6); }
@@ -0,0 +1,52 @@
1
+ // Specific container styles for DMS
2
+ .container-wrap {
3
+ position: relative;
4
+ z-index: 0;
5
+ @include media-breakpoint-down(lg) {
6
+ padding-bottom: ($spacer * 2);
7
+ &.nav-slide {
8
+ .site-navbar { left: 200px; }
9
+ .container-main { margin-left: 200px; }
10
+ }
11
+ }
12
+ @include media-breakpoint-up(xl) {
13
+ padding-top: ($spacer * 2);
14
+ padding-left: 200px;
15
+ }
16
+ }
17
+
18
+ // Wraps main page content
19
+ .container-main {
20
+ margin-left: 0;
21
+ padding-right: ($grid-gutter-width / 2);
22
+ padding-left: ($grid-gutter-width / 2);
23
+ width: 100%;
24
+ @include transition(margin-left .2s ease-in-out);
25
+ @include media-breakpoint-up(xl) {
26
+ padding-right: $grid-gutter-width;
27
+ padding-left: $grid-gutter-width;
28
+ }
29
+
30
+ // Used in DMS to make the tiles the width of device on mobile size
31
+ > .container-fluid:not(.page-header) {
32
+ @include media-breakpoint-down(sm) {
33
+ margin-right: -($grid-gutter-width / 2);
34
+ margin-left: -($grid-gutter-width / 2);
35
+ width: auto;
36
+ }
37
+ }
38
+ }
39
+
40
+ // Used in banners at the top of the app (ex: engagement banner)
41
+ .container-flush {
42
+ margin-left: -$spacer;
43
+ margin-right: -$spacer;
44
+ }
45
+
46
+ // Used in page header for most situations
47
+ .container-narrow {
48
+ @include media-breakpoint-down(sm) {
49
+ padding-right: ($grid-gutter-width / 2);
50
+ padding-left: ($grid-gutter-width / 2);
51
+ }
52
+ }
@@ -0,0 +1,6 @@
1
+ // Hides #quick-add-modal modal if task modal is enabled in DMS
2
+ #task-modal.show {
3
+ z-index: $zindex-modal + 1;
4
+ + #quick-add-modal { display: none !important; }
5
+ ~ .modal-backdrop.show ~ .modal-backdrop.show { display: none !important; }
6
+ }
@@ -20,3 +20,85 @@
20
20
  }
21
21
  }
22
22
  }
23
+
24
+ // Top navigation bar in DMS
25
+ .site-nav {
26
+ position: fixed;
27
+ top: 0;
28
+ width: 200px;
29
+ height: 100%;
30
+ background-color: #006D9D;
31
+ overflow-y: auto;
32
+ -webkit-overflow-scrolling: touch;
33
+ @include transition(all .2s ease-in-out);
34
+ @include media-breakpoint-down(lg) {
35
+ left: -200px;
36
+ opacity: 0;
37
+ z-index: 10;
38
+ overflow-x: hidden;
39
+ }
40
+ @include media-breakpoint-up(xl) {
41
+ left: 0;
42
+ z-index: 30;
43
+ }
44
+
45
+ // Slide styles
46
+ &.nav-slide {
47
+ @include media-breakpoint-down(lg) {
48
+ left: 0;
49
+ opacity: 1;
50
+ z-index: 30;
51
+ overflow-x: visible;
52
+ overflow-y: auto;
53
+ }
54
+ }
55
+ .nav-pills {
56
+ .nav-item {
57
+ font-weight: $font-weight-bold;
58
+ line-height: $line-height-sm;
59
+ }
60
+ .nav-link {
61
+ padding: ($spacer * .75) ($spacer * .5);
62
+ @include border-radius($nav-pills-border-radius);
63
+ color: $white;
64
+ vertical-align: middle;
65
+ background-color: transparent;
66
+ border-left: 4px solid transparent;
67
+ @include clearfix();
68
+ @include transition($btn-transition);
69
+ &:hover, &.active, &[aria-expanded="true"] {
70
+ color: $nav-pills-link-active-color;
71
+ cursor: pointer;
72
+ background-color: $nav-pills-link-active-bg;
73
+ }
74
+ .fa {
75
+ width: 1em;
76
+ min-width: 14px;
77
+ line-height: 18px;
78
+ }
79
+ }
80
+ &.nav-sub-menu {
81
+ .nav-link {
82
+ padding-top: ($spacer * .5);
83
+ padding-bottom: ($spacer * .5);
84
+ font-size: ($font-size-base * .75);
85
+ line-height: $line-height-base;
86
+ background-color: darken(#006D9D, 13%);
87
+ &:hover, &:focus, &.active {
88
+ background-color: darken(#006D9D, 17%);
89
+ }
90
+ }
91
+ }
92
+ }
93
+ }
94
+
95
+ // Color variations for border
96
+ @each $color in $colors {
97
+ .site-nav {
98
+ .nav-item.#{nth($color, 1)} {
99
+ .nav-link {
100
+ &:hover, &.active, &[aria-expanded="true"] { border-color: nth($color, 2); }
101
+ }
102
+ }
103
+ }
104
+ }
@@ -1,4 +1,4 @@
1
- // Styles that replicate the legacy top navs
1
+ // Styles that replicate the legacy top navs in EVO
2
2
  #admin-nav {
3
3
  background-color: #444444;
4
4
  .navbar {
@@ -130,3 +130,96 @@
130
130
  }
131
131
  }
132
132
  }
133
+
134
+ // Main navigation bar (left) in DMS
135
+ .site-navbar {
136
+ position: fixed;
137
+ right: 0;
138
+ left: 0;
139
+ z-index: $zindex-fixed;
140
+ @include transition(left .2s ease-in-out);
141
+ @include media-breakpoint-down(lg) {
142
+ bottom: 0;
143
+ width: 100%;
144
+ border-top: $border-width solid $nav-divider-color;
145
+ }
146
+ @include media-breakpoint-up(xl) {
147
+ top: 0;
148
+ left: 200px;
149
+ border-bottom: $border-width solid $nav-divider-color;
150
+ }
151
+ .navbar-brand {
152
+ font-size: ($font-size-base * .75);
153
+ @include media-breakpoint-down(lg) { display: none !important; }
154
+ }
155
+ .nav {
156
+ @include media-breakpoint-down(lg) { width: 100%; }
157
+ .nav-item {
158
+ position: relative;
159
+ font-size: ($font-size-base * .75);
160
+ font-weight: $font-weight-bold;
161
+ line-height: 1;
162
+ text-align: center;
163
+ border-left: $border-width solid $border-color;
164
+ @include media-breakpoint-down(lg) {
165
+ width: 20%;
166
+ &:first-child { border-left: none; }
167
+ }
168
+ .nav-alert {
169
+ position: absolute;
170
+ top: -4px;
171
+ right: -4px;
172
+ width: 8px;
173
+ height: 8px;
174
+ background-color: $primary;
175
+ @include border-radius(50%);
176
+ box-shadow: 0 0 0 2px rgba(255,255,255,1);
177
+ &.nav-alert-danger { background-color: $danger; }
178
+ }
179
+ .nav-link {
180
+ color: $text-muted;
181
+ outline: none !important;
182
+ @include transition(background-color .2s ease-in-out);
183
+ @include media-breakpoint-down(sm) { padding: ($spacer * .5); }
184
+ @include media-breakpoint-up(md) { padding: 18px $spacer; }
185
+ @include hover() { background-color: $body-bg; }
186
+ &[aria-expanded="true"],
187
+ &:not(:disabled):not(.disabled).active { background-color: $body-bg; }
188
+ &.disabled {
189
+ cursor: disabled;
190
+ pointer-events: none;
191
+ opacity: .4;
192
+ }
193
+ &.dropdown-toggle {
194
+ @include media-breakpoint-down(lg) {
195
+ + .dropdown-menu {
196
+ top: auto;
197
+ bottom: 100%;
198
+ margin-bottom: 2px;
199
+ }
200
+ }
201
+ }
202
+ &.has-label {
203
+ @include media-breakpoint-up(xl) {
204
+ padding-top: 15px;
205
+ height: ($spacer * 2);
206
+ }
207
+ }
208
+ .nav-text {
209
+ &.visible {
210
+ @include media-breakpoint-up(xl) { display: inline-block; }
211
+ }
212
+ @include media-breakpoint-down(sm) {
213
+ display: block;
214
+ margin-top: 2px;
215
+ font-weight: $font-weight-bold;
216
+ font-size: 10px;
217
+ }
218
+ @include media-breakpoint-up(md) { margin-left: ($spacer * .25); }
219
+ @include media-breakpoint-up(xl) { display: none; }
220
+ }
221
+ + .nav-link { margin-left: 0; }
222
+ }
223
+ }
224
+ }
225
+ }
@@ -0,0 +1,52 @@
1
+ // Free trial styles for DMS
2
+
3
+ // Height of banner
4
+ $free_trial_banner_height: 6.2rem;
5
+
6
+ // Styles for container elements when body tag is using .has-free-trial
7
+ body.has-free-trial.nfg_ui {
8
+ padding-top: 0;
9
+
10
+ // For Top Banner
11
+ @include media-breakpoint-down(lg) {
12
+ .site-nav { padding-top: $free_trial_banner_height; }
13
+ .page-wrap { padding-top: $free_trial_banner_height; }
14
+ }
15
+ @include media-breakpoint-up(xl) {
16
+ .site-nav {
17
+ top: $free_trial_banner_height;
18
+ height: calc(100% - 62px);
19
+ }
20
+ .full_width_layout { padding-top: ($spacer * 3); }
21
+ .container-wrap { padding-top: ($spacer * 2) + $free_trial_banner_height; }
22
+ .site-navbar, .email-navbar { top: $free_trial_banner_height; }
23
+
24
+ .page-wrap { padding-top: ($spacer * 2) + ($spacer * .5) + $free_trial_banner_height; }
25
+ .builder-container { padding-top: 110px !important; }
26
+ .sidebar { padding-top: $free_trial_banner_height; }
27
+
28
+ .builder-header { top: $free_trial_banner_height; }
29
+ .builder-wrap { padding-top: ($spacer * 2) + $free_trial_banner_height; }
30
+ .builder-options { padding-top: ($spacer * 3) + $spacer + $free_trial_banner_height; }
31
+
32
+ // Sticky redactor to render above the free trial banner
33
+ #email-layout .cs-html-editor-overlay,
34
+ .cs-html-editor-overlay { z-index: $zindex-fixed + 2; }
35
+ }
36
+ @include media-breakpoint-up(xl) {
37
+ .sidebar { height: 100%; }
38
+ }
39
+
40
+ // Free trial banner specific styles
41
+ .free-trial-alert {
42
+ z-index: $zindex-fixed + 1;
43
+ @include media-breakpoint-up(xl) {
44
+ position: fixed !important;
45
+ top: 0;
46
+ left: 0;
47
+ right: 0;
48
+ width: 100%;
49
+ }
50
+ }
51
+ }
52
+
@@ -0,0 +1,33 @@
1
+ // Product icons
2
+ @font-face {
3
+ font-family: 'IcoMoon-product-icons';
4
+ src: font-url('product_icons/IcoMoon-product-icons.eot?b2y89i');
5
+ src: font-url('product_icons/IcoMoon-product-icons.eot?b2y89i#iefix') format('embedded-opentype'),
6
+ font-url('product_icons/IcoMoon-product-icons.ttf?b2y89i') format('truetype'),
7
+ font-url('product_icons/IcoMoon-product-icons.woff?b2y89i') format('woff'),
8
+ font-url('product_icons/IcoMoon-product-icons.svg?b2y89i#IcoMoon-product-icons') format('svg');
9
+ font-weight: normal;
10
+ font-style: normal;
11
+ }
12
+ [class^="icon-sso-"], [class*=" icon-sso-"] {
13
+ /* use !important to prevent issues with browser extensions that change fonts */
14
+ font-family: 'IcoMoon-product-icons' !important;
15
+ speak: none;
16
+ font-style: normal;
17
+ font-weight: normal;
18
+ font-variant: normal;
19
+ text-transform: none;
20
+ line-height: 1;
21
+
22
+ /* Better Font Rendering =========== */
23
+ -webkit-font-smoothing: antialiased;
24
+ -moz-osx-font-smoothing: grayscale;
25
+ }
26
+ .icon-sso-donatenow:before { content: "\e900"; }
27
+ .icon-sso-donation-pages:before { content: "\e683"; }
28
+ .icon-sso-dms:before { content: "\e6ba"; }
29
+ .icon-sso-product-fundraising-coach:before,
30
+ .fa-icon-sso-product-fundraising-coach:before {
31
+ content: "\e199";
32
+ font-family: 'IcoMoon-product-icons' !important; } // allows use as a resource icon
33
+ .icon-sso-disbursements:before { content: "\e466"; }
@@ -1,2 +1,2 @@
1
1
  // Sort
2
- [class*='sort'] { cursor: move; }
2
+ [class*='sort']:not(.sort_link) { cursor: move; }
@@ -3,6 +3,11 @@
3
3
  .nav {
4
4
  display: -ms-flexbox;
5
5
  -ms-flex-wrap: wrap;
6
+ // override because flexbox displays incorrect in <= IE10
7
+ &.site-nav {
8
+ display: block !important;
9
+ .nav-sub-menu { display: block !important; }
10
+ }
6
11
  }
7
12
 
8
13
  // Justified variants
@@ -19,3 +24,5 @@
19
24
  -ms-flex-positive: 1;
20
25
  }
21
26
  }
27
+
28
+
@@ -52,6 +52,9 @@
52
52
  }
53
53
  }
54
54
 
55
+ //** Needed to support legacy bs4 alpha collapse styles in DMS
56
+ .collapse.in { display: block; }
57
+
55
58
  //** Time/Date Toggle
56
59
  .collapse.show {
57
60
  .timepicker-picker {
@@ -45,6 +45,7 @@ body:not(.modal-open) {
45
45
  height: $custom-select-height !important;
46
46
  transition: $transition-base;
47
47
  }
48
+ .select2-selection__placeholder { color: $primary; }
48
49
  .select2-selection__arrow { display: none; }
49
50
  }
50
51
 
@@ -65,7 +66,6 @@ body:not(.modal-open) {
65
66
  .select2-search__field {
66
67
  margin-top: 0;
67
68
  min-height: 18px;
68
- border: $input-border-width solid $input-border-color;
69
69
  }
70
70
  }
71
71
  .select2-selection__rendered {
@@ -204,8 +204,7 @@ body:not(.modal-open) {
204
204
  top: 0;
205
205
  right: 0;
206
206
  width: 60px;
207
- font-size: 10px;
208
- line-height: 34px;
207
+ font-size: 12px;
209
208
  font-family: $font-family-sans-serif;
210
209
  color: $link-color;
211
210
  text-transform: uppercase;
@@ -0,0 +1,6 @@
1
+ // Turbolink progress bar
2
+ .turbolinks-progress-bar {
3
+ background-color: $success !important;
4
+ height: ($spacer * .25);
5
+ z-index: ($zindex-fixed + 1);
6
+ }
@@ -0,0 +1,44 @@
1
+ //*****************************//
2
+ // TWITTER TYPEAHEAD -- (ex. used on address type ahead)
3
+ //*****************************//
4
+ .twitter-typeahead { width: 100%; }
5
+ .tt-query {
6
+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
7
+ -moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
8
+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
9
+ }
10
+ .tt-hint { color: $text-muted; }
11
+ .tt-menu {
12
+ margin-top: 2px;
13
+ padding: ($spacer * .25) 0;
14
+ width: 100%;
15
+ max-width: 100%;
16
+ max-height: 350px;
17
+ font-size: $font-size-sm;
18
+ background-color: $dropdown-bg;
19
+ background-clip: padding-box;
20
+ border: $dropdown-border-width solid $dropdown-border-color;
21
+ @include border-radius($border-radius);
22
+ @include box-shadow(0 0 5px transparentize($black, 0.7));
23
+ overflow-y: auto;
24
+ }
25
+ .tt-suggestion {
26
+ padding: ($spacer * .5);
27
+ line-height: 1;
28
+ + .tt-suggestion { border-top: $dropdown-border-width solid $dropdown-border-color; }
29
+ }
30
+ .tt-selectable { cursor: pointer; }
31
+ .tt-suggestion.tt-cursor, .tt-selectable:hover {
32
+ color: $dropdown-link-hover-color;
33
+ background-color: $dropdown-link-hover-bg;
34
+ }
35
+
36
+ .tt-highlight {
37
+ font-weight: $font-weight-bold;
38
+ background-color: $body-bg;
39
+ }
40
+
41
+ .tt-empty-template {
42
+ padding: ($spacer * .5);
43
+ line-height: 1;
44
+ }
@@ -5,16 +5,22 @@ module NfgUi
5
5
  module Elements
6
6
  # Nav doc coming soon
7
7
  class NavLink < NfgUi::Bootstrap::Components::NavLink
8
+ include Bootstrap::Utilities::CollapseToggleable
9
+ include Bootstrap::Utilities::Modalable
10
+
8
11
  include NfgUi::Components::Utilities::Traitable
9
12
  include NfgUi::Components::Utilities::Describable
10
13
  include NfgUi::Components::Utilities::Iconable
11
14
  include NfgUi::Components::Utilities::Renderable
12
15
 
13
16
  include NfgUi::Components::Traits::Active
14
- include NfgUi::Components::Traits::Remote
15
17
  include NfgUi::Components::Traits::Disable
18
+ include NfgUi::Components::Traits::Remote
16
19
 
17
20
  def render
21
+ # Do NOT use :collapse while also using dropdown. That would be
22
+ # self-defeating. Since a dropdown menu is a more specific type
23
+ # of collapse component.
18
24
  if dropdown
19
25
  NfgUi::Components::Elements::DropdownToggle.new({ body: (block_given? ? yield : body), as: :a, **html_options, theme: nil, nav_link: true }, view_context).render
20
26
  else
@@ -17,6 +17,15 @@ module NfgUi
17
17
  sticky ? super.merge!(toggle: 'sticky-div') : super
18
18
  end
19
19
 
20
+ # Supplies a slightly smaller design-system approved column structure
21
+ # when set to false (as used in Evo), by default.
22
+ # DMS, however requires a simple 'col' (full width) layout
23
+ # and will have :full_width set to true manually while both apps
24
+ # co-exist with slightly different page layouts.
25
+ def full_width
26
+ options.fetch(:full_width, false)
27
+ end
28
+
20
29
  def sticky
21
30
  return if Rails.env.test? || browser.mobile?
22
31
  options.fetch(:sticky, true)
@@ -41,7 +50,7 @@ module NfgUi
41
50
 
42
51
  content_tag(:div, html_options) do
43
52
  content_tag(:div, class: 'row') do
44
- content_tag(:div, class: 'col col-xl-11 mx-auto') do
53
+ content_tag(:div, class: column_structure_css_classes) do
45
54
  content_tag(:div, class: 'row align-items-center') do
46
55
  concat(content_tag(:div, class: 'col py-2') {
47
56
  NfgUi::Components::Patterns::Media.new({}, view_context).render do
@@ -80,8 +89,12 @@ module NfgUi
80
89
 
81
90
  private
82
91
 
92
+ def column_structure_css_classes
93
+ "col #{'col-xl-11 mx-auto' unless full_width}".squish
94
+ end
95
+
83
96
  def non_html_attribute_options
84
- super.push(:subtitle)
97
+ super.push(:subtitle, :full_width, :sticky)
85
98
  end
86
99
  end
87
100
  end
@@ -22,7 +22,19 @@ module NfgUi
22
22
  maybe_update_option(:theme, value: NfgUi::DEFAULT_TIP_THEME)
23
23
 
24
24
  if options[:text].present?
25
- maybe_update_option(:right, value: true)
25
+ # We are unable to use #maybe_update_option method due to how traits
26
+ # are calculated when sub components are
27
+ # rendered within sub components (example: nav_link being rendered within a nav_item)...
28
+ #
29
+ # This will leave options[:right] alone unless
30
+ # there is a value stored in the component's options[:right]
31
+ #
32
+ # Example where options[:right] is left alone:
33
+ # ui.nfg(:icon, :tip, right: false, text: 'Tip icon is on the left')
34
+ #
35
+ # Example where options[:right] gets updated:
36
+ # ui.nfg(:icon, :tip, text: 'Tip icon is on the right')
37
+ options[:right] = true if options[:right].nil?
26
38
  options[:class] += ' fa-fw'
27
39
  end
28
40
  end
@@ -5,6 +5,8 @@ module NfgUi
5
5
  module Utilities
6
6
  # The library of dedicated theme resources in Evo & DMS
7
7
  module ResourceThemeable
8
+ FALLBACK_ICON = 'heart-o'
9
+ DEFAULT_THEME_COLOR = 'primary'
8
10
  # This method represents an existential question
9
11
  # for the UX team at NFG
10
12
  #
@@ -14,11 +16,11 @@ module NfgUi
14
16
  def resource_theme_color(object = nil)
15
17
  case resource_theme_name(object)
16
18
  when 'Project'
17
- 'primary'
19
+ DEFAULT_THEME_COLOR
18
20
  when 'Campaign'
19
- 'primary'
21
+ DEFAULT_THEME_COLOR
20
22
  else
21
- 'primary'
23
+ DEFAULT_THEME_COLOR
22
24
  end
23
25
  end
24
26
 
@@ -45,7 +47,7 @@ module NfgUi
45
47
  when 'RecurringDonation'
46
48
  'refresh'
47
49
  else
48
- 'heart-o'
50
+ FALLBACK_ICON
49
51
  end
50
52
  end
51
53
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module NfgUi
4
- VERSION = '0.10.5'
4
+ VERSION = '0.10.6'
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.10.5
4
+ version: 0.10.6
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: 2020-01-28 00:00:00.000000000 Z
12
+ date: 2020-03-30 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bootstrap
@@ -357,6 +357,11 @@ files:
357
357
  - README.md
358
358
  - Rakefile
359
359
  - app/assets/config/nfg_ui_manifest.js
360
+ - app/assets/fonts/product_icons/IcoMoon-product-icons.eot
361
+ - app/assets/fonts/product_icons/IcoMoon-product-icons.svg
362
+ - app/assets/fonts/product_icons/IcoMoon-product-icons.ttf
363
+ - app/assets/fonts/product_icons/IcoMoon-product-icons.woff
364
+ - app/assets/fonts/product_icons/product-icons-icomoon.zip
360
365
  - app/assets/images/nfg_ui/app_icon/android-chrome-192x192.png
361
366
  - app/assets/images/nfg_ui/app_icon/android-chrome-384x384.png
362
367
  - app/assets/images/nfg_ui/app_icon/apple-touch-icon.png
@@ -395,7 +400,9 @@ files:
395
400
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_custom.scss
396
401
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_dropdown.scss
397
402
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_forms.scss
403
+ - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_grid.scss
398
404
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_media.scss
405
+ - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_modal.scss
399
406
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_nav.scss
400
407
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_navbar.scss
401
408
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/_progress.scss
@@ -412,13 +419,14 @@ files:
412
419
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_custom_receipt_language.scss
413
420
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_device_preview.scss
414
421
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_email_preview.scss
422
+ - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_free_trial.scss
423
+ - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_icomoon.scss
415
424
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_illustration.scss
416
425
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_interaction.scss
417
426
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_mobile.scss
418
427
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_nav_step.scss
419
428
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_overlay_blocker.scss
420
429
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_page_header.scss
421
- - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_product_icons.scss
422
430
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_redactor.scss
423
431
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_share_dropdown.scss
424
432
  - app/assets/stylesheets/nfg_ui/network_for_good/admin/nfg_theme/custom/_slat.scss
@@ -518,13 +526,14 @@ files:
518
526
  - app/assets/stylesheets/nfg_ui/network_for_good/public/plugins/_intercom.scss
519
527
  - app/assets/stylesheets/nfg_ui/network_for_good/public/plugins/_select2.scss
520
528
  - app/assets/stylesheets/nfg_ui/network_for_good/public/plugins/_sticky_div.scss
529
+ - app/assets/stylesheets/nfg_ui/network_for_good/public/plugins/_turbolinks.scss
530
+ - app/assets/stylesheets/nfg_ui/network_for_good/public/plugins/_twitter_typeahead.scss
521
531
  - app/controllers/nfg_ui/application_controller.rb
522
532
  - app/helpers/nfg_ui/application_helper.rb
523
533
  - app/helpers/nfg_ui/components/browser_helper.rb
524
534
  - app/helpers/nfg_ui/components/email_helpers.rb
525
535
  - app/helpers/nfg_ui/components/resource_themes_helper.rb
526
536
  - app/helpers/nfg_ui/components/tooltip_helper.rb
527
- - app/models/nfg_ui/application_record.rb
528
537
  - app/views/nfg_ui/app_icons/_icons.html.haml
529
538
  - app/views/nfg_ui/email/README.md
530
539
  - app/views/nfg_ui/email/_alert.html.inky-haml
@@ -782,7 +791,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
782
791
  - !ruby/object:Gem::Version
783
792
  version: '0'
784
793
  requirements: []
785
- rubygems_version: 3.0.3
794
+ rubygems_version: 3.0.8
786
795
  signing_key:
787
796
  specification_version: 4
788
797
  summary: NFG UI front-end design system code for rapid product building
@@ -1,45 +0,0 @@
1
- // Product icons
2
-
3
- @font-face {
4
- font-family: 'IcoMoon-product-icons';
5
- src: font-url('admin/nfg_product_icons/IcoMoon-product-icons.eot?b2y89i');
6
- src: font-url('admin/nfg_product_icons/IcoMoon-product-icons.eot?b2y89i#iefix') format('embedded-opentype'),
7
- font-url('admin/nfg_product_icons/IcoMoon-product-icons.ttf?b2y89i') format('truetype'),
8
- font-url('admin/nfg_product_icons/IcoMoon-product-icons.woff?b2y89i') format('woff'),
9
- font-url('admin/nfg_product_icons/IcoMoon-product-icons.svg?b2y89i#IcoMoon-product-icons') format('svg');
10
- font-weight: normal;
11
- font-style: normal;
12
- }
13
-
14
- [class^="icon-sso-"], [class*=" icon-sso-"] {
15
- /* use !important to prevent issues with browser extensions that change fonts */
16
- font-family: 'IcoMoon-product-icons' !important;
17
- speak: none;
18
- font-style: normal;
19
- font-weight: normal;
20
- font-variant: normal;
21
- text-transform: none;
22
- line-height: 1;
23
-
24
- /* Better Font Rendering =========== */
25
- -webkit-font-smoothing: antialiased;
26
- -moz-osx-font-smoothing: grayscale;
27
- }
28
-
29
- .icon-sso-donatenow:before {
30
- content: "\e900";
31
- }
32
- .icon-sso-donation-pages:before {
33
- content: "\e683";
34
- }
35
- .icon-sso-dms:before {
36
- content: "\e6ba";
37
- }
38
- .icon-product-fundraising-coach:before {
39
- content: "\e199";
40
- }
41
- .icon-sso-disbursements:before {
42
- content: "\e466";
43
- }
44
-
45
-
@@ -1,5 +0,0 @@
1
- module NfgUi
2
- class ApplicationRecord < ActiveRecord::Base
3
- self.abstract_class = true
4
- end
5
- end