【问题标题】:How to make CSS change in Angular Material Stepper?如何在 Angular Material Stepper 中更改 CSS?
【发布时间】:2022-08-19 23:09:18
【问题描述】:

我在一个项目上与 Mat-Stepper 合作。这是该项目的 stackblitz link。我想在这里做两个改变:-

  1. 如何删除步骤之间的水平线并用其他东西替换它,如箭头或其他东西?
  2. 我想通过在标签周围添加阴影来突出显示标签。那可能吗?

    在此先感谢您的帮助。

    标签: javascript angular typescript angular-module mat-stepper


    【解决方案1】:

    将此添加到您的样式中并将背景更改为您喜欢的任何样式

    .mat-stepper-horizontal-line{border-color: transparent; position: relative;}
    .mat-stepper-horizontal-line:after{content: ""; position: absolute; left: 50%; top: 50%; width: 20px; height: 20px; background: red; margin: -10px 0 0 -10px;}
    

    盒影

    .mat-horizontal-stepper-header-container{box-shadow: inset 0 0 0 1px red;}
    

    【讨论】:

    • 谢谢,工作就像一个魅力。第二题呢?
    • 请查看更新的答案
    猜你喜欢
    • 2018-12-31
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-03-12
    • 2021-01-20
    • 1970-01-01
    相关资源
    最近更新 更多