barbican-reset 2.34.0 → 2.36.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 (87) hide show
  1. package/README.md +26 -18
  2. package/components/card_display.vue +15 -15
  3. package/components/fluid_iframe.vue +8 -9
  4. package/package.json +4 -6
  5. package/patterns/scss/styles.scss +1 -1
  6. package/scss/_atomic.scss +40 -14
  7. package/scss/_br-alert.scss +10 -5
  8. package/scss/_br-button.scss +114 -68
  9. package/{helpers → scss/helpers}/mixins/_font.scss +1 -1
  10. package/{helpers → scss/helpers}/mixins/_headings.scss +2 -0
  11. package/scss/helpers/variables/colors/_brand.scss +96 -0
  12. package/scss/index.scss +3 -2
  13. package/fonts/SupremeLLWeb-Black.woff +0 -0
  14. package/fonts/SupremeLLWeb-Black.woff2 +0 -0
  15. package/fonts/SupremeLLWeb-BlackItalic.woff +0 -0
  16. package/fonts/SupremeLLWeb-BlackItalic.woff2 +0 -0
  17. package/fonts/SupremeLLWeb-Italic.woff +0 -0
  18. package/fonts/SupremeLLWeb-Italic.woff2 +0 -0
  19. package/fonts/SupremeLLWeb-Light.woff +0 -0
  20. package/fonts/SupremeLLWeb-Light.woff2 +0 -0
  21. package/fonts/SupremeLLWeb-LightItalic.woff +0 -0
  22. package/fonts/SupremeLLWeb-LightItalic.woff2 +0 -0
  23. package/fonts/SupremeLLWeb-Regular.woff +0 -0
  24. package/fonts/SupremeLLWeb-Regular.woff2 +0 -0
  25. package/helpers/variables/colors/_brand.scss +0 -79
  26. /package/{helpers → scss/helpers}/functions/index.scss +0 -0
  27. /package/{helpers → scss/helpers}/index.scss +0 -0
  28. /package/{helpers → scss/helpers}/mixins/_basket.scss +0 -0
  29. /package/{helpers → scss/helpers}/mixins/_br-alert.scss +0 -0
  30. /package/{helpers → scss/helpers}/mixins/_br-card.scss +0 -0
  31. /package/{helpers → scss/helpers}/mixins/_br-footer.scss +0 -0
  32. /package/{helpers → scss/helpers}/mixins/_br-form-password.scss +0 -0
  33. /package/{helpers → scss/helpers}/mixins/_br-form-row.scss +0 -0
  34. /package/{helpers → scss/helpers}/mixins/_br-form-update.scss +0 -0
  35. /package/{helpers → scss/helpers}/mixins/_br-skiplink.scss +0 -0
  36. /package/{helpers → scss/helpers}/mixins/_breakpoints.scss +0 -0
  37. /package/{helpers → scss/helpers}/mixins/_buttons.scss +0 -0
  38. /package/{helpers → scss/helpers}/mixins/_city-of-london.scss +0 -0
  39. /package/{helpers → scss/helpers}/mixins/_content.scss +0 -0
  40. /package/{helpers → scss/helpers}/mixins/_core.scss +0 -0
  41. /package/{helpers → scss/helpers}/mixins/_festival.scss +0 -0
  42. /package/{helpers → scss/helpers}/mixins/_focus.scss +0 -0
  43. /package/{helpers → scss/helpers}/mixins/_input.scss +0 -0
  44. /package/{helpers → scss/helpers}/mixins/_loading.scss +0 -0
  45. /package/{helpers → scss/helpers}/mixins/_table.scss +0 -0
  46. /package/{helpers → scss/helpers}/mixins/account/_orders.scss +0 -0
  47. /package/{helpers → scss/helpers}/mixins/buttons/_outline.scss +0 -0
  48. /package/{helpers → scss/helpers}/mixins/buttons/_setup.scss +0 -0
  49. /package/{helpers → scss/helpers}/mixins/buttons/_solid.scss +0 -0
  50. /package/{helpers → scss/helpers}/mixins/buttons/_spektrix.scss +0 -0
  51. /package/{helpers → scss/helpers}/mixins/drupal/_br-border-reset.scss +0 -0
  52. /package/{helpers → scss/helpers}/mixins/drupal/_br-column.scss +0 -0
  53. /package/{helpers → scss/helpers}/mixins/drupal/_br-container.scss +0 -0
  54. /package/{helpers → scss/helpers}/mixins/drupal/_br-inner.scss +0 -0
  55. /package/{helpers → scss/helpers}/mixins/drupal/_br-search-form.scss +0 -0
  56. /package/{helpers → scss/helpers}/mixins/drupal/_br-site-logo.scss +0 -0
  57. /package/{helpers → scss/helpers}/mixins/drupal/index.scss +0 -0
  58. /package/{helpers → scss/helpers}/mixins/index.scss +0 -0
  59. /package/{helpers → scss/helpers}/mixins/input/_checkbox.scss +0 -0
  60. /package/{helpers → scss/helpers}/mixins/input/_generic.scss +0 -0
  61. /package/{helpers → scss/helpers}/mixins/input/_radio.scss +0 -0
  62. /package/{helpers → scss/helpers}/mixins/input/_select.scss +0 -0
  63. /package/{helpers → scss/helpers}/mixins/input/_status.scss +0 -0
  64. /package/{helpers → scss/helpers}/mixins/input/_text.scss +0 -0
  65. /package/{helpers → scss/helpers}/mixins/table/_basket.scss +0 -0
  66. /package/{helpers → scss/helpers}/mixins/table/_details.scss +0 -0
  67. /package/{helpers → scss/helpers}/mixins/table/_etickets.scss +0 -0
  68. /package/{helpers → scss/helpers}/mixins/table/_gifts.scss +0 -0
  69. /package/{helpers → scss/helpers}/mixins/table/_membership.scss +0 -0
  70. /package/{helpers → scss/helpers}/mixins/table/_orders.scss +0 -0
  71. /package/{helpers → scss/helpers}/mixins/table/_preferences.scss +0 -0
  72. /package/{helpers → scss/helpers}/mixins/table/_resale.scss +0 -0
  73. /package/{helpers → scss/helpers}/mixins/table/_section.scss +0 -0
  74. /package/{helpers → scss/helpers}/mixins/table/_simple.scss +0 -0
  75. /package/{helpers → scss/helpers}/mixins/table/_tickets.scss +0 -0
  76. /package/{helpers → scss/helpers}/mixins/table/row/_disabled.scss +0 -0
  77. /package/{helpers → scss/helpers}/variables/_alerts.scss +0 -0
  78. /package/{helpers → scss/helpers}/variables/_columns.scss +0 -0
  79. /package/{helpers → scss/helpers}/variables/_layout.scss +0 -0
  80. /package/{helpers → scss/helpers}/variables/_typography.scss +0 -0
  81. /package/{helpers → scss/helpers}/variables/colors/_docs.scss +0 -0
  82. /package/{helpers → scss/helpers}/variables/colors/_grey.scss +0 -0
  83. /package/{helpers → scss/helpers}/variables/colors/_llf.scss +0 -0
  84. /package/{helpers → scss/helpers}/variables/colors/_status.scss +0 -0
  85. /package/{helpers → scss/helpers}/variables/colors/_wgp.scss +0 -0
  86. /package/{helpers → scss/helpers}/variables/colors/index.scss +0 -0
  87. /package/{helpers → scss/helpers}/variables/index.scss +0 -0
