@qld-gov-au/qgds-bootstrap5 2.0.12 → 2.1.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/.esbuild/plugins/qgds-plugin-generate-icon-assets.js +31 -24
- package/.storybook/preview.js +15 -6
- package/dist/assets/components/bs5/button/button.hbs +1 -1
- package/dist/assets/components/bs5/callToAction/callToAction.hbs +3 -3
- package/dist/assets/components/bs5/dateinput/dateinput.hbs +21 -27
- package/dist/assets/components/bs5/footer/customLinks.hbs +1 -1
- package/dist/assets/components/bs5/footer/followLinks.hbs +1 -1
- package/dist/assets/components/bs5/globalAlert/globalAlert.hbs +8 -1
- package/dist/assets/components/bs5/head/head.hbs +1 -1
- package/dist/assets/components/bs5/inpageAlert/inpageAlert.hbs +10 -2
- package/dist/assets/components/bs5/pagination/pagination.hbs +7 -2
- package/dist/assets/components/bs5/promotionalPanel/promotionalPanel.hbs +1 -1
- package/dist/assets/components/bs5/searchInput/searchInput.hbs +11 -9
- package/dist/assets/css/qld.bootstrap.css +2 -2
- package/dist/assets/css/qld.bootstrap.css.map +3 -3
- package/dist/assets/css/qld.bootstrap.legacy.css +2 -2
- package/dist/assets/css/qld.bootstrap.legacy.css.map +3 -3
- package/dist/assets/img/icons-sprite.svg +24 -24
- package/dist/assets/js/handlebars.helpers.bundle.js +1 -1
- package/dist/assets/js/handlebars.init.min.js +80 -64
- package/dist/assets/js/handlebars.init.min.js.map +2 -2
- package/dist/assets/js/handlebars.partials.js +80 -64
- package/dist/assets/js/handlebars.partials.js.map +2 -2
- package/dist/assets/js/qld.bootstrap.min.js +6 -6
- package/dist/assets/js/qld.bootstrap.min.js.map +4 -4
- package/dist/assets/node/handlebars.init.min.js +28 -19
- package/dist/assets/node/handlebars.init.min.js.map +2 -2
- package/dist/components/bs5/button/button.hbs +1 -1
- package/dist/components/bs5/callToAction/callToAction.hbs +3 -3
- package/dist/components/bs5/dateinput/dateinput.hbs +21 -27
- package/dist/components/bs5/footer/customLinks.hbs +1 -1
- package/dist/components/bs5/footer/followLinks.hbs +1 -1
- package/dist/components/bs5/globalAlert/globalAlert.hbs +8 -1
- package/dist/components/bs5/head/head.hbs +1 -1
- package/dist/components/bs5/inpageAlert/inpageAlert.hbs +10 -2
- package/dist/components/bs5/pagination/pagination.hbs +7 -2
- package/dist/components/bs5/promotionalPanel/promotionalPanel.hbs +1 -1
- package/dist/components/bs5/searchInput/searchInput.hbs +11 -9
- package/dist/package.json +33 -32
- package/dist/sample-data/callToAction/callToAction.data.json +2 -1
- package/dist/sample-data/dateinput/dateinput.data.json +3 -1
- package/dist/sample-data/footer/footer.data.json +3 -0
- package/dist/sample-data/inpageAlert/inpageAlert.data.json +1 -1
- package/dist/sample-data/pagination/pagination.data.json +4 -4
- package/dist/sample-data/promotionalPanel/promotionalPanel.data.json +45 -47
- package/dist/sample-data/searchInput/searchInput.data.json +1 -0
- package/package.json +33 -32
- package/src/components/bs5/breadcrumbs/breadcrumbs.scss +4 -4
- package/src/components/bs5/button/Button.js +32 -6
- package/src/components/bs5/button/button.hbs +1 -1
- package/src/components/bs5/button/button.scss +1 -5
- package/src/components/bs5/button/button.stories.js +16 -4
- package/src/components/bs5/callToAction/callToAction.data.json +2 -1
- package/src/components/bs5/callToAction/callToAction.hbs +3 -3
- package/src/components/bs5/callToAction/callToAction.stories.js +2 -2
- package/src/components/bs5/card/card.scss +4 -2
- package/src/components/bs5/dateinput/Dateinput.js +1 -38
- package/src/components/bs5/dateinput/Dateinput.mdx +27 -0
- package/src/components/bs5/dateinput/Dateinput.stories.js +48 -4
- package/src/components/bs5/dateinput/dateinput.data.json +3 -1
- package/src/components/bs5/dateinput/dateinput.functions.js +91 -0
- package/src/components/bs5/dateinput/dateinput.hbs +21 -27
- package/src/components/bs5/footer/customLinks.hbs +1 -1
- package/src/components/bs5/footer/followLinks.hbs +1 -1
- package/src/components/bs5/footer/footer.data.json +3 -0
- package/src/components/bs5/formcheck/_form-variables.scss +36 -0
- package/src/components/bs5/formcheck/formcheck.scss +59 -14
- package/src/components/bs5/globalAlert/globalAlert.hbs +8 -1
- package/src/components/bs5/globalAlert/globalAlert.scss +14 -19
- package/src/components/bs5/globalAlert/globalAlert.stories.js +1 -0
- package/src/components/bs5/globalAlert/globalAlert.test.js +10 -5
- package/src/components/bs5/header/header.scss +1 -2
- package/src/components/bs5/icons/_icons.list.js +7 -7
- package/src/components/bs5/icons/_icons.list.scss +113 -112
- package/src/components/bs5/icons/_icons.variables.scss +7 -6
- package/src/components/bs5/icons/icons.scss +2 -1
- package/src/components/bs5/inpageAlert/inpageAlert.data.json +1 -1
- package/src/components/bs5/inpageAlert/inpageAlert.hbs +10 -2
- package/src/components/bs5/inpageAlert/inpageAlert.scss +52 -55
- package/src/components/bs5/inpageAlert/inpageAlert.stories.js +54 -3
- package/src/components/bs5/inpagenav/inpagenav.scss +9 -1
- package/src/components/bs5/modal/modal.scss +1 -1
- package/src/components/bs5/navbar/navbar.functions.js +39 -28
- package/src/components/bs5/navbar/navbar.scss +43 -28
- package/src/components/bs5/navbar/navbar.stories.js +4 -3
- package/src/components/bs5/pageLayout/PaletteShowcase.stories.js +4 -3
- package/src/components/bs5/pagination/pagination.data.json +4 -4
- package/src/components/bs5/pagination/pagination.hbs +7 -2
- package/src/components/bs5/pagination/pagination.scss +1 -1
- package/src/components/bs5/promotionalPanel/promotionalPanel.data.json +45 -47
- package/src/components/bs5/promotionalPanel/promotionalPanel.hbs +1 -1
- package/src/components/bs5/quickexit/quickexit.scss +1 -1
- package/src/components/bs5/searchInput/__snapshots__/searchInput.test.js.snap +16 -16
- package/src/components/bs5/searchInput/search.functions.js +70 -71
- package/src/components/bs5/searchInput/searchInput.data.json +1 -0
- package/src/components/bs5/searchInput/searchInput.hbs +11 -9
- package/src/components/bs5/searchInput/searchInput.scss +92 -38
- package/src/components/bs5/searchInput/searchInput.test.js +91 -119
- package/src/components/bs5/sidenav/sidenav.scss +17 -19
- package/src/components/bs5/skiplinks/skipLinks.scss +12 -4
- package/src/components/bs5/table/table.scss +93 -83
- package/src/components/common/focus-styles/focusStyles.mdx +20 -0
- package/src/components/common/focus-styles/focusStyles.stories.js +58 -0
- package/src/css/functions/_index.scss +3 -0
- package/src/css/functions/color-icon.scss +31 -0
- package/src/css/functions/string-replace.scss +49 -0
- package/src/css/functions/svg-encode.scss +22 -0
- package/src/css/main.scss +3 -0
- package/src/css/mixins/focusable.scss +1 -1
- package/src/css/mixins/make-icon.scss +1 -1
- package/src/css/mixins/make-link.scss +13 -10
- package/src/css/qld-palettes.scss +20 -12
- package/src/css/qld-reduced-motion.scss +51 -0
- package/src/css/qld-tokens.scss +3 -3
- package/src/css/qld-type.scss +11 -13
- package/src/css/qld-utilities.scss +9 -1
- package/src/css/qld-variables.scss +1 -1
- package/src/img/icons-sprite.svg +24 -24
- package/src/js/constants.js +10 -0
- package/src/js/qld.bootstrap.js +99 -151
- package/src/js/utils.js +3 -1
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
{{#unless islink}}
|
|
12
12
|
|
|
13
|
-
<button class="btn {{variantClass}} {{#if isprogress}}btn-progress{{/if}}
|
|
13
|
+
<button class="btn {{variantClass}} {{#if isprogress}}btn-progress{{/if}}" onclick="{{{onclick}}}" {{#if isdisabled}}disabled{{/if}} {{#if isprogress}}disabled aria-live="polite"{{/if}} {{#if arialabel}}aria-label="{{arialabel}}"{{/if}} {{{dataatts}}} {{#if progressLabel}}data-progress-label="{{progressLabel}}"{{/if}}>
|
|
14
14
|
{{#if isprogress}}
|
|
15
15
|
{{~>progressSpinner~}}
|
|
16
16
|
{{else}}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
<a class="qld-cta-link {{getClassNames "small, view-all" class}}"
|
|
2
2
|
{{#if id}}id="{{id}}"{{/if}}
|
|
3
|
-
href="{{href}}"
|
|
4
|
-
target="{{target}}"
|
|
5
|
-
{{#if arialabel}}aria-label="{{arialabel}}"{{/if}}
|
|
3
|
+
href="{{href}}"
|
|
4
|
+
target="{{target}}"
|
|
5
|
+
{{#if arialabel}}aria-label="{{arialabel}}"{{/if}}
|
|
6
6
|
>
|
|
7
7
|
{{label}}
|
|
8
8
|
<span class="icon" aria-hidden="true"></span>
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
<!-- QGDS Component: Date input -->
|
|
2
2
|
|
|
3
|
-
<label id="{{id}}-label"
|
|
4
|
-
class="qld-text-input-label {{#if isRequired}}field-required{{/if}} {{#if isDisabled}}field-disabled{{/if}}"
|
|
5
|
-
for="{{id}}">
|
|
3
|
+
<label id="{{id}}-label" class="qld-text-input-label {{#if isRequired}}field-required{{/if}} {{#if isDisabled}}field-disabled{{/if}}" for="{{id}}">
|
|
6
4
|
{{label-text}}
|
|
7
5
|
{{#if optional-text}}
|
|
8
6
|
<span class="label-text-optional">({{optional-text}})</span>
|
|
@@ -12,53 +10,49 @@
|
|
|
12
10
|
{{#if hint-text}}
|
|
13
11
|
<span class="qld-hint-text" id="{{id}}-hint">{{hint-text}}</span>
|
|
14
12
|
{{/if}}
|
|
15
|
-
|
|
16
13
|
{{#contains "qld-input-success" customClass}}{{! legacy support for feedback classes `qld-input-success`}}
|
|
17
14
|
<span class="qld-input-success">{{successMessageText}}</span>
|
|
18
|
-
{{else}}
|
|
19
|
-
{{#if successMessageText}}{{! updated bootstrap style classes - `valid-feedback`}}
|
|
15
|
+
{{else if successMessageText}}{{! updated bootstrap style classes - `valid-feedback`}}
|
|
20
16
|
<div class="valid-feedback">{{successMessageText}}</div>
|
|
21
|
-
{{/
|
|
22
|
-
|
|
17
|
+
{{/contains}}
|
|
23
18
|
{{#contains "qld-input-error" customClass}}{{! legacy support for feedback classes `qld-input-error`}}
|
|
24
19
|
<span class="qld-input-error">{{errorMessageText}}</span>
|
|
25
|
-
{{else}}
|
|
26
|
-
{{#if errorMessageText}}{{! updated bootstrap style classes - `invalid-feedback`}}
|
|
20
|
+
{{else if errorMessageText}}{{! updated bootstrap style classes - `invalid-feedback`}}
|
|
27
21
|
<div class="invalid-feedback">{{errorMessageText}}</div>
|
|
28
|
-
{{/
|
|
22
|
+
{{/contains}}
|
|
29
23
|
|
|
30
24
|
<div aria-labelledby="{{id}}-label" role="group" class="row date-container {{customClass}}">
|
|
31
25
|
<!-- day group -->
|
|
32
26
|
<div class="day-group">
|
|
33
27
|
<label id="{{id}}-dayinput-label" for="{{id}}-dayinput" class="date-label qld-text-input-label">Day</label>
|
|
34
28
|
<div>
|
|
35
|
-
<input id="{{id}}-dayinput" aria-
|
|
36
|
-
inputmode="numeric" maxlength="2"
|
|
37
|
-
class="
|
|
38
|
-
|
|
39
|
-
{{/if}}>
|
|
29
|
+
<input id="{{id}}-dayinput" aria-labelledby="{{id}}-label {{id}}-dayinput-label" placeholder="{{day-placeholder}}" type="text"
|
|
30
|
+
inputmode="numeric" maxlength="2" minlength="2" min="1" max="31" pattern="^(0?[1-9]|[12][0-9]|3[01])$"
|
|
31
|
+
class="form-control dayinput {{customClass}} {{#if isFilled}}form-style-filled{{/if}}
|
|
32
|
+
{{#if isValid}}is-valid{{else}}{{#ifCond isValid "===" false}}is-invalid{{/ifCond}}{{/if}}" ref="day"
|
|
33
|
+
aria-invalid="false" {{#if isDisabled}}disabled{{/if}} {{#if isRequired}}required{{/if}}>
|
|
40
34
|
</div>
|
|
41
35
|
</div>
|
|
42
36
|
<!-- month group -->
|
|
43
37
|
<div class="date-group">
|
|
44
38
|
<label id="{{id}}-monthinput-label" for="{{id}}-monthinput" class="date-label qld-text-input-label">Month</label>
|
|
45
39
|
<div>
|
|
46
|
-
<input id="{{id}}-monthinput" aria-
|
|
47
|
-
type="text" inputmode="numeric" maxlength="2"
|
|
48
|
-
class="
|
|
49
|
-
|
|
50
|
-
{{/if}}>
|
|
40
|
+
<input id="{{id}}-monthinput" aria-labelledby="{{id}}-label {{id}}-monthinput-label" placeholder="{{month-placeholder}}"
|
|
41
|
+
type="text" inputmode="numeric" maxlength="2" minlength="2" min="1" max="12" pattern="^(0?[1-9]|[1][0-2])$"
|
|
42
|
+
class="form-control monthinput {{customClass}} {{#if isFilled}}form-style-filled{{/if}}
|
|
43
|
+
{{#if isValid}}is-valid{{else}}{{#ifCond isValid "===" false}}is-invalid{{/ifCond}}{{/if}}" ref="month"
|
|
44
|
+
aria-invalid="false" {{#if isDisabled}}disabled{{/if}} {{#if isRequired}}required{{/if}}>
|
|
51
45
|
</div>
|
|
52
46
|
</div>
|
|
53
47
|
<!-- year group -->
|
|
54
48
|
<div class="date-group">
|
|
55
|
-
<label id="{{id}}-yearinput-label" for="{{id}}-yearinput" class="date-label">Year</label>
|
|
49
|
+
<label id="{{id}}-yearinput-label" for="{{id}}-yearinput" class="date-label qld-text-input-label">Year</label>
|
|
56
50
|
<div class="year-label">
|
|
57
|
-
<input id="{{id}}-yearinput" aria-
|
|
58
|
-
placeholder="{{year-placeholder}}" type="text" inputmode="numeric" maxlength="4"
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
isRequired}}required{{/if}}>
|
|
51
|
+
<input id="{{id}}-yearinput" aria-labelledby="{{id}}-label {{id}}-yearinput-label"
|
|
52
|
+
placeholder="{{year-placeholder}}" type="text" inputmode="numeric" maxlength="4" minlength="4" pattern="[0-9]*"
|
|
53
|
+
{{#if yearMin}}min="{{yearMin}}"{{/if}} {{#if yearMax}}max="{{yearMax}}"{{/if}}
|
|
54
|
+
class="form-control yearinput {{customClass}} {{#if isFilled}}form-style-filled{{/if}} {{#if isValid}}is-valid{{else}}{{#ifCond isValid "===" false}}is-invalid{{/ifCond}}{{/if}}"
|
|
55
|
+
ref="year" aria-invalid="false" {{#if isDisabled}}disabled{{/if}} {{#if isRequired}}required{{/if}}>
|
|
62
56
|
</div>
|
|
63
57
|
</div>
|
|
64
58
|
</div>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{{#if customLinks }}
|
|
2
|
-
<ul class="nav footer-link-list footer-link-list--custom flex-column">
|
|
2
|
+
<ul class="nav footer-link-list footer-link-list--custom flex-column">
|
|
3
3
|
{{#each customLinks }}
|
|
4
4
|
<li><a class="nav-link" href="{{ link }}" {{#if target }} target="_blank" {{/if}}>{{ label }}</a></li>
|
|
5
5
|
{{/each }}
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
<span class="qld-icon qld-icon-md qld-icon-{{icon}} d-lg-none" aria-hidden="true"></span>
|
|
7
7
|
<span class="qld-icon qld-icon-sm qld-icon-{{icon}} d-none d-lg-block" aria-hidden="true"></span>
|
|
8
8
|
<span class="nav-link-label d-none d-lg-block">{{ label }}</span>
|
|
9
|
-
<span class="sr-only">{{ label
|
|
9
|
+
<span class="sr-only">{{isdefined accessibleLabel label}}</span>
|
|
10
10
|
</a>
|
|
11
11
|
</li>
|
|
12
12
|
{{/each }}
|
|
@@ -3,7 +3,13 @@
|
|
|
3
3
|
<div class="global-alert-include">
|
|
4
4
|
{{#each alertItems}}
|
|
5
5
|
<section role="region" class="global-alert alert container-full d-none {{variant}}" data-variant="{{variant}}"
|
|
6
|
-
|
|
6
|
+
{{#if ariaLabel}} aria-label="{{ ariaLabel }}"
|
|
7
|
+
{{~else ifCond variant "==" "global-alert-critical"}} aria-label="Critical alert"
|
|
8
|
+
{{~else ifCond variant "==" "global-alert-info"}} aria-label="Informational alert"
|
|
9
|
+
{{~else ifCond variant "==" "global-alert-warning"}} aria-label="Warning alert"
|
|
10
|
+
{{~else}} aria-label="Informational alert"
|
|
11
|
+
{{~/if}}
|
|
12
|
+
{{#if id}} data-id="{{id}}" {{/if}}{{#if dismissedExpiryDays}}
|
|
7
13
|
data-expiry-days="{{dismissedExpiryDays}}" {{/if}}>
|
|
8
14
|
<div class="qld-global-alert-main">
|
|
9
15
|
<div class="global-alert-icon">
|
|
@@ -13,6 +19,7 @@
|
|
|
13
19
|
<span class="qld-icon qld-icon-sm qld-icon-alert-information" aria-hidden="true"></span>
|
|
14
20
|
{{else ifCond variant '==' 'global-alert-warning'}}
|
|
15
21
|
<span class="qld-icon qld-icon-sm qld-icon-alert-warning" aria-hidden="true"></span>
|
|
22
|
+
{{else}}<span class="qld-icon qld-icon-sm qld-icon-alert-information" aria-hidden="true"></span>
|
|
16
23
|
{{/ifCond}}
|
|
17
24
|
</div>
|
|
18
25
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
<!-- VERSION_DETAILS={"project_id":"@qld-gov-au/qgds-bootstrap5","version":"2.
|
|
2
|
+
<!-- VERSION_DETAILS={"project_id":"@qld-gov-au/qgds-bootstrap5","version":"2.1.1","branch":"HEAD","tag":"v2.1.1","commit":"e9b014307ee0b957ab946f973a0bd735811415db","majorVersion":"v2"} -->
|
|
3
3
|
|
|
4
4
|
{{! Select environment, used verbatium if not using predefind key
|
|
5
5
|
cdn := PROD|STAGING|BETA|TEST|DEV|???
|
|
@@ -1,5 +1,13 @@
|
|
|
1
|
-
<div class="alert {{variantClass}} {{customClass}}" role="alert"
|
|
2
|
-
{{#if
|
|
1
|
+
<div class="alert {{variantClass}} {{customClass}}" role="alert"
|
|
2
|
+
{{#if ariaLabel}}
|
|
3
|
+
aria-label="{{ ariaLabel }}"
|
|
4
|
+
{{else}}
|
|
5
|
+
{{#ifCond variantClass "==" "alert-info"}}aria-label="Information alert"{{/ifCond}}
|
|
6
|
+
{{#ifCond variantClass "==" "alert-success"}}aria-label="Success alert"{{/ifCond}}
|
|
7
|
+
{{#ifCond variantClass "==" "alert-error"}}aria-label="Error alert"{{/ifCond}}
|
|
8
|
+
{{#ifCond variantClass "==" "alert-warning"}}aria-label="Warning alert"{{/ifCond}}
|
|
9
|
+
{{/if}}
|
|
10
|
+
>
|
|
3
11
|
{{#if heading}}
|
|
4
12
|
{{#if headingTag}}
|
|
5
13
|
<{{headingTag}} class="alert-heading">{{{ heading }}}</{{headingTag}}>
|
|
@@ -23,8 +23,13 @@ Reference: https://getbootstrap.com/docs/5.0/components/pagination/
|
|
|
23
23
|
{{! More button }}
|
|
24
24
|
<span></span>
|
|
25
25
|
{{else}}
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
{{#ifCond "active" "in" customClasses}}
|
|
27
|
+
{{! Active page - not a link }}
|
|
28
|
+
<span class="page-link" aria-current="page" aria-label="{{#if arialabel}}{{arialabel}}{{else}}Page {{linktext}}, current page{{/if}}">{{ linktext }}</span>
|
|
29
|
+
{{else}}
|
|
30
|
+
{{! Page button }}
|
|
31
|
+
<a class="page-link" href="{{href}}" aria-label="{{#if arialabel}}{{arialabel}}{{else}}Page {{linktext}}{{/if}}">{{ linktext }}</a>
|
|
32
|
+
{{/ifCond}}
|
|
28
33
|
{{/if}}
|
|
29
34
|
</li>
|
|
30
35
|
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
{{/ifCond}}>
|
|
6
6
|
<div class="image-panel">
|
|
7
7
|
{{#ifCond type '!=' 'promo'}}
|
|
8
|
-
<img class="promo-panel-image" src="{{promoImage}}" alt="Promotional
|
|
8
|
+
<img class="promo-panel-image" src="{{promoImage}}" alt="{{isdefined promoImageDescription "Promotional image"}}">
|
|
9
9
|
{{else}}
|
|
10
10
|
<div class="promo-panel-image"></div>
|
|
11
11
|
{{/ifCond}}
|
|
@@ -3,38 +3,40 @@
|
|
|
3
3
|
-->
|
|
4
4
|
<div class="qld-search-input {{customClass}}">
|
|
5
5
|
<input id="{{ inputID }}" name="{{ inputName }}" class="form-control" type="text" autocomplete="off"
|
|
6
|
-
aria-label="{{ ariaLabel }}" {{#each tags}} data-{{@key}}="{{this}}" {{/each}} />
|
|
7
|
-
<button class="btn btn-primary" type="{{ buttonType }}" id="{{ buttonID }}">
|
|
8
|
-
<span class="btn-icon"></span>
|
|
6
|
+
aria-label="{{ ariaLabel }}" {{#each tags}} data-{{@key}}="{{this}}" {{/each}} placeholder="{{placeholder}}" />
|
|
7
|
+
<button class="btn btn-primary" type="{{ buttonType }}" id="{{ buttonID }}" aria-label="{{ buttonLabel }}">
|
|
8
|
+
<span class="btn-icon" aria-hidden="true"></span>
|
|
9
9
|
<span class="btn-label">{{ buttonLabel }}</span>
|
|
10
10
|
</button>
|
|
11
11
|
{{#ifCond hasDynamicSuggestions '||' hasDefaultSuggestions}}
|
|
12
|
-
|
|
12
|
+
|
|
13
|
+
<div class="suggestions suggestions__group default">
|
|
13
14
|
{{#if hasDefaultSuggestions}}
|
|
14
15
|
<div class="default-suggestions">
|
|
15
16
|
<div class="suggestions-category">
|
|
16
17
|
<strong class="suggestions-category-label d-block">{{defaultSuggestions.popularServicesTitle}}</strong>
|
|
17
18
|
<ul>
|
|
18
19
|
{{#each defaultSuggestions.popularServices}}
|
|
19
|
-
<li><a href="{{link}}">{{title}}</a></li>
|
|
20
|
+
<li><a tabindex="0" href="{{link}}">{{title}}</a></li>
|
|
20
21
|
{{/each}}
|
|
21
22
|
{{#if defaultSuggestions.popularServicesLink}}
|
|
22
|
-
<li><a href="{{defaultSuggestions.popularServicesLink.href}}" class="view-more">{{#if defaultSuggestions.popularServicesLink.label}}{{defaultSuggestions.popularServicesLink.label}}{{else}}View More{{/if}}</a></li>
|
|
23
|
+
<li><a tabindex="0" href="{{defaultSuggestions.popularServicesLink.href}}" class="view-more">{{#if defaultSuggestions.popularServicesLink.label}}{{defaultSuggestions.popularServicesLink.label}}{{else}}View More{{/if}}</a></li>
|
|
23
24
|
{{/if}}
|
|
24
25
|
</ul>
|
|
25
26
|
</div>
|
|
26
|
-
|
|
27
|
+
{{#if defaultSuggestions.categories}}
|
|
27
28
|
<div class="suggestions-category">
|
|
28
29
|
<strong class="suggestions-category-label d-block">{{defaultSuggestions.categoriesTitle}}</strong>
|
|
29
30
|
<ul>
|
|
30
31
|
{{#each defaultSuggestions.categories}}
|
|
31
|
-
<li><a href="{{link}}">{{title}}</a></li>
|
|
32
|
+
<li><a tabindex="0"href="{{link}}">{{title}}</a></li>
|
|
32
33
|
{{/each}}
|
|
33
34
|
{{#if defaultSuggestions.categoriesLink}}
|
|
34
|
-
<li><a href="{{defaultSuggestions.categoriesLink.href}}" class="view-more">{{#if defaultSuggestions.categoriesLink.label}}{{defaultSuggestions.categoriesLink.label}}{{else}}View More{{/if}}</a></li>
|
|
35
|
+
<li><a tabindex="0" href="{{defaultSuggestions.categoriesLink.href}}" class="view-more">{{#if defaultSuggestions.categoriesLink.label}}{{defaultSuggestions.categoriesLink.label}}{{else}}View More{{/if}}</a></li>
|
|
35
36
|
{{/if}}
|
|
36
37
|
</ul>
|
|
37
38
|
</div>
|
|
39
|
+
{{/if}}
|
|
38
40
|
</div>
|
|
39
41
|
{{/if}}
|
|
40
42
|
{{#if hasDynamicSuggestions}}
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@qld-gov-au/qgds-bootstrap5",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.1.1",
|
|
4
4
|
"description": "",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -12,13 +12,15 @@
|
|
|
12
12
|
},
|
|
13
13
|
"scripts": {
|
|
14
14
|
"prepare": "husky && npm run build",
|
|
15
|
+
"ci:all": "npm ci && npm run lint && npm run test:run && npm run test:integration && npm run build && npm run build-storybook",
|
|
15
16
|
"start": "npm run build",
|
|
16
17
|
"lint": "eslint --fix --ext .js,.json --ignore-pattern 'docs/*' --ignore-pattern 'dist/*' --ignore-pattern 'storybook-static/*' --ignore-pattern 'src/js/handlebars.partials.js' .",
|
|
17
18
|
"build": "node esbuild.js",
|
|
18
19
|
"build:icons": "node esbuild.js --icons",
|
|
19
20
|
"build:theme": "node esbuild.js --theme",
|
|
20
21
|
"build:theme:icons": "node esbuild.js --theme --icons",
|
|
21
|
-
"test": "vitest",
|
|
22
|
+
"test": "vitest watch",
|
|
23
|
+
"test:run": "vitest run",
|
|
22
24
|
"test:ui": "vitest --ui",
|
|
23
25
|
"test:integration": "npm-run-all --parallel --race serve:test test:testrunner",
|
|
24
26
|
"test:testrunner": "sleep 2 && mocha --timeout 10000 --require ./test/testServer.test.js ",
|
|
@@ -53,56 +55,55 @@
|
|
|
53
55
|
"bootstrap": "^5.3.8"
|
|
54
56
|
},
|
|
55
57
|
"devDependencies": {
|
|
56
|
-
"@chromatic-com/storybook": "^4.1.
|
|
58
|
+
"@chromatic-com/storybook": "^4.1.3",
|
|
57
59
|
"@eslint/eslintrc": "^3.3.1",
|
|
58
|
-
"@eslint/json": "^0.
|
|
60
|
+
"@eslint/json": "^0.14.0",
|
|
59
61
|
"@qld-gov-au/qgds-tokens": "^1.2.1",
|
|
60
|
-
"@storybook/addon-a11y": "^
|
|
61
|
-
"@storybook/addon-docs": "^
|
|
62
|
-
"@storybook/addon-links": "^
|
|
63
|
-
"@storybook/addon-themes": "^
|
|
64
|
-
"@storybook/cli": "^
|
|
65
|
-
"@storybook/html-vite": "^
|
|
66
|
-
"@
|
|
67
|
-
"@vitest/ui": "^3.2.4",
|
|
62
|
+
"@storybook/addon-a11y": "^10.0.8",
|
|
63
|
+
"@storybook/addon-docs": "^10.0.8",
|
|
64
|
+
"@storybook/addon-links": "^10.0.8",
|
|
65
|
+
"@storybook/addon-themes": "^10.0.8",
|
|
66
|
+
"@storybook/cli": "^10.0.8",
|
|
67
|
+
"@storybook/html-vite": "^10.0.8",
|
|
68
|
+
"@vitest/ui": "^4.0.10",
|
|
68
69
|
"autoprefixer": "^10.4.20",
|
|
69
|
-
"chai": "^
|
|
70
|
-
"chalk": "^5.
|
|
71
|
-
"chromatic": "^13.3.
|
|
72
|
-
"esbuild": "0.
|
|
70
|
+
"chai": "^6.2.1",
|
|
71
|
+
"chalk": "^5.6.2",
|
|
72
|
+
"chromatic": "^13.3.3",
|
|
73
|
+
"esbuild": "0.27.0",
|
|
73
74
|
"esbuild-plugin-copy": "^2.1.1",
|
|
74
|
-
"esbuild-plugin-eslint": "^0.3.
|
|
75
|
+
"esbuild-plugin-eslint": "^0.3.12",
|
|
75
76
|
"esbuild-plugin-handlebars": "1.0.3",
|
|
76
77
|
"esbuild-sass-plugin": "3.3.1",
|
|
77
|
-
"eslint": "9.
|
|
78
|
+
"eslint": "9.39.1",
|
|
78
79
|
"eslint-plugin-json": "^4.0.1",
|
|
79
|
-
"eslint-plugin-storybook": "^
|
|
80
|
-
"globals": "16.
|
|
80
|
+
"eslint-plugin-storybook": "^10.0.8",
|
|
81
|
+
"globals": "16.5.0",
|
|
81
82
|
"handlebars": "4.7.8",
|
|
82
83
|
"http-server": "^14.1.1",
|
|
83
84
|
"husky": "^9.1.7",
|
|
84
|
-
"jsdom": "^
|
|
85
|
+
"jsdom": "^27.2.0",
|
|
85
86
|
"mini-svg-data-uri": "^1.4.4",
|
|
86
87
|
"minimist": "^1.2.8",
|
|
87
|
-
"mocha": "^11.
|
|
88
|
+
"mocha": "^11.7.5",
|
|
88
89
|
"node-html-parser": "^7.0.1",
|
|
89
90
|
"npm-run-all2": "^8.0.4",
|
|
90
91
|
"onchange": "^7.1.0",
|
|
91
|
-
"portfinder": "^1.0.
|
|
92
|
-
"postcss": "^8.5.
|
|
92
|
+
"portfinder": "^1.0.38",
|
|
93
|
+
"postcss": "^8.5.6",
|
|
93
94
|
"prettier": "3.6.2",
|
|
94
95
|
"raw-loader": "^4.0.2",
|
|
95
|
-
"rimraf": "^6.0
|
|
96
|
+
"rimraf": "^6.1.0",
|
|
96
97
|
"run-parallel": "^1.2.0",
|
|
97
|
-
"sass": "^1.
|
|
98
|
-
"selenium-webdriver": "^4.
|
|
99
|
-
"storybook": "^
|
|
100
|
-
"storybook-addon-deep-controls": "^0.
|
|
101
|
-
"vite": "^
|
|
102
|
-
"vitest": "^
|
|
98
|
+
"sass": "^1.94.0",
|
|
99
|
+
"selenium-webdriver": "^4.38.0",
|
|
100
|
+
"storybook": "^10.0.8",
|
|
101
|
+
"storybook-addon-deep-controls": "^0.10.0",
|
|
102
|
+
"vite": "^7.1.11",
|
|
103
|
+
"vitest": "^4.0.10"
|
|
103
104
|
},
|
|
104
105
|
"peerDependencies": {
|
|
105
|
-
"typescript": "
|
|
106
|
+
"typescript": ">=5.0.0 <5.9.0"
|
|
106
107
|
},
|
|
107
108
|
"exports": {
|
|
108
109
|
"./qld.bootstrap.min.js": "./dist/assets/js/qld.bootstrap.min.js",
|
|
@@ -61,18 +61,21 @@
|
|
|
61
61
|
"followLinks": [
|
|
62
62
|
{
|
|
63
63
|
"label": "Facebook",
|
|
64
|
+
"accessibleLabel": "Facebook page",
|
|
64
65
|
"link": "#",
|
|
65
66
|
"icon": "facebook",
|
|
66
67
|
"target": "_blank"
|
|
67
68
|
},
|
|
68
69
|
{
|
|
69
70
|
"label": "LinkedIn",
|
|
71
|
+
"accessibleLabel": "LinkedIn page",
|
|
70
72
|
"link": "#",
|
|
71
73
|
"icon": "linkedin",
|
|
72
74
|
"target": "_blank"
|
|
73
75
|
},
|
|
74
76
|
{
|
|
75
77
|
"label": "X (Twitter)",
|
|
78
|
+
"accessibleLabel": "X page",
|
|
76
79
|
"link": "#",
|
|
77
80
|
"icon": "x",
|
|
78
81
|
"target": "_blank"
|
|
@@ -12,10 +12,10 @@
|
|
|
12
12
|
},
|
|
13
13
|
|
|
14
14
|
"pages": [
|
|
15
|
-
{ "href": "#", "linktext": "1", "customClasses": "" },
|
|
16
|
-
{ "href": "#", "linktext": "2", "customClasses": "active" },
|
|
17
|
-
{ "href": "#", "linktext": "3", "customClasses": "" },
|
|
15
|
+
{ "href": "#", "linktext": "1", "arialabel": "Page 1", "customClasses": "" },
|
|
16
|
+
{ "href": "#", "linktext": "2", "arialabel": "Page 2, current page", "customClasses": "active" },
|
|
17
|
+
{ "href": "#", "linktext": "3", "arialabel": "Page 3", "customClasses": "" },
|
|
18
18
|
{ "href": "#", "linktext": "", "customClasses": "more", "more": true },
|
|
19
|
-
{ "href": "#", "linktext": "7", "customClasses": "" }
|
|
19
|
+
{ "href": "#", "linktext": "7", "arialabel": "Page 7", "customClasses": "" }
|
|
20
20
|
]
|
|
21
21
|
}
|
|
@@ -1,48 +1,46 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
}
|
|
48
|
-
}
|
|
2
|
+
"type": "indent-text",
|
|
3
|
+
"variantClass": "light",
|
|
4
|
+
"promoImage": "./assets/img/banner-example-3-to-2.jpg",
|
|
5
|
+
"promoImageDescription": "Promotional image",
|
|
6
|
+
"contentAlignment": "content-left",
|
|
7
|
+
"icon": "icon-dot-grid",
|
|
8
|
+
"title": "Title goes here and has a maximum of 65 character limit",
|
|
9
|
+
"abstract": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed tortor, leo vulputate ut odio mattis.",
|
|
10
|
+
"body": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed tortor, leo vulputate ut odio mattis. Vel suspendisse mi quisque consequat aliquet egestas.",
|
|
11
|
+
"cta": {
|
|
12
|
+
"items": [
|
|
13
|
+
{
|
|
14
|
+
"url": "#",
|
|
15
|
+
"id": "https://www.wired.com",
|
|
16
|
+
"value": "Label",
|
|
17
|
+
"target": "_blank",
|
|
18
|
+
"class": [{ "small": false }, { "view-all": false }]
|
|
19
|
+
}
|
|
20
|
+
]
|
|
21
|
+
},
|
|
22
|
+
"btn": {
|
|
23
|
+
"items": [
|
|
24
|
+
{
|
|
25
|
+
"variantClass": "btn-primary",
|
|
26
|
+
"islink": true,
|
|
27
|
+
"isdisabled": false,
|
|
28
|
+
"iconClass": "",
|
|
29
|
+
"iconPosition": "",
|
|
30
|
+
"label": "Primary",
|
|
31
|
+
"href": "https://google.com",
|
|
32
|
+
"target": "_self"
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"variantClass": "btn-secondary",
|
|
36
|
+
"islink": true,
|
|
37
|
+
"isdisabled": false,
|
|
38
|
+
"iconClass": "",
|
|
39
|
+
"iconPosition": "",
|
|
40
|
+
"label": "Secondary",
|
|
41
|
+
"href": "https://google.com",
|
|
42
|
+
"target": "_self"
|
|
43
|
+
}
|
|
44
|
+
]
|
|
45
|
+
}
|
|
46
|
+
}
|