feat: 优化

main
lichaojun 1 year ago
parent e934e944f5
commit 921ba0e5ff

@ -12,7 +12,7 @@ const config = {
inputDir: '',
// inputDir: 'E:/商品资料汇总/商品资料(1051-1100)/ppt1056-研究生复试',
// 指定要查找的目录
directoryPath: 'E:/商品资料汇总/商品资料(1151-1200)',
directoryPath: 'E:/商品资料汇总/商品资料(1201-1250)',
// 要转换的文件个数, 0表示全部转换
rangeNum: 0,
// rangeNum: 3,

@ -31,7 +31,7 @@ class Config:
if directory_path_match:
Config.WORK_PATH = directory_path_match.group(1)
if range_num_match:
Config.RANGE_NUM = range_num_match.group(1)
Config.RANGE_NUM = int(range_num_match.group(1))
@staticmethod
def get_latest_folder(base_directory):

@ -27,7 +27,7 @@ async function nodeGenWatermark({ img, text, filepath }) {
* @param {string} color 字体颜色
* @return {Buffer}
*/
function text2SVG({ text, fontSize = 24, color = 'rgba(204, 204, 204, 0.2)' }) {
function text2SVG({ text, fontSize = 24, color = 'rgba(204, 204, 204, 0.3)' }) {
const fontPath = path.join(__dirname, '../assets/STHUPO.TTF');
// 加载字体文件
const text2SVG = Text2SVG.loadSync(fontPath);

Loading…
Cancel
Save