# bootstrapSideButtons **Repository Path**: xiaoxu1111/bootstrap-side-buttons ## Basic Information - **Project Name**: bootstrapSideButtons - **Description**: 基于bootstrap的一个侧边栏按钮插件 - **Primary Language**: JavaScript - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2024-01-02 - **Last Updated**: 2024-01-02 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # bootstrapSideButtons #### 介绍 基于bootstrap的一个侧边栏按钮插件 #### 使用说明 使用new Hsb创建实例 ``` const sbs = new Hsb({ buttons: [{ content: "按钮1", instance: function () { $(this).css("font-size","12px") $(this).click(()=>console.log(this.textContent)) }, }, { content: "按钮2", instance: function () { $(this).css("font-size","12px") $(this).click(()=>console.log(this.textContent)) }, }], dom: $("#SideButton")[0], pagemax: 4, }) ``` buttons:按钮组
按钮组:connent —— 内容,instance——创建时执行,this指向创建的按钮
dom:侧边栏父级元素
pagemax:最多多少按钮