package/README.md CHANGED
@@ -8,10 +8,10 @@ The Barbican Reset is an NPM module created to maintain consistency between the
8
8
 
9
9
  1. Setup
10
10
  2. Component library
11
- 3. SCSS patterns
12
- 4. Pattern library
13
- 5. Font library
14
- 6. SVG library
11
+ 3. SCSS documentation
12
+ 4. JS documentation
13
+ 5. Pattern library
14
+ 6. Font library
15
15
 
16
16
  ## 1. Setup
17
17
 
@@ -31,17 +31,15 @@ Spektrix iframe development: `@import "../../node_modules/barbican-reset/scss/in
31
31
 
32
32
  #### SCSS Mixins
33
33
 
34
- Vue.js: `@import "~barbican-reset/helpers";`
34
+ Vue.js: `@import "~barbican-reset/scss/helpers";`
35
35
 
36
36
  > The Barbican ticketing site makes SCSS mixins globally available via the `vue.config.js` file
37
37
 
38
- Drupal: `@import "../node_modules/barbican-reset/helpers/index";`
39
-
40
- ... fonts
38
+ Drupal: `@import "../node_modules/barbican-reset/scss/helpers/index";`
41
39
 
42
40
  ## 2. Component library
43
41
 
44
- The component library is **only available to Vue.js** apps.
42
+ The component library is currently **only available to Vue.js** apps.
45
43
 
46
44
  > Many components are available globally within the Barbican ticketing app. Check the main.js file to see which components are currently available. These won't need an additional import statement.
47
45
 
@@ -92,11 +90,25 @@ The BR naming convention imitates the Bootstrap example. This format is useful f
92
90
  2. It forces components to use a two word syntax, which is the recommended format for custom components. For example, <br-header> instead of <header>, which avoids clashing with native HTML5 components.
93
91
  ```
94
92
 
