All Downloads are FREE. Search and download functionalities are using the official Maven repository.

components.form.task.standard.StepCard.js Maven / Gradle / Ivy

There is a newer version: 0.80.3
Show newest version
import { Divider, Box } from '@mui/material';
import { RenderValue } from 'components/render';
import { partitionType } from 'utils/type-utils';
import { useFormInfo } from 'hooks/form';
import Elevate from 'components/common/Elevate';
import { useLocalState } from 'hooks/state';
import StepCardContent from 'components/form/task/standard/StepCardContent';
import StepCardHeader from 'components/form/task/standard/StepCardHeader';

const StepHeader = ({partition}) => {
  if (!partition.header)
    return null

  return (
    <>
      
      { partition.fields.length ?  : null }
    
  )
}

const StepFields = ({partition, ...props}) => {
  const showFields = partition.fields.length || partition.submit
  if (!showFields)
    return null

  return 
}

const StepBasedOn = ({partition}) => {
  const formInfo = useFormInfo()
  const basedOn  = formInfo.form.values?.__basedOn
  if (!partition.basedOn || basedOn === null || basedOn === undefined)
    return null

  return (
    <>
      
        
          {basedOn} 
        
      
    
  )
}

const StepCard = ({partition, ...props}) =>{
  const unlimited         = partition.type == "free"
  const [width, setWidth] = useLocalState("TASK.WIDTH", "1000px") 

  return (
    
       theme.palette.grey[200]
        }}
      >
        { unlimited 
          ?  
              
             
          : null
        }
        
        
        
      
    

  )
 //   
 //     
 //     
 //     
 //     
 //   
 // )
} 

StepCard.propTypes = {
  partition: partitionType
}

export default StepCard




© 2015 - 2024 Weber Informatics LLC | Privacy Policy