export default function (publicProps) {
    let { strataSize } = publicProps
    const { derrickSize, mainSize, pipeSize, partSize, platformSize, derrickConfig } = publicProps
    function strataSizeInit () {
        return {
            width: (derrickSize.width - pipeSize.gridWidth) / 2,
            height: (mainSize.height - (partSize.topRed.height + derrickSize.height + platformSize.height)),
            firstLeft: derrickConfig.padLeft + (platformSize.width - derrickSize.width) / 2,
            secondLeft: derrickConfig.padLeft + (platformSize.caledRightRect.leftTop.x - platformSize.caledLeftRect.leftTop.x),
            top: partSize.topRed.height + derrickSize.height + platformSize.height
        }
    }
    strataSize = strataSizeInit()
    return {
        strataSize,
        strataSizeInit
    }
}
