登录、注册页样式修改

This commit is contained in:
2026-03-12 09:11:48 +08:00
parent affb2342eb
commit e6d95b52b9
5 changed files with 302 additions and 192 deletions

View File

@@ -1,7 +1,7 @@
const fs = require('fs');
const path = 'D:/骅锋/mall/pages/mall/admin/userCenter/index.uvue';
const fs = require("fs");
const path = "D:/骅锋/mall/pages/mall/admin/userCenter/index.uvue";
let text = fs.readFileSync(path, 'utf-8');
let text = fs.readFileSync(path, "utf-8");
const targetScript = `<script setup lang="uts">
import { reactive, computed, onMounted } from 'vue'
@@ -135,9 +135,12 @@ const onSubmit = async () => {
}
</script>`;
text = text.replace(/<script setup lang=["']uts["']>[\s\S]*?<\/script>/, targetScript);
text = text.replace(
/<script setup lang=["']uts["']>[\s\S]*?<\/script>/,
targetScript,
);
text = text.replace(/value="demo"/, ':value="userAccount"');
text = text.replace(/src="\/static\/logo\.png"/, ':src="avatarUrl"');
fs.writeFileSync(path, text, 'utf-8');
console.log('Done');
fs.writeFileSync(path, text, "utf-8");
console.log("Done");