@dubai-design-system/components-js 3.11.2 → 3.11.4
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/dist/cjs/dda-header-menu_3.cjs.entry.js +2 -2
- package/dist/cjs/dda-header-menu_3.cjs.entry.js.map +1 -1
- package/dist/cjs/dda-header.cjs.entry.js +21 -9
- package/dist/cjs/dda-header.cjs.entry.js.map +1 -1
- package/dist/cjs/dda-search-input.cjs.entry.js +12 -1
- package/dist/cjs/dda-search-input.cjs.entry.js.map +1 -1
- package/dist/cjs/dda-select.cjs.entry.js +1 -1
- package/dist/cjs/dda-select.cjs.entry.js.map +1 -1
- package/dist/cjs/dda-toggle.cjs.entry.js +7 -7
- package/dist/cjs/dda-toggle.cjs.entry.js.map +1 -1
- package/dist/cjs/dda.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/dda-header/dda-header.js +74 -9
- package/dist/collection/components/dda-header/dda-header.js.map +1 -1
- package/dist/collection/components/dda-header-menu/dda-header-menu.js +2 -2
- package/dist/collection/components/dda-header-menu/dda-header-menu.js.map +1 -1
- package/dist/collection/components/dda-search-input/dda-search-input.js +64 -2
- package/dist/collection/components/dda-search-input/dda-search-input.js.map +1 -1
- package/dist/collection/components/dda-select/dda-select.js +1 -1
- package/dist/collection/components/dda-select/dda-select.js.map +1 -1
- package/dist/collection/components/dda-toggle/dda-toggle.js +24 -7
- package/dist/collection/components/dda-toggle/dda-toggle.js.map +1 -1
- package/dist/components/dda-header-menu.js +1 -1
- package/dist/components/dda-header.js +24 -10
- package/dist/components/dda-header.js.map +1 -1
- package/dist/components/dda-search-input.js +16 -3
- package/dist/components/dda-search-input.js.map +1 -1
- package/dist/components/dda-select.js +1 -1
- package/dist/components/dda-select.js.map +1 -1
- package/dist/components/dda-toggle.js +8 -8
- package/dist/components/dda-toggle.js.map +1 -1
- package/dist/components/{p-256a4938.js → p-c30037a8.js} +3 -3
- package/dist/components/p-c30037a8.js.map +1 -0
- package/dist/dda/dda.esm.js +1 -1
- package/dist/dda/dda.esm.js.map +1 -1
- package/dist/dda/p-23c2a581.entry.js +2 -0
- package/dist/dda/p-23c2a581.entry.js.map +1 -0
- package/dist/dda/p-2477d805.entry.js +2 -0
- package/dist/dda/p-2477d805.entry.js.map +1 -0
- package/dist/dda/p-5a8cfeec.entry.js +2 -0
- package/dist/dda/p-5a8cfeec.entry.js.map +1 -0
- package/dist/dda/{p-2a57fd0d.entry.js → p-a5199deb.entry.js} +2 -2
- package/dist/dda/p-a5199deb.entry.js.map +1 -0
- package/dist/dda/p-bb94fb97.entry.js +2 -0
- package/dist/dda/p-bb94fb97.entry.js.map +1 -0
- package/dist/esm/dda-header-menu_3.entry.js +2 -2
- package/dist/esm/dda-header-menu_3.entry.js.map +1 -1
- package/dist/esm/dda-header.entry.js +21 -9
- package/dist/esm/dda-header.entry.js.map +1 -1
- package/dist/esm/dda-search-input.entry.js +13 -2
- package/dist/esm/dda-search-input.entry.js.map +1 -1
- package/dist/esm/dda-select.entry.js +1 -1
- package/dist/esm/dda-select.entry.js.map +1 -1
- package/dist/esm/dda-toggle.entry.js +8 -8
- package/dist/esm/dda-toggle.entry.js.map +1 -1
- package/dist/esm/dda.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/dda-header/dda-header.d.ts +4 -0
- package/dist/types/components/dda-search-input/dda-search-input.d.ts +8 -0
- package/dist/types/components/dda-toggle/dda-toggle.d.ts +2 -0
- package/dist/types/components.d.ts +42 -0
- package/package.json +2 -2
- package/readme.md +13 -1
- package/www/build/dda.esm.js +1 -1
- package/www/build/dda.esm.js.map +1 -1
- package/www/build/p-23c2a581.entry.js +2 -0
- package/www/build/p-23c2a581.entry.js.map +1 -0
- package/www/build/p-2477d805.entry.js +2 -0
- package/www/build/p-2477d805.entry.js.map +1 -0
- package/www/build/p-5a8cfeec.entry.js +2 -0
- package/www/build/p-5a8cfeec.entry.js.map +1 -0
- package/www/build/{p-2a57fd0d.entry.js → p-a5199deb.entry.js} +2 -2
- package/www/build/p-a5199deb.entry.js.map +1 -0
- package/www/build/p-bb94fb97.entry.js +2 -0
- package/www/build/p-bb94fb97.entry.js.map +1 -0
- package/dist/components/p-256a4938.js.map +0 -1
- package/dist/dda/p-152fa1ea.entry.js +0 -2
- package/dist/dda/p-152fa1ea.entry.js.map +0 -1
- package/dist/dda/p-2a57fd0d.entry.js.map +0 -1
- package/dist/dda/p-61794089.entry.js +0 -2
- package/dist/dda/p-61794089.entry.js.map +0 -1
- package/dist/dda/p-a38e72e8.entry.js +0 -2
- package/dist/dda/p-a38e72e8.entry.js.map +0 -1
- package/dist/dda/p-f4ea252b.entry.js +0 -2
- package/dist/dda/p-f4ea252b.entry.js.map +0 -1
- package/www/build/p-152fa1ea.entry.js +0 -2
- package/www/build/p-152fa1ea.entry.js.map +0 -1
- package/www/build/p-2a57fd0d.entry.js.map +0 -1
- package/www/build/p-61794089.entry.js +0 -2
- package/www/build/p-61794089.entry.js.map +0 -1
- package/www/build/p-a38e72e8.entry.js +0 -2
- package/www/build/p-a38e72e8.entry.js.map +0 -1
- package/www/build/p-f4ea252b.entry.js +0 -2
- package/www/build/p-f4ea252b.entry.js.map +0 -1
|
@@ -15,6 +15,7 @@ export class DdaHeader {
|
|
|
15
15
|
this.useNavigator = 'false';
|
|
16
16
|
this.mobileMenuSearchId = 'mobileSearch';
|
|
17
17
|
this.mobileMenuSearchUrl = 'javascript:void(0)';
|
|
18
|
+
this.selected_contrast = "normal";
|
|
18
19
|
this.hideOtherMenu = false;
|
|
19
20
|
this.parsedOtherMenuItems = [];
|
|
20
21
|
this.parsedDropDownMenuItems = [];
|
|
@@ -102,24 +103,31 @@ export class DdaHeader {
|
|
|
102
103
|
this.languageSwitch.emit();
|
|
103
104
|
};
|
|
104
105
|
this.smTexthandler = () => {
|
|
106
|
+
this.selected_text_size = "small";
|
|
105
107
|
this.smTextSize.emit();
|
|
106
108
|
};
|
|
107
109
|
this.baseTexthandler = () => {
|
|
110
|
+
this.selected_text_size = "normal";
|
|
108
111
|
this.baseTextSize.emit();
|
|
109
112
|
};
|
|
110
113
|
this.lgTexthandler = () => {
|
|
114
|
+
this.selected_text_size = "large";
|
|
111
115
|
this.lgTextSize.emit();
|
|
112
116
|
};
|
|
113
117
|
this.normalContrasthandler = () => {
|
|
118
|
+
this.selected_contrast = "normal";
|
|
114
119
|
this.normalContrast.emit();
|
|
115
120
|
};
|
|
116
121
|
this.blindContrasthandler = () => {
|
|
122
|
+
this.selected_contrast = "colorblind";
|
|
117
123
|
this.blindContrast.emit();
|
|
118
124
|
};
|
|
119
125
|
this.redContrasthandler = () => {
|
|
126
|
+
this.selected_contrast = "redweakness";
|
|
120
127
|
this.redContrast.emit();
|
|
121
128
|
};
|
|
122
129
|
this.greenContrasthandler = () => {
|
|
130
|
+
this.selected_contrast = "greenweakness";
|
|
123
131
|
this.greenContrast.emit();
|
|
124
132
|
};
|
|
125
133
|
this.accessibilitymenuhandler = () => {
|
|
@@ -131,12 +139,15 @@ export class DdaHeader {
|
|
|
131
139
|
this.searchhandler = searchval => {
|
|
132
140
|
this.searchfunctionality.emit(searchval);
|
|
133
141
|
};
|
|
142
|
+
this.toggleLogin = () => {
|
|
143
|
+
this.loginClick.emit();
|
|
144
|
+
};
|
|
134
145
|
this.renderSubMenu = (subMenu, parentLi) => {
|
|
135
146
|
if (!subMenu || subMenu.length === 0)
|
|
136
147
|
return null;
|
|
137
|
-
return (h("div", { class: `main_sub_menu ${this.openMenus[parentLi] ? 'showSubMenu' : ''}` }, subMenu[0].headerLabel && h("
|
|
148
|
+
return (h("div", { class: `main_sub_menu ${this.openMenus[parentLi] ? 'showSubMenu' : ''}` }, subMenu[0].headerLabel && h("h6", { class: "dda-side-nav__title" }, subMenu[0].headerLabel), h("ol", null, subMenu.map((item, index) => {
|
|
138
149
|
const currentIndex = `${parentLi}-${index}`;
|
|
139
|
-
return (h("li", { key: currentIndex }, h("a", { href: this.useNavigator ==
|
|
150
|
+
return (h("li", { key: currentIndex }, h("a", { href: this.useNavigator == 'true' ? 'javascript:void(0)' : item.href, class: `${item.subLinkClass} ${item.subMenu && item.subMenu.length > 0 ? 'showSub' : ''}`, onClick: e => {
|
|
140
151
|
this.handleMenuClick(e, item, currentIndex);
|
|
141
152
|
} }, item.label), this.renderSubMenu(item.subMenu, currentIndex)));
|
|
142
153
|
}))));
|
|
@@ -235,18 +246,18 @@ export class DdaHeader {
|
|
|
235
246
|
}
|
|
236
247
|
else {
|
|
237
248
|
console.log('check navigator', this.useNavigator, this.navigatorClick);
|
|
238
|
-
if (this.useNavigator ==
|
|
249
|
+
if (this.useNavigator == 'true') {
|
|
239
250
|
this.navigatorClick.emit(item.href);
|
|
240
251
|
}
|
|
241
252
|
}
|
|
242
253
|
}
|
|
243
254
|
render() {
|
|
244
255
|
const sideMenuItems = this.parseJsonArray(this.sideMenuItems);
|
|
245
|
-
return (h("header", { key: '
|
|
256
|
+
return (h("header", { key: '5b3a3813776b22c58ad7e4a2aefad2b39b761a3a', class: 'dda-header' }, h("div", { key: '971e102a55c77ec014c622e30b39e8f6fa95c370', class: "dda-head-logo" }, h("a", { key: '6757fa31aae9e45f318697b69d28b546da11159c', href: this.useNavigator == 'true' ? 'javascript:void(0)' : this.firstLogoHref, onClick: () => (this.useNavigator == 'true' ? this.navigatorClick.emit(this.firstLogoHref) : ''), class: "govt-logo" }, h("img", { key: 'a5c8833849236777cfa78bdb44a15888d81ebe6b', class: "logo-white", src: this.firstLogoWhiteSrc, alt: `${this.firstLogoAlt} White` }), h("img", { key: '21fa8096c11780cbec19f19d1f63f9d4a13a0318', class: "logo-colored", src: this.firstLogoSrc, alt: this.firstLogoAlt })), h("a", { key: '1ac6a9058edbb62416b86dca33608ef8996e58b1', href: this.useNavigator == 'true' ? 'javascript:void(0)' : this.secondLogoHref, onClick: () => (this.useNavigator == 'true' ? this.navigatorClick.emit(this.secondLogoHref) : ''), class: "entt-logo" }, h("img", { key: 'e05bdf61cf1f17af4626fa83ad1b6028c7c81a59', class: "logo-white", src: this.secondLogoWhiteSrc, alt: `${this.secondLogoAlt} White` }), h("img", { key: '3910bceaa2c18c9b282a3e3f7c60faf869d47fae', class: "logo-colored", src: this.secondLogoSrc, alt: this.secondLogoAlt }))), h("div", { key: '461e1fd23356c18774be40ea282459b42f2691d3', class: "dda-menu-container" }, h("div", { key: '345eda9d0b3a68dfee74aeafa3f22f14bcc3f634', class: "dda-main-navigation" }, h("div", { key: '3bd8dffbda85e83640e8f2c96bf486142dfdff4f', class: `dda-menu-overley ${this.isMenuOpen ? 'show-overley' : ''}`, onClick: this.toggleMenu }), h("div", { key: '9bc8b4eca9dd792d7fb38c6b28c9ccca71819509', class: "hamburger-menu", onClick: this.toggleMenu }, h("dda-tooltip", { key: 'aecac2047e399458ed27721e453958379da37729', title_text: this.hamburger_menu_button_name, position: "top", class: "dda-d-block" }, h("button", { key: '1c99b38cfe929568d1a8c59a198afb36a5fc03a8', type: "button", class: "hamburger-menu-btn", name: this.hamburger_menu_button_name }, h("span", { key: '73a7fa9fca06df34eb1097bab60c90e0a8266812', class: "hamburger-line" }), h("span", { key: '2884ca405ab7168c6740b051284cdefd1c6b89aa', class: "hamburger-menu-text" }, this.hamburger_menu_button_name)))), h("div", { key: 'b1d1982a8efa8e647011e4cc3c61f4b44a34eaff', class: "dda-sidemenu", style: { display: this.isMenuOpen ? 'block' : '', insetInlineStart: this.isMenuOpen ? '0px' : '' } }, h("div", { key: '54e31cecc2fb10b0eccf43f953954bc5b3dbcc3b', class: "dda-sidemenu-content" }, h("h6", { key: 'd3afb136281500a34d90816f17e6d2283ff255b1', class: "dda-side-nav-title" }, this.sideMainMenuTitle), h("ul", { key: '9e699de177dd5c3dfdb1fe3b6000fc1bb648d73d', class: "main_side_menu" }, sideMenuItems.map((menu, index) => {
|
|
246
257
|
const currentIndex = `menu-${index}`;
|
|
247
258
|
return (h("li", { key: currentIndex, id: `header_${menu.label}` }, h("a", {
|
|
248
259
|
// href={menu.href}
|
|
249
|
-
href: this.useNavigator ==
|
|
260
|
+
href: this.useNavigator == 'true' ? 'javascript:void(0)' : menu.href, class: menu.subMenu && menu.subMenu.length > 0 ? 'showSub' : '', onClick: e => {
|
|
250
261
|
if (menu.subMenu && menu.subMenu.length > 0) {
|
|
251
262
|
e.preventDefault();
|
|
252
263
|
const current = e.currentTarget;
|
|
@@ -265,19 +276,19 @@ export class DdaHeader {
|
|
|
265
276
|
this.toggleSidebarSubMenu(currentIndex);
|
|
266
277
|
}
|
|
267
278
|
else {
|
|
268
|
-
if (this.useNavigator ==
|
|
279
|
+
if (this.useNavigator == 'true') {
|
|
269
280
|
this.navigatorClick.emit(menu.href);
|
|
270
281
|
}
|
|
271
282
|
}
|
|
272
283
|
}
|
|
273
284
|
}, menu.label), this.renderSubMenu(menu.subMenu, currentIndex)));
|
|
274
|
-
})), this.hideOtherMenu == false && h("p", { key: '7b948023a69c525a925ec5ed1e16be53247824f8', class: "dda-side-nav-title" }, this.sideOtherMenuTitle), !this.hideOtherMenu && (h("ul", { key: '24b3239603e6e63bbc3b1466a39b3ff0fa980b56', class: "main_side_menu" }, this.parsedOtherMenuItems.map((itemlist, index) => (h("li", { key: `other-${index}` }, h("a", { href: this.useNavigator == "true" ? 'javascript:void(0)' : itemlist.href, onClick: () => this.useNavigator == "true" ? this.navigatorClick.emit(itemlist.href) : "" }, itemlist.label))))))), h("div", { key: 'a642a9bd5a19ae73f30ad304d9a3ffa3ebfc6bfa', class: "dda-sidemenu-bottom" }, h("div", { key: 'b9124e37e11679ca02a7aed1aff2d5d3f40d55c7', class: "dda-sidemenu-gov-logo" }, h("a", { key: '5cdced20b8e20795023c21f26be09738b301fb49', href: this.useNavigator == "true" ? 'javascript:void(0)' : this.firstLogoHref, onClick: () => this.useNavigator == "true" ? this.navigatorClick.emit(this.firstLogoHref) : "", class: "govt-logo dda-mb-2" }, h("img", { key: 'e35667da5a2ab4b16964a3a8ba9bd36b58af5754', class: "", src: this.firstLogoSrc, alt: this.firstLogoAlt }))), h("div", { key: '29d24a79ecad7192986aff73cfe40685e4fd234a', class: "dda-toolbar-menu-sidemenu" }, h("ul", { key: 'd27d6549ca3c36b6a41889b495ececdfb880fe83' }, this.accessibility_button_id && (h("li", { key: '33e38e43a1280d5639503f5132589528705888d2' }, h("button", { key: '0bd39c2522d90a54791cff5c7970e50f08b43e9a', name: this.toggle_accessibility_button_name, class: "tool-btn accessibility-btn", type: "button", onClick: this.toggleMobileAccessibilty, id: this.accessibility_button_id }, h("i", { key: '4cf9cc02d768ebc4cad0cca3f0d335bd8573ea0b', class: this.accessibility_button_icon_family }, this.accessibility_button_icon_name), h("span", { key: 'e6abfd1c4197a5983382bb71fa668da9b30a68fe', class: "visually-hidden" }, this.accessibility_button_text)))), this.language_text && (h("li", { key: 'f3200292e65f25625e0967fb163d622c164b1c3a' }, h("button", { key: '0b93e773b7ce02deda37a52e2a97bbe223d15ee0', name: this.language_button_name, class: "tool-btn", type: "button", onClick: this.languagehandler }, this.language_text))), this.loginText && (h("li", { key: '9c373a95f9622fe5e564aac19df0dabc0d067886' }, h("dda-link-button", { key: '7e3baaca4d7e775b6dd5aeba799d104f1a32a5f4', button_color: "onsurface-secondary", start_icon: this.loginIcon, custom_class: "tool-btn", link_button_text: this.loginText, href: this.loginLink, button_shape: "circle", size: "sm" })))))), h("button", { key: '9f040d397435fd4c4d250a4d50cd22f8697eafa6', type: "button", name: this.close_menu_button_name, class: "close-btn side-nav-close-btn", "aria-label": "Close Sidebar", onClick: this.toggleMenu }, h("i", { key: '4a111ed3e872d77feba712bf436fa14a2b6816e5', class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "close")), this.usePredesignedAccessibilityMenu ? (h("div", { class: "dda-accessibility hide-accessibility mobile-accessibility", style: { display: this.isMobileAccessibiltyOpen ? 'block' : 'none' } }, h("div", { class: "mobile-accessibility-content" }, h("div", { class: "dda-row" }, h("div", { class: "dda-col-md-4 dda-accessibility-item" }, h("p", { class: "h6 Regular dda-mb-1" }, this.contrast_title), h("form", null, h("fieldset", { class: "dda-theme-list" }, h("legend", null, h("p", { class: "body Regular dda-mb-3" }, this.contrast_description)), this.contrast_noraml_text ? (h("dda-radiobutton", { title_text: this.contrast_noraml_text, checked: true, size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "NormalThemeMobile", group_name: "themeselectionMobile", input_id: "NormalThemeMobile", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.normalContrasthandler, class: "hydrated" })) : null, this.contrast_color_blind_text ? (h("dda-radiobutton", { title_text: this.contrast_color_blind_text, checked: false, size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "ColoursBlindMobile", group_name: "themeselectionMobile", input_id: "ColoursBlindMobile", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.blindContrasthandler, class: "hydrated" })) : null, this.contrast_red_weakness_text ? (h("dda-radiobutton", { title_text: this.contrast_red_weakness_text, checked: false, size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "RedWeaknessMobile", group_name: "themeselectionMobile", input_id: "RedWeaknessMobile", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.redContrasthandler, class: "hydrated" })) : null, this.contrast_green_weakness_text ? (h("dda-radiobutton", { title_text: this.contrast_green_weakness_text, checked: false, size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "GreenWeaknessMobile", group_name: "themeselectionMobile", input_id: "GreenWeaknessMobile", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.greenContrasthandler, class: "hydrated" })) : null))), h("div", { class: "dda-col-md-4 dda-accessibility-item" }, h("p", { class: "h6 Regular dda-mb-1" }, this.screen_reader_title), h("p", { class: "body Regular dda-mb-3" }, this.screen_reader_description), h("div", { class: "rs_skip rsbtn rs_preserve rs_mobile", id: "readspeaker_button1" }, h("a", { rel: "nofollow", href: this.read_speaker_link, role: "button", class: "rsbtn_play circle readspeaker", accessKey: "L", "aria-label": "Listen to this page using ReadSpeaker", "data-rsshortcut": "play", "aria-haspopup": "menu", "data-rs-lang": "en_uk" }, h("i", { class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "volume_up")))), h("div", { class: "dda-col-md-4 dda-accessibility-item" }, h("p", { class: "h6 Regular dda-mb-1" }, this.text_size_title), h("p", { class: "body Regular dda-mb-3" }, this.text_size_description), h("div", { class: "dda-d-flex dda-gap-4" }, h("dda-button", { button_color: "default-secondary", button_text: "A", icon_button_shape: "circle", custom_class: "", size: "lg", onClick: this.baseTexthandler }), h("dda-button", { button_color: "default-secondary", button_text: "A+", icon_button_shape: "circle", custom_class: "", size: "lg", onClick: this.lgTexthandler }), h("dda-button", { button_color: "default-secondary", button_text: "A-", icon_button_shape: "circle", custom_class: "", size: "lg", onClick: this.smTexthandler }))))), h("button", { type: "button", name: this.close_accessibility_button_name, class: "close-btn close_accessibility", "aria-label": "Close Accessibility", onClick: this.toggleMobileAccessibilty }, h("i", { class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "close")))) : null), this.quickLinks && h("dda-header-menu", { key: '4736381c58195033efaf5d3c7157ce12d536be6f', "use-navigator": this.useNavigator, "navigator-click": this.navigatorClick, "quick-links": typeof this.quickLinks === 'string' ? this.quickLinks : JSON.stringify(this.quickLinks) })), h("div", { key: 'beb8812806d83a8cf926bf73267d3f23eaaea1d4', class: "dda-mobile-entt-logo" }, h("a", { key: 'b8b558b72c8c09f9635c07b27ff3bc5701217898', href: this.useNavigator == "true" ? 'javascript:void(0)' : this.secondLogoHref, onClick: () => this.useNavigator == "true" ? this.navigatorClick.emit(this.secondLogoHref) : "", class: "entt-logo" }, h("img", { key: '4656e0909c8a1446eb072de7d7561c853df2fb33', class: "logo-colored", src: this.secondLogoSrc, alt: this.secondLogoAlt }), h("img", { key: 'af50f82c652803eadd9ac776ee848a8b3e24c07c', class: "logo-white", src: this.secondLogoWhiteSrc, alt: this.secondLogoAlt }))), h("div", { key: 'd5f83006305e5a527814157c5e5c135dce5aeb98', class: "dda-mobile-search" }, this.mobileMenuSearchId && (h("a", { key: '33f75a6cb279429c1645536e8f83722d53afec60', href: this.useNavigator == "true" ? 'javascript:void(0)' : this.mobileMenuSearchUrl, onClick: () => this.useNavigator == "true" ? this.navigatorClick.emit(this.mobileMenuSearchUrl) : "", class: "tool-btn", id: this.mobileMenuSearchId }, h("span", { key: '684d7dd95b924b6efb81d2f5fd6b50e3ececd3e9', class: "visualy-hidden" }, this.searchText || 'Search'), h("i", { key: '69599948bfc6e5483b23d3c2b3146fc67ed8c1e2', class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "search")))), h("div", { key: '1a16ea763aa52de38c7071215d0aceea5d6be0d4', class: "dda-toolbar-menu" }, h("ul", { key: '49c96b4848f5f822f77486ba220bd9a3e4a80e49' }, this.search_input_name && (h("li", { key: 'bba9b19c0b22366f10ca0964e2e7d1350e528ab8' }, h("dda-tooltip", { key: '9d95f12f5c70c353ea30a5ea4abf9e9df81753e1', title_text: this.search_tooltip || 'Search', description: "", position: "top" }, h("div", { key: 'a5f99f07a404f26affad4e59700cb20809ddb0bc', class: "dda-search dda-header-search" }, h("label", { key: '32fde277170ffa38654412dd37c8f98979fa4ccb', id: "ddaSearch-label", class: "visualy-hidden", "aria-hidden": "true" }, this.searchText || 'Search'), h("i", { key: 'e6a8bcadcd18d5b5e0366610d0ee28a8043e828a', class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "search"), h("dda-input", { key: 'afd257ca8b019923378b0b86755d20c654b060a9', placeholder: this.search_input_placeholder || 'Search', type: "text", input_id: "ddaSearch", value: this.search_value, input_name: this.search_input_name, aria_label: "input", input_role: "search", error_message: "Error text", validation_type: "normal", validation_id: "validationId", input_status: "normal", size: "default", custom_class: "dda-header-search-input tool-btn", component_mode: "",
|
|
285
|
+
})), this.hideOtherMenu == false && h("h6", { key: 'e8a089963257075dcb92ac460d8c01109115035b', class: "dda-side-nav-title" }, this.sideOtherMenuTitle), !this.hideOtherMenu && (h("ul", { key: '6c1146ecd2ec22c528ccc950655d0ff68f6d8d9c', class: "main_side_menu" }, this.parsedOtherMenuItems.map((itemlist, index) => (h("li", { key: `other-${index}` }, h("a", { href: this.useNavigator == 'true' ? 'javascript:void(0)' : itemlist.href, onClick: () => (this.useNavigator == 'true' ? this.navigatorClick.emit(itemlist.href) : '') }, itemlist.label))))))), h("div", { key: '22eee46a71a8b1949745f312bdc2cff5002abe38', class: "dda-sidemenu-bottom" }, h("div", { key: '732447c0c6e07ee78afb06e80757721f5dc11e5b', class: "dda-sidemenu-gov-logo" }, h("a", { key: '9370ac9680b5091a886682ae63da1065247b3bbd', href: this.useNavigator == 'true' ? 'javascript:void(0)' : this.firstLogoHref, onClick: () => (this.useNavigator == 'true' ? this.navigatorClick.emit(this.firstLogoHref) : ''), class: "govt-logo dda-mb-2" }, h("img", { key: '4ddc8180372e059717c92c09729c9a97e9de5fa5', class: "", src: this.firstLogoSrc, alt: this.firstLogoAlt }))), h("div", { key: 'd5914d8167adc1d63e1cafdcc2339e8afcc6bee3', class: "dda-toolbar-menu-sidemenu" }, h("ul", { key: 'e7edddffc2b0b97bfab95bf25f20356fca6f362b' }, this.accessibility_button_id && (h("li", { key: 'a89c92d5c17031a591d7ea103b7a6af68d85aa55' }, h("button", { key: 'b31628dcbc66c74aee46890b2d4b74133b9db91d', name: this.toggle_accessibility_button_name, class: "tool-btn accessibility-btn", type: "button", onClick: this.toggleMobileAccessibilty, id: this.accessibility_button_id }, h("i", { key: 'f9822507c8ef644ec69387b9934f25aa24c2b569', class: this.accessibility_button_icon_family }, this.accessibility_button_icon_name), h("span", { key: '311ef8ff33c0f7a2fad5074d688f450090036626', class: "visually-hidden" }, this.accessibility_button_text)))), this.language_text && (h("li", { key: '2b51194553515bd3f27f027e7702a33dfe423c47' }, h("button", { key: 'b151d47feaf27abcc8b88781641205d50b12b6f7', name: this.language_button_name, class: "tool-btn", type: "button", onClick: this.languagehandler }, this.language_text))), this.loginText && (h("li", { key: 'c6631083330da8be5dabdb1637c7f92e17c578dc' }, h("dda-link-button", { key: 'f5f233738ce7408c9387d90dc0af5d7064037b72', button_color: "onsurface-secondary", start_icon: this.loginIcon, custom_class: "tool-btn", link_button_text: this.loginText, onClick: this.toggleLogin, href: this.loginLink, button_shape: "circle", size: "sm" })))))), h("button", { key: '5fd9ea00c8d6684225eb8dbca2c6b5bf211d1bf1', type: "button", name: this.close_menu_button_name, class: "close-btn side-nav-close-btn", "aria-label": "Close Sidebar", onClick: this.toggleMenu }, h("i", { key: 'b5be5b1bd68cea8f629069055cc256a043caf541', class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "close")), this.usePredesignedAccessibilityMenu ? (h("div", { class: "dda-accessibility hide-accessibility mobile-accessibility", style: { display: this.isMobileAccessibiltyOpen ? 'block' : 'none' } }, h("div", { class: "mobile-accessibility-content" }, h("div", { class: "dda-row" }, h("div", { class: "dda-col-md-4 dda-accessibility-item" }, h("h6", { class: "h6 Regular dda-mb-1" }, this.contrast_title), h("form", null, h("fieldset", { class: "dda-theme-list" }, h("legend", null, h("p", { class: "body Regular dda-mb-3" }, this.contrast_description)), this.contrast_noraml_text ? (h("dda-radiobutton", { title_text: this.contrast_noraml_text, checked: this.selected_contrast == "normal", size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "NormalThemeMobile", group_name: "themeselectionMobile", input_id: "NormalThemeMobile", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.normalContrasthandler, class: "hydrated" })) : null, this.contrast_color_blind_text ? (h("dda-radiobutton", { title_text: this.contrast_color_blind_text, checked: this.selected_contrast == "colorblind", size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "ColoursBlindMobile", group_name: "themeselectionMobile", input_id: "ColoursBlindMobile", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.blindContrasthandler, class: "hydrated" })) : null, this.contrast_red_weakness_text ? (h("dda-radiobutton", { title_text: this.contrast_red_weakness_text, checked: this.selected_contrast == "redweakness", size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "RedWeaknessMobile", group_name: "themeselectionMobile", input_id: "RedWeaknessMobile", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.redContrasthandler, class: "hydrated" })) : null, this.contrast_green_weakness_text ? (h("dda-radiobutton", { title_text: this.contrast_green_weakness_text, checked: this.selected_contrast == "greenweakness", size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "GreenWeaknessMobile", group_name: "themeselectionMobile", input_id: "GreenWeaknessMobile", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.greenContrasthandler, class: "hydrated" })) : null))), h("div", { class: "dda-col-md-4 dda-accessibility-item" }, h("h6", { class: "h6 Regular dda-mb-1" }, this.screen_reader_title), h("p", { class: "body Regular dda-mb-3" }, this.screen_reader_description), h("div", { class: "rs_skip rsbtn rs_preserve rs_mobile", id: "readspeaker_button1" }, h("a", { rel: "nofollow", href: this.read_speaker_link, role: "button", class: "rsbtn_play circle readspeaker", accessKey: "L", "aria-label": "Listen to this page using ReadSpeaker", "data-rsshortcut": "play", "aria-haspopup": "menu", "data-rs-lang": "en_uk" }, h("i", { class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "volume_up")))), h("div", { class: "dda-col-md-4 dda-accessibility-item" }, h("h6", { class: "h6 Regular dda-mb-1" }, this.text_size_title), h("p", { class: "body Regular dda-mb-3" }, this.text_size_description), h("div", { class: "dda-d-flex dda-gap-4" }, h("dda-button", { button_color: this.selected_text_size == "normal" ? "default-primary" : "default-secondary", button_text: "A", icon_button_shape: "circle", custom_class: "", size: "lg", onClick: this.baseTexthandler }), h("dda-button", { button_color: this.selected_text_size == "large" ? "default-primary" : "default-secondary", button_text: "A+", icon_button_shape: "circle", custom_class: "", size: "lg", onClick: this.lgTexthandler }), h("dda-button", { button_color: this.selected_text_size == "small" ? "default-primary" : "default-secondary", button_text: "A-", icon_button_shape: "circle", custom_class: "", size: "lg", onClick: this.smTexthandler }))))), h("button", { type: "button", name: this.close_accessibility_button_name, class: "close-btn close_accessibility", "aria-label": "Close Accessibility", onClick: this.toggleMobileAccessibilty }, h("i", { class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "close")))) : null), this.quickLinks && (h("dda-header-menu", { key: 'fdbcfe6ab93ebff747cf38c75b58c321355b9c53', "use-navigator": this.useNavigator, "navigator-click": this.navigatorClick, "quick-links": typeof this.quickLinks === 'string' ? this.quickLinks : JSON.stringify(this.quickLinks) }))), h("div", { key: '465f1028ecdde4f35fef3ceed0940c6945a7ffc6', class: "dda-mobile-entt-logo" }, h("a", { key: 'fe1467675d5bbc3f8c34dd56de2e5706c7dd49c3', href: this.useNavigator == 'true' ? 'javascript:void(0)' : this.secondLogoHref, onClick: () => (this.useNavigator == 'true' ? this.navigatorClick.emit(this.secondLogoHref) : ''), class: "entt-logo" }, h("img", { key: '61599183bdf54c1276b2b2773a4f56098f075c54', class: "logo-colored", src: this.secondLogoSrc, alt: this.secondLogoAlt }), h("img", { key: '4283106fa7ea1946369bffab4991ce2509eea277', class: "logo-white", src: this.secondLogoWhiteSrc, alt: this.secondLogoAlt }))), h("div", { key: 'da2f3a3f8804664266a30e85b53a09eb0dcaea27', class: "dda-mobile-search" }, this.mobileMenuSearchId && (h("a", { key: '84a3d68be0af96516eaa4a8eaf49200296907326', href: this.useNavigator == 'true' ? 'javascript:void(0)' : this.mobileMenuSearchUrl, onClick: () => (this.useNavigator == 'true' ? this.navigatorClick.emit(this.mobileMenuSearchUrl) : ''), class: "tool-btn", id: this.mobileMenuSearchId }, h("span", { key: 'd18824918b0f3f2519b906aeefc5432bab6fc3a3', class: "visualy-hidden" }, this.searchText || 'Search'), h("i", { key: 'e946965ceb576074acd2a5cfda084fb5fd136684', class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "search")))), h("div", { key: '128845fd6b5b23b536c6d82badff6d6eb30c2940', class: "dda-toolbar-menu" }, h("ul", { key: '505b5230f451c2985485d3c2c36d4afe5eda85e8' }, this.search_input_name && (h("li", { key: 'a3a2b1ec44f00a78ccc136d869c99ade2618f3af' }, h("dda-tooltip", { key: '3892729103daadc7d8374748f919a0e3412dd204', title_text: this.search_tooltip || 'Search', description: "", position: "top" }, h("div", { key: '8ddcf9225a880f595b1b235bab2fc407398efb6a', class: "dda-search dda-header-search" }, h("label", { key: 'aace4820df1ab0d1289ba85bb6e269bd5b066513', id: "ddaSearch-label", class: "visualy-hidden", "aria-hidden": "true" }, this.searchText || 'Search'), h("i", { key: '90c3085af23a8984aa6dac13f07936e34b56bb29', class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "search"), h("dda-input", { key: 'aa3ad19ddce4a1248155fd1a7aaab1b10a9cdecb', placeholder: this.search_input_placeholder || 'Search', type: "text", input_id: "ddaSearch", value: this.search_value, input_name: this.search_input_name, aria_label: "input", input_role: "search", error_message: "Error text", validation_type: "normal", validation_id: "validationId", input_status: "normal", size: "default", custom_class: "dda-header-search-input tool-btn", component_mode: "",
|
|
275
286
|
// handleInput={(event) => console.log(event.target.value,"")}
|
|
276
|
-
onKeyPress:
|
|
287
|
+
onKeyPress: e => {
|
|
277
288
|
if (e.key === 'Enter') {
|
|
278
289
|
this.searchhandler(e.target.value); // Pass the value to the searchhandler
|
|
279
290
|
}
|
|
280
|
-
} }), h("span", { key: '
|
|
291
|
+
} }), h("span", { key: '4e2685a5599d65fc32e0f0c22c99652fd18e5c23', id: "validationId", class: "visually-hidden" }, "Enter keywords to search the site."))))), this.accessibility_button_id && (h("li", { key: 'f5299b335fac79b0e797b566fd2c2da16aa596a1' }, h("dda-tooltip", { key: '4ddb7685688b2bb9d512d7f1ba05e8c14259da7d', title_text: this.accessibility_tooltip, position: "top" }, h("button", { key: '031fa52d02ffd1767757d2c8c1dc2058ad7884df', name: this.toggle_accessibility_button_name, class: "tool-btn dda-btn btn-color-onsurface-secondary btn-size-sm btn-shape-circle accessibility-btn", type: "button", onClick: this.toggleAccessibilty, id: this.accessibility_button_id }, h("i", { key: '2d5c9c677dffe41a62d5bfe1ab057aef53eb80ab', class: this.accessibility_button_icon_family }, this.accessibility_button_icon_name), h("span", { key: '06b73b92e55c757827e9b18f5247e14f11abcdd0', class: "visually-hidden" }, this.accessibility_button_text))), this.usePredesignedAccessibilityMenu ? (h("div", { class: "dda-accessibility-wrap" }, h("div", { class: "dda-accessibility hide-accessibility", style: { display: this.isAccessibiltyOpen ? 'block' : 'none' } }, h("div", { class: "dda-row" }, h("div", { class: "dda-col-md-4 dda-accessibility-item" }, h("h6", { class: "h6 Regular dda-mb-1" }, this.contrast_title), h("form", null, h("fieldset", { class: "dda-theme-list" }, h("legend", null, h("p", { class: "body Regular dda-mb-3" }, this.contrast_description)), this.contrast_noraml_text ? (h("dda-radiobutton", { title_text: this.contrast_noraml_text, checked: this.selected_contrast == "normal", size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "NormalTheme", group_name: "themeselection", input_id: "NormalTheme", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.normalContrasthandler, class: "" })) : null, this.contrast_color_blind_text ? (h("dda-radiobutton", { title_text: this.contrast_color_blind_text, checked: this.selected_contrast == "colorblind", size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "ColoursBlind", group_name: "themeselection", input_id: "ColoursBlind", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.blindContrasthandler, class: "hydrated" })) : null, this.contrast_red_weakness_text ? (h("dda-radiobutton", { title_text: this.contrast_red_weakness_text, checked: this.selected_contrast == "redweakness", size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "RedWeakness", group_name: "themeselection", input_id: "RedWeakness", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.redContrasthandler, class: "hydrated" })) : null, this.contrast_green_weakness_text ? (h("dda-radiobutton", { title_text: this.contrast_green_weakness_text, checked: this.selected_contrast == "greenweakness", size: "default", variants: "normal", supporting: "", error_message: "", validation_id: "GreenWeakness", group_name: "themeselection", input_id: "GreenWeakness", custom_class: "", component_mode: "", aria_label: "radio-button", validation_type: "normal", onChange: this.greenContrasthandler, class: "hydrated" })) : null))), h("div", { class: "dda-col-md-4 dda-accessibility-item" }, h("h6", { class: "h6 Regular dda-mb-1" }, this.screen_reader_title), h("p", { class: "body Regular dda-mb-3" }, this.screen_reader_description), h("div", { class: "rs_skip rsbtn rs_preserve rs_mobile", id: "readspeaker_button1" }, h("a", { rel: "nofollow", href: this.read_speaker_link, role: "button", class: "rsbtn_play circle readspeaker", accessKey: "L", "aria-label": "Listen to this page using ReadSpeaker", "data-rsshortcut": "play", "aria-haspopup": "menu", "data-rs-lang": "en_uk" }, h("i", { class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "volume_up")))), h("div", { class: "dda-col-md-4 dda-accessibility-item" }, h("h6", { class: "h6 Regular dda-mb-1" }, this.text_size_title), h("p", { class: "body Regular dda-mb-3" }, this.text_size_description), h("div", { class: "dda-d-flex dda-gap-4" }, h("dda-button", { button_color: this.selected_text_size == "normal" ? "default-primary" : "default-secondary", button_text: "A", icon_button_shape: "circle", custom_class: "", size: "lg", onClick: this.baseTexthandler }), h("dda-button", { button_color: this.selected_text_size == "large" ? "default-primary" : "default-secondary", button_text: "A+", icon_button_shape: "circle", custom_class: "", size: "lg", onClick: this.lgTexthandler }), h("dda-button", { button_color: this.selected_text_size == "small" ? "default-primary" : "default-secondary", button_text: "A-", icon_button_shape: "circle", custom_class: "", size: "lg", onClick: this.smTexthandler })))), h("button", { type: "button", name: this.close_accessibility_button_name, class: "close-btn close_accessibility", "aria-label": "Close Sidebar", onClick: this.toggleAccessibilty }, h("i", { class: "material-icons material-symbols-outlined", "aria-hidden": "true" }, "close"))))) : null)), this.language_text && (h("li", { key: '34f7535b38286b1053442d5c9d85dae9c5f99b03' }, h("dda-tooltip", { key: 'c2bcf53cdf5671c0797bdf1244fbcf3e3c794e7e', title_text: this.language_tooltip, position: "top" }, h("dda-button", { key: '83a9660dca131f30c2a5905c2744351cfd2decf5', button_color: "onsurface-secondary", custom_class: "tool-btn", button_text: this.language_text, button_shape: "circle", size: "sm", onClick: this.languagehandler })))), this.loginText && (h("li", { key: 'df36c7a1b07a4541b3a3d9252fee89d00c9a59a3' }, h("dda-tooltip", { key: '7e354257b66f1baae6a5b295f72ee7390a8837fa', title_text: this.login_tooltip, position: "top" }, h("dda-link-button", { key: '646861568427a1bc3134aa59a205b8ca5e1f9583', button_color: "onsurface-secondary", start_icon: this.loginIcon, custom_class: "tool-btn login-button", link_button_text: this.loginText, onClick: this.toggleLogin, href: this.loginLink, button_shape: "circle", size: "sm" })))))))));
|
|
281
292
|
}
|
|
282
293
|
static get is() { return "dda-header"; }
|
|
283
294
|
static get originalStyleUrls() {
|
|
@@ -1174,6 +1185,45 @@ export class DdaHeader {
|
|
|
1174
1185
|
"attribute": "contrast_green_weakness_text",
|
|
1175
1186
|
"reflect": false
|
|
1176
1187
|
},
|
|
1188
|
+
"selected_contrast": {
|
|
1189
|
+
"type": "string",
|
|
1190
|
+
"mutable": false,
|
|
1191
|
+
"complexType": {
|
|
1192
|
+
"original": "\"normal\" | \"colorblind\" | \"redweakness\" | \"greenweakness\"",
|
|
1193
|
+
"resolved": "\"colorblind\" | \"greenweakness\" | \"normal\" | \"redweakness\"",
|
|
1194
|
+
"references": {}
|
|
1195
|
+
},
|
|
1196
|
+
"required": false,
|
|
1197
|
+
"optional": false,
|
|
1198
|
+
"docs": {
|
|
1199
|
+
"tags": [],
|
|
1200
|
+
"text": ""
|
|
1201
|
+
},
|
|
1202
|
+
"getter": false,
|
|
1203
|
+
"setter": false,
|
|
1204
|
+
"attribute": "selected_contrast",
|
|
1205
|
+
"reflect": false,
|
|
1206
|
+
"defaultValue": "\"normal\""
|
|
1207
|
+
},
|
|
1208
|
+
"selected_text_size": {
|
|
1209
|
+
"type": "string",
|
|
1210
|
+
"mutable": false,
|
|
1211
|
+
"complexType": {
|
|
1212
|
+
"original": "\"normal\" | \"large\" | \"small\"",
|
|
1213
|
+
"resolved": "\"large\" | \"normal\" | \"small\"",
|
|
1214
|
+
"references": {}
|
|
1215
|
+
},
|
|
1216
|
+
"required": false,
|
|
1217
|
+
"optional": false,
|
|
1218
|
+
"docs": {
|
|
1219
|
+
"tags": [],
|
|
1220
|
+
"text": ""
|
|
1221
|
+
},
|
|
1222
|
+
"getter": false,
|
|
1223
|
+
"setter": false,
|
|
1224
|
+
"attribute": "selected_text_size",
|
|
1225
|
+
"reflect": false
|
|
1226
|
+
},
|
|
1177
1227
|
"screen_reader_title": {
|
|
1178
1228
|
"type": "string",
|
|
1179
1229
|
"mutable": false,
|
|
@@ -1338,6 +1388,21 @@ export class DdaHeader {
|
|
|
1338
1388
|
"resolved": "void",
|
|
1339
1389
|
"references": {}
|
|
1340
1390
|
}
|
|
1391
|
+
}, {
|
|
1392
|
+
"method": "loginClick",
|
|
1393
|
+
"name": "loginClick",
|
|
1394
|
+
"bubbles": true,
|
|
1395
|
+
"cancelable": true,
|
|
1396
|
+
"composed": true,
|
|
1397
|
+
"docs": {
|
|
1398
|
+
"tags": [],
|
|
1399
|
+
"text": ""
|
|
1400
|
+
},
|
|
1401
|
+
"complexType": {
|
|
1402
|
+
"original": "void",
|
|
1403
|
+
"resolved": "void",
|
|
1404
|
+
"references": {}
|
|
1405
|
+
}
|
|
1341
1406
|
}, {
|
|
1342
1407
|
"method": "navigatorClick",
|
|
1343
1408
|
"name": "navigatorClick",
|