/**
 * Calculates the conversion factor from ch units to px units.
 *
 * Creates a temporary div element with a width of '1ch', appends it to the document body,
 * measures its width in pixels, and then removes the element.
 *
 * @returns The width of '1ch' in pixels.
 */
export default () => {
    const chToPxDiv = document.createElement('div');
    chToPxDiv.style.width = '1ch';
    chToPxDiv.style.position = 'fixed';
    document.body.append(chToPxDiv);
    const conversionFactor = chToPxDiv.offsetWidth;
    chToPxDiv.remove();
    return conversionFactor;
};
//# sourceMappingURL=getChToPxConversionFactor.js.map