(
key: LayoutKey,
testId: string,
orientation: 'vertical' | 'horizontal',
label: string,
invert = false,
)
| 4757 | |
| 4758 | /** Ein Griff, mit seinen Grenzen aus dem Modell. */ |
| 4759 | const splitter = ( |
| 4760 | key: LayoutKey, |
| 4761 | testId: string, |
| 4762 | orientation: 'vertical' | 'horizontal', |
| 4763 | label: string, |
| 4764 | invert = false, |
| 4765 | ): JSX.Element => { |
| 4766 | const bounds = layoutBounds(key, frame); |
| 4767 | return ( |
| 4768 | <Splitter |
| 4769 | testId={testId} |
| 4770 | orientation={orientation} |
| 4771 | label={label} |
| 4772 | value={key === 'rightWidth' ? Math.max(360, shownZones[key]) : shownZones[key]} |
| 4773 | min={key === 'rightWidth' ? Math.max(360, bounds.min) : bounds.min} |
| 4774 | max={key === 'rightWidth' ? Math.max(360, bounds.max) : bounds.max} |
| 4775 | invert={invert} |
| 4776 | onChange={(value) => changeZone(key, value)} |
| 4777 | onReset={() => resetZone(key)} |
| 4778 | /> |
| 4779 | ); |
| 4780 | }; |
| 4781 | |
| 4782 | const attachSelection = (selection: ReaderSelection): void => { |
| 4783 | if (selection.path !== activePath || document?.path !== activePath) return; |
no test coverage detected