sales-frontend-utils 0.0.52 → 0.0.53

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -625,7 +625,7 @@ var convertTextToImg = ({
625
625
  fontColor,
626
626
  fontSize,
627
627
  fontWeight,
628
- fontFamily = `'Malgun Gothic', '\uB9D1\uC740 \uACE0\uB515', 'sans-serif', 'Arial'`
628
+ fontFamily = `'system-ui', 'sans-serif'`
629
629
  }) => {
630
630
  const canvas = document.createElement("canvas");
631
631
  const ctx = canvas.getContext("2d");
@@ -642,8 +642,8 @@ var convertTextToImg = ({
642
642
  }
643
643
  ctx.fillStyle = fontColor ?? "black";
644
644
  ctx.textAlign = "center";
645
- ctx.font = `${fontWeight ?? "bold"} ${fontSize ?? 75}px ${fontFamily}`;
646
- console.log("font", `${fontWeight ?? "bold"} ${fontSize ?? 75}px ${fontFamily}`);
645
+ ctx.font = `${fontWeight ?? "normal"} ${fontSize ?? 75}px ${fontFamily}`;
646
+ console.log("font", `${fontWeight ?? "normal"} ${fontSize ?? 75}px ${fontFamily}`);
647
647
  ctx.textBaseline = "middle";
648
648
  ctx.fillText(targetStr, canvas.width / 2, canvas.height / 2);
649
649
  return canvas.toDataURL();