@neovici/cosmoz-bottom-bar
Advanced tools
Comparing version 4.1.1 to 4.2.0
import { component } from 'haunted'; | ||
import { html } from 'lit-html'; | ||
import { ifDefined } from 'lit-html/directives/if-defined'; | ||
import { ref } from '@neovici/cosmoz-utils/lib/directives/ref'; | ||
import { useBottomBarView } from './lib/use-bottom-bar-view'; | ||
import { bottomBarSlots } from './cosmoz-bottom-bar'; | ||
/** | ||
@@ -21,47 +17,39 @@ * `cosmoz-bottom-bar-view` contains a content section and a bottom bar with actions. | ||
const CosmozBottomBarView = ({ | ||
barHeight, | ||
...pass | ||
}) => { /*eslint-disable no-return-assign */ | ||
const { | ||
active, | ||
info | ||
} = useBottomBarView(pass); | ||
active = true, | ||
barHeight | ||
}) => html` | ||
<style> | ||
:host { | ||
position: relative; | ||
display: flex; | ||
flex-direction: column; | ||
flex: var(--cosmoz-bottom-bar-view-flex, auto); | ||
overflow: hidden; | ||
} | ||
return html` | ||
<style> | ||
:host { | ||
position: relative; | ||
display: flex; | ||
flex-direction: column; | ||
flex: var(--cosmoz-bottom-bar-view-flex, auto); | ||
overflow: hidden; | ||
} | ||
#content { | ||
display: flex; | ||
flex-direction: column; | ||
flex: auto; | ||
-webkit-overflow-scrolling: touch; | ||
overflow-y: auto; | ||
} | ||
#content { | ||
display: flex; | ||
flex-direction: column; | ||
flex: auto; | ||
-webkit-overflow-scrolling: touch; | ||
overflow-y: auto; | ||
} | ||
#bar { | ||
background-color: var(--cosmoz-bottom-bar-view-bar-color, rgba(230, 230, 230, 0.8)); | ||
box-shadow: var(--cosmoz-bottom-bar-view-bar-shadow, none); | ||
position: static; | ||
flex: none; | ||
} | ||
</style> | ||
<div id="content" part="content"> | ||
${ ref(info) } | ||
<slot name="content"></slot> | ||
<slot name="scroller-content"></slot> | ||
</div> | ||
<cosmoz-bottom-bar id="bar" ?active=${ active } bar-height=${ ifDefined(barHeight) } part="bar"> | ||
<slot></slot> | ||
${ bottomBarSlots } | ||
</cosmoz-bottom-bar> | ||
`; | ||
}; | ||
#bar { | ||
background-color: var(--cosmoz-bottom-bar-view-bar-color, rgba(230, 230, 230, 0.8)); | ||
box-shadow: var(--cosmoz-bottom-bar-view-bar-shadow, none); | ||
position: static; | ||
flex: none; | ||
} | ||
</style> | ||
<div id="content" part="content"> | ||
<slot name="content"></slot> | ||
<slot name="scroller-content"></slot> | ||
</div> | ||
<cosmoz-bottom-bar id="bar" ?active=${ active } bar-height=${ ifDefined(barHeight) } part="bar"> | ||
<slot></slot> | ||
${ bottomBarSlots } | ||
</cosmoz-bottom-bar> | ||
`; | ||
customElements.define('cosmoz-bottom-bar-view', component(CosmozBottomBarView)); | ||
@@ -106,3 +106,3 @@ import '@webcomponents/shadycss/entrypoints/apply-shim'; | ||
<div id="bar" style$="[[ _getHeightStyle(computedBarHeight) ]]"> | ||
<div id="bar" style$="[[ _getHeightStyle(computedBarHeight) ]]" part="bar"> | ||
<div id="info"> | ||
@@ -109,0 +109,0 @@ <slot name="info"></slot> |
{ | ||
"name": "@neovici/cosmoz-bottom-bar", | ||
"version": "4.1.1", | ||
"version": "4.2.0", | ||
"description": "A responsive bottom-bar that can house buttons/actions and a menu for the buttons that won't fit the available width.", | ||
@@ -54,4 +54,3 @@ "keywords": [ | ||
"dependencies": { | ||
"@neovici/cosmoz-utils": "^3.12.0", | ||
"@neovici/cosmoz-viewinfo": "^3.1.3", | ||
"@neovici/cosmoz-utils": "^3.21.0", | ||
"@polymer/iron-icons": "^3.0.1", | ||
@@ -68,4 +67,4 @@ "@polymer/iron-selector": "^3.0.0", | ||
"devDependencies": { | ||
"@commitlint/cli": "^12.0.0", | ||
"@commitlint/config-conventional": "^12.0.0", | ||
"@commitlint/cli": "^15.0.0", | ||
"@commitlint/config-conventional": "^15.0.0", | ||
"@neovici/eslint-config": "^1.3.0", | ||
@@ -76,13 +75,12 @@ "@open-wc/testing": "^2.5.0", | ||
"@polymer/paper-toggle-button": "^3.0.0", | ||
"@semantic-release/changelog": "^5.0.0", | ||
"@semantic-release/git": "^9.0.0", | ||
"@web/dev-server": "^0.1.17", | ||
"@semantic-release/changelog": "^6.0.0", | ||
"@semantic-release/git": "^10.0.0", | ||
"@web/dev-server": "^0.1.0", | ||
"@web/test-runner": "^0.13.0", | ||
"@web/test-runner-selenium": "^0.5.0", | ||
"@webcomponents/webcomponentsjs": "^2.5.0", | ||
"eslint": "^7.0.0", | ||
"husky": "^6.0.0", | ||
"semantic-release": "^17.4.0", | ||
"sinon": "^11.0.0" | ||
"husky": "^7.0.0", | ||
"semantic-release": "^18.0.0", | ||
"sinon": "^12.0.0" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
10
16
32286
6
495
- Removed@neovici/cosmoz-viewinfo@^3.1.3
- Removed@neovici/cosmoz-viewinfo@3.2.0(transitive)