diff --git a/.Jules/palette.md b/.Jules/palette.md new file mode 100644 index 00000000..71ae2e00 --- /dev/null +++ b/.Jules/palette.md @@ -0,0 +1,3 @@ +## 2023-10-23 - Add `type="search"` to search inputs +**Learning:** For accessibility and mobile UX, applying `type="search"` to search inputs ensures native mobile search keyboards and built-in browser clear buttons are triggered without requiring custom JS or CSS. +**Action:** Always add `type="search"` to any `` intended for filtering or searching lists, especially on pages accessed frequently from mobile devices (like the catalogue or hardware inventory). diff --git a/src/pages/hardware.tsx b/src/pages/hardware.tsx index 8edea871..532e24e2 100644 --- a/src/pages/hardware.tsx +++ b/src/pages/hardware.tsx @@ -18,6 +18,7 @@ export default function HardwareCatalogue() {

{t("catalogue")}

setSearch(event.target.value)} diff --git a/src/pages/internal/hardware.tsx b/src/pages/internal/hardware.tsx index 559e3f8d..0093d647 100644 --- a/src/pages/internal/hardware.tsx +++ b/src/pages/internal/hardware.tsx @@ -56,6 +56,7 @@ export default function HardwareDesk() {

{t("inventory")}

)}