@linzjs/lui 10.2.2 → 10.3.2

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 (97) hide show
  1. package/CHANGELOG.md +289 -767
  2. package/README.md +16 -11
  3. package/dist/assets/icons/account_circle.svg +1 -0
  4. package/dist/assets/icons/add_circle.svg +1 -0
  5. package/dist/assets/icons/add_circle_outline.svg +1 -0
  6. package/dist/assets/icons/arrow_back.svg +1 -0
  7. package/dist/assets/icons/arrow_back_ios.svg +1 -0
  8. package/dist/assets/icons/arrow_drop_down.svg +1 -0
  9. package/dist/assets/icons/arrow_drop_up.svg +1 -0
  10. package/dist/assets/icons/arrow_forward_ios.svg +1 -0
  11. package/dist/assets/icons/attachment.svg +1 -0
  12. package/dist/assets/icons/border_color.svg +1 -0
  13. package/dist/assets/icons/check.svg +1 -0
  14. package/dist/assets/icons/check_circle.svg +1 -0
  15. package/dist/assets/icons/check_circle_outline.svg +1 -0
  16. package/dist/assets/icons/clear.svg +1 -0
  17. package/dist/assets/icons/corporate_fare.svg +1 -0
  18. package/dist/assets/icons/create.svg +1 -0
  19. package/dist/assets/icons/error.svg +1 -0
  20. package/dist/assets/icons/error_outline.svg +1 -0
  21. package/dist/assets/icons/expand_less.svg +1 -0
  22. package/dist/assets/icons/expand_more.svg +1 -0
  23. package/dist/assets/icons/filter_list.svg +1 -0
  24. package/dist/assets/icons/flag.svg +1 -0
  25. package/dist/assets/icons/forward.svg +1 -0
  26. package/dist/assets/icons/insert_invitation.svg +1 -0
  27. package/dist/assets/icons/insert_photo.svg +1 -0
  28. package/dist/assets/icons/keyboard_arrow_down.svg +1 -0
  29. package/dist/assets/icons/keyboard_arrow_left.svg +1 -0
  30. package/dist/assets/icons/keyboard_arrow_right.svg +1 -0
  31. package/dist/assets/icons/keyboard_arrow_up.svg +1 -0
  32. package/dist/assets/icons/navigate_before.svg +1 -0
  33. package/dist/assets/icons/navigate_next.svg +1 -0
  34. package/dist/assets/icons/people_outline.svg +1 -0
  35. package/dist/assets/icons/person.svg +1 -0
  36. package/dist/assets/icons/person_add.svg +1 -0
  37. package/dist/assets/icons/remove_circle.svg +1 -0
  38. package/dist/assets/icons/remove_circle_outline.svg +1 -0
  39. package/dist/assets/icons/send.svg +1 -0
  40. package/dist/assets/icons/view_week.svg +1 -0
  41. package/dist/assets/icons/warning.svg +1 -0
  42. package/dist/assets/svg-content.d.ts +39 -1
  43. package/dist/assets/svg-content.tsx +231 -7
  44. package/dist/components/LuiMenu/LuiMenu.d.ts +3 -0
  45. package/dist/components/common/Icons.d.ts +53 -3
  46. package/dist/govNZ-DS/FlexColumn.scss +1 -1
  47. package/dist/govNZ-DS/FlexContainer.scss +1 -1
  48. package/dist/govNZ-DS/FlexRow.scss +1 -1
  49. package/dist/govNZ-DS/FooterStandard.scss +1 -1
  50. package/dist/govNZ-DS/FooterWrapper.scss +1 -1
  51. package/dist/govNZ-DS/_index.scss +1 -1
  52. package/dist/lui.cjs.development.js +16 -19
  53. package/dist/lui.cjs.development.js.map +1 -1
  54. package/dist/lui.cjs.production.min.js +1 -1
  55. package/dist/lui.cjs.production.min.js.map +1 -1
  56. package/dist/lui.css +357 -376
  57. package/dist/lui.css.map +1 -1
  58. package/dist/lui.esm.js +16 -19
  59. package/dist/lui.esm.js.map +1 -1
  60. package/dist/scss/Components/ContextMenu/context-menu.scss +1 -1
  61. package/dist/scss/Components/ExpandingSection/expanding-section.scss +0 -1
  62. package/dist/scss/Components/Footer/footer.scss +6 -6
  63. package/dist/scss/Components/Header/header.scss +7 -5
  64. package/dist/scss/Components/HelpSection/help-section.scss +2 -2
  65. package/dist/scss/Components/LOLCommonMenu/LOLAuthorisedLink.scss +0 -1
  66. package/dist/scss/Components/LOLCommonMenu/LOLFirmSwitcherMenu.scss +1 -1
  67. package/dist/scss/Components/LuiFilterContainer/LuiFilterContainer.scss +5 -0
  68. package/dist/scss/Components/Menu/menu.scss +8 -0
  69. package/dist/scss/Components/Messaging/messaging.scss +8 -8
  70. package/dist/scss/Components/Modal/modal.scss +6 -6
  71. package/dist/scss/Components/Notifications/notifications.scss +5 -5
  72. package/dist/scss/Elements/Buttons/buttons.scss +16 -17
  73. package/dist/scss/Elements/Forms/FormComponents/FormSpacing.scss +7 -7
  74. package/dist/scss/Elements/Forms/FormComponents/Inputs.scss +0 -5
  75. package/dist/scss/Elements/Forms/FormComponents/RadiosCheckboxes.scss +92 -103
  76. package/dist/scss/Elements/Forms/forms.scss +14 -32
  77. package/dist/scss/Elements/Tables/tables.scss +1 -1
  78. package/dist/scss/Foundation/Utilities/AspectRatio.scss +1 -1
  79. package/dist/scss/Foundation/Utilities/Borders.scss +1 -1
  80. package/dist/scss/Foundation/Utilities/Breakpoint.scss +19 -7
  81. package/dist/scss/Foundation/Utilities/DLColumns.scss +21 -6
  82. package/dist/scss/Foundation/Utilities/Ease.scss +1 -8
  83. package/dist/scss/Foundation/Utilities/FitMedia.scss +2 -1
  84. package/dist/scss/Foundation/Utilities/FluidType.scss +28 -6
  85. package/dist/scss/Foundation/Utilities/Placeholder.scss +12 -5
  86. package/dist/scss/Foundation/Variables/FontVars.scss +7 -7
  87. package/dist/scss/Foundation/Variables/FormVars.scss +8 -8
  88. package/dist/scss/Foundation/Variables/SpacingVars.scss +17 -10
  89. package/dist/scss/Global/GenericElements/Lists.scss +2 -2
  90. package/dist/scss/Global/GenericElements/Typography.scss +5 -5
  91. package/dist/scss/Global/_index.scss +1 -1
  92. package/dist/scss/Vendor/_index.scss +1 -1
  93. package/dist/scss/Vendor/naturalize.scss +32 -39
  94. package/dist/scss/{Global → Vendor}/print.scss +0 -0
  95. package/dist/scss/base.scss +2 -1
  96. package/package.json +4 -1
  97. package/dist/assets/icons/icon-cart.svg +0 -1
