@ministryofjustice/frontend 1.3.1 → 1.4.1
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.
- package/moj/all-ie8.scss +0 -0
- package/moj/all.js +6 -6
- package/moj/all.scss +0 -0
- package/moj/assets/images/icon-alert-information.svg +0 -0
- package/moj/assets/images/icon-alert-success.svg +0 -0
- package/moj/assets/images/icon-alert-warning.svg +0 -0
- package/moj/assets/images/icon-arrow-black-down.svg +0 -0
- package/moj/assets/images/icon-arrow-black-up.svg +0 -0
- package/moj/assets/images/icon-arrow-white-down.svg +0 -0
- package/moj/assets/images/icon-arrow-white-up.svg +0 -0
- package/moj/assets/images/icon-close-cross-black.svg +0 -0
- package/moj/assets/images/icon-document.png +0 -0
- package/moj/assets/images/icon-document.svg +0 -0
- package/moj/assets/images/icon-progress-tick.png +0 -0
- package/moj/assets/images/icon-progress-tick.svg +0 -0
- package/moj/assets/images/icon-search-white.svg +0 -0
- package/moj/assets/images/icon-tag-remove-cross-white.svg +0 -0
- package/moj/assets/images/icon-tag-remove-cross.svg +0 -0
- package/moj/assets/images/icon-toggle-plus-minus.svg +0 -0
- package/moj/assets/images/icon-wysiwyg-bold.svg +0 -0
- package/moj/assets/images/icon-wysiwyg-italic.svg +0 -0
- package/moj/assets/images/icon-wysiwyg-ordered-list.svg +0 -0
- package/moj/assets/images/icon-wysiwyg-underline.svg +0 -0
- package/moj/assets/images/icon-wysiwyg-unordered-list.svg +0 -0
- package/moj/assets/images/moj-apple-touch-icon-152x152.png +0 -0
- package/moj/assets/images/moj-apple-touch-icon-167x167.png +0 -0
- package/moj/assets/images/moj-apple-touch-icon-180x180.png +0 -0
- package/moj/assets/images/moj-apple-touch-icon.png +0 -0
- package/moj/assets/images/moj-logotype-crest.png +0 -0
- package/moj/assets/images/moj-logotype-crest.svg +0 -0
- package/moj/assets/images/moj-opengraph-image.png +0 -0
- package/moj/components/_all.scss +0 -0
- package/moj/components/add-another/README.md +0 -0
- package/moj/components/add-another/_add-another.scss +0 -0
- package/moj/components/add-another/add-another.js +0 -0
- package/moj/components/cookie-banner/README.md +0 -0
- package/moj/components/cookie-banner/_cookie-banner.scss +0 -0
- package/moj/components/form-validator/README.md +0 -0
- package/moj/components/form-validator/form-validator.js +0 -0
- package/moj/components/multi-file-upload/multi-file-upload.js +3 -3
- package/moj/components/pagination/README.md +0 -0
- package/moj/components/pagination/_pagination.scss +0 -0
- package/moj/components/pagination/macro.njk +0 -0
- package/moj/components/pagination/template.njk +6 -8
- package/moj/components/password-reveal/password-reveal.js +3 -3
- package/moj/components/progress-bar/README.md +0 -0
- package/moj/components/progress-bar/_progress-bar.scss +0 -0
- package/moj/components/progress-bar/macro.njk +0 -0
- package/moj/components/progress-bar/template.njk +0 -0
- package/moj/components/rich-text-editor/README.md +0 -0
- package/moj/components/rich-text-editor/_rich-text-editor.scss +0 -0
- package/moj/components/rich-text-editor/rich-text-editor.js +0 -0
- package/moj/components/search/README.md +0 -0
- package/moj/components/search/_search.scss +0 -0
- package/moj/components/search/macro.njk +0 -0
- package/moj/components/search/template.njk +0 -0
- package/moj/components/search-toggle/README.md +0 -0
- package/moj/components/sortable-table/README.md +0 -0
- package/moj/components/sortable-table/_sortable-table.scss +0 -0
- package/moj/components/sortable-table/sortable-table.js +0 -0
- package/moj/components/sub-navigation/README.md +0 -0
- package/moj/components/sub-navigation/_sub-navigation.scss +0 -0
- package/moj/components/sub-navigation/macro.njk +0 -0
- package/moj/components/sub-navigation/template.njk +0 -0
- package/moj/components/ticket-panel/README.md +0 -0
- package/moj/components/ticket-panel/_ticket-panel.scss +0 -0
- package/moj/components/ticket-panel/macro.njk +0 -0
- package/moj/components/ticket-panel/template.njk +0 -0
- package/moj/components/timeline/README.md +0 -0
- package/moj/components/timeline/_timeline.scss +0 -0
- package/moj/components/timeline/macro.njk +0 -0
- package/moj/components/timeline/template.njk +0 -0
- package/moj/helpers/_all.scss +0 -0
- package/moj/helpers/_hidden.scss +0 -0
- package/moj/helpers.js +0 -0
- package/moj/namespace.js +0 -0
- package/moj/objects/_all.scss +0 -0
- package/moj/objects/_filter-layout.scss +0 -0
- package/moj/objects/_scrollable-pane.scss +0 -0
- package/moj/objects/_width-container.scss +0 -0
- package/moj/settings/_all.scss +0 -0
- package/moj/settings/_assets.scss +0 -0
- package/moj/settings/_colours.scss +0 -0
- package/moj/settings/_measurements.scss +0 -0
- package/moj/utilities/_all.scss +0 -0
- package/moj/utilities/_hidden.scss +0 -0
- package/moj/utilities/_width-container.scss +0 -0
- package/moj/vendor/html5shiv.js +0 -0
- package/moj/vendor/jquery.js +0 -0
- package/package.json +1 -1
package/moj/all-ie8.scss
CHANGED
|
File without changes
|
package/moj/all.js
CHANGED
|
@@ -711,11 +711,11 @@ if(MOJFrontend.dragAndDropSupported() && MOJFrontend.formDataSupported() && MOJF
|
|
|
711
711
|
MOJFrontend.MultiFileUpload.prototype.getFileRowHtml = function(file) {
|
|
712
712
|
var html = '';
|
|
713
713
|
html += '<div class="govuk-summary-list__row moj-multi-file-upload__row">';
|
|
714
|
-
html += ' <
|
|
714
|
+
html += ' <div class="govuk-summary-list__value moj-multi-file-upload__message">';
|
|
715
715
|
html += '<span class="moj-multi-file-upload__filename">'+file.name+'</span>';
|
|
716
716
|
html += '<span class="moj-multi-file-upload__progress">0%</span>';
|
|
717
|
-
html += ' </
|
|
718
|
-
html += ' <
|
|
717
|
+
html += ' </div>';
|
|
718
|
+
html += ' <div class="govuk-summary-list__actions moj-multi-file-upload__actions"></div>';
|
|
719
719
|
html += '</div>';
|
|
720
720
|
return html;
|
|
721
721
|
};
|
|
@@ -874,7 +874,7 @@ MOJFrontend.PasswordReveal = function(element) {
|
|
|
874
874
|
};
|
|
875
875
|
|
|
876
876
|
MOJFrontend.PasswordReveal.prototype.createButton = function() {
|
|
877
|
-
this.button = $('<button type="button" class="govuk-button govuk-button--secondary moj-password-reveal__button">Show</button>');
|
|
877
|
+
this.button = $('<button type="button" class="govuk-button govuk-button--secondary moj-password-reveal__button">Show <span class="govuk-visually-hidden">password</span></button>');
|
|
878
878
|
this.container.append(this.button);
|
|
879
879
|
this.button.on('click', $.proxy(this, 'onButtonClick'));
|
|
880
880
|
};
|
|
@@ -882,10 +882,10 @@ MOJFrontend.PasswordReveal.prototype.createButton = function() {
|
|
|
882
882
|
MOJFrontend.PasswordReveal.prototype.onButtonClick = function() {
|
|
883
883
|
if (this.el.type === 'password') {
|
|
884
884
|
this.el.type = 'text';
|
|
885
|
-
this.button.
|
|
885
|
+
this.button.html('Hide <span class="govuk-visually-hidden">password</span>');
|
|
886
886
|
} else {
|
|
887
887
|
this.el.type = 'password';
|
|
888
|
-
this.button.
|
|
888
|
+
this.button.html('Show <span class="govuk-visually-hidden">password</span>');
|
|
889
889
|
}
|
|
890
890
|
};
|
|
891
891
|
|
package/moj/all.scss
CHANGED
|
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
|
|
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
|
package/moj/components/_all.scss
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -99,11 +99,11 @@ if(MOJFrontend.dragAndDropSupported() && MOJFrontend.formDataSupported() && MOJF
|
|
|
99
99
|
MOJFrontend.MultiFileUpload.prototype.getFileRowHtml = function(file) {
|
|
100
100
|
var html = '';
|
|
101
101
|
html += '<div class="govuk-summary-list__row moj-multi-file-upload__row">';
|
|
102
|
-
html += ' <
|
|
102
|
+
html += ' <div class="govuk-summary-list__value moj-multi-file-upload__message">';
|
|
103
103
|
html += '<span class="moj-multi-file-upload__filename">'+file.name+'</span>';
|
|
104
104
|
html += '<span class="moj-multi-file-upload__progress">0%</span>';
|
|
105
|
-
html += ' </
|
|
106
|
-
html += ' <
|
|
105
|
+
html += ' </div>';
|
|
106
|
+
html += ' <div class="govuk-summary-list__actions moj-multi-file-upload__actions"></div>';
|
|
107
107
|
html += '</div>';
|
|
108
108
|
return html;
|
|
109
109
|
};
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -1,29 +1,27 @@
|
|
|
1
|
-
<nav class="moj-pagination {{- ' ' + params.classes if params.classes}}"
|
|
2
|
-
|
|
3
|
-
<p class="govuk-visually-hidden" aria-labelledby="pagination-label">Pagination navigation</p>
|
|
1
|
+
<nav class="moj-pagination {{- ' ' + params.classes if params.classes}}" aria-label="Pagination navigation">
|
|
4
2
|
|
|
5
3
|
<ul class="moj-pagination__list">
|
|
6
4
|
{%- if params.previous %}
|
|
7
5
|
<li class="moj-pagination__item moj-pagination__item--prev">
|
|
8
|
-
<a class="moj-pagination__link" href="{{ params.previous.href }}">{{ params.previous.text }}<span class="govuk-visually-hidden">
|
|
6
|
+
<a class="moj-pagination__link" href="{{ params.previous.href }}">{{ params.previous.text }}<span class="govuk-visually-hidden"> page</span></a>
|
|
9
7
|
</li>
|
|
10
8
|
{% endif -%}
|
|
11
9
|
|
|
12
10
|
{%- for item in params.items %}
|
|
13
11
|
{%- if item.type == 'dots' %}
|
|
14
|
-
<li class="moj-pagination__item moj-pagination__item--dots"
|
|
12
|
+
<li class="moj-pagination__item moj-pagination__item--dots">…</li>
|
|
15
13
|
{% else %}
|
|
16
14
|
{%- if item.selected %}
|
|
17
|
-
<li class="moj-pagination__item moj-pagination__item--active">{{ item.text }}</li>
|
|
15
|
+
<li class="moj-pagination__item moj-pagination__item--active" aria-label="Page {{ item.text }} of {{ params.results.count }}" aria-current="page">{{ item.text }}</li>
|
|
18
16
|
{% else %}
|
|
19
|
-
<li class="moj-pagination__item"><a class="moj-pagination__link" href="{{ item.href }}">{{ item.text }}</a></li>
|
|
17
|
+
<li class="moj-pagination__item"><a class="moj-pagination__link" href="{{ item.href }}" aria-label="Page {{ item.text }} of {{ params.results.count }}">{{ item.text }}</a></li>
|
|
20
18
|
{% endif -%}
|
|
21
19
|
{% endif -%}
|
|
22
20
|
{% endfor -%}
|
|
23
21
|
|
|
24
22
|
{%- if params.next %}
|
|
25
23
|
<li class="moj-pagination__item moj-pagination__item--next">
|
|
26
|
-
<a class="moj-pagination__link" href="{{ params.next.href }}">{{ params.next.text }}<span class="govuk-visually-hidden">
|
|
24
|
+
<a class="moj-pagination__link" href="{{ params.next.href }}">{{ params.next.text }}<span class="govuk-visually-hidden"> page</span></a>
|
|
27
25
|
</li>
|
|
28
26
|
{% endif -%}
|
|
29
27
|
</ul>
|
|
@@ -14,7 +14,7 @@ MOJFrontend.PasswordReveal = function(element) {
|
|
|
14
14
|
};
|
|
15
15
|
|
|
16
16
|
MOJFrontend.PasswordReveal.prototype.createButton = function() {
|
|
17
|
-
this.button = $('<button type="button" class="govuk-button govuk-button--secondary moj-password-reveal__button">Show</button>');
|
|
17
|
+
this.button = $('<button type="button" class="govuk-button govuk-button--secondary moj-password-reveal__button">Show <span class="govuk-visually-hidden">password</span></button>');
|
|
18
18
|
this.container.append(this.button);
|
|
19
19
|
this.button.on('click', $.proxy(this, 'onButtonClick'));
|
|
20
20
|
};
|
|
@@ -22,9 +22,9 @@ MOJFrontend.PasswordReveal.prototype.createButton = function() {
|
|
|
22
22
|
MOJFrontend.PasswordReveal.prototype.onButtonClick = function() {
|
|
23
23
|
if (this.el.type === 'password') {
|
|
24
24
|
this.el.type = 'text';
|
|
25
|
-
this.button.
|
|
25
|
+
this.button.html('Hide <span class="govuk-visually-hidden">password</span>');
|
|
26
26
|
} else {
|
|
27
27
|
this.el.type = 'password';
|
|
28
|
-
this.button.
|
|
28
|
+
this.button.html('Show <span class="govuk-visually-hidden">password</span>');
|
|
29
29
|
}
|
|
30
30
|
};
|
|
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
|
|
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
|
package/moj/helpers/_all.scss
CHANGED
|
File without changes
|
package/moj/helpers/_hidden.scss
CHANGED
|
File without changes
|
package/moj/helpers.js
CHANGED
|
File without changes
|
package/moj/namespace.js
CHANGED
|
File without changes
|
package/moj/objects/_all.scss
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
package/moj/settings/_all.scss
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
package/moj/utilities/_all.scss
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|
package/moj/vendor/html5shiv.js
CHANGED
|
File without changes
|
package/moj/vendor/jquery.js
CHANGED
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ministryofjustice/frontend",
|
|
3
3
|
"description": "The MOJ Frontend contains the code you need to start building user interfaces for UK Ministry of Justice government services.",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.4.1",
|
|
5
5
|
"main": "moj/all.js",
|
|
6
6
|
"sass": "moj/all.scss",
|
|
7
7
|
"engines": {
|