@cbpds/web-components
Version:
Web components for the CBP Design System.
39 lines (33 loc) • 1.36 kB
JavaScript
/*!
* CPB Design System web components - built with Stencil
*/
'use strict';
Object.defineProperty(exports, '__esModule', { value: true });
const index = require('./index-cd71cbd5.js');
const utils = require('./utils-99c9e716.js');
const cbpFlexItemCss = "cbp-flex-item:not([hidden]){display:block}";
const CbpFlexItemStyle0 = cbpFlexItemCss;
const CbpFlexItem = class {
constructor(hostRef) {
index.registerInstance(this, hostRef);
this.alignSelf = undefined;
this.order = undefined;
this.flexGrow = undefined;
this.flexShrink = undefined;
this.flexBasis = undefined;
this.sx = {};
}
componentWillLoad() {
if (typeof this.sx == "string") {
this.sx = JSON.parse(this.sx) || {};
}
utils.setCSSProps(this.host, Object.assign({ 'align-self': this.alignSelf, 'order': this.order, 'flex-grow': this.flexGrow, 'flex-shrink': this.flexShrink, 'flex-basis': this.flexBasis }, this.sx));
}
render() {
return (index.h(index.Host, { key: '6626f482159918ae5b06af8aeb700e0a6cb3f403' }, index.h("slot", { key: '69fb7a18bc77181b74a4316eb528eda820700e1f' })));
}
get host() { return index.getElement(this); }
};
CbpFlexItem.style = CbpFlexItemStyle0;
exports.cbp_flex_item = CbpFlexItem;
//# sourceMappingURL=cbp-flex-item.cjs.entry.js.map