vue ul li颜色字体不同

效果图:

 

 

<footbutton :style="{'color':item.color}" v-for="(item,index) in footlist" :key="index" :item="item">{{item.name}}</footbutton>
footlist: [{
                        id: 7,
                        name: "下载",
                        color: "#888888"
                    },
                    {
                        id: 8,
                        name: "移动",
                        color: "blue",
                     
                    },
                    {
                        id: 9,
                        name: "删除",
                        color: "#ffffff",
                    
                    },
                    {
                        id: 10,
                        name: "分享",
                        color: "#ffffff",
                    
                    },
                    {
                        id: 11,
                        name: "重命名",
                        color: "red",
                 
                    },
                ],

 

posted @ 2020-05-07 10:28  熊大的小跟班  阅读(1092)  评论(0编辑  收藏  举报