Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
import { isLedgerCapable } from '@polkadot/react-api';
import { Button, Dropdown } from '@polkadot/react-components';
import uiSettings, { SettingsStruct } from '@polkadot/ui-settings';
import translate from './translate';
import { createIdenticon, createOption, save, saveAndReload } from './util';
import SelectUrl from './SelectUrl';
interface Props extends I18nProps{
isModalContent?: boolean;
onClose?: () => void;
}
const prefixOptions = uiSettings.availablePrefixes.map((o): Option => createOption(o, ['default']));
const iconOptions = uiSettings.availableIcons.map((o): Option => createIdenticon(o, ['default']));
const ledgerConnOptions = uiSettings.availableLedgerConn;
const availableLanguages: SetOption[] = [
{
text: 'Default browser language (auto-detect)',
value: 'default'
},
{
text: 'English',
value: 'en'
},
{
text: '日本語',
value: 'ja'
}
];
function General ({ className, isModalContent, onClose, t }: Props): React.ReactElement {