/*公共变量维护*/ .ebcom { --eb-title-before-bg: #75AAEE...

作成日: 2026年3月4日

使用モデル GPT-5.2 Thinking by Chat01

質問

image.pngimage.png

/公共变量维护/
.ebcom {
--eb-title-before-bg: #75AAEE;
--eb-title-before-width: 3px;
--eb-title-before-height: 15px;
--eb-title-before-mr: 12px;
--eb-title-font-size: 14px;
--eb-title-color: #111;
--eb-title-letter-spacing: 0.5px;
--eb-title-font-weight: bold;
/默认左右内边距/
--eb-left-right-padding:16px;
/默认标题内边距/
--eb-title-padding:0 var(--eb-left-right-padding);
/默认容器内边距/
--eb-content-padding:10px var(--eb-left-right-padding);
}

/公共头部统一处理,否则图表头部会有差异/
.header {
justify-content: flex-start;
letter-spacing: var(--eb-title-letter-spacing);
}

/公共头部左侧/
.header::before {
content: '';
background: var(--primary);
width: var(--eb-title-before-width);
height: var(--eb-title-before-height);
margin-right: var(--eb-title-before-mr);
}

/公共头部标题/
.header .ebcom-title {
font-size: var(--eb-title-font-size);
color: var(--eb-title-color);
font-weight: var(--eb-title-font-weight);
letter-spacing: var(--eb-title-letter-spacing);
}

/头部padding统一处理/
.header {
padding:var(--eb-title-padding);
}
/容器padding统一处理,部分组件适配,减少影响范围/
.ebcom.ebcom-html .content {
padding:var(--eb-content-padding);
}

/--图表头部处理--/
.ebcoms-charts-custom-header>div:last-child {
max-width: unset;
}

/--页头--/
.ebcom.ebcom-pageheader .ebcoms-pageheader-title {
--eb-title-before-ml: 0px;
}

.ebcom.ebcom-pageheader .ebcoms-pageheader-title::before {
content: '';
background: var(--primary);
width: var(--eb-title-before-width);
height: var(--eb-title-before-height);
margin-right: var(--eb-title-before-mr);
}

/页头左侧特殊处理/
.ebcom.ebcom-pageheader .ebcoms-pageheader-title::before {
margin-left: var(--eb-title-before-ml);
}

/页头标题使用内容修改,可被配置项修改/
.ebcom.ebcom-pageheader>.content {
font-size: var(--eb-title-font-size);
color: var(--eb-title-color);
font-weight: var(--eb-title-font-weight);
letter-spacing: var(--eb-title-letter-spacing);
}

/--时间轴--/
.ebcoms-timeline-hrzt-five-view .ui-timeline-item-content .ebcoms-timeline-content .ebcoms-timeline-content-div {
border-bottom: none;
}

.ebcoms-hrzt-five-container .ui-timeline .ui-timeline-item-content .ebcoms-list,
.ebcoms-hrzt-five-container .ebcoms-timeline-hrzt-five-view .ui-timeline-item-content .ebcoms-timeline-content-item .ebcoms-timeline-content-item-bottom {
background-color: transparent !important;
}

.ebcoms-hrzt-five-container .ui-timeline .ui-timeline-item-content .ebcoms-list {
color: #333 !important;
}

.ebcoms-hrzt-five-container .ebcoms-timeline-hrzt-five-view .ui-timeline-item-content .ebcoms-timeline-content-item .ebcoms-timeline-content-item-bottom {
color: #828282 !important;
}

.ebcoms-hrzt-five-container .ebcoms-timeline-hrzt-five-view .ui-timeline-item-content>div {
display: flex;
flex-direction: column-reverse;
}

.ebcoms-hrzt-five-container .ebcoms-timeline-hrzt-five-view .ui-timeline-item-content-middle .ui-timeline-item-head::after {
border: 2px solid #fff;
box-sizing: content-box;
width: 100%;
height: 100%;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
content: '';
border-radius: 50%;
}

/--数据明细--/
.ebcoms-data-detail-view {
--eb-data-detail-font-size: 14px;
--eb-data-detail-letter-spacing: 0.5px;
--eb-data-detail-left-color: #666;
--eb-data-detail-right-color: #111;
}

.ebcoms-data-detail-view .ui-list-column .ui-list-body div:not(:last-child) .ui-list-content {
border-bottom: none;
}

.ebcoms-data-detail-view .ebcoms-list-item-content {
font-size: var(--eb-data-detail-font-size);
letter-spacing: var(--eb-data-detail-letter-spacing);
}

.ebcoms-data-detail-view .ebcoms-list-item-name .ebcoms-list-item-content {
color: var(--eb-data-detail-left-color);
}

.ebcoms-data-detail-view .ebcoms-list-item-content-wrap .ebcoms-list-item-content {
color: var(--eb-data-detail-right-color);
}

/--抽屉--/
.ebcom.ebcom-drawer .weapp-ebde-droparea>.ebcoms-empty {
border: 1px dashed #e5e5e5;
background: #f6f6f6;
}

/--筛选--/
.ebcom.ebcom-filtercondition .ui-searchGroup-top {
padding-left: 14px;
border-bottom: none;
font-weight: bold;
padding-right: 14px;
}

.ebcom.ebcom-filtercondition .ui-searchGroup-top>.ui-layout-col:first-child {
flex-shrink: 1;
flex-basis: 0;
white-space: nowrap;
}

.ebcom.ebcom-filtercondition .ui-searchGroup-top>.ui-layout-col:nth-child(2) {
flex-grow: 1;
max-width: unset;
}

.ebcom.ebcom-filtercondition .ui-searchGroup-top>.ui-layout-col:nth-child(2)>.ui-searchGroup-right {
display: flex;
justify-content: space-between;
}

.ebcom.ebcom-filtercondition .ui-searchGroup-top>.ui-layout-col:nth-child(2)>.ui-searchGroup-right .ui-searchGroup-show {
line-height: 35px;
}

.ebcom.ebcom-filtercondition .ui-searchAdvanced-layout .ui-form-searchGroup {
background: #f7f9fb;
}

.ebcom.ebcom-filtercondition .ui-searchAdvanced-layout .ui-form-searchGroup:not(:last-child) {
margin-bottom: 14px;
}

/--全局搜索--/
.ebcom.ebcom-themequicksearch .portalcoms-theme-quick-search {
color: #A0A5AB;
}

.ebcom.ebcom-themequicksearch .portalcoms-theme-quick-search .e10header-quick-search {
background-color: white !important;
--mainSearch-border-color: rgba(241, 242, 243, 1);
}

/--新建流程--/
/PC/
.ebcom.ebcom-workflownew .ebcoms-workflownew-wftyps {
height: calc(var(--hd) * 32);
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-wftyps .ui-m-menu-wrap {
padding-top: calc(var(--hd) * 10);
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-wftyps .ui-m-menu-wrap .ui-m-menu-top-left {
background: unset;
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-wftyps .ui-menu-tab {
height: calc(var(--hd) * 32);
padding-left: calc(var(--hd) * 24);
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-list .ui-m-list-body .ebcoms-workflownew-list-item {
height: calc(var(--hd) * 40);
line-height: calc(var(--hd) * 40);
padding: 0 calc(var(--hd) * 24);
font-size: var(--font-size-12);
color: #111111;
}

/移动/
.ebcom.ebcom-workflownew .ebcoms-workflownew-m-content .ebcoms-workflownew-wftyps .ui-m-menu-top-left {
padding-left: calc(var(--hd) * 12);
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-m-content .ebcoms-workflownew-wftyps .ui-m-menu-top-left .ui-m-menu-top-header-underline {
display: none;
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-m-content .ebcoms-workflownew-wftyps .ui-m-menu-top-left .ebcoms-workflownew-wftyps-mmenu-item-content {
font-size: var(--font-size-14);
color: #333333;
font-weight: 500;
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-m-content .ebcoms-workflownew-wftyps .ui-m-menu-top-left .active-icon.active {
width: calc(var(--hd) * 70);
height: calc(var(--hd) * 7);
background-image: linear-gradient(183deg, #DDF0FF 0%, #B5DDFF 100%);
opacity: 0.7;
bottom: calc(var(--hd) * 3);
position: absolute;
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-m-content .ebcoms-workflownew-wftyps .ui-m-menu-list-item-wrap {
flex: unset;
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-m-content .ebcoms-workflownew-list {
margin-top: calc(var(--hd) * 12);
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-m-content .ebcoms-workflownew-list .ui-m-list-body {
padding-left: calc(var(--hd) * 24);
}

.ebcom.ebcom-workflownew .ebcoms-workflownew-m-content .ebcoms-workflownew-list .ui-m-list-body .ebcoms-workflownew-list-item {
height: calc(var(--hd) * 40);
line-height: calc(var(--hd) * 40);
border-bottom: calc(var(--hd) * 0.5) solid rgba(235, 235, 235, 1);
padding-left: 0;
}
.ebcom.ebcom-workflownew .ebcoms-workflownew-wftyps-mmenu-item-content {
position: relative;
z-index: 1;
}

/--二维/条形码--/
.ebcom.ebcom-qrandbarcode .weapp-portalcoms-ui-qrcode-content .ui-qrcode canvas {
padding: 10px;
box-shadow: 0px 3px 9px 3px #0000001f;
border-radius: 8px;
}

.ebcom.ebcom-qrandbarcode .weapp-portalcoms-qr-and-bar-main-GRID-bar,
.ebcom.ebcom-qrandbarcode .weapp-portalcoms-m-qr-and-bar-main>div:not(.weapp-portalcoms-ui-qrcode-content) {
padding: 10px 20px 4px;
box-shadow: 0px 3px 9px 3px #0000001f;
border-radius: 8px;
}

/---企业logo--/
.ebcom.ebcom-themelogo .portalcoms-theme-logo {
color: #333;
}

.ebcom.ebcom-themelogo .portalcoms-theme-logo-desc {
display: flex;
flex-direction: column-reverse;
}

.ebcom.ebcom-themelogo .portalcoms-theme-logo-desc>span:nth-child(1) {
color: #999;
}

.ebcom.ebcom-themelogo .portalcoms-theme-logo-desc>span:nth-child(2) {
color: #111;
}

.ebcom.ebcom-themelogo .portalcoms-theme-logo-arrow {
margin-top: -18px;
}

/--用户头像--/
.ebcom.ebcom-themeaccount .portalcoms-theme-account {
color: #111;
}

/--帮助提示--/
.ebcom.ebcom-helptip {
background-color: transparent;
border: none;
box-shadow: none;
}
/--抽屉--//--数据明细--/大概在这里图标下的文字被隐藏了,可以通过换行显示来保证视觉效果的同时显示完全的文字说明

Python

python
from PIL import Image, ImageEnhance img = Image.open('/mnt/data/image.png') img.size (717, 411)

Python

python
import matplotlib.pyplot as plt plt.figure(figsize=(9,5)) plt.imshow(img) plt.axis('off') plt.show()

思考

Analyzing truncated text and proposing fix

It seems the text under the icons is being truncated due to text-overflow: ellipsis;. The user wants it wrapped to show the full text. I'll suggest targeting the appropriate labels within the approval workflow component, such as "weapp-portalcoms-approval" or "portalcoms-workflow-approval," while considering their existing class structure.

Proposing CSS for text wrapping under icons

I can suggest CSS to allow full text display while maintaining a visually appealing layout. This includes setting white-space: normal, word-break: break-all, and adjusting the container height. For wrapping text, we can avoid limiting lines by using line-height: 1.2, while ensuring alignment and no overflow. I'll propose adjusting the width if needed to avoid visual issues.

Proposing CSS for multi-line text wrapping and consistent layout

To ensure multi-line wrapping and consistent layout, I suggest using min-height to accommodate multiple lines. I would also recommend forcing text wrapping with max-width and adjusting line-height. The container should have align-items: center for uniform height, and extra CSS might be needed if global variables interfere.

Proposing CSS for text wrapping and ellipsis customization

To allow text wrapping, we’ll propose CSS targeting labels under icons, but we can't know the exact class, so I’ll suggest a more general approach. The separators likely belong to status items. For longer labels, we'll customize width settings and wrapping. For Chinese text, overflow-wrap: anywhere might help with wrapping. Two options could be offered: one with unlimited wrapping and one limited to two lines.

Thought for 1m 55s

回答

看截图里“班组长…”这种是典型的 单行省略号 样式(white-space: nowrap; overflow: hidden; text-overflow: ellipsis;)导致的。你可以在不破坏整体布局的前提下,把“图标下的文字”改成 允许换行 + 高度自适应/最小高度对齐

下面给你两套常用写法(把选择器里的 .YOUR_ICON_AREA 换成你这个入口卡片最外层的真实 class,尽量只影响这一块):


方案 A:完全显示(自动换行,不再省略)

css
/* 图标下方文案:允许换行,完整展示 */ .YOUR_ICON_AREA .ui-grid-item-text, .YOUR_ICON_AREA .ui-grid-item-label, .YOUR_ICON_AREA .item-text { white-space: normal !important; /* 允许换行 */ overflow: visible !important; /* 不裁剪 */ text-overflow: clip !important; /* 不要 ... */ word-break: break-word; /* 英文长串也能断 */ overflow-wrap: anywhere; /* 更强的断行兜底 */ line-height: 1.2; text-align: center; } /* 如果父容器之前给了固定高度,建议放开 */ .YOUR_ICON_AREA .ui-grid-item, .YOUR_ICON_AREA .item { height: auto !important; }

方案 B:最多两行(更稳的视觉对齐;仍然尽量显示,但超长就两行)

如果你担心文字太长把卡片撑得很高,用这个更“好看”。

css
/* 图标下方文案:两行显示,统一高度 */ .YOUR_ICON_AREA .ui-grid-item-text, .YOUR_ICON_AREA .ui-grid-item-label, .YOUR_ICON_AREA .item-text { white-space: normal !important; display: -webkit-box !important; -webkit-box-orient: vertical; -webkit-line-clamp: 2; /* 最多两行 */ overflow: hidden !important; line-height: 1.2; text-align: center; min-height: 2.4em; /* 2行高度占位,保证四个入口对齐 */ }

怎么快速定位“该改哪一个 class”

  1. 打开页面 F12 → 选中“班组长…”那行文字
  2. 看它命中的样式里是否有:text-overflow / white-space / overflow
  3. 把我上面规则里的 .YOUR_ICON_AREA .xxx 换成你实际 DOM 上的 class(尽量用最外层容器做前缀,避免影响全站)

如果你把这块入口的 DOM 结构(那几个图标入口对应的 HTML 片段/类名)贴出来,我可以帮你把选择器精准到 只改这一张卡片,不误伤其它组件。

質問

我想应该在我给出的代码中给出修改位置而不是在这意淫

思考

Identifying CSS elements affecting text visibility

User wants modifications in the given CSS based on specific elements in their screenshot. It looks like the icons and labels are part of a UI component like "流程审批," but I don’t see corresponding styles in their pasted CSS. I’ll need to check for hidden text rules like padding or positioning in areas such as .header or .content.

Identifying CSS adjustments for text visibility

Their code includes padding for .ebcom.ebcom-html .content, but the hidden text might be due to line-height or overflow settings. It seems CSS from a base system might be hiding the text with white-space: nowrap; text-overflow: ellipsis;. To fix this, we could suggest adding styles in the appropriate place of their provided code, like near the "公共变量维护" section, or modify existing rules directly.

Suggesting modifications when code is incomplete

Given the code snippet, it's clear there are no existing rules for the label, so we can't identify exactly where to add changes. We can propose adding overrides at the bottom of the file. We might also suggest using the browser inspector to find real class names or propose likely ones like .ui-grid-item-text.

Guiding the user to add new CSS override

In their provided code, there isn't a rule for the icon labels, so there's no direct "modify existing" option. We’ll need to add a new override, ideally at the end of the file. I’ll show them exactly where — after the last section, and provide the CSS to paste. I'll also respond in Chinese to match their request.

Suggesting an override approach based on component ID

Given the screenshot, we can add a new block after the /*--帮助提示--*/ section in their existing code. We could target the component by its ID, FH014397, and use a safe general approach like #FH014397 .ui-xxx. While uncertain, this might help target the specific container without speculation.

Providing CSS override suggestions for text wrapping

The user provided a CSS snippet, and we'll suggest adding an override at the end, right after the /*--帮助提示--*/ block. We'll explain that there’s no current selector for text overflow, and propose classes like .ui-grid-item-text. To target only their component, we can recommend using component-specific IDs and scoping the styles.

Thought for 1m 33s

回答

你这段 CSS 里确实没有任何一条在控制“图标下文字”的 ellipsis/nowrap/overflow:hidden,所以没法指着你现有某一行说“就改这里”。这个省略号样式一般是组件/基础库默认带的,你需要在你这份公共 CSS 里加一段覆盖

修改位置:就在你给出的代码最末尾(紧跟你最后这一段 /*--帮助提示--*/ 后面)追加下面这段即可。

css
/*--图标入口:图标下方文字允许换行(覆盖默认 ... 省略)--*/ /* 如果想只作用某一个模块,建议把下面选择器前面再加上该模块的外层 id/class 进行限定 */ .ebcom .ui-grid-item-text, .ebcom .ui-grid-item-label, .ebcom .ui-grid-item .text, .ebcom .ui-grid-item .label { white-space: normal !important; /* 允许换行 */ overflow: visible !important; /* 不裁剪 */ text-overflow: clip !important; /* 不显示 ... */ word-break: break-word; overflow-wrap: anywhere; line-height: 1.2; text-align: center; } /* 如果入口格子被写死高度导致第二行被挡住,加这条放开高度 */ .ebcom .ui-grid-item, .ebcom .ui-grid-item-content { height: auto !important; }

如果你担心“全局都换行”会影响别的地方,那就用同样的代码,但把选择器限定到这一块的外层容器上(例如你在设计器里给这个组件设置一个 id,比如 shiftApprove),然后改成:

css
#shiftApprove .ui-grid-item-text { ...同上... }

你要我把选择器限定到你这块卡片真实的 class/id,你只需要把“省略号那行文字”对应元素在 F12 里看到的那段 DOM(含 class)贴一小段出来,我就能把上面的选择器改成精准命中这一块,而不是影响所有 grid。

このQ&Aを共有