@hmcts/media-viewer 4.2.42-CME-776-dart-angular-20 → 4.2.42

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.
Binary file
package/README.md CHANGED
@@ -495,14 +495,14 @@ Add these styles to your component.scss if you need them.
495
495
  If you're writing your own toolbar styles then do not import those
496
496
 
497
497
  ```
498
- // Load GOV.UK Frontend
499
- @use "govuk-frontend/govuk/all" as *;
500
- // Load Media Viewer Styles
501
- @use "media-viewer/src/assets/all"; // use this to load all the styles
498
+ // Import GOV.UK Frontend
499
+ @import "~govuk-frontend/govuk/all";
500
+ // Import Media Viewer Styles
501
+ @import "~media-viewer/src/assets/all"; // use this to import all the styles
502
502
  ```
503
503
  Alternatively, it is possible to import file by file as required from ```assets/sass``` directory
504
504
 
505
- eg. ```media-viewer/assets/sass/toolbar/main```
505
+ eg. ```~media-viewer/assets/sass/toolbar/main```
506
506
 
507
507
  ## Customisations
508
508
  ### Toolbar
package/assets/all.scss CHANGED
@@ -1,34 +1,36 @@
1
1
  // CDK overlays require a small set of structural styles to work correctly
2
2
  // As the component is not yet using Angular Material we have to include the style ourself
3
3
  // see https://material.angular.io/cdk/overlay/overview
4
- @use '@angular/cdk/overlay-prebuilt';
4
+ @import 'node_modules/@angular/cdk/overlay-prebuilt';
5
5
 
6
- @use 'sass/annotation-set';
7
- @use 'sass/bookmarks';
8
- @use 'sass/box-highlight';
9
- @use 'sass/comment';
10
- @use 'sass/comment-search';
11
- @use 'sass/comment-set-header';
12
- @use 'sass/comment-set-panel';
13
- @use 'sass/comment-set-toggle';
14
- @use 'sass/comments-summary-dialog';
15
- @use 'sass/confirm-action-dialog';
16
- @use 'sass/document';
17
- @use 'sass/image-viewer';
18
- @use 'sass/media-viewer';
19
- @use 'sass/outline-attachment';
20
- @use 'sass/participants-list';
21
- @use 'sass/pdf-viewer';
22
- @use 'sass/popup-toolbar';
23
- @use 'sass/rectangle';
24
- @use 'sass/tags';
25
- @use 'sass/toolbar/main';
26
- @use 'sass/tabs';
27
- @use 'sass/tooltip';
28
- @use 'sass/comment-filter';
29
- @use 'sass/angular-tree-component';
30
- @use 'sass/redaction';
31
- @use 'pdfjs/pdf_viewer';
6
+ @import 'sass/settings';
7
+ @import "sass/annotation-set";
8
+ @import 'sass/bookmarks.scss';
9
+ @import "sass/box-highlight";
10
+ @import "sass/bookmarks";
11
+ @import "sass/comment";
12
+ @import "sass/comment-search";
13
+ @import "sass/comment-set-header";
14
+ @import "sass/comment-set-panel";
15
+ @import "sass/comment-set-toggle";
16
+ @import "sass/comments-summary-dialog";
17
+ @import "sass/confirm-action-dialog";
18
+ @import 'sass/document';
19
+ @import "sass/image-viewer";
20
+ @import 'sass/media-viewer';
21
+ @import 'sass/outline-attachment';
22
+ @import 'sass/participants-list';
23
+ @import "sass/pdf-viewer";
24
+ @import "sass/popup-toolbar";
25
+ @import "sass/rectangle";
26
+ @import "sass/tags";
27
+ @import "sass/toolbar/main";
28
+ @import 'sass/tabs';
29
+ @import 'sass/tooltip';
30
+ @import 'sass/comment-filter';
31
+ @import 'sass/angular-tree-component';
32
+ @import 'sass/redaction';
33
+ @import 'pdfjs/pdf_viewer';
32
34
  div.govuk-prose-scope, p {
33
35
  white-space: pre-wrap;
34
36
  }
@@ -1,5 +1,3 @@
1
- @use "govuk-frontend/govuk/base" as *;
2
-
3
1
  .comment-filter {
4
2
  border: none;
5
3
  margin-bottom: 20px;
@@ -74,10 +72,8 @@
74
72
  font-weight: bold;
75
73
  position: relative;
76
74
  @include govuk-font($size: 19);
77
- & {
78
- color: govuk-colour("blue");
79
- cursor: pointer;
80
- }
75
+ color: govuk-colour("blue");
76
+ cursor: pointer;
81
77
 
82
78
  }
83
79
 
