(manualOptionHeight)
| 106 | } |
| 107 | |
| 108 | getKeyAreaHeights(manualOptionHeight) { |
| 109 | const { optionHeight } = this.state; |
| 110 | const { style } = this.props; |
| 111 | |
| 112 | const gradientHeight = manualOptionHeight || optionHeight; |
| 113 | const listViewHeight = this.calculateListViewHeight(gradientHeight); |
| 114 | const screenHeight = window.height; |
| 115 | const paddedScreenHeight = style.modal.paddingVertical |
| 116 | ? screenHeight - style.modal.paddingVertical * 2 |
| 117 | : screenHeight; |
| 118 | const bufferHeight = Math.max( |
| 119 | (paddedScreenHeight - listViewHeight) / 2, |
| 120 | gradientHeight * 2, |
| 121 | ); |
| 122 | |
| 123 | return { |
| 124 | listViewHeight, |
| 125 | screenHeight, |
| 126 | gradientHeight, |
| 127 | bufferHeight, |
| 128 | }; |
| 129 | } |
| 130 | |
| 131 | renderGradient() { |
| 132 | const { style } = this.props; |
no test coverage detected