📜  幽灵标签

📅  最后修改于: 2022-05-13 01:56:17.457000             🧑  作者: Mango

幽灵标签

Spectre 标签是用于突出显示信息文本的格式化文本标签。这些标签通常是矩形的。但是,我们可以在 Spectre Labels Rounded 标签的帮助下将标签的形状更改为圆形。

幽灵标签类型:

  • Spectre 标签:这是默认的矩形标签。
  • 幽灵标签四舍五入: 这是圆形标签,已用于制作药丸/圆形药丸。

幽灵标签类:

  • label:该类用于创建默认的矩形标签。
  • label-rounded:该类用于将标签整形为药丸状标签。

句法:

HTML


  

    
    
    

  

    
        

GeeksforGeeks

        SPECTRE labels     
    

    
        
        Labels on span Elements:         
                     Default label                               Primary label                               Success label                               Error label                               Warning label                  
        
        
        Labels on small Elements:         
                     Default label                               Primary label                               Success label                               Error label                               Warning label                  
    
  


HTML


  

    
    
    

  

    
        

GeeksforGeeks

        SPECTRE Labels Rounded labels     
    

    
        
        Labels on span Elements:         
                     Default label                               Primary label                               Success label                               Error label                               Warning label                  
        
        
        Labels on small Elements:         
                     Default label                               Primary label                               Success label                               Error label                               Warning label                  
    
  


输出:

幽灵标签

幽灵标签

示例 2:在此示例中,我们将创建多种颜色的圆形标签。

HTML



  

    
    
    

  

    
        

GeeksforGeeks

        SPECTRE Labels Rounded labels     
    

    
        
        Labels on span Elements:         
                     Default label                               Primary label                               Success label                               Error label                               Warning label                  
        
        
        Labels on small Elements:         
                     Default label                               Primary label                               Success label                               Error label                               Warning label                  
    
  

输出:

幽灵标签

幽灵标签

参考: https://picturepan2.github.io/spectre/elements/labels.html