summaryrefslogtreecommitdiff
path: root/packages/cli/src/ui/utils/itermDetection.tsx
blob: 6747305e69b830c9236ad82e1c20483f48b4d680 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/**
 * @license
 * Copyright 2025 Google LLC
 * SPDX-License-Identifier: Apache-2.0
 */

import React from 'react';
import { Box, Text } from 'ink';

export const ITermDetectionWarning: React.FC = () => {
  if (process.env.TERM_PROGRAM !== 'iTerm.app') {
    return null; // Don't render anything if not in iTerm
  }

  return (
    <Box marginTop={1}>
      <Text dimColor>Note: Flickering may occur in iTerm.</Text>
    </Box>
  );
};