waibu-bootstrap 2.12.4 → 2.12.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -9,7 +9,8 @@ export async function buildMenu (params = {}) { // scope: component
|
|
|
9
9
|
const { isString } = this.app.lib._
|
|
10
10
|
const $ = this.$
|
|
11
11
|
let menuHtml = params.html
|
|
12
|
-
let style = params.attr.
|
|
12
|
+
let style = params.attr.menuStyle ?? ''
|
|
13
|
+
style += params.attr.menuOnly ? 'display:block;' : ''
|
|
13
14
|
if (params.attr.menuMax) {
|
|
14
15
|
const max = parseInt(params.attr.menuMax)
|
|
15
16
|
if (max > 0) {
|
|
@@ -11,6 +11,8 @@ export async function build (handler) {
|
|
|
11
11
|
const contents = []
|
|
12
12
|
attr._.id = this.params.attr.id ?? generateId('alpha')
|
|
13
13
|
if (attr._.color) attr.label.class.push(parseVariant.call(this, { cls: 'btn', value: attr._.color, values: colors, variants, prepend: true }))
|
|
14
|
+
if (attr._.size) attr.label.class.push('btn-' + attr._.size)
|
|
15
|
+
delete attr._.size
|
|
14
16
|
delete attr._.color
|
|
15
17
|
|
|
16
18
|
contents.push(await handler.call(this, attr, this.params))
|
|
@@ -10,6 +10,7 @@ function setResponsive (params) {
|
|
|
10
10
|
const { isString } = this.app.lib._
|
|
11
11
|
let xcls = `${cls}-responsive`
|
|
12
12
|
if (isString(this.params.attr.responsive)) xcls += '-' + this.params.attr.responsive
|
|
13
|
+
if (this.params.attr.rounded) xcls += ' rounded-3'
|
|
13
14
|
this.params.prepend = `<div class="${xcls}">`
|
|
14
15
|
this.params.append = '</div>'
|
|
15
16
|
}
|
package/package.json
CHANGED