Fix IgxDateRangePicker type incompatibility with strict TypeScript checks #16438
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Closes #16437
Description
IgxDateRangePickerComponent.getEditElement()returnedHTMLInputElement | undefined, incompatible with base classPickerBaseDirectivewhich definesHTMLInputElement. Applications with strict TypeScript checks failed to compile.The optional chaining was unnecessary:
getEditElement()is only called whenhasProjectedInputsis false, at which pointinputDirectiveis guaranteed to exist in the rendered template.Additional information (check all that apply):
Checklist:
feature/README.MDupdates for the feature docsREADME.MDCHANGELOG.MDupdates for newly added functionalityng updatemigrations for the breaking changes (migrations guidelines)Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
accounts.google.com/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --disable-dev-shm-usage --use-angle=swiftshader-webgl --crashpad-handler-pid=3904 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/karma-83250547 --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,14400582546214623126,5943833251440008836,262144 --disable-features=PaintHolding --variations-seed-version(dns block)/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --disable-dev-shm-usage --use-angle=swiftshader-webgl --crashpad-handler-pid=3906 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/karma-97812633 --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,17779351793697573338,6741410952299742747,262144 --disable-features=PaintHolding --variations-seed-version(dns block)/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --user-data-dir=/tmp/karma-83250547 --enable-automation --no-default-browser-check --no-first-run --disable-default-apps --disable-popup-blocking --disable-translate --disable-REDACTED-timer-throttling --disable-renderer-REDACTEDing --disable-device-discovery-notifications --no-sandbox --disable-gpu --window-size=820,800 --js-flags=--expose-gc --headless --disable-gpu --disable-dev-shm-usage --remote-debugging-port=9222 --noerrdialogs --ozone-platform=headless --ozone-override-screen-size=800,600 --use-angle=swiftshader-webgl http://localhost:9876/?id=83250547(dns block)clients2.google.com/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --disable-dev-shm-usage --use-angle=swiftshader-webgl --crashpad-handler-pid=3906 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/karma-97812633 --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,17779351793697573338,6741410952299742747,262144 --disable-features=PaintHolding --variations-seed-version(dns block)/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --disable-dev-shm-usage --use-angle=swiftshader-webgl --crashpad-handler-pid=3904 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/karma-83250547 --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,14400582546214623126,5943833251440008836,262144 --disable-features=PaintHolding --variations-seed-version(dns block)/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --user-data-dir=/tmp/karma-83250547 --enable-automation --no-default-browser-check --no-first-run --disable-default-apps --disable-popup-blocking --disable-translate --disable-REDACTED-timer-throttling --disable-renderer-REDACTEDing --disable-device-discovery-notifications --no-sandbox --disable-gpu --window-size=820,800 --js-flags=--expose-gc --headless --disable-gpu --disable-dev-shm-usage --remote-debugging-port=9222 --noerrdialogs --ozone-platform=headless --ozone-override-screen-size=800,600 --use-angle=swiftshader-webgl http://localhost:9876/?id=83250547(dns block)redirector.gvt1.com/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --disable-dev-shm-usage --use-angle=swiftshader-webgl --crashpad-handler-pid=3904 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/karma-83250547 --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,14400582546214623126,5943833251440008836,262144 --disable-features=PaintHolding --variations-seed-version(dns block)/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --user-data-dir=/tmp/karma-83250547 --enable-automation --no-default-browser-check --no-first-run --disable-default-apps --disable-popup-blocking --disable-translate --disable-REDACTED-timer-throttling --disable-renderer-REDACTEDing --disable-device-discovery-notifications --no-sandbox --disable-gpu --window-size=820,800 --js-flags=--expose-gc --headless --disable-gpu --disable-dev-shm-usage --remote-debugging-port=9222 --noerrdialogs --ozone-platform=headless --ozone-override-screen-size=800,600 --use-angle=swiftshader-webgl http://localhost:9876/?id=83250547(dns block)/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --disable-dev-shm-usage --use-angle=swiftshader-webgl --crashpad-handler-pid=3906 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/karma-97812633 --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,17779351793697573338,6741410952299742747,262144 --disable-features=PaintHolding --variations-seed-version(dns block)www.google.com/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --disable-dev-shm-usage --use-angle=swiftshader-webgl --crashpad-handler-pid=3906 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/karma-97812633 --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,17779351793697573338,6741410952299742747,262144 --disable-features=PaintHolding --variations-seed-version(dns block)/home/REDACTED/.cache/puppeteer/chrome/linux-136.0.7103.94/chrome-linux64/chrome --user-data-dir=/tmp/karma-97812633 --enable-automation --no-default-browser-check --no-first-run --disable-default-apps --disable-popup-blocking --disable-translate --disable-REDACTED-timer-throttling --disable-renderer-REDACTEDing --disable-device-discovery-notifications --no-sandbox --disable-gpu --window-size=820,800 --js-flags=--expose-gc --headless --disable-gpu --disable-dev-shm-usage --remote-debugging-port=9222 --noerrdialogs --ozone-platform=headless --ozone-override-screen-size=800,600 --use-angle=swiftshader-webgl http://localhost:9876/?id=97812633(dns block)If you need me to access, download, or install something from one of these locations, you can either:
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.