feat(angular): expose core 0.2.0 morph options in the wrapper#13
Merged
Conversation
The core 0.2.0 morph release added configurable options that the Angular wrapper never surfaced. Sync them and bump the wrapper to 0.2.0. - Per-call options (PrettyModalOptions + directive inputs): openDuration, closeDuration, scale, originGap, respectReducedMotion. Forwarded only when set, so unset inputs fall back to the core instance defaults. - Instance-level config via providePrettyModal() / PRETTY_MODAL_CONFIG. This is the only way to set ease/originEase: the core compiles them once in its constructor (CustomEase.create), so they are not read per-call. - Bump peerDependency prettier-modals to >=0.2.0. - Docs + tests (13 -> 18). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Why
When the core (
prettier-modals) was bumped to 0.2.0 with the morph open/close animation, it gained new configurable options that the Angular wrapper (still0.1.0) never surfaced. This syncs the wrapper with the core API and bumps it to 0.2.0.What changed
Per-call options (
PrettyModalOptions+ directive inputs):openDuration,closeDuration,scale,originGap,respectReducedMotion.PrettyModalTriggerDirective: new inputsduration,openDuration,scale,originGap,respectReducedMotion.PrettyModalCloseDirective: new inputsduration,closeDuration.undefined.Instance-level config via new
providePrettyModal()/PRETTY_MODAL_CONFIG:ease/originEase. The core compiles these CustomEase paths once in its constructor (CustomEase.create) —open()/close()never read them per-call — so they're intentionally excluded fromPrettyModalOptionsand exposed only as instance config.new PrettyModal(config)from the injected token.Other:
peerDependencyprettier-modalsbumped>=0.1.0→>=0.2.0.0.1.0→0.2.0.providePrettyModal)" section.Verification
npm run build✅ (ng-packagr)npm test✅ 18/18🤖 Generated with Claude Code