|
|
| (未显示同一用户的3个中间版本) |
| 第1行: |
第1行: |
| <includeonly> | | <includeonly> |
| <!-- 核心样式:抽离为内联样式(也可迁移到站点CSS) -->
| | <div style="display:inline-block; vertical-align:top; width:80px; min-width:80px; height:80px; min-height:80px;margin:1px; border:solid 1px; padding:4px; text-align:center; line-height:12px;">{{fa|{{{1}}}|size=28px|style= border-bottom:solid 1px; padding:8px; margin-bottom:8px; }}<br/><span style=font-size:12px; max-height:24px; line-height: 12px;">{{{1}}}</span></div> |
| <div style=" | | </includeonly><noinclude>{{Documentation}}</noinclude> |
| display: inline-block;
| |
| vertical-align: top;
| |
| width: 80px;
| |
| min-width: 80px;
| |
| height: 80px;
| |
| min-height: 80px;
| |
| margin: 1px;
| |
| border: solid 1px #ccc; /* 浅灰色边框,更通用 */
| |
| border-radius: 2px; /* 轻微圆角,提升视觉 */
| |
| padding: 4px;
| |
| text-align: center;
| |
| line-height: 12px;
| |
| overflow: hidden; /* 防止图标/文字溢出 */
| |
| box-sizing: border-box; /* 盒模型兼容 */
| |
| "> | |
| <!-- Font Awesome图标:支持默认值+样式 -->
| |
| {{fa|{{{1|question-circle}}}|size=28px|style=
| |
| display: block; /* 独占一行,避免对齐问题 */
| |
| border-bottom: solid 1px #eee;
| |
| padding: 8px 0;
| |
| margin-bottom: 8px;
| |
| color: #333; /* 图标默认颜色 */
| |
| }}
| |
| <!-- 图标名称:自动换行+溢出隐藏 -->
| |
| <span style="
| |
| font-size: 12px;
| |
| max-height: 24px;
| |
| line-height: 12px;
| |
| color: #666; /* 文字浅于图标,层级更清晰 */
| |
| display: inline-block;
| |
| word-break: break-all; /* 超长名称自动换行 */
| |
| overflow: hidden;
| |
| text-overflow: ellipsis; /* 溢出显示省略号 */
| |
| ">
| |
| {{{1|question-circle}}}
| |
| </span>
| |
| </div> | |
| </includeonly> | |
| | |
| <noinclude> | |
| {{Documentation}} <!-- 关联维基百科标准文档模板(可选) --> | |
| | |
| == 模板说明 ==
| |
| ### 功能
| |
| 快速生成统一样式的Font Awesome图标卡片,包含图标+图标名称,支持自定义图标名。
| |
| | |
| ### 用法
| |
| ```wiki
| |
| {{IconCard|图标名称}}
| |