95
- ## 3. SCSS patterns
93
+ ## 3. SCSS documentation
94
+
95
+ We use SassDoc to document our SCSS. Here's some useful commands for working with this documentation:
96
+
97
+ - To output the latest documentation and watch for changes to scss, run `gulp watch:css`
98
+ - To view the documentation, open the file `sassdoc/index.html` in your browser. You will need to refresh this page to view any additional changes that you make.
96
99
 
97
100
  Most components have corresponding SCSS classes (and mixins) which allow us to implement consistent styling across our various frontends, irrespective of their HTML structure.
98
101
 
99
- ## 4. Pattern library
102
+ ## 4. JS documentation
103
+
104
+ We use JSDoc to document our Javascript. Here's some useful commands for working with this documentation:
105
+
106
+ - To output the latest documentation and watch for changes to javascript, run `gulp watch:js`
107
+ - To manually output documentation using gulp, run `gulp doc:js`
108
+ - To manually output documentation using jsdoc, run `jsdoc gulpfile.js`
109
+ - To view the documentation, open the file `out/index.html` in your browser. You will need to refresh this page to view any additional changes that you make.
110
+
111
+ ## 5. Pattern library
100
112
 
101
113
  The Barbican Reset includes a pattern library. This provides a single source of truth for all the SCSS contained within and allows us to view a whole family of Barbican styles alongside each other.
102
114
 
@@ -136,12 +148,8 @@ Mixins are useful for printing repetitive code, such as loops to the page. The p
136
148
 
137
149
  The pattern library was created as a single source of truth for Barbican styles and components. Unfortunately the components are only compatible with Vue.js currently and so the HTML markup is duplicated.
138
150
 
139
- ## 5. Font library
140
-
141
- The Barbican Reset includes a SCSS mixin called `font-face` which constructs font paths...
142
-
143
- #### Future intent
151
+ ## 6. Font library
144
152
 
145
- To have this available on a url for assets... ie. assets.barbican.org.uk/supreme
153
+ The Barbican Reset includes a SCSS mixin called `font-face` which defaults font-face urls to `https://www.barbican.org.uk/themes/barb22/fonts/`. This means none of digital projects need to host additional font files.
146
154
 
147
- ## 6. SVG library
155
+ > If you do need to host fonts locally, you can overwrite the path parameter in the `font-face` mixin to point to a local asset.
@@ -6,7 +6,7 @@
6
6
  <live-icon :class="$style.svg" />
7
7
  </div>
8
8
  </div>
9
- <img :class="$style.image" :src="image">
9
+ <img :class="$style.image" :src="image" />
10
10
  <div v-if="expired" :class="$style.title">
11
11
  <h4>Expired</h4>
12
12
  </div>
@@ -14,7 +14,7 @@
14
14
  </template>
15
15
 
16
16
  <script>
17
- import { LiveIcon } from 'barbican-reset/icons/stream'
17
+ import { LiveIcon } from "barbican-reset/icons/stream";
18
18
  export default {
19
19
  name: "CardDisplay",
20
20
  components: { LiveIcon },
@@ -33,28 +33,31 @@ export default {
33
33
  },
34
34
  type: {
35
35
  type: String,
36
- default: 'concert',
36
+ default: "concert",
37
37
  },
38
38
  },
39
39
  computed: {
40
40
  styleComponent() {
41
41
  const style = this.$style;
42
42
  let output = [style.component];
43
- if (this.hero) { output.push(style.hero); }
43
+ if (this.hero) {
44
+ output.push(style.hero);
45
+ }
44
46
  return output;
45
47
  },
46
48
  styleButton() {
47
49
  const style = this.$style;
48
50
  let output = [style.button];
49
- if (this.hero) { output.push(style.hero); }
51
+ if (this.hero) {
52
+ output.push(style.hero);
53
+ }
50
54
  return output;
51
- }
52
- }
53
- }
55
+ },
56
+ },
57
+ };
54
58
  </script>
55
59
 
56
60
  <style lang="scss" scoped>
