Files
intc-vue-h5/scripts/patch-u-input.js
2026-06-28 13:47:31 +08:00

24 lines
692 B
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/**
* uView u-input 组件补丁
* 直接用预存的补丁文件覆盖原始文件
* 使下拉选择框readonly/disabled超长文字可自动换行完整显示
*/
const fs = require('fs');
const path = require('path');
const target = path.join('node_modules', 'uview-plus', 'components', 'u-input', 'u-input.vue');
const source = path.join('scripts', 'u-input.vue');
if (!fs.existsSync(target)) {
console.log('[patch-u-input] target not found, skipping');
process.exit(0);
}
if (!fs.existsSync(source)) {
console.log('[patch-u-input] source not found, skipping');
process.exit(0);
}
fs.copyFileSync(source, target);
console.log('[patch-u-input] Patched successfully');