Upgrading to the new `ts_library` rule uncovered TS errors in these files. This commit fixes the code to pass TS checking. PR Close #27600
Upgrading to the new `ts_library` rule uncovered TS errors in these files. This commit fixes the code to pass TS checking. PR Close #27600