57
-
58
61
  .btn.btn-secondary {
59
62
  &:not(.hero) {
60
63
  border-radius: 50%;
@@ -68,12 +71,10 @@ export default {
68
71
  gap: 0.5rem;
69
72
  }
70
73
  }
71
-
72
74
  </style>
73
75
 
74
76
  <style lang="scss" module>
75
-
76
- @import "../helpers";
77
+ @import "../scss/helpers";
77
78
 
78
79
  .svg {
79
80
  fill: white;
@@ -112,12 +113,11 @@ export default {
112
113
  right: 1.5rem;
113
114
  top: 1.5rem;
114
115
  }
115
-
116
+
116
117
  .title {
117
118
  h4 {
118
119
  font-size: $h2-font-size;
119
120
  }
120
121
  }
121
122
  }
122
-
123
- </style>
123
+ </style>
@@ -5,26 +5,26 @@
5
5
  allowfullscreen
6
6
  frameborder="0"
7
7
  height="100%"
8
- width="100%"
9
- :src="src" />
8
+ width="100%"
9
+ :src="src"
10
+ />
10
11
  </div>
11
12
  </template>
12
13
 
13
14
  <script>
14
15
  export default {
15
- name: 'FluidIframe',
16
+ name: "FluidIframe",
16
17
  props: {
17
18
  src: {
18
19
  type: String,
19
- required: true
20
- }
21
- }
20
+ required: true,
21
+ },
22
+ },
22
23
  };
23
24
  </script>
24
25
 
25
26
  <style lang="scss" module>
26
-
27
- @import "../helpers";
27
+ @import "../scss/helpers";
28
28
 
29
29
  .component {
30
30
  border-radius: $border-radius-lg;
@@ -37,5 +37,4 @@ export default {
37
37
  position: absolute;
38
38
  @include inset(0);
39
39
  }
40
-
41
40
  </style>
package/package.json CHANGED
@@ -64,15 +64,14 @@
64
64
  "gulp-sass": "^5.0.0",
65
65
  "gulp-sourcemaps": "^3.0.0",
66
66
  "gulp-uglify": "^3.0.2",
67
+ "js-doc": "^0.5.0",
67
68
  "luxon": "^3.2.1",
68
69
  "node-sass-tilde-importer": "^1.0.2",
69
70
  "nodemon": "^3.1.0",
70
- "placeholder-loading": "^0.4.0",
71
71
  "pug": "^3.0.2",
72
72
  "sass": "^1.41.0",
73
- "save-dev": "^0.0.1-security",
74
- "serve-favicon": "^2.5.0",
75
- "vue-slick-carousel": "^1.0.6"
73
+ "sassdoc": "^2.7.4",
74
+ "serve-favicon": "^2.5.0"
76
75
  },
77
76
  "devDependencies": {
78
77
  "bootstrap": "^5.1.3"
@@ -83,7 +82,6 @@
83
82
  "components/**/*",
84
83
  "dist/**/*",
85
84
  "fonts/*",
86
- "helpers/**/*",
87
85
  "icons/**/*",
88
86
  "patterns/**/*",
89
87
  "logos/*",
@@ -106,5 +104,5 @@
106
104
  "build:patterns": "cd patterns && rm -rf html && pug views --out html"
107
105
  },
108
106
  "style": "dist/css/barbican-reset.css",
109
- "version": "2.34.0"
107
+ "version": "2.36.0"
110
108
  }
@@ -2,7 +2,7 @@
2
2
  @import "../../node_modules/bootstrap/scss/variables";
3
3
  @import "../../node_modules/bootstrap/scss/mixins";
4
4
 
5
- @import "../../helpers/index";
5
+ @import "../../scss/helpers/index";
6
6
 
7
7
  @import "../../scss/br-alert";
8
8
  @import "../../scss/br-button";
package/scss/_atomic.scss CHANGED
@@ -3,32 +3,57 @@ $text-aligns: 'left', 'center', 'right';
3
3
  $margins05: 'margin-top', 'margin-bottom', 'margin-right', 'margin-left';
4
4
  $paddings05: 'padding-top', 'padding-bottom', 'padding-right', 'padding-left';
5
5
 
