@while-and-for/tremor-react
Version:
The React library to build dashboards faster.
2 lines (1 loc) • 3.22 kB
JavaScript
;Object.defineProperty(exports,"__esModule",{value:!0});var r=require("../../../lib/shape.cjs"),e=require("../../../lib/sizing.cjs"),o=require("../../../lib/spacing.cjs"),t=require("../../../lib/theme.cjs"),d=require("../../../lib/utils.cjs");require("../../../lib/tremorTwMerge.cjs");const a={xs:{paddingX:o.spacing.xs.paddingX,paddingY:o.spacing.xs.paddingY},sm:{paddingX:o.spacing.xs.paddingX,paddingY:o.spacing.xs.paddingY},md:{paddingX:o.spacing.sm.paddingX,paddingY:o.spacing.sm.paddingY},lg:{paddingX:o.spacing.sm.paddingX,paddingY:o.spacing.sm.paddingY},xl:{paddingX:o.spacing.md.paddingX,paddingY:o.spacing.md.paddingY}},i={xs:{height:e.sizing.sm.height,width:e.sizing.sm.width},sm:{height:e.sizing.lg.height,width:e.sizing.lg.width},md:{height:e.sizing.lg.height,width:e.sizing.lg.width},lg:{height:e.sizing.twoXl.height,width:e.sizing.twoXl.width},xl:{height:e.sizing.threeXl.height,width:e.sizing.threeXl.width}},g={simple:{rounded:"",border:"",ring:"",shadow:""},light:{rounded:"rounded-tremor-default",border:"",ring:"",shadow:""},shadow:{rounded:"rounded-tremor-default",border:r.border.sm.all,ring:"",shadow:"shadow-tremor-card dark:shadow-dark-tremor-card"},solid:{rounded:"rounded-tremor-default",border:r.border.md.all,ring:"ring-1",shadow:""},outlined:{rounded:"rounded-tremor-default",border:r.border.sm.all,ring:"ring-2",shadow:""}};exports.getIconColors=(r,e)=>{switch(r){case"simple":return{textColor:e?d.getColorClassNames(e,t.colorPalette.text).textColor:"text-tremor-brand dark:text-dark-tremor-brand",bgColor:"",borderColor:"",ringColor:""};case"light":return{textColor:e?d.getColorClassNames(e,t.colorPalette.text).textColor:"text-tremor-brand dark:text-dark-tremor-brand",bgColor:e?d.getColorClassNames(e,t.colorPalette.lightBackground).bgColor:"bg-tremor-brand-muted dark:bg-dark-tremor-brand-muted",borderColor:"",ringColor:""};case"shadow":return{textColor:e?d.getColorClassNames(e,t.colorPalette.text).textColor:"text-tremor-brand dark:text-dark-tremor-brand",bgColor:e?d.getColorClassNames(e,t.colorPalette.lightBackground).bgColor:"bg-tremor-background dark:bg-dark-tremor-background",borderColor:"border-tremor-border dark:border-dark-tremor-border",ringColor:""};case"solid":return{textColor:e?d.getColorClassNames(e,t.colorPalette.text).textColor:"text-tremor-brand-inverted dark:text-dark-tremor-brand-inverted",bgColor:e?d.getColorClassNames(e,t.colorPalette.lightBackground).bgColor:"bg-tremor-brand dark:bg-dark-tremor-brand",borderColor:"border-tremor-brand-inverted dark:border-dark-tremor-brand-inverted",ringColor:"ring-tremor-ring dark:ring-dark-tremor-ring"};case"outlined":return{textColor:e?d.getColorClassNames(e,t.colorPalette.text).textColor:"text-tremor-brand dark:text-dark-tremor-brand",bgColor:e?d.getColorClassNames(e,t.colorPalette.lightBackground).bgColor:"bg-tremor-background dark:bg-dark-tremor-background",borderColor:e?d.getColorClassNames(e,t.colorPalette.ring).borderColor:"border-tremor-brand-subtle dark:border-dark-tremor-brand-subtle",ringColor:e?d.getColorClassNames(e,t.colorPalette.lightRing).ringColor:"ring-tremor-brand-muted dark:ring-dark-tremor-brand-muted"}}},exports.iconSizes=i,exports.shape=g,exports.wrapperProportions=a;