Skip to content

pantoken-root / plugins/pantoken/custom-theme-colors/src / deriveScale

함수: deriveScale() ​

deriveScale(hex, curve): CustomColorScale

베타

하나의 헥스에서 전체 프리미티브 스케일을 파생합니다: 참조 명도가 가장 가까운 단계에 앵커한 후, 입력의 색상(hue)과 참조 형태로 스케일된 채도로 각 단계를 해당 참조 명도에서 재구성합니다.

매개변수 ​

hex ​

string

parseHexColor에서 허용되는 헥스 색상.

curve ​

ReferenceCurve

buildReferenceCurve의 출력.

반환값 ​

CustomColorScale

해당 CustomColorScale.