6
- @each $gap in $gaps {
7
- @for $i from 1 to 5 {
8
- .#{$gap}-#{$i} {
9
- #{$gap}: 1rem * $i;
6
+ /// @group Atomic
7
+ /// Generator for gap classes. Creates 5 variations
8
+ /// @example .margin-top-1, .margin-top-2, .margin-top-3, .margin-top-4, .margin-top-5
9
+ @mixin printGapClasses {
10
+ @each $gap in $gaps {
11
+ @for $i from 1 to 5 {
12
+ .#{$gap}-#{$i} {
13
+ #{$gap}: 1rem * $i;
14
+ }
10
15
  }
11
16
  }
12
17
  }
13
18
 
14
- @each $align in $text-aligns {
15
- .text-align-#{$align} {
16
- text-align: #{$align};
19
+ /// @group Atomic
20
+ /// Generator for text-align classes. Creates 3 variations
21
+ /// @example .text-align-left, .text-align-center, .text-align-right
22
+ @mixin printTextAlignClasses {
23
+ @each $align in $text-aligns {
24
+ .text-align-#{$align} {
25
+ text-align: #{$align};
26
+ }
17
27
  }
18
28
  }
19
29
 
20
- @each $margin in $margins05 {
21
- .#{$margin}-05 {
22
- #{$margin}: 0.5rem;
30
+ /// @group Atomic
31
+ /// Generator for margin half classes. Creates 4 variations
32
+ /// @example .margin-top-05, .margin-bottom-05, .margin-right-05, .margin-left-05
33
+ @mixin printMarginClasses {
34
+ @each $margin in $margins05 {
35
+ .#{$margin}-05 {
36
+ #{$margin}: 0.5rem;
37
+ }
23
38
  }
24
39
  }
25
40
 
26
- @each $padding in $paddings05 {
27
- .#{$padding}-05 {
28
- #{$padding}: 0.5rem;
41
+ /// @group Atomic
42
+ /// Generator for padding half classes. Creates 4 variations
43
+ /// @example .padding-top-05, .padding-bottom-05, .padding-right-05, .padding-left-05
44
+ @mixin printPaddingClasses {
45
+ @each $padding in $paddings05 {
46
+ .#{$padding}-05 {
47
+ #{$padding}: 0.5rem;
48
+ }
29
49
  }
30
50
  }
31
51
 
52
+ @include printGapClasses;
53
+ @include printTextAlignClasses;
54
+ @include printMarginClasses;
55
+ @include printPaddingClasses;
56
+
32
57
  .font-weight-700 {
33
58
  @include fontfamily-black;
34
59
  }
@@ -91,6 +116,7 @@ $paddings05: 'padding-top', 'padding-bottom', 'padding-right', 'padding-left';
91
116
  min-width: 3rem;
92
117
  }
93
118
 
