Home > Enterprise >  Have 2 types of sized in google icon font
Have 2 types of sized in google icon font

Time:11-24

I need to have 2 types of menu

one with small icons and one with larger icons

I have tried adding small class

<!DOCTYPE html>
<html>

<body>
<!doctype html>
<html lang="en">
  <head>
  
    <link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Material Symbols Outlined:opsz,wght,FILL,GRAD@40,400,0,0" />
    <link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-rbsA2VBKQhggwzxH7pPCaAqO46MgnOM80zW1RWuH61DGLwZJEdK2Kadq2F9CUG65" crossorigin="anonymous">
    
    <style>
    <style>
.material-symbols-outlined {
    font-variation-settings: "FILL"0,"wght"400,"GRAD"0,"opsz"40
}

.material-symbols-outlined-small {
    font-variation-settings: "FILL"0,"wght"100,"GRAD"0,"opsz"24

}

</style>
    
    </style>
    
    
  </head>
  
  <body>

    <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-kenU1KFdBIe4zVF0s0G1M5b4hcpxyD9F7jL jjXkk Q2h455rYXK/7HAuoJl 0I4" crossorigin="anonymous"></script>
    
<ul  style=" margin: 0px; transform: translate3d(0px, 38.4px, 0px);" data-popper-placement="bottom-end">
                <li><a  href="#"><span >share</span>&nbsp;Export</a></li>
                <li><a  href="#"><span >edit</span>&nbsp;Duplicate</a></li>
                <li><a  href="#"><span >delete</span>&nbsp;Delete</a></li>
            </ul>
            

<ul  style="inset: 0px 0px auto auto; margin: 0px; transform: translate3d(0px, 38.4px, 0px);" data-popper-placement="bottom-end">
                <li><a  href="#"><span >share</span>&nbsp;Export</a></li>
                <li><a  href="#"><span >edit</span>&nbsp;Duplicate</a></li>
                <li><a  href="#"><span >delete</span>&nbsp;Delete</a></li>
            </ul>
            

  </body>
</html>

CodePudding user response:

The class material-symbols-outlined is reserved for Google Material Symbols. You cannot change it to material-symbols-outlined-small and expect Google Material Symbols to work. Instead, add the second class (e.g., small).

WRONG:

<li><a  href="#"><span >share</span>&nbsp;Export</a></li>

CORRECT:

<li><a  href="#"><span >share</span>&nbsp;Export</a></li>

See the snippet below.

.material-symbols-outlined {
  font-variation-settings: "FILL"0, "wght"400, "GRAD"0, "OPSZ"40;
}

.material-symbols-outlined.small {
  font-variation-settings: "FILL"0, "wght"100, "GRAD"0, "OPSZ"24;
}
<!doctype html>
<html lang="en">

<head>
  <link href="https://fonts.googleapis.com/css2?family=Material Symbols Outlined:opsz,wght,FILL,[email protected],100..700,0..1,-50..200" rel="stylesheet" />
  <link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-rbsA2VBKQhggwzxH7pPCaAqO46MgnOM80zW1RWuH61DGLwZJEdK2Kadq2F9CUG65" crossorigin="anonymous">
</head>

<body>
  <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-kenU1KFdBIe4zVF0s0G1M5b4hcpxyD9F7jL jjXkk Q2h455rYXK/7HAuoJl 0I4" crossorigin="anonymous"></script>

  <ul  style=" margin: 0px; transform: translate3d(0px, 38.4px, 0px);" data-popper-placement="bottom-end">
    <li><a  href="#"><span >share</span>&nbsp;Export</a></li>
    <li><a  href="#"><span >edit</span>&nbsp;Duplicate</a></li>
    <li><a  href="#"><span >delete</span>&nbsp;Delete</a></li>
  </ul>


  <ul  style="inset: 0px 0px auto auto; margin: 0px; transform: translate3d(0px, 38.4px, 0px);" data-popper-placement="bottom-end">
    <li><a  href="#"><span >share</span>&nbsp;Export</a></li>
    <li><a  href="#"><span >edit</span>&nbsp;Duplicate</a></li>
    <li><a  href="#"><span >delete</span>&nbsp;Delete</a></li>
  </ul>
</body>

</html>

  • Related