@qhealth-design-system/core 1.18.0 → 1.18.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/CHANGELOG.md CHANGED
@@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## Unreleased
9
9
 
10
+ ## 1.18.1 - 2025-11-12
11
+
10
12
  ## 1.18.0 - 2025-11-12
11
13
 
12
14
  ## 1.17.2 - 2025-10-23
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qhealth-design-system/core",
3
- "version": "1.18.0",
3
+ "version": "1.18.1",
4
4
  "description": "",
5
5
  "licence": "MIT",
6
6
  "main": "index.js",
@@ -5,11 +5,17 @@
5
5
  // Search toggle button
6
6
  const searchToggle = document.querySelector(".qld__main-nav__toggle-search");
7
7
  const searchForm = document.querySelector(".qld__header__search .qld__search-form");
8
- const targetId = searchToggle.getAttribute("aria-controls");
9
- const target = document.getElementById(targetId);
10
- const focustrapTop = target.querySelector(".qld__main-nav__focus-trap-top");
11
- const focustrapBottom = target.querySelector(".qld__main-nav__focus-trap-bottom");
12
- const searchToggleText = searchToggle.querySelector(".qld__main-nav__toggle-text");
8
+ let searchToggleText, targetId, target, focustrapTop, focustrapBottom;
9
+ if (searchToggle) {
10
+ searchToggleText = searchToggle.querySelector(".qld__main-nav__toggle-text");
11
+ targetId = searchToggle.getAttribute("aria-controls");
12
+ target = document.getElementById(targetId);
13
+ if (target) {
14
+ focustrapTop = target.querySelector(".qld__main-nav__focus-trap-top");
15
+ focustrapBottom = target.querySelector(".qld__main-nav__focus-trap-bottom");
16
+ }
17
+ }
18
+
13
19
  // Hold state of the header (open vs close)
14
20
  let isHeaderOpen = false;
15
21
  // Global events object
@@ -42,7 +42,7 @@
42
42
  }
43
43
 
44
44
  // Push the input cursor to the right when search icon is present
45
- > input.qld__text-input {
45
+ input.qld__text-input {
46
46
  padding-left: 3rem;
47
47
  }
48
48
  }