Skip to content

fix(cdk): tuiCreateToken with no arguments should not create token with default undefined-value#10682

Merged
nsbarsukov merged 1 commit intomainfrom
create-token-fix
Mar 28, 2025
Merged

fix(cdk): tuiCreateToken with no arguments should not create token with default undefined-value#10682
nsbarsukov merged 1 commit intomainfrom
create-token-fix

Conversation

@nsbarsukov
Copy link
Copy Markdown
Member

@nsbarsukov nsbarsukov commented Mar 28, 2025

https://stackblitz.com/edit/option-content-with-skip-self

TUI_OPTION_CONTENT is projected content via polymorpheusOutlet (legacy approach) / createComponent (modern approach). Both approaches attach parent injector to this projected component.

Previous behavior:
inject(TUI_OPTION_CONTENT, {skipSelf: true)) looks inside local injectors and get default undefined (from token factory). Stop exploring DI hierarchy (do not explore "parent" injectors).

New behavior:
inject(TUI_OPTION_CONTENT, {skipSelf: true)) is not found inside "local" injectors - we reach "local" NullInjector => Got to "parent" inejctors.

@nsbarsukov nsbarsukov self-assigned this Mar 28, 2025
@nsbarsukov nsbarsukov requested a review from a team as a code owner March 28, 2025 08:56
@nsbarsukov nsbarsukov requested review from MarsiBarsi, mdlufy, vladimirpotekhin and waterplea and removed request for a team March 28, 2025 08:56
@screenshot-report-bot
Copy link
Copy Markdown

screenshot-report-bot Bot commented Mar 28, 2025

Pull request was closed ✔️

All saved screenshots (for current PR) were deleted 🗑️

@nx-cloud
Copy link
Copy Markdown

nx-cloud Bot commented Mar 28, 2025

View your CI Pipeline Execution ↗ for commit 716539a.

Command Status Duration Result
nx build icons-fontawesome ✅ Succeeded 1s View ↗
nx prebuild icons-fontawesome ✅ Succeeded 8s View ↗
nx build icons-material ✅ Succeeded 2s View ↗
nx prebuild icons-material ✅ Succeeded 32s View ↗
nx build icons ✅ Succeeded 1s View ↗
nx prebuild icons ✅ Succeeded 16s View ↗

☁️ Nx Cloud last updated this comment at 2025-03-28 09:19:33 UTC

@github-actions
Copy link
Copy Markdown
Contributor

Visit the preview URL for this PR (updated for commit 716539a):

https://taiga-previews-demo--pr10682-create-token-fix-demo-9vvvf7ow.web.app

(expires Sat, 29 Mar 2025 09:01:10 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: 73dddc3c665194f3e11f18c16aeb71af4c289c37

@codecov
Copy link
Copy Markdown

codecov Bot commented Mar 28, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 65.50%. Comparing base (787bb60) to head (716539a).
Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff            @@
##             main   #10682    +/-   ##
========================================
  Coverage   65.50%   65.50%            
========================================
  Files        1267     1267            
  Lines       16697    16698     +1     
  Branches     2475     2382    -93     
========================================
+ Hits        10937    10938     +1     
- Misses       5449     5560   +111     
+ Partials      311      200   -111     
Flag Coverage Δ
summary 65.50% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@bundlemon
Copy link
Copy Markdown

bundlemon Bot commented Mar 28, 2025

BundleMon

Unchanged files (5)
Status Path Size Limits
demo/browser/main.(hash).js
314.86KB +10%
demo/browser/vendor.(hash).js
260.52KB +10%
demo/browser/runtime.(hash).js
48.07KB +10%
demo/browser/styles.(hash).css
21.14KB +10%
demo/browser/polyfills.(hash).js
11.18KB +10%

Total files change +9B 0%

Unchanged groups (1)
Status Path Size Limits
demo/browser/*..js
8.27MB -

Final result: ✅

View report in BundleMon website ➡️


Current branch size history | Target branch size history

@github-actions
Copy link
Copy Markdown
Contributor

Playwright test results

failed  1 failed
passed  1105 passed
skipped  1 skipped

Details

report  Open report ↗︎
stats  1107 tests across 74 suites
duration  12 minutes, 52 seconds
commit  716539a

Failed tests

chromium › tests/core/dropdown/dropdown.pw.spec.ts › Dropdown › Hosted dropdown initial width

Skipped tests

chromium › tests/addon-mobile/mobile-dropdown/mobile-dropdown-with-textfield.pw.spec.ts › DropdownMobile for textfields › with select

@nsbarsukov nsbarsukov merged commit feadfcd into main Mar 28, 2025
28 of 29 checks passed
@nsbarsukov nsbarsukov deleted the create-token-fix branch March 28, 2025 10:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants