mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-11 22:00:41 -07:00
19 lines
421 B
TypeScript
19 lines
421 B
TypeScript
/**
|
|
* @license
|
|
* Copyright 2025 Google LLC
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
|
|
import type { Config } from '@google/gemini-cli-core';
|
|
import { isAlternateBufferEnabled } from '../hooks/useAlternateBuffer.js';
|
|
|
|
export const calculateMainAreaWidth = (
|
|
terminalWidth: number,
|
|
config: Config,
|
|
): number => {
|
|
if (isAlternateBufferEnabled(config)) {
|
|
return terminalWidth - 1;
|
|
}
|
|
return terminalWidth;
|
|
};
|