/*!
 * Built by ShiftSoftware
 * Copyright (c)
 */
'use strict';

var index = require('./index-CmK48vN3.js');
var cn = require('./cn-BHnqYtun.js');

const MaterialCard = (props, children = []) => {
    var _a;
    const wrapperStyle = {
        flex: '1',
        display: 'flex',
        width: props.width,
        flexDirection: 'column',
        minWidth: props.minWidth,
        maxWidth: props.maxWidth,
    };
    const titleStyle = {
        padding: '10px 0',
        fontWeight: 'bold',
        marginBottom: '8px',
        borderBottom: '1px solid gray',
    };
    return (index.h("div", { style: wrapperStyle, class: props.class },
        index.h("strong", { style: titleStyle }, props.title),
        index.h("flexible-container", null, !children.length ? index.h(MaterialCardChildren, { hidden: '' === ((_a = props === null || props === void 0 ? void 0 : props.desc) === null || _a === void 0 ? void 0 : _a.trim()) }, props.desc || index.h("p", null, "\u00A0")) : children)));
};
const MaterialCardChildren = (props, children) => {
    const wrapperStyles = {
        width: '100%',
    };
    const contentStyles = {
        'transition-duration': '0ms !important',
        'opacity': props.hidden ? '0' : '1',
    };
    return (index.h("div", { style: wrapperStyles, class: cn.cn('shift-skeleton', props.class) },
        index.h("div", { style: contentStyles }, children)));
};

exports.MaterialCard = MaterialCard;
exports.MaterialCardChildren = MaterialCardChildren;