@@ -35,7 +35,8 @@
35
35
  transform: translate(-50%, -50%);
36
36
  }
37
37
 
38
- > img { // don't stretch the image
38
+ > img {
39
+ // don't stretch the image
39
40
  min-width: 100%;
40
41
  min-height: 100%;
41
42
  // Set up proportionate scaling
@@ -20,7 +20,12 @@
20
20
  @return math.div($value, $value * 0 + 1);
21
21
  }
22
22
 
23
- @mixin fluidType--size($min-size, $max-size, $min-breakpoint: 1px, $max-breakpoint) {
23
+ @mixin fluidType--size(
24
+ $min-size,
25
+ $max-size,
26
+ $min-breakpoint: 1px,
27
+ $max-breakpoint
28
+ ) {
24
29
  $u1: unit($min-breakpoint);
25
30
  $u2: unit($max-breakpoint);
26
31
  $u3: unit($min-size);
@@ -28,10 +33,16 @@
28
33
 
29
34
  @if $u1 == $u2 and $u1 == $u3 and $u1 == $u4 {
30
35
  & {
31
-
32
36
  font-size: $min-size;
33
37
  @media screen and (min-width: $min-breakpoint) {
34
- font-size: calc(#{$min-size} + #{strip-unit($max-size - $min-size)} * ((100vw - #{$min-breakpoint}) / #{strip-unit($max-breakpoint - $min-breakpoint)}));
38
+ font-size: calc(
39
+ #{$min-size} + #{strip-unit($max-size - $min-size)} *
40
+ (
41
+ (100vw - #{$min-breakpoint}) / #{strip-unit(
42
+ $max-breakpoint - $min-breakpoint
43
+ )}
44
+ )
45
+ );
35
46
  }
36
47
 
37
48
  @media screen and (min-width: $max-breakpoint) {
@@ -41,7 +52,12 @@
41
52
  }
42
53
  }
43
54
 
44
- @mixin fluidType--lineHeight($min-size: 1px, $max-size, $min-breakpoint: 1px, $max-breakpoint) {
55
+ @mixin fluidType--lineHeight(
56
+ $min-size: 1px,
57
+ $max-size,
58
+ $min-breakpoint: 1px,
59
+ $max-breakpoint
60
+ ) {
45
61
  $u1: unit($min-size);
46
62
  $u2: unit($max-size);
47
63
  $u3: unit($min-breakpoint);
@@ -49,10 +65,16 @@
49
65
 
50
66
  @if $u1 == $u2 and $u1 == $u3 and $u1 == $u4 {
51
67
  & {
52
-
53
68
  line-height: $min-size;
54
69
  @media screen and (min-width: $min-breakpoint) {
55
- line-height: calc(#{$min-size} + #{strip-unit($max-size - $min-size)} * ((100vw - #{$min-breakpoint}) / #{strip-unit($max-breakpoint - $min-breakpoint)}));
70
+ line-height: calc(
71
+ #{$min-size} + #{strip-unit($max-size - $min-size)} *
72
+ (
73
+ (100vw - #{$min-breakpoint}) / #{strip-unit(
74
+ $max-breakpoint - $min-breakpoint
75
+ )}
76
+ )
77
+ );
56
78
  }
57
79
 
58
80
  @media screen and (min-width: $max-breakpoint) {
@@ -12,25 +12,32 @@
12
12
  // }
13
13
  // }
14
14
 
15
-
16
15
  @mixin placeholder($color: null) {
17
16
  &::-webkit-input-placeholder {
18
- @if $color { color: $color; }
17
+ @if $color {
18
+ color: $color;
19
+ }
19
20
  @content;
20
21
  }
21
22
 
22
23
  &::-moz-placeholder {
23
- @if $color { color: $color; }
24
+ @if $color {
25
+ color: $color;
26
+ }
24
27
  @content;
25
28
  }
26
29
 
27
30
  &:-moz-placeholder {
28
- @if $color { color: $color; }
31
+ @if $color {
32
+ color: $color;
33
+ }
29
34
  @content;
30
35
  }
31
36
 
32
37
  &:-ms-input-placeholder {
33
- @if $color { color: $color; }
38
+ @if $color {
39
+ color: $color;
40
+ }
34
41
  @content;
35
42
  }
36
43
  }
@@ -7,11 +7,11 @@ $base-font-size: 16px;
7
7
  $base-font-weight: 300;
8
8
 
9
9
  //Adjust these to your font – don't need all of them if you don't need
10
- $base-font--light: "OpenSans Light";
11
- $base-font--regular: "OpenSans Regular";
12
- $base-font--italic: "OpenSans Italic";
13
- $base-font--bold: "OpenSans Bold";
14
- $base-font--semibold: "OpenSans SemiBold";
10
+ $base-font--light: 'OpenSans Light';
11
+ $base-font--regular: 'OpenSans Regular';
12
+ $base-font--italic: 'OpenSans Italic';
13
+ $base-font--bold: 'OpenSans Bold';
14
+ $base-font--semibold: 'OpenSans SemiBold';
15
15
  $base-font--header: $base-font--light;
16
16
 
17
17
  // =====================
@@ -67,6 +67,6 @@ $base: 16 * ($base-font-size * 0.01);
67
67
  $leading: $base * $base-line-height;
68
68
 
69
69
  @mixin type-margin-bottom($number) {
70
- margin-bottom: #{$number * $leading + "px"};
71
- margin-bottom: #{$number * $line-height + "rem"};
70
+ margin-bottom: #{$number * $leading + 'px'};
71
+ margin-bottom: #{$number * $line-height + 'rem'};
72
72
  }
@@ -3,16 +3,16 @@
3
3
  @use './SpacingVars.scss' as spacing;
4
4
  @use './ColorVars.scss' as colors;
5
5
 
6
- $label-spacing: spacing.$px; // 24px
7
- $input-spacing: math.div(spacing.$px, 3); // 8px
6
+ $label-spacing: spacing.$unit-md; // 24px
7
+ $input-spacing: spacing.$unit-xs; // 8px
8
8
 
9
- $input-width: 24px;
10
- $input-border-width: 1px;
11
- $input-border-width-thick: 2px;
9
+ $input-width: spacing.$unit-md;
10
+ $input-border-width: 0.06rem; // 1px
11
+ $input-border-width-thick: 0.13rem; // 2px
12
12
 
13
- $checkbox-icon-font-size: 18px;
14
- $checkbox-icon-line-height: spacing.$px; //24px
13
+ $checkbox-icon-font-size: 1.13rem; // 18px
14
+ $checkbox-icon-line-height: spacing.$unit-md; // 24px
15
15
  $checkbox-label-spacing: $input-spacing;
16
16
  $checkbox-border-colour: colors.$blue-75;
17
17
 
18
- $form-error-icon-size: 32px;
18
+ $form-error-icon-size: spacing.$unit-lg;
@@ -2,18 +2,25 @@
2
2
 
3
3
  @use "sass:math";
4
4
 
5
- $px: 24px;
6
- $v: $px;
7
- $h: $v;
8
-
9
5
  // Grid variables and margins
10
6
 
11
- $base-unit: math.div($px, 3); // changes base unit to 8px
7
+ $base-unit: 0.5rem; // changes base unit to 8px
12
8
 
13
9
  $unit-xxs: $base-unit * 0.5; // 4px
14
10
  $unit-xs: $base-unit; // 8px
15
- $unit-sm: $base-unit * 2; // 16px
16
- $unit-md: $base-unit * 4; // 32px
17
- $unit-lg: $base-unit * 6; // 48px
18
- $unit-xl: $base-unit * 10; // 80px
19
- $unit-xxl: $base-unit * 20; // 160px
11
+ $unit-sm: $base-unit * 1.5; // 12px
12
+ $unit-md: $base-unit * 3; // 24px
13
+ $unit-lg: $base-unit * 4; // 32px
14
+ $unit-xl: $base-unit * 6; // 48px
15
+ $unit-xxl: $base-unit * 10; // 80px
16
+
17
+ // Deprecated //
18
+ $px: 24px;
19
+ $v: $px;
20
+ $h: $v;
21
+
22
+ // $unit-sm: // 16px -> 12px
23
+ // $unit-md: // 32px ->24px
24
+ // $unit-lg: // 48px -> 32px
25
+ // $unit-xl: // 80px -> 48px
26
+ // $unit-xxl: // 160px -> 80px
@@ -20,9 +20,9 @@ ul {
20
20
  // This is used to add generic list styles to ul & li's
21
21
  .lui-list-bullet {
22
22
  list-style-type: disc;
23
- padding-left: lui.$px * 2; // 24px
23
+ padding-left: lui.$unit-md; // 24px
24
24
 
25
25
  li {
26
- margin-top: lui.$px * 0.5; // 12px
26
+ margin-top: lui.$unit-sm; // 12px
27
27
  }
28
28
  }
@@ -125,7 +125,7 @@ h2,
125
125
  .h2 {
126
126
  @include fonts.font-light();
127
127
  font-size: rem(32px);
128
- margin-top: spacing.$unit-lg; // 96px
128
+ margin-top: spacing.$unit-xl; // 96px
129
129
 
130
130
  & + p {
131
131
  margin-top: spacing.$unit-sm; // 32px
@@ -136,7 +136,7 @@ h3,
136
136
  .h3 {
137
137
  @include fonts.font-regular();
138
138
  font-size: rem(26px);
139
- margin-top: spacing.$unit-md; // 64px
139
+ margin-top: spacing.$unit-lg; // 64px
140
140
 
141
141
  & + p {
142
142
  margin-top: spacing.$unit-sm; // 32px
@@ -147,7 +147,7 @@ h4,
147
147
  .h4 {
148
148
  @include fonts.font-regular();
149
149
  font-size: rem(22px);
150
- margin-top: spacing.$unit-md; // 64px
150
+ margin-top: spacing.$unit-lg; // 64px
151
151
 
152
152
  & + p {
153
153
  margin-top: spacing.$unit-sm; // 32px
@@ -174,12 +174,12 @@ p,
174
174
  .p {
175
175
  @include fonts.font-light();
176
176
  font-size: rem(16px);
177
- margin-top: spacing.$unit-md; //64px
177
+ margin-top: spacing.$unit-lg; //64px
178
178
  }
179
179
 
180
180
  p.lui-small {
181
181
  @include fonts.font-light();
182
182
  font-size: rem(13px);
183
183
  line-height: rem(20px);
184
- margin-top: spacing.$unit-md; //64px
184
+ margin-top: spacing.$unit-lg; //64px
185
185
  }
@@ -1,2 +1,2 @@
1
1
  @forward './GenericElements/index';
2
- @forward './Layout/index';
2
+ @forward './Layout/index';
@@ -1 +1 @@
1
- @use "naturalize";
1
+ @use "naturalize";
@@ -6,17 +6,21 @@
6
6
  // ============
7
7
  // Apply a natural box layout model to all elements, but allowing components to change
8
8
  // http://www.paulirish.com/2012/box-sizing-border-box-ftw/
9
- html { box-sizing: border-box; }
9
+ html {
10
+ box-sizing: border-box;
11
+ }
10
12
 
11
- *, *::before, *::after {
13
+ *,
14
+ *::before,
15
+ *::after {
12
16
  box-sizing: inherit;
13
17
  }
14
18
 
15
-
16
19
  // ============
17
20
  // Remove iOS Safari's default colour for active elements
18
- * { -webkit-tap-highlight-color: color.adjust(white, $alpha: -1); }
19
-
21
+ * {
22
+ -webkit-tap-highlight-color: color.adjust(white, $alpha: -1);
23
+ }
20
24
 
21
25
  /*! normalize.css v4.2.0 | MIT License | github.com/necolas/normalize.css// ============ */
22
26
 
@@ -27,11 +31,11 @@ html {
27
31
  -webkit-text-size-adjust: 100%; // 1
28
32
  }
29
33
 
30
-
31
34
  // ============
32
35
  // Remove the margin in all browsers
33
- body { margin: 0; }
34
-
36
+ body {
37
+ margin: 0;
38
+ }
35
39
 
36
40
  // ============
37
41
  // Correct the margin on `h1` elements within `section` and
@@ -41,7 +45,6 @@ h1 {
41
45
  margin-bottom: 0.67em;
42
46
  }
43
47
 
44
-
45
48
  // ============
46
49
  // 1. Add the correct box sizing in Firefox.
47
50
  // 2. Show the overflow in Edge and IE.
@@ -50,7 +53,6 @@ hr {
50
53
  overflow: visible; // 2
51
54
  }
52
55
 
53
-
54
56
  // ============
55
57
  // 1. Remove the gray background on active links in IE 10.
56
58
  // 2. Remove gaps in links underline in iOS 8+ and Safari 8+.
@@ -59,7 +61,6 @@ a {
59
61
  -webkit-text-decoration-skip: objects; // 2
60
62
  }
61
63
 
62
-
63
64
  // ============
64
65
  // Remove the outline on focused links when they are also active or hovered
65
66
  // in all browsers (opinionated).
@@ -68,7 +69,6 @@ a:hover {
68
69
  outline-width: 0;
69
70
  }
70
71
 
71
-
72
72
  // ============
73
73
  // 1. Remove the border on images inside links in IE 10-.
74
74
  // 2. Don't allow images to overflow their content
@@ -77,11 +77,11 @@ img {
77
77
  max-width: 100%; // 2
78
78
  }
79
79
 
80
-
81
80
  // ============
82
81
  // Hide the overflow in IE.
83
- svg:not(:root) { overflow: hidden; }
84
-
82
+ svg:not(:root) {
83
+ overflow: hidden;
84
+ }
85
85
 
86
86
  // ============
87
87
  // Forms
@@ -99,7 +99,6 @@ textarea {
99
99
  margin: 0; // 2
100
100
  }
101
101
 
102
-
103
102
  // ============
104
103
  // Show the overflow in IE.
105
104
  // 1. Show the overflow in Edge.
@@ -108,7 +107,6 @@ input {
108
107
  overflow: visible; // 1
109
108
  }
110
109
 
111
-
112
110
  // ============
113
111
  // Remove the inheritance of text transform in Edge, Firefox, and IE.
114
112
  // 1. Remove the inheritance of text transform in Firefox.
@@ -117,7 +115,6 @@ select {
117
115
  text-transform: none; // 1
118
116
  }
119
117
 
120
-
121
118
  // ============
122
119
  // 1. Prevent a WebKit bug where (2) destroys native `audio` and `video`
123
120
  // controls in Android 4.
@@ -132,16 +129,16 @@ html [type="button"], // 1
132
129
  // ============
133
130
  // Remove the inner border and padding in Firefox.
134
131
  button::-moz-focus-inner,
135
- [type="button"]::-moz-focus-inner,
136
- [type="reset"]::-moz-focus-inner,
137
- [type="submit"]::-moz-focus-inner {
132
+ [type='button']::-moz-focus-inner,
133
+ [type='reset']::-moz-focus-inner,
134
+ [type='submit']::-moz-focus-inner {
138
135
  border-style: none;
139
136
  padding: 0;
140
137
  }
141
138
 
142
139
  // ============
143
140
  // Ensure button hover cursor state
144
- [role="button"]:not([disabled]),
141
+ [role='button']:not([disabled]),
145
142
  button:not([disabled]) {
146
143
  cursor: pointer;
147
144
  }
@@ -153,53 +150,49 @@ button[disabled] {
153
150
  // ============
154
151
  // Restore the focus styles unset by the previous rule.
155
152
  button:-moz-focusring,
156
- [type="button"]:-moz-focusring,
157
- [type="reset"]:-moz-focusring,
158
- [type="submit"]:-moz-focusring {
153
+ [type='button']:-moz-focusring,
154
+ [type='reset']:-moz-focusring,
155
+ [type='submit']:-moz-focusring {
159
156
  outline: 1px dotted ButtonText;
160
157
  }
161
158
 
162
-
163
159
  // ============
164
160
  // Remove the default vertical scrollbar in IE.
165
- textarea { overflow: auto; }
166
-
161
+ textarea {
162
+ overflow: auto;
163
+ }
167
164
 
168
165
  // ============
169
166
  // 1. Add the correct box sizing in IE 10-.
170
167
  // 2. Remove the padding in IE 10-.
171
- [type="checkbox"],
172
- [type="radio"] {
168
+ [type='checkbox'],
169
+ [type='radio'] {
173
170
  box-sizing: border-box; // 1// ============
174
171
  padding: 0; // 2// ============
175
172
  }
176
173
 
177
-
178
174
  // ============
179
175
  // Correct the cursor style of increment and decrement buttons in Chrome.
180
- [type="number"]::-webkit-inner-spin-button,
181
- [type="number"]::-webkit-outer-spin-button {
176
+ [type='number']::-webkit-inner-spin-button,
177
+ [type='number']::-webkit-outer-spin-button {
182
178
  height: auto;
183
179
  }
184
180
 
185
-
186
181
  // ============
187
182
  // 1. Correct the odd appearance in Chrome and Safari.
188
183
  // 2. Correct the outline style in Safari.
189
- [type="search"] {
184
+ [type='search'] {
190
185
  -webkit-appearance: textfield; // 1// ============
191
186
  outline-offset: -2px; // 2// ============
192
187
  }
193
188
 
194
-
195
189
  // ============
196
190
  // Remove the inner padding and cancel buttons in Chrome and Safari on OS X.
197
- [type="search"]::-webkit-search-cancel-button,
198
- [type="search"]::-webkit-search-decoration {
191
+ [type='search']::-webkit-search-cancel-button,
192
+ [type='search']::-webkit-search-decoration {
199
193
  -webkit-appearance: none;
200
194
  }
201
195
 
202
-
203
196
  // ============
204
197
  // 1. Correct the inability to style clickable types in iOS and Safari.
205
198
  // 2. Change font properties to `inherit` in Safari.