119
+ /// Class for visually hiding markup, while still allowing screen readers to parse the content
94
120
  .sr-only {
95
121
  @include sr-only;
96
- }
122
+ }
@@ -1,4 +1,6 @@
1
-
1
+ /// @group Components
2
+ /// BrAlert component class
3
+ /// @example .br-alert.center .wrap.inline.error
2
4
  .br-alert {
3
5
  @include br-alert--setup;
4
6
 
@@ -10,14 +12,16 @@
10
12
  @include br-alert-wrap--colors($neutral_wrap...);
11
13
  @include br-alert-wrap--setup;
12
14
 
13
- .btn.btn-link, a {
15
+ .btn.btn-link,
16
+ a {
14
17
  @include br-alert-link($neutral_focus...);
15
18
  }
16
19
 
17
20
  &.error {
18
21
  @include br-alert-wrap--colors($error_wrap...);
19
22
 
20
- .btn.btn-link, a {
23
+ .btn.btn-link,
24
+ a {
21
25
  @include br-alert-link($error_focus...);
22
26
  }
23
27
  }
@@ -25,7 +29,8 @@
25
29
  &.success {
26
30
  @include br-alert-wrap--colors($success_wrap...);
27
31
 
28
- .btn.btn-link, a {
32
+ .btn.btn-link,
33
+ a {
29
34
  @include br-alert-link($success_focus...);
30
35
  }
31
36
  }
@@ -41,7 +46,7 @@
41
46
  p {
42
47
  margin-bottom: 0;
43
48
 
44
- + p {
49
+ +p {
45
50
  margin-top: 1rem;
46
51
  }
47
52
  }
@@ -1,74 +1,120 @@
1
+ /// Button component setup class.
2
+ /// Used in combination with a button style class
3
+ /// @group Buttons
4
+ /// @example .btn.btn-primary
1
5
  .btn {
2
6
  @include setup-button;
7
+ }
8
+
9
+ /// Primary button.
10
+ /// Defaults to solid orange. Borders orange on focus.
11
+ /// @group Buttons
12
+ .btn.btn-primary {
13
+ @include btn-primary;
14
+ }
15
+
16
+ /// Primary outline button.
17
+ /// Defaults to orange outline. Fills orange on focus
18
+ /// @group Buttons
19
+ .btn.btn-outline-primary {
20
+ @include btn-outline-primary;
21
+ }
22
+
23
+ /// Primary outline header button.
24
+ /// Defaults to white outline. Fills white on focus
25
+ /// @group Buttons
26
+ .btn.btn-outline-header {
27
+ @include btn-outline-header;
28
+ }
29
+
30
+ /// Info button.
31
+ /// Defaults to solid blue. Borders blue on focus.
32
+ /// @group Buttons
33
+ .btn.btn-info {
34
+ @include btn-info;
35
+ }
36
+
37
+ /// Primary outline info button.
38
+ /// Defaults to blue outline. Fills blue on focus
39
+ /// @group Buttons
40
+ .btn.btn-outline-info {
41
+ @include btn-outline-info;
42
+ }
43
+
44
+ /// Secondary button.
45
+ /// Defaults to solid grey. Borders grey on focus.
46
+ /// @group Buttons
47
+ .btn.btn-secondary {
48
+ @include btn-secondary;
49
+ }
50
+
51
+ /// Primary outline info button.
52
+ /// Defaults to grey outline. Fills grey on focus
53
+ /// @group Buttons
54
+ .btn.btn-outline-secondary {
55
+ @include btn-outline-secondary;
56
+ }
57
+
58
+ /// Input edit button.
59
+ /// Semi circular control for lockable input fields.
60
+ /// Defaults to grey outline. Fills grey on focus.
61
+ /// @group Buttons
62
+ .btn.btn-input-edit {
63
+ @include btn-input-edit;
64
+ }
65
+
66
+ /// Remove button.
67
+ /// Used only by StreamDonation.vue component. Could be deprecated.
68
+ /// Defaults to slim solid grey. Borders grey on focus.
69
+ /// @group Buttons
70
+ .btn.btn-remove {
71
+ @include btn-remove;
72
+ }
73
+
74
+ /// Link button.
75
+ /// Imitates the appearance of an anchor link.
76
+ /// Defaults to transparent fill. Fills grey on focus.
77
+ /// @group Buttons
78
+ .btn.btn-link {
79
+ @include btn-link;
80
+ }
81
+
82
+ /// Video help button.
83
+ /// Apparently no longer used. Could be deprecated.
84
+ /// @group Buttons
85
+ .btn.btn-video-help {
86
+ @include btn-video-help;
87
+ }
88
+
89
+ /// Exit button.
90
+ /// Circular close button. Used in the BrAlert component.
91
+ /// @group Buttons
92
+ .btn.btn-exit {
93
+ @include btn-exit;
94
+ }
95
+
96
+ /// Remove ticket button.
97
+ /// Used in the basket to remove items or donations.
98
+ /// @group Buttons
99
+ .btn.btn-remove-ticket {
100
+ @include btn-remove-ticket;
101
+ }
102
+
103
+ /// Remove gift button.
104
+ /// Used in the basket to remove items or donations.
105
+ /// @group Buttons
106
+ .btn.btn-remove-gift {
107
+ @include btn-remove-gift;
108
+ }
109
+
110
+ /// Membership card button.
111
+ /// Used for membership renewals.
112
+ /// @group Buttons
113
+ .btn.btn-membership-card {
114
+ @include btn-membership-card;
115
+ }
3
116
 
4
- &.btn-primary {
5
- // solid orange
6
- @include btn-primary;
7
- }
8
-
9
- &.btn-outline-primary {
10
- // orange outline, fill on focus
11
- @include btn-outline-primary;
12
- }
13
-
14
- &.btn-outline-header {
15
- // orange outline, fill on focus
16
- @include btn-outline-header;
17
- }
18
-
19
- &.btn-info {
20
- // solid blue
21
- @include btn-info;
22
- }
23
-
24
- &.btn-outline-info {
25
- // blue outline, fill on focus
26
- @include btn-outline-info;
27
- }
28
-
29
- &.btn-secondary {
30
- // solid grey
31
- @include btn-secondary;
32
- }
33
-
34
- &.btn-outline-secondary {
35
- // grey outline, fill on focus
36
- @include btn-outline-secondary;
37
- }
38
-
39
- &.btn-input-edit {
40
- @include btn-input-edit;
41
- }
42
-
43
- &.btn-remove {
44
- // solid grey, slim
45
- @include btn-remove;
46
- }
47
-
48
- &.btn-link {
49
- @include btn-link;
50
- }
51
-
52
- &.btn-video-help {
53
- @include btn-video-help;
54
- }
55
-
56
- &.btn-exit {
57
- @include btn-exit;
58
- }
59
-
60
- &.btn-remove-ticket {
61
- @include btn-remove-ticket;
62
- }
63
-
64
- &.btn-remove-gift {
65
- @include btn-remove-gift;
66
- }
67
-
68
- &.btn-membership-card {
69
- @include btn-membership-card;
70
- }
71
-
117
+ .btn {
72
118
  &.btn-video-login {
73
119
  @include btn-video-login;
74
120
  }
@@ -1,4 +1,4 @@
1
- @mixin font-face($name: "SupremeLLWeb", $path: "/fonts/") {
1
+ @mixin font-face($name: "SupremeLLWeb", $path: "https://www.barbican.org.uk/themes/barb22/fonts/") {
2
2
  @font-face {
3
3
  font-family: "Supreme-Light";
4
4
  src: url("#{$path}#{$name}-Light.woff") format("woff"),
@@ -1,3 +1,5 @@
1
+ /// Generic margin/font weight reset for title headings
2
+ /// @param {String} $margin [0] - pixel value
1
3
  @mixin br-heading($margin: 0) {
2
4
  @include fontfamily-black;
3
5
  margin: $margin;
@@ -0,0 +1,96 @@
1
+ /// $c-brand-art
2
+ $c-brand-art: hsl(329, 100%, 45%);
3
+ /// $c-brand-cinema
4
+ $c-brand-cinema: hsl(126, 62%, 33%);
5
+ /// $c-brand-classical
6
+ $c-brand-classical: hsl(38, 53%, 38%);
7
+ /// $c-brand-contemporary
8
+ $c-brand-contemporary: hsl(254, 44%, 33%);
9
+ $c-brand-generic: hsl(21, 100%, 41%);
10
+ $c-brand-membership: hsl(217, 72%, 53%);
11
+ $c-brand-programme: $c-grey-l21;
12
+ $c-brand-shop: hsl(168, 75%, 30%);
13
+ $c-brand-talks: hsl(214, 30%, 49%);
14
+ $c-brand-theatre: hsl(192, 99%, 31%);
15
+
16
+ $c-patron: $c-grey-l44;
17
+ $c-patron-light: hsl(0, 0%, 60%);
18
+ $c-principle: $c-brand-classical;
19
+ $c-principle-light: hsl(38, 53%, 53%);
20
+
21
+ /// see map-merge for example usage. talks--workshops is deprecated, use talks--events instead.
22
+ $setup: (
23
+ contemporary-music: $c-brand-contemporary,
24
+ membership--support: $c-brand-membership,
25
+ tours--public-spaces: $c-brand-generic,
26
+ classical-music: $c-brand-classical,
27
+ talks--workshops: $c-brand-talks,
28
+ theatre--dance: $c-brand-theatre,
29
+ talks--events: $c-brand-talks,
30
+ art--design: $c-brand-art,
31
+ generic: $c-brand-generic,
32
+ library: $c-brand-generic,
33
+ cinema: $c-brand-cinema,
34
+ hire: $c-brand-generic,
35
+ programme: $c-brand-programme,
36
+ shop: $c-brand-shop,
37
+ );
38
+
39
+ /// brands map will contain a shade map for each color variable
40
+ $brands: ();
41
+
42
+ /// map-brands automates the process of creating tints/shades for individual colors.
43
+ @function map-brands($color) {
44
+ $map: (
45
+ shade-65: shade($color, 65%),
46
+ shade-20: shade($color, 20%),
47
+ shade-10: shade($color, 10%),
48
+ base: $color,
49
+ tint-40: tint($color, 40%),
50
+ tint-70: tint($color, 70%),
51
+ tint-85: tint($color, 85%),
52
+ tint-95: tint($color, 95%),
53
+ tint-98: tint($color, 98%),
54
+ );
55
+ @return $map;
56
+ }
57
+
58
+ /// this process loops through the $setup map and creates a mappable value for each item, then merges the item into the $brands map
59
+ @each $key, $value in $setup {
60
+ $map: ();
61
+ $map: map-merge($map, ($key: map-brands($value)));
62
+ $brands: map-merge($brands, $map);
63
+ }
64
+
65
+ /// utility function for referencing a color variant from the brands map
66
+ /// @param {Map} $name - color reference from the $setup map
67
+ /// @param {String} $variant - shade reference from the map-brands function
68
+ @function brandColor($name, $variant: base) {
69
+ @return map-get(map-get($brands, $name), $variant);
70
+ }
71
+
72
+ $c-background-alt: brandColor(generic, tint-95);
73
+
74
+ /// @deprecated $c-brand-cinema-dark
75
+ $c-brand-cinema-dark: brandColor(cinema, shade-20);
76
+ /// @deprecated $c-brand-shop-light
77
+ $c-brand-shop-light: brandColor(shop, tint-85);
78
+ /// @deprecated $c-brand-shop-dark
79
+ $c-brand-shop-dark: brandColor(shop, shade-20);
80
+
81
+ /// @deprecated $c-brand-faint?
82
+ $c-brand-generic-s60-l99: brandColor(generic, tint-95);
83
+ /// @deprecated $c-brand-light?
84
+ $c-brand-generic-s100-l95: brandColor(generic, tint-85);
85
+ /// @deprecated $c-brand-shade?
86
+ $c-brand-generic-s50-l90: brandColor(generic, tint-70);
87
+ /// @deprecated $c-brand-dark?
88
+ $c-brand-generic-s100-l38: brandColor(generic, shade-10);
89
+ /// @deprecated $c-brand-x-dark?
90
+ $c-brand-generic-s100-l15: brandColor(generic, shade-65);
91
+ /// @deprecated $c-brand-classical-light
92
+ $c-brand-classical-light: brandColor(classical-music, tint-95);
93
+ /// @deprecated $c-brand-classical-dark
94
+ $c-brand-classical-dark: brandColor(classical-music, shade-20);
95
+
96
+ $c-brand-membership-dark: hsl(223, 87%, 21%);
package/scss/index.scss CHANGED
@@ -1,7 +1,8 @@
1
1
  @import "node_modules/bootstrap/scss/functions";
2
2
  @import "node_modules/bootstrap/scss/variables";
3
3
  @import "node_modules/bootstrap/scss/mixins";
4
- @import "../helpers/index";
4
+
5
+ @import "helpers/index";
5
6
 
6
7
  @include font-face;
7
8
 
@@ -105,8 +106,8 @@ p+p {
105
106
  margin-top: 1rem;
106
107
  }
107
108
 
109
+ /// b tag in use on iframes
108
110
  strong,
109
111
  b {
110
- // b tag in use on iframes
111
112
  @include fontfamily-black;
112
113
  }
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
@@ -1,79 +0,0 @@
1
- $c-brand-art: hsl(329, 100%, 45%);
2
- $c-brand-cinema: hsl(126, 62%, 33%);
3
- $c-brand-classical: hsl(38, 53%, 38%);
4
- $c-brand-contemporary: hsl(254, 44%, 33%);
5
- $c-brand-generic: hsl(21, 100%, 41%);
6
- $c-brand-membership: hsl(217, 72%, 53%);
7
- $c-brand-programme: $c-grey-l21;
8
- $c-brand-shop: hsl(168, 75%, 30%);
9
- $c-brand-talks: hsl(214, 30%, 49%);
10
- $c-brand-theatre: hsl(192, 99%, 31%);
11
-
12
- $c-patron: $c-grey-l44;
13
- $c-patron-light: hsl(0, 0%, 60%);
14
- $c-principle: $c-brand-classical;
15
- $c-principle-light: hsl(38, 53%, 53%);
16
-
17
- $setup: (
18
- contemporary-music: $c-brand-contemporary,
19
- membership--support: $c-brand-membership,
20
- tours--public-spaces: $c-brand-generic,
21
- classical-music: $c-brand-classical,
22
- talks--workshops: $c-brand-talks,
23
- // deprecated
24
- theatre--dance: $c-brand-theatre,
25
- talks--events: $c-brand-talks,
26
- art--design: $c-brand-art,
27
- generic: $c-brand-generic,
28
- library: $c-brand-generic,
29
- cinema: $c-brand-cinema,
30
- hire: $c-brand-generic,
31
- programme: $c-brand-programme,
32
- shop: $c-brand-shop,
33
- );
34
-
35
- $brands: (
36
- );
37
-
38
- @function map-brands($color) {
39
- $map: (
40
- shade-65: shade($color, 65%),
41
- shade-20: shade($color, 20%),
42
- shade-10: shade($color, 10%),
43
- base: $color,
44
- tint-40: tint($color, 40%),
45
- tint-70: tint($color, 70%),
46
- tint-85: tint($color, 85%),
47
- tint-95: tint($color, 95%),
48
- tint-98: tint($color, 98%),
49
- );
50
- @return $map;
51
- }
52
-
53
- @each $key, $value in $setup {
54
- $map: (
55
- );
56
- $map: map-merge($map,
57
- ($key: map-brands($value),
58
- ));
59
- $brands: map-merge($brands, $map);
60
- }
61
-
62
- @function brandColor($name, $variant: base) {
63
- @return map-get(map-get($brands, $name), $variant);
64
- }
65
-
66
- $c-background-alt: brandColor(generic, tint-95);
67
-
68
- $c-brand-cinema-dark: brandColor(cinema, shade-20); // deprecated
69
- $c-brand-shop-light: brandColor(shop, tint-85); // deprecated
70
- $c-brand-shop-dark: brandColor(shop, shade-20); // deprecated
71
- $c-brand-generic-s60-l99: brandColor(generic, tint-95); // faint deprecated
72
- $c-brand-generic-s100-l95: brandColor(generic, tint-85); // light deprecated
73
- $c-brand-generic-s50-l90: brandColor(generic, tint-70); // shade deprecated
74
- $c-brand-generic-s100-l38: brandColor(generic, shade-10); // dark deprecated
75
- $c-brand-generic-s100-l15: brandColor(generic, shade-65); // x-dark deprecated
76
-
77
- $c-brand-classical-light: brandColor(classical-music, tint-95); // deprecated
78
- $c-brand-classical-dark: brandColor(classical-music, shade-20); // deprecated
79
- $c-brand-membership-dark: hsl(223, 87%, 21%);
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes