-
-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add node and isInViewport to props of action functions #34
Conversation
🦋 Changeset detectedLatest commit: 6c32491 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
2 Ignored Deployments
|
WalkthroughThis update enhances the 'sveltekit-view-transition' package by adding new arguments to action functions and exporting additional types. It also introduces a feature to skip transitions if an element is not in the viewport, improving performance and user experience. Changes
TipsChat with CodeRabbit Bot (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 2
Files selected for processing (4)
- .changeset/soft-phones-sip.md (1 hunks)
- README.md (4 hunks)
- src/lib/index.ts (1 hunks)
- src/lib/sveltekit-view-transition.ts (4 hunks)
Files skipped from review due to trivial changes (2)
- README.md
- src/lib/index.ts
Additional comments (Suppressed): 3
.changeset/soft-phones-sip.md (1)
- 1-5: The changeset file correctly indicates a minor version update for the 'sveltekit-view-transition' package and provides a brief description of the changes. Ensure that this description accurately reflects the changes made in the code.
src/lib/sveltekit-view-transition.ts (2)
7-26: The new
TransitionActionFunctionProps
type and the modifications to theTransitionAction
andTransitionActionFunctions
types are well done. They incorporate the newnode
andisInViewport
properties, which will be passed to callback functions. This change enhances the flexibility of the package by allowing developers to make decisions based on whether an element is currently in the viewport.299-305: The changes here look good. The
props.classes
function now receives the newprops_for_callback
object, which includes thenode
andisInViewport
properties. This allows developers to conditionally apply classes based on whether an element is in the viewport.
Closes #33