-
Notifications
You must be signed in to change notification settings - Fork 0
feat: warped grid #14
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
Open
svvimming
wants to merge
22
commits into
develop
Choose a base branch
from
feat-warped-grid
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
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.
Here is a first version of the warped grid component which uses a basic svg grid and applies a warp to it to match the current image on the live site. The warp is applied directly to the svg elements using warpjs.
@orvn I still need to add the animation on entry, was wondering if you had any thoughts on what it should look like/animation speed, duration, etc. Currently only the grid on the index (apply page) is using the new component so you can navigate to another page to compare with the older warped grid there.
UPDATE: March 31st 2023
The warp js implementation using SVGs in the dom has been replaced with a canvas implementation. More info to come on editing animation parameters by adding props to the
WarpedGridcomponent.UPDATE: April 4th 2023
The following props can be passed to the warped grid component to customize animation:
animation-active- boolean indicating the play state of the animation (true = running, false = paused)vertical-lines- the number of vertical lines in the gridhorizontal-lines- the number of horizontal lines in the gridcell-width- the width/height of a grid cell in pixelsline-width- grid line width in pixelsresolution- the number of sublines used to create each side of each cellpulse-speed- how fast the pulse should oscillate (nb: this should be well under 1.0. Using integer values will appear to pause the pulse but this is because the step size is too large for the underlying sin/cos calculation and will cause them to jump straight to function zeros)pulse-intensity- how strong the pulse animation component isinteraction-springing- a coefficient determining how bouncy the bulge should behave when agitated by the mouseinteraction-damping- a coefficient determining how stiff the bulge should behave when agitated by the mouse (nb: values of 1.0 are equivalent to no damping, values above 1.0 produce an amplification effect and the animation will diverge)interaction-intensity- how strong the interaction component isgrid-color- a string determining the color of the lines** all props are of type
Numberunless otherwise statedUPDATE: April 27th 2023
The warped grids have been added to each instance across the site pages and adjusted in each location to ensure proper display. The only exception is on the notaries page which is very long and was performing poorly with several canvas filling the height of the page. The original image has been used in on this page instead.