fix: 样式打包失效优化

This commit is contained in:
ZhuRui
2026-08-07 20:12:33 +08:00
parent d9a20c906b
commit ac7bfeacfe
2 changed files with 32 additions and 35 deletions
+3 -6
View File
@@ -1,6 +1,4 @@
// 参数值单元格:文字最多 2 行省略,末尾带"查看"链接 .cell {
:global {
.param-value-cell {
display: flex; display: flex;
align-items: center; align-items: center;
gap: 6px; gap: 6px;
@@ -8,7 +6,7 @@
cursor: default; cursor: default;
} }
.param-value-text { .text {
flex: 1; flex: 1;
min-width: 0; min-width: 0;
display: -webkit-box; display: -webkit-box;
@@ -21,7 +19,7 @@
color: rgba(0, 0, 0, 0.88); color: rgba(0, 0, 0, 0.88);
} }
.param-value-view { .view {
flex-shrink: 0; flex-shrink: 0;
color: #1677ff; color: #1677ff;
cursor: pointer; cursor: pointer;
@@ -33,4 +31,3 @@
opacity: 0.85; opacity: 0.85;
} }
} }
}
+4 -4
View File
@@ -5,7 +5,7 @@ import { saveParam, updateParam } from './model/services';
import { useState, useThrottleFn, useContainerSize, useEffect } from '@/hooks'; import { useState, useThrottleFn, useContainerSize, useEffect } from '@/hooks';
import ParamFormModal from './components/ParamFormModal'; import ParamFormModal from './components/ParamFormModal';
import pageStyles from '@/assets/styles/pageLayout.module.less'; import pageStyles from '@/assets/styles/pageLayout.module.less';
import './index.module.less'; import cellStyles from './index.module.less';
/** /**
* 参数值单元格:最多 2 行截断,溢出时显示"查看"按钮 * 参数值单元格:最多 2 行截断,溢出时显示"查看"按钮
@@ -38,12 +38,12 @@ const ParamValueCell = defineComponent({
return () => { return () => {
const raw = props.text; const raw = props.text;
return ( return (
<div class="param-value-cell"> <div class={cellStyles.cell}>
<div ref={textRef} class="param-value-text"> <div ref={textRef} class={cellStyles.text}>
{raw} {raw}
</div> </div>
{overflow.value ? ( {overflow.value ? (
<span class="param-value-view" onClick={() => setModalOpen(true)}> <span class={cellStyles.view} onClick={() => setModalOpen(true)}>
</span> </span>
) : null} ) : null}