@foeewni/web-core 3.0.0-alpha.1 → 3.0.0-alpha.3

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.
@@ -19,21 +19,18 @@ The Friends of the Earth blockquotes use the secondary font
19
19
  @import '../../utils/scss/loader';
20
20
 
21
21
  blockquote {
22
- border-color: $gray-400;
23
- border-style: double;
24
- border-width: .2em 0;
25
- padding: $spacer*1.5 0;
22
+ padding: $spacer * 1.5 0;
26
23
  width: 80%;
27
- margin: $spacer*2 auto;
24
+ margin: ($spacer * 2) auto;
28
25
  float: none;
29
26
  clear: both;
30
27
 
31
28
  p {
32
29
  font-family: $font-family-serif;
33
- font-weight: 700;
30
+ font-weight: normal;
34
31
  font-size: $blockquote-font-size;
35
32
  line-height: $blockquote-font-size * 1.35;
36
- color: $foe-primary;
33
+ color: $foe-extradark;
37
34
 
38
35
  @include media-breakpoint-down(sm) {
39
36
  font-size: strip-units($blockquote-font-size) * $font-size-sm;
@@ -75,24 +72,24 @@ blockquote {
75
72
 
76
73
  cite,
77
74
  & + .citation {
78
- font-family: $font-family-sans-serif;
79
- font-size: 1rem;
75
+ width: 80%;
76
+ margin: auto;
77
+ font-family: $font-family-serif;
78
+ font-size: $blockquote-font-size;
80
79
  line-height: 1.3rem;
81
- font-weight: 400;
82
- font-style: italic;
83
- color: $gray-500;
80
+ font-weight: bold;
81
+ color: $foe-extradark;
84
82
  display: block;
85
- text-align: right;
86
- margin-top: 1em;
87
- padding-left: 10%;
83
+ text-align: left;
84
+ margin-top: $spacer;
88
85
 
89
- &::before {
90
- content: "\2014\00A0\00A0";
91
- color: $foe-primary;
86
+ @include media-breakpoint-up(sm) {
87
+ width: calc(100% * 4 / 6);
92
88
  }
93
89
  }
94
90
 
95
91
  & + .citation {
96
- margin-top: $spacer * -1;
92
+ margin-top: $spacer * -2.75;
93
+ margin-bottom: $spacer * 2;
97
94
  }
98
95
  }
package/src/fonts.js CHANGED
@@ -32,6 +32,7 @@ To use them on your CSS please import the webfonts through Google Fonts
32
32
  // Note, single line deep imports are needed here, for some reason fontawesome messes up
33
33
  // with normal imports and webpack ends up bundling the whole library (1.25mb!)
34
34
  import { library, dom } from '@fortawesome/fontawesome-svg-core';
35
+
35
36
  import { faEnvelope } from '@fortawesome/free-solid-svg-icons/faEnvelope';
36
37
  import { faSearch } from '@fortawesome/free-solid-svg-icons/faSearch';
37
38
  import { faTimes } from '@fortawesome/free-solid-svg-icons/faTimes';
@@ -40,19 +41,6 @@ import { faExternalLinkSquareAlt } from '@fortawesome/free-solid-svg-icons/faExt
40
41
  import { faArrowAltCircleUp } from '@fortawesome/free-solid-svg-icons/faArrowAltCircleUp';
41
42
  import { faShare } from '@fortawesome/free-solid-svg-icons/faShare';
42
43
  import { faLink } from '@fortawesome/free-solid-svg-icons/faLink';
43
- import { faTwitter } from '@fortawesome/free-brands-svg-icons/faTwitter';
44
- import { faFacebook } from '@fortawesome/free-brands-svg-icons/faFacebook';
45
- import { faFacebookF } from '@fortawesome/free-brands-svg-icons/faFacebookF';
46
- import { faPinterest } from '@fortawesome/free-brands-svg-icons/faPinterest';
47
- import { faLinkedin } from '@fortawesome/free-brands-svg-icons/faLinkedin';
48
- import { faInstagram } from '@fortawesome/free-brands-svg-icons/faInstagram';
49
- import { faYoutube } from '@fortawesome/free-brands-svg-icons/faYoutube';
50
- import { faTumblr } from '@fortawesome/free-brands-svg-icons/faTumblr';
51
- import { faWhatsapp } from '@fortawesome/free-brands-svg-icons/faWhatsapp';
52
- import { faFacebookMessenger } from '@fortawesome/free-brands-svg-icons/faFacebookMessenger';
53
- import { faTelegram } from '@fortawesome/free-brands-svg-icons/faTelegram';
54
- import { faTelegramPlane } from '@fortawesome/free-brands-svg-icons/faTelegramPlane';
55
- import { faTiktok } from '@fortawesome/free-brands-svg-icons/faTiktok';
56
44
  import { faChevronDown } from '@fortawesome/free-solid-svg-icons/faChevronDown';
57
45
  import { faChevronUp } from '@fortawesome/free-solid-svg-icons/faChevronUp';
58
46
  import { faAngleDown } from '@fortawesome/free-solid-svg-icons/faAngleDown';
@@ -76,6 +64,23 @@ import { faSave } from '@fortawesome/free-solid-svg-icons/faSave';
76
64
  import { faSignInAlt } from '@fortawesome/free-solid-svg-icons/faSignInAlt';
77
65
  import { faTrashAlt } from '@fortawesome/free-solid-svg-icons/faTrashAlt';
78
66
 
67
+ import { faTwitter } from '@fortawesome/free-brands-svg-icons/faTwitter';
68
+ import { faXTwitter } from '@fortawesome/free-brands-svg-icons/faXTwitter';
69
+ import { faFacebook } from '@fortawesome/free-brands-svg-icons/faFacebook';
70
+ import { faFacebookF } from '@fortawesome/free-brands-svg-icons/faFacebookF';
71
+ import { faPinterest } from '@fortawesome/free-brands-svg-icons/faPinterest';
72
+ import { faLinkedin } from '@fortawesome/free-brands-svg-icons/faLinkedin';
73
+ import { faInstagram } from '@fortawesome/free-brands-svg-icons/faInstagram';
74
+ import { faYoutube } from '@fortawesome/free-brands-svg-icons/faYoutube';
75
+ import { faTumblr } from '@fortawesome/free-brands-svg-icons/faTumblr';
76
+ import { faWhatsapp } from '@fortawesome/free-brands-svg-icons/faWhatsapp';
77
+ import { faFacebookMessenger } from '@fortawesome/free-brands-svg-icons/faFacebookMessenger';
78
+ import { faTelegram } from '@fortawesome/free-brands-svg-icons/faTelegram';
79
+ import { faTelegramPlane } from '@fortawesome/free-brands-svg-icons/faTelegramPlane';
80
+ import { faTiktok } from '@fortawesome/free-brands-svg-icons/faTiktok';
81
+ import { faBluesky } from '@fortawesome/free-brands-svg-icons/faBluesky';
82
+ import { faThreads } from '@fortawesome/free-brands-svg-icons/faThreads';
83
+
79
84
 
80
85
  // Add actually used FA icons
81
86
  library.add(
@@ -88,6 +93,7 @@ library.add(
88
93
  faShare,
89
94
  faLink,
90
95
  faTwitter,
96
+ faXTwitter,
91
97
  faFacebook,
92
98
  faFacebookF,
93
99
  faPinterest,
@@ -121,20 +127,25 @@ library.add(
121
127
  faSave,
122
128
  faTrashAlt,
123
129
  faCloudUploadAlt,
124
- faSignInAlt
130
+ faSignInAlt,
131
+ faBluesky,
132
+ faThreads
125
133
  );
126
134
 
127
135
  // Look for Google fonts and append them if they are not there already
128
136
  // We avoiding using @import url(); because the new URL has semicolons on it
129
137
  // and it tremendously gets broken from some preprocessors.
130
138
 
131
- const fonts = window.document.createElement('link');
132
139
  // eslint-disable-next-line max-len
133
- const href = 'https://fonts.googleapis.com/css2?family=Libre+Baskerville:ital@0;1&family=Libre+Franklin:ital,wght@0,400;0,700;1,400;1,700&display=swap';
134
- fonts.setAttribute('rel', 'stylesheet');
135
- fonts.setAttribute('crossorigin', 'anonymous');
136
- fonts.setAttribute('href', href);
137
- document.head.appendChild(fonts);
140
+ const googleFontsHref = 'https://fonts.googleapis.com/css2?family=Libre+Baskerville:ital@0;1&family=Libre+Franklin:ital,wght@0,400;0,700;1,400;1,700&display=swap';
141
+ const googleFontsLink = window.document.querySelector(`link[href="${googleFontsHref}"]`);
142
+ if (!googleFontsLink) {
143
+ const fonts = window.document.createElement('link');
144
+ fonts.setAttribute('rel', 'stylesheet');
145
+ fonts.setAttribute('crossorigin', 'anonymous');
146
+ fonts.setAttribute('href', googleFontsHref);
147
+ document.head.appendChild(fonts);
148
+ }
138
149
 
139
150
  // Kicks off the process of finding <i> tags and replacing with <svg>
140
151
  dom.watch();
@@ -8,28 +8,44 @@
8
8
  //
9
9
 
10
10
  // Colours
11
- $foe-primary: #56a085 !default;
12
- $foe-light: #7ae1bd !default;
13
- $foe-secondary: $foe-light !default;
14
- $foe-dark: #3b867f !default;
15
- // $foe-extradark: #232f4a !default;
16
- $foe-extradark: #a01fed !default;
17
- $foe-sunset: #ea5c5c !default;
18
-
19
- $foe-white: #f3f3f7 !default;
11
+ $foe-leaf: #61bdaa !default;
12
+ $foe-iris: #5a54a0 !default;
13
+ $foe-sunset: #ed6132 !default;
14
+ $foe-space: #1e234d !default;
15
+ $foe-ice: #f3f3f7 !default;
16
+ $foe-conch: #f1e2d4 !default;
17
+
18
+ // Tints, would prefer to do this algorithmically but it's useful to have the hex codes on hand to compare with figmas
19
+ $foe-leaf-75: #81cabb !default;
20
+ $foe-leaf-50: #c0e5dd !default;
21
+ $foe-leaf-25: #dff2ee !default;
22
+ $foe-sunset-75: #f1815b !default;
23
+ $foe-sunset-50: #f6b099 !default;
24
+ $foe-sunset-25: #fbdfd6 !default;
25
+ $foe-iris-75: #6d68a7 !default;
26
+ $foe-iris-50: #adaad0 !default;
27
+ $foe-iris-25: #deddec !default;
28
+
29
+ $foe-primary: $foe-leaf !default;
30
+ $foe-light: $foe-leaf-25 !default;
31
+ $foe-secondary: $foe-light !default;
32
+ $foe-dark: #182f2a !default;
33
+ $foe-extradark: $foe-space !default;
34
+
35
+ $foe-white: #fff !default;
20
36
  $foe-gray: #b1b8c0 !default;
21
- $foe-accent: #34da96 !default;
22
- $foe-offwhite: #f3f3f7 !default;
37
+ $foe-accent: $foe-iris !default;
38
+ $foe-offwhite: $foe-ice !default;
23
39
 
24
40
  $foe-success: #5cb85c !default;
25
41
  $foe-info: #5bc0de !default;
26
42
  $foe-warning: #f0ad4e !default;
27
43
  $foe-danger: #d9534f !default;
28
44
 
29
- $foe-text: #6b6b6f !default;
45
+ $foe-text: $foe-extradark !default;
30
46
 
31
- $foe-donate: #ea4848 !default;
32
- $foe-donate-text: $foe-offwhite !default;
47
+ $foe-donate: $foe-sunset !default;
48
+ $foe-donate-text: $foe-extradark !default;
33
49
 
34
50
  $foe-join: #ffef1e !default;
35
51
  $foe-join-text: $foe-text !default;
@@ -51,6 +67,11 @@ $foe-nav-shadow: 0 0 .5em .2em rgba(0, 0, 0, .25);
51
67
 
52
68
  $foe-text-shadow: 0 0 .5rem $foe-tint-overlay-heavy !default;
53
69
 
70
+ $foe-backgrounds:
71
+ $foe-leaf-50,
72
+ $foe-sunset-50,
73
+ $foe-iris-50;
74
+
54
75
  //
55
76
  // Palettes vars, needed for Campaignion (mostly) maybe also D8
56
77
  //
@@ -219,11 +240,11 @@ $theme-colors: map-merge(
219
240
  $theme-color-interval: 8%;
220
241
 
221
242
  // The yiq lightness value that determines when the lightness of color changes from "dark" to "light". Acceptable values are between 0 and 255.
222
- $yiq-contrasted-threshold: 150;
243
+ $yiq-contrasted-threshold: 142; // this works for a hover cover for text-dark over leaf - any higher and it uses text-light.
223
244
 
224
245
  // Customize the light and dark text colors for use in our YIQ color contrast function.
225
- $yiq-text-dark: $gray-900;
226
- $yiq-text-light: $white;
246
+ $yiq-text-dark: $foe-extradark;
247
+ $yiq-text-light: $foe-offwhite;
227
248
 
228
249
  // Options
229
250
  //
@@ -288,7 +309,7 @@ $body-color: $foe-text;
288
309
  //
289
310
  // Style anchor elements.
290
311
 
291
- $link-color: theme-color("primary");
312
+ $link-color: theme-color("accent");
292
313
  $link-decoration: none;
293
314
  $link-hover-color: darken($link-color, 15%);
294
315
  $link-hover-decoration: underline;
@@ -391,7 +412,7 @@ $line-height-sm: 1.5;
391
412
  $border-width: 1px;
392
413
  $border-color: $gray-300;
393
414
 
394
- $border-radius: .1rem * 3;
415
+ $border-radius: 0; // .1rem * 3;
395
416
  $border-radius-lg: .1rem * 4;
396
417
  $border-radius-sm: .1rem * 2;
397
418
 
@@ -399,8 +420,8 @@ $box-shadow-sm: 0 .125rem .25rem rgba($black, .075);
399
420
  $box-shadow: 0 .5rem 1rem rgba($black, .15);
400
421
  $box-shadow-lg: 0 1rem 3rem rgba($black, .175);
401
422
 
402
- $component-active-color: $gray-900;
403
- $component-active-bg: theme-color("accent");
423
+ $component-active-color: $foe-extradark;
424
+ $component-active-bg: theme-color("primary");
404
425
 
405
426
  $caret-width: .3em;
406
427
 
@@ -452,7 +473,7 @@ $headings-margin-bottom: calc($spacer / 2);
452
473
  $headings-font-family: inherit;
453
474
  $headings-font-weight: 600;
454
475
  $headings-line-height: 1.2;
455
- $headings-color: $foe-primary;
476
+ $headings-color: $foe-accent;
456
477
 
457
478
  $display1-size: calc(60 / 16) * $font-size-base;
458
479
  $display2-size: calc(60 / 16) * $font-size-base;
@@ -465,8 +486,8 @@ $display3-weight: 300;
465
486
  $display4-weight: 300;
466
487
  $display-line-height: $headings-line-height;
467
488
 
468
- $lead-font-size: ($font-size-base * 1.25);
469
- $lead-font-weight: 300;
489
+ $lead-font-size: $font-size-base;
490
+ $lead-font-weight: bold;
470
491
 
471
492
  $small-font-size: 80%;
472
493