Skip to content

pantoken / design/swatches/src / toGpl

Fall: toGpl()

toGpl(swatches, options?): string

Tilrauna

Kóða litasýni sem GIMP .gpl litaspjaldstreng.

Færibreytur

swatches

aðeins-lesið Swatch[]

Litasafnið.

options?

ToGplOptions = {}

ToGplOptions.

Skilar

string

Dæmi

Skrifa GIMP .gpl litaspjald

ts
import { writeFileSync } from "node:fs";
import { swatches, toGpl } from "@pantoken/swatches";

writeFileSync("instructure.gpl", toGpl(swatches));

Með sérsniðið nafn litaspjalds

ts
import { swatches, toGpl } from "@pantoken/swatches";

const gpl = toGpl(swatches, { name: "Instructure Rebrand" });