@@ -1,5 +1,3 @@
1
- @use "govuk-frontend/govuk/base" as *;
2
-
3
1
  a.disabledLink {
4
2
  pointer-events: none;
5
3
  cursor: default;
@@ -1,5 +1,3 @@
1
- @use "govuk-frontend/govuk/base" as *;
2
-
3
1
  .commentSummaryHeader {
4
2
  .has-scroll-bar & {
5
3
  right: 14px
@@ -1,5 +1,3 @@
1
- @use "govuk-frontend/govuk/base" as *;
2
-
3
1
  mv-anno-comment {
4
2
  .aui-comment {
5
3
  width: 85%;
@@ -102,18 +100,14 @@ mv-anno-comment {
102
100
 
103
101
  .aui-comment__author {
104
102
  @include govuk-font($size: 19);
105
- & {
106
- display: block;
107
- font-weight: bold;
108
- }
103
+ display: block;
104
+ font-weight: bold;
109
105
  }
110
106
 
111
107
 
112
108
  .aui-comment__meta {
113
109
  @include govuk-font($size: 16);
114
- & {
115
- color: $govuk-secondary-text-colour;
116
- }
110
+ color: $govuk-secondary-text-colour;
117
111
  }
118
112
 
119
113
  .aui-comment__footer {
@@ -33,11 +33,11 @@
33
33
  mv-confirm-action,
34
34
  mv-comments-summary {
35
35
  .dates {
36
- overflow: hidden;
37
- clear: both;
38
36
  * {
39
37
  font-size: 16px;
40
38
  }
39
+ overflow: hidden;
40
+ clear: both;
41
41
  .dates__from, .dates__to, .dates__tags {
42
42
  float: left;
43
43
  }
@@ -1,6 +1,3 @@
1
- @use "govuk-frontend/govuk/base" as *;
2
- @use "settings" as *;
3
-
4
1
  .aui {
5
2
 
6
3
  &--show-comments {
@@ -60,32 +57,28 @@
60
57
 
61
58
  .aui__toolbar-container {
62
59
  @include aui-width-container;
63
- & {
64
- border-left:1px solid govuk-colour("light-grey");
65
- border-right: 1px solid govuk-colour("light-grey");
66
- height: 100%;
67
- position: relative;
68
- left: 0; top: 0;
69
- z-index: 1;
70
- }
60
+ border-left:1px solid govuk-colour("light-grey");
61
+ border-right: 1px solid govuk-colour("light-grey");
62
+ height: 100%;
63
+ position: relative;
64
+ left: 0; top: 0;
65
+ z-index: 1;
71
66
  }
72
67
 
73
68
 
74
69
  .aui__toolbar-button {
75
70
  @include govuk-font($size: 19);
76
- & {
77
- background-color: govuk-colour("white");
78
- border: 0 none;
79
- border: 1px solid #f00;
80
- color: govuk-colour("black");
81
- cursor: pointer;
82
- float: left;
83
- height: 50px;
84
- margin: 0;
85
- padding-left: 15px;
86
- padding-right: 15px;
87
- position: relative;
88
- }
71
+ background-color: govuk-colour("white");
72
+ border: 0 none;
73
+ border: 1px solid #f00;
74
+ color: govuk-colour("black");
75
+ cursor: pointer;
76
+ float: left;
77
+ height: 50px;
78
+ margin: 0;
79
+ padding-left: 15px;
80
+ padding-right: 15px;
81
+ position: relative;
89
82
  &:first-child {
90
83
  &::after {
91
84
  background-color: #DEE0E2;
@@ -168,9 +161,7 @@
168
161
  .aui__window-container {
169
162
  @include aui-width-container;
170
163
  @include govuk-clearfix;
171
- & {
172
- position: relative;
173
- }
164
+ position: relative;
174
165
  }
175
166
 
176
167
 
@@ -199,9 +190,7 @@
199
190
 
200
191
  .aui__document-page {
201
192
  @include aspect-ratio(1,1.414); // True A4 aspect ratio
202
- & {
203
- margin-top: govuk-spacing(4);
204
- }
193
+ margin-top: govuk-spacing(4);
205
194
 
206
195
  &:first-child {
207
196
  margin-top: 0;
@@ -209,13 +198,11 @@
209
198
 
210
199
  &[data-page]::after {
211
200
  @include govuk-font(16);
212
- & {
213
- color: $govuk-secondary-text-colour;
214
- content: attr(data-page);
215
- line-height: 1;
216
- position: absolute; right: govuk-spacing(4);
217
- bottom: govuk-spacing(4);
218
- }
201
+ color: $govuk-secondary-text-colour;
202
+ content: attr(data-page);
203
+ line-height: 1;
204
+ position: absolute; right: govuk-spacing(4);
205
+ bottom: govuk-spacing(4);
219
206
  }
220
207
 
221
208
  img {
@@ -252,3 +239,4 @@
252
239
  }
253
240
 
254
241
  }
242
+
@@ -1,5 +1,3 @@
1
- @use "govuk-frontend/govuk/base" as *;
2
-
3
1
  mv-participants-list {
4
2
 
5
3
  .participant__card {
@@ -23,10 +21,8 @@ mv-participants-list {
23
21
  border-bottom: 1px solid #ddd;
24
22
  margin-bottom: govuk-spacing(1);
25
23
  @include govuk-font($size: 16);
26
- & {
27
- display: block;
28
- font-weight: bold;
29
- }
24
+ display: block;
25
+ font-weight: bold;
30
26
  }
31
27
 
32
28
  .participant__name {
@@ -2,23 +2,15 @@
2
2
  #GENERAL CONFIGURATIONS
3
3
  ========================================================================== */
4
4
 
5
- @use "sass:math";
6
- @use "govuk-frontend/govuk/base" as *;
7
-
8
5
  $aui-page-width: 1220px;
9
6
  $aui-gutter: govuk-spacing(6);
10
- $aui-gutter-half: math.div($govuk-gutter, 2);
7
+ $aui-gutter-half: $govuk-gutter / 2;
11
8
 
12
9
  // Assets path
13
10
  $aui-assets-path : "/public/images/";
14
11
 
15
12
  @mixin aspect-ratio($ratio-or-width, $height: null) {
16
- $padding: null;
17
- @if $height {
18
- $padding: math.percentage(math.div($height, $ratio-or-width));
19
- } @else {
20
- $padding: math.percentage(math.div(1, $ratio-or-width));
21
- }
13
+ $padding: if($height, percentage($height/$ratio-or-width), percentage(1/$ratio-or-width));
22
14
  &:before { content:''; float: left; padding-bottom: $padding; }
23
15
  &:after { content:''; display: table; clear: both; }
24
16
  }
@@ -1,5 +1,3 @@
1
- @use "govuk-frontend/govuk/base" as *;
2
-
3
1
  .govuk-tabs {
4
2
  p{
5
3
  @include govuk-font($size: 16);
@@ -1,6 +1,3 @@
1
- @use "sass:color";
2
- @use "node_modules/ngx-chips/core/styles/core/core" as *;
3
-
4
1
  .tags {
5
2
  margin-bottom: 10px;
6
3
  &__renderer {
@@ -21,8 +18,10 @@
21
18
  }
22
19
 
23
20
 
21
+ @import "node_modules/ngx-chips/core/styles/core/core";
22
+
24
23
  $foundation-primary: #1779ba;
25
- $foundation-primary-dark: color.adjust($foundation-primary, $lightness: -10%);
24
+ $foundation-primary-dark: darken($foundation-primary, 10%);
26
25
 
27
26
  $foundation-theme: (
28
27
  container-border-bottom: 1px solid $foundation-primary
@@ -85,3 +84,4 @@ button {
85
84
 
86
85
  }
87
86
  }
87
+
@@ -1,18 +1,18 @@
1
- @use "buttons";
2
- @use "side-bar";
3
- @use "search-bar";
4
- @use "sub-toolbar";
5
- @use "thumbnail";
6
- @use "dialog-overlay";
7
- @use "field-label";
8
- @use "loading-bar";
9
- @use "debugging";
10
- @use "text-selection";
11
- @use "media";
12
- @use "redaction-toolbar";
13
- @use "icp-buttons";
14
- @use "icp-toolbar";
15
- @use "main-toolbar";
1
+ @import "buttons";
2
+ @import "side-bar";
3
+ @import "search-bar";
4
+ @import "sub-toolbar";
5
+ @import "thumbnail";
6
+ @import "dialog-overlay";
7
+ @import "field-label";
8
+ @import "loading-bar";
9
+ @import "debugging";
10
+ @import "text-selection";
11
+ @import "media";
12
+ @import "redaction-toolbar";
13
+ @import "icp-buttons";
14
+ @import "icp-toolbar";
15
+ @import "main-toolbar";
16
16
 
17
17
  .hidden {
18
18
  display: none !important;
@@ -1,5 +1,3 @@
1
- @use "govuk-frontend/govuk/base" as *;
2
-
3
1
  .searchbar {
4
2
  z-index: 100;
5
3
  position: absolute;
@@ -16,10 +14,8 @@
16
14
  }
17
15
  span {
18
16
  @include govuk-font($size: 16);
19
- & {
20
- color: $govuk-secondary-text-colour;
21
- min-width: 110px;
22
- }
17
+ color: $govuk-secondary-text-colour;
18
+ min-width: 110px;
23
19
  }
24
20
  }
25
21