如何根据屏幕尺寸设置角度图标?

时间:2015-12-22 10:44:03

标签: angularjs responsive-design

图形设计师为我创建了不同尺寸的每个图标。 如何将它们集成到角度html文件中?

如何使用桌面最大的图标,平板电脑尺寸较小,移动电话尺寸最小?

1 个答案:

答案 0 :(得分:0)

在您不想显示时隐藏每个图标

<head>
      <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css" />
      <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/js/bootstrap.min.js"></script>
</head>
<body>       
        <div id="big-icon" class="hidden-sm hidden-xs hidden-md"></div>
        <div id="small-icon" class="hidden-lg hidden-xs hidden-md"></div>
        <div id="smallest-icon" class="hidden-lg hidden-sm hidden-md"></div>
</body>