-
Notifications
You must be signed in to change notification settings - Fork 264
Description
hlm-sheet does not work correctly in a standalone Angular application.
- Clicking the trigger does not render the sheet properly.
<div class="cdk-overlay-container">is not created when usingHlmSheet.- The sheet only works when using
BrnSheetdirectly. - Even when it opens, there is no transition animation (it appears instantly without smooth slide-in).
Environment
- Angular: 21.0.x
- @angular/cdk: 21.0.x
- "@spartan-ng/cli": "^0.0.1-alpha.575",
- "@spartan-ng/brain": "^0.0.1-alpha.575"
- Standalone bootstrap (no NgModules)
@component({
standalone: true,
imports: [HlmSheetImports],
template: `
Are you absolutely sure?
This action cannot be undone. This will permanently delete your account and remove your data from our servers.
`,
})
export class TestComponent {}
In main.ts:
bootstrapApplication(AppComponent, {
providers: [
provideAnimations(),
],
})
Observed Behavior
hlm-sheetdoes not createcdk-overlay-container- Using
BrnSheetworks correctly - No slide transition animation
- Providing animations via:
provideAnimations()
or
provideAnimationsAsync('animations')
does not restore transition behavior
Expected Behavior
hlm-sheetshould initialize CDK Overlay properlycdk-overlay-containershould be created on trigger- Sheet should slide in smoothly from the specified side
- Should work correctly in standalone Angular 20+ without relying on deprecated animation providers
Additional Notes
Both:
provideAnimations()provideAnimationsAsync()
are deprecated in Angular 20.2 with intent to remove in v23.
Currently, hlm-sheet appears to depend on the legacy animation engine, and transition animations do not function properly even when the deprecated providers are added.
It seems there may be:
- A compatibility issue with Angular 20+
- A missing provider registration for CDK Overlay
- Or a mismatch between
HlmSheetwrapper andBrnSheetimplementation
Question
Is hlm-sheet fully compatible with Angular 20+ standalone setup?
Is there a recommended way to enable transitions without relying on deprecated animation providers?