如何使聚合物网格项目在材料设计规范(主要作用)中成为“href”?这是到材料设计规范:https://material.google.com/components/grid-lists.html#grid-lists-content的链接。
发布于 2016-11-11 13:11:12
你读过文档吗?可以将div用作许多a链接的容器,如下所示:
<dom-module id="grid-test">
<template>
<style include="app-grid-style">
:host {
--app-grid-columns: 3;
--app-grid-item-height: 100px;
}
div {
padding: 0;
list-style: none;
}
.item {
background-color: white;
border: 1px solid black;
}
</style>
<div class="app-grid">
<a href="#" class="item">1</a>
<a href="#" class="item">2</a>
<a href="#" class="item">3</a>
<a href="#" class="item">4</a>
<a href="#" class="item">5</a>
<a href="#" class="item">6</a>
<a href="#" class="item">7</a>
<a href="#" class="item">8</a>
<a href="#" class="item">9</a>
<a href="#" class="item">10</a>
<a href="#" class="item">11</a>
<a href="#" class="item">12</a>
<a href="#" class="item">13</a>
<a href="#" class="item">14</a>
</div>
</template>
<script>
Polymer({
is: "grid-test"
});
</script>
</dom-module>https://stackoverflow.com/questions/40545397
复制相似问题