Color configre cleanup

This commit is contained in:
CHIEFSOFT\ameye
2025-10-19 13:04:10 -04:00
parent a4db58ba97
commit fa9d7f69e4
@@ -29,8 +29,8 @@ const ColorStyleConfigure = memo(({name = 'Full Name', data, productData}) => {
})
const templateResponse = colorStyleCss?.data
const currentTemUID = templateResponse?.current_template_uid
const templates = templateResponse?.templates
const currentColorUID = templateResponse?.current_colorstyle_uid
const color_styles = templateResponse?.color_styles
const custom_template_name = templateResponse?.custom_template_name
// console.log('data Template', templateResponse)
@@ -105,25 +105,30 @@ const ColorStyleConfigure = memo(({name = 'Full Name', data, productData}) => {
:
<div className="row">
<>
{!templates?.length ?
{!color_styles?.length ?
<p>No data Found</p>
:
templates.map(color_style => (
color_styles.map(color_style => (
<div key={color_style.color_style_uid} className="col-xl-6 col-sm-6">
<div className="card card-statistics">
<div className="card-body">
<div className="text-center p-2" style={{backgroundColor: `#${color_style.color_code}`}}>
<div className="card-body" style={{
backgroundColor: `#${color_style.color_code}`,
opacity: '0.5',
borderRadius: '10px'
}}>
<div className="text-center p-2">
{/*<div className="mb-2">*/}
{/* <img src={getImage('file-icon/svg.png')}*/}
{/* alt={template.title}/>*/}
{/*</div>*/}
<h4 className="mb-0">{color_style.title}</h4>
{currentTemUID === color_style.color_style_uid ?
{currentColorUID === color_style.color_style_uid ?
<button className="btn btn-light"
disabled={true}>Active</button>
:
<button onClick={() => handleSubmit(color_style.color_style_uid)}
className="btn btn-primary">Select</button>
<button
onClick={() => handleSubmit(color_style.color_style_uid)}
className="btn btn-primary">Select</button>
}
</div>
</div>