선의 시작부터 끝까지 경로를 순서대로 드러내는 표현An animation that progressively reveals a path from start to finish.
시간 순서의 꺾은선을 그리고 점으로 현재 진행 위치를 보여준다
범주형 자료를 연속된 선으로 연결해 추세처럼 보이게 한다
기본값은 클립에 쓴 값Defaults are the values used in the clip
| 항목PARAM | 기본DEFAULT | 범위RANGE | 메모NOTE |
|---|---|---|---|
| 선 길이 정규화 | 1 | 1 | pathLength로 dash 단위 고정 |
| 지속 | 1.85s | 1.2~2.2s | 좌측부터 연속 진행 |
| 점 반지름 | 8px | 5~10px | 현재 선 끝 표시 |
| 출발 | 0.30s | 0.2~0.4s | 빈 경로 준비 상태 |
const path=document.querySelector('#graph'), tip=document.querySelector('#tip');
const length=path.getTotalLength(), progress={value:0};
gsap.set(path,{strokeDasharray:1,strokeDashoffset:1});
const start=path.getPointAtLength(0);gsap.set(tip,{x:start.x,y:start.y});
tl.to(path,{strokeDashoffset:0,autoRound:false,duration:1.85,ease:'none'},.3);
tl.to(progress,{value:1,duration:1.85,ease:'none',onUpdate:()=>{const p=path.getPointAtLength(progress.value*length);gsap.set(tip,{x:p.x,y:p.y});}},.3);그대로 붙여 넣는다Paste as is
<대상>에 선 그리기 효과를 적용해. 시간 순서의 꺾은선을 그리고 점으로 현재 진행 위치를 보여준다. 선 길이 정규화 1; 지속 1.85s; 점 반지름 8px; 출발 0.30s로 만들고 이징은 none를 써. GSAP 타임라인 하나로 제어하고 2.5초부터 3초까지 완성 상태를 유지해.
Apply Line Draw to <target>. Draw a chronological line chart and use a dot to mark the current drawing position. Use these settings: normalized path length 1; duration 1.85s; dot radius 8px; start 0.30s; ease none. Control everything with a single GSAP timeline and hold the completed state from 2.5 to 3 seconds.
<파일>의 데이터 장면에 선 그리기 효과를 구현해. 선 길이 정규화 1; 지속 1.85s; 점 반지름 8px; 출발 0.30s를 적용하고 이징은 none로 지정해. 0초, 0.75초, 1.75초, 2.9초를 캡처해서 시작 상태와 진행 변화, 최종 상태의 잘림과 겹침을 확인해. Math.random과 타이머 없이 타임라인으로 재생하고 마지막 0.5초 이상 정지해.
Implement Line Draw in the data scene in <file>. Use these settings: normalized path length 1; duration 1.85s; dot radius 8px; start 0.30s; ease none. Capture at 0, 0.75, 1.75, and 2.9 seconds to check the initial state, progression, and any clipping or overlap in the final state. Play using a timeline without Math.random or timers, and hold still for at least the final 0.5 seconds.
HyperFrames · ReelForge · Scrolline
개념 출처와 라이선스. 구현은 이 레포에서 새로 씀Concept sources and licenses. Implementations are original to this repo