updated tooltip popovers

This commit is contained in:
Jennifer Player
2024-02-19 12:50:11 -05:00
parent f36b5990ed
commit f0d4c71960
23 changed files with 224 additions and 65 deletions

View File

@ -1,6 +1,7 @@
import type { ComboboxOnChange, ComboboxOption } from '@invoke-ai/ui-library';
import { Combobox, FormControl, FormLabel } from '@invoke-ai/ui-library';
import { useAppDispatch, useAppSelector } from 'app/store/storeHooks';
import { InformationalPopover } from 'common/components/InformationalPopover/InformationalPopover';
import { setHrfMethod } from 'features/hrf/store/hrfSlice';
import { isParameterHRFMethod } from 'features/parameters/types/parameterSchemas';
import { memo, useCallback, useMemo } from 'react';
@ -30,7 +31,9 @@ const ParamHrfMethodSelect = () => {
return (
<FormControl>
<FormLabel>{t('hrf.upscaleMethod')}</FormLabel>
<InformationalPopover feature="paramUpscaleMethod">
<FormLabel>{t('hrf.upscaleMethod')}</FormLabel>
</InformationalPopover>
<Combobox value={value} options={options} onChange={onChange} />
</FormControl>
);

View File

@ -1,5 +1,6 @@
import { CompositeNumberInput, CompositeSlider, FormControl, FormLabel } from '@invoke-ai/ui-library';
import { useAppDispatch, useAppSelector } from 'app/store/storeHooks';
import { InformationalPopover } from 'common/components/InformationalPopover/InformationalPopover';
import { setHrfStrength } from 'features/hrf/store/hrfSlice';
import { memo, useCallback } from 'react';
import { useTranslation } from 'react-i18next';
@ -25,7 +26,9 @@ const ParamHrfStrength = () => {
return (
<FormControl>
<FormLabel>{t('parameters.denoisingStrength')}</FormLabel>
<InformationalPopover feature="paramDenoisingStrength">
<FormLabel>{`${t('parameters.denoisingStrength')}`}</FormLabel>
</InformationalPopover>
<CompositeSlider
min={sliderMin}
max={sliderMax}

View File

@ -1,5 +1,6 @@
import { FormControl, FormLabel, Switch } from '@invoke-ai/ui-library';
import { useAppDispatch, useAppSelector } from 'app/store/storeHooks';
import { InformationalPopover } from 'common/components/InformationalPopover/InformationalPopover';
import { setHrfEnabled } from 'features/hrf/store/hrfSlice';
import type { ChangeEvent } from 'react';
import { memo, useCallback } from 'react';
@ -18,7 +19,9 @@ const ParamHrfToggle = () => {
return (
<FormControl w="full">
<FormLabel flexGrow={1}>{t('hrf.enableHrf')}</FormLabel>
<InformationalPopover feature="paramHrf">
<FormLabel flexGrow={1}>{t('hrf.enableHrf')}</FormLabel>
</InformationalPopover>
<Switch isChecked={hrfEnabled} onChange={handleHrfEnabled} />
</FormControl>
);