Fix various typos

This commit is contained in:
Bogdan 2025-04-15 15:09:45 +03:00 committed by Mark McDowall
parent 2fa02472ee
commit fae014c8be
21 changed files with 36 additions and 47 deletions

View file

@ -222,7 +222,7 @@ function FormInputGroup<T, C extends InputType>(
<div className={containerClassName}>
<div className={className}>
<div className={styles.inputContainer}>
{/* @ts-expect-error - tpyes are validated already */}
{/* @ts-expect-error - types are validated already */}
<InputComponent
className={inputClassName}
helpText={helpText}

View file

@ -120,7 +120,7 @@ function ProviderFieldFormGroup<T>({
helpTextWarning={helpTextWarning}
helpLink={helpLink}
placeholder={placeholder}
// @ts-expect-error - this isn;'t available on all types
// @ts-expect-error - this isn't available on all types
selectOptionsProviderAction={selectOptionsProviderAction}
value={value}
values={selectValues}

View file

@ -316,7 +316,7 @@ function SeriesSearchInput() {
return;
}
// If an suggestion is not selected go to the first series,
// If a suggestion is not selected go to the first series,
// otherwise go to the selected series.
const selectedSuggestion =

View file

@ -1,11 +0,0 @@
.grid {
flex: 1 0 auto;
}
.container {
&:hover {
.content {
background-color: var(--tableRowHoverBackgroundColor);
}
}
}

View file

@ -80,17 +80,17 @@ function SeriesIndexOverviews(props: SeriesIndexOverviewsProps) {
const [size, setSize] = useState({ width: 0, height: 0 });
const posterWidth = useMemo(() => {
const maxiumPosterWidth = isSmallScreen ? 152 : 162;
const maximumPosterWidth = isSmallScreen ? 152 : 162;
if (posterSize === 'large') {
return maxiumPosterWidth;
return maximumPosterWidth;
}
if (posterSize === 'medium') {
return Math.floor(maxiumPosterWidth * 0.75);
return Math.floor(maximumPosterWidth * 0.75);
}
return Math.floor(maxiumPosterWidth * 0.5);
return Math.floor(maximumPosterWidth * 0.5);
}, [posterSize, isSmallScreen]);
const posterHeight = useMemo(() => {

View file

@ -54,7 +54,7 @@
}
.createGroupButton {
composes: buton from '~Components/Link/IconButton.css';
composes: button from '~Components/Link/IconButton.css';
display: flex;
align-items: center;

View file

@ -36,7 +36,7 @@ interface ItemProps {
preferredSize: number | null;
isInGroup?: boolean;
onCreateGroupPress?: (qualityId: number) => void;
onItemAllowedChange: (id: number, allowd: boolean) => void;
onItemAllowedChange: (id: number, allowed: boolean) => void;
}
interface GroupProps {
@ -45,8 +45,8 @@ interface GroupProps {
items: QualityProfileQualityItem[];
qualityIndex: string;
onDeleteGroupPress: (groupId: number) => void;
onItemAllowedChange: (id: number, allowd: boolean) => void;
onGroupAllowedChange: (id: number, allowd: boolean) => void;
onItemAllowedChange: (id: number, allowed: boolean) => void;
onGroupAllowedChange: (id: number, allowed: boolean) => void;
onItemGroupNameChange: (groupId: number, name: string) => void;
}
@ -67,9 +67,9 @@ export type QualityProfileItemDragSourceProps = CommonProps &
export interface QualityProfileItemDragSourceActionProps {
onCreateGroupPress?: (qualityId: number) => void;
onItemAllowedChange: (id: number, allowd: boolean) => void;
onItemAllowedChange: (id: number, allowed: boolean) => void;
onDeleteGroupPress: (groupId: number) => void;
onGroupAllowedChange: (id: number, allowd: boolean) => void;
onGroupAllowedChange: (id: number, allowed: boolean) => void;
onItemGroupNameChange: (groupId: number, name: string) => void;
onDragMove: (move: DragMoveState) => void;
onDragEnd: (didDrop: boolean) => void;

View file

@ -79,7 +79,7 @@
}
.deleteGroupButton {
composes: buton from '~Components/Link/IconButton.css';
composes: button from '~Components/Link/IconButton.css';
display: flex;
align-items: center;

View file

@ -243,7 +243,7 @@ export default function QualityProfileItemSize({
max={preferredSize ? preferredSize - 5 : MAX - 5}
step={0.1}
isFloat={true}
// @ts-expect-error - Typngs are too loose
// @ts-expect-error - Typings are too loose
onChange={handleMinSizeChange}
/>
<Label kind={kinds.INFO}>
@ -261,7 +261,7 @@ export default function QualityProfileItemSize({
max={maxSize ? maxSize - 5 : MAX - 5}
step={0.1}
isFloat={true}
// @ts-expect-error - Typngs are too loose
// @ts-expect-error - Typings are too loose
onChange={handlePreferredSizeChange}
/>
@ -280,7 +280,7 @@ export default function QualityProfileItemSize({
max={MAX}
step={0.1}
isFloat={true}
// @ts-expect-error - Typngs are too loose
// @ts-expect-error - Typings are too loose
onChange={handleMaxSizeChange}
/>

View file

@ -377,7 +377,7 @@ export const reducers = createHandleActions({
const items = newState.items;
const index = items.findIndex((item) => item.guid === guid);
// Don't try to update if there isnt a matching item (the user closed the modal)
// Don't try to update if there isn't a matching item (the user closed the modal)
if (index >= 0) {
const item = Object.assign({}, items[index], payload);

View file

@ -2,8 +2,8 @@ import { createSelector } from 'reselect';
import { isCommandExecuting } from 'Utilities/Command';
import createCommandSelector from './createCommandSelector';
function createCommandExecutingSelector(name: string, contraints = {}) {
return createSelector(createCommandSelector(name, contraints), (command) => {
function createCommandExecutingSelector(name: string, constraints = {}) {
return createSelector(createCommandSelector(name, constraints), (command) => {
return command ? isCommandExecuting(command) : false;
});
}

View file

@ -2,9 +2,9 @@ import { createSelector } from 'reselect';
import { findCommand } from 'Utilities/Command';
import createCommandsSelector from './createCommandsSelector';
function createCommandSelector(name: string, contraints = {}) {
function createCommandSelector(name: string, constraints = {}) {
return createSelector(createCommandsSelector(), (commands) => {
return findCommand(commands, { name, ...contraints });
return findCommand(commands, { name, ...constraints });
});
}

View file

@ -8,7 +8,7 @@ window.console.debug = window.console.debug || function() {};
window.console.warn = window.console.warn || function() {};
window.console.assert = window.console.assert || function() {};
// TODO: Remove in v5, well suppoprted in browsers
// TODO: Remove in v5, well supported in browsers
if (!String.prototype.startsWith) {
Object.defineProperty(String.prototype, 'startsWith', {
enumerable: false,
@ -21,7 +21,7 @@ if (!String.prototype.startsWith) {
});
}
// TODO: Remove in v5, well suppoprted in browsers
// TODO: Remove in v5, well supported in browsers
if (!String.prototype.endsWith) {
Object.defineProperty(String.prototype, 'endsWith', {
enumerable: false,

View file

@ -15,7 +15,7 @@ static BuildInfo()
var attributes = assembly.GetCustomAttributes(true);
Branch = "unknow";
Branch = "unknown";
var config = attributes.OfType<AssemblyConfigurationAttribute>().FirstOrDefault();
if (config != null)

View file

@ -12,7 +12,7 @@ protected override void MainDbUpgrade()
{
Create.Column("RelativePath").OnTable("EpisodeFiles").AsString().Nullable();
// TODO: Add unique contraint for series ID and Relative Path
// TODO: Add unique constraint for series ID and Relative Path
// TODO: Warn if multiple series share the same path
Execute.WithConnection(UpdateRelativePaths);

View file

@ -74,7 +74,7 @@ public void ConvertToLocalUrls(int seriesId, IEnumerable<MediaCover> covers)
{
if (seriesId == 0)
{
// Series isn't in Sonarr yet, map via a proxy to circument referrer issues
// Series isn't in Sonarr yet, map via a proxy to circumvent referrer issues
foreach (var mediaCover in covers)
{
mediaCover.Url = _mediaCoverProxy.RegisterUrl(mediaCover.RemoteUrl);

View file

@ -7,7 +7,7 @@ namespace NzbDrone.Core.Notifications.Mailgun
{
public interface IMailgunProxy
{
void SendNotification(string tittle, string message, MailgunSettings settings);
void SendNotification(string title, string message, MailgunSettings settings);
}
public class MailgunProxy : IMailgunProxy

View file

@ -332,7 +332,7 @@ public static string TitleYear(string title, int year)
return title;
}
// Regex match incase the year in the title doesn't match the year, for whatever reason.
// Regex match in case the year in the title doesn't match the year, for whatever reason.
if (YearRegex.IsMatch(title))
{
return title;
@ -349,7 +349,7 @@ public static string CleanTitleTheYear(string title, int year)
return CleanTitleThe(title);
}
// Regex match incase the year in the title doesn't match the year, for whatever reason.
// Regex match in case the year in the title doesn't match the year, for whatever reason.
if (YearRegex.IsMatch(title))
{
var splitReturn = YearRegex.Split(title);

View file

@ -21,7 +21,7 @@ public interface IQualityProfileService
QualityProfile Get(int id);
bool Exists(int id);
QualityProfile GetDefaultProfile(string name, Quality cutoff = null, params Quality[] allowed);
void UpdateALlSizeLimits(params QualityProfileSizeLimit[] sizeLimits);
void UpdateAllSizeLimits(params QualityProfileSizeLimit[] sizeLimits);
}
public class QualityProfileService : IQualityProfileService,
@ -255,7 +255,7 @@ public QualityProfile GetDefaultProfile(string name, Quality cutoff = null, para
return qualityProfile;
}
public void UpdateALlSizeLimits(params QualityProfileSizeLimit[] sizeLimits)
public void UpdateAllSizeLimits(params QualityProfileSizeLimit[] sizeLimits)
{
var all = All();

View file

@ -91,11 +91,11 @@ public void should_not_stop_nzbdrone_service_if_service_isnt_installed()
[Test]
public void should_kill_nzbdrone_process_if_running()
{
var proccesses = Builder<ProcessInfo>.CreateListOfSize(2).Build().ToList();
var processes = Builder<ProcessInfo>.CreateListOfSize(2).Build().ToList();
Mocker.GetMock<IProcessProvider>()
.Setup(c => c.GetProcessByName(ProcessProvider.NzbDroneProcessName))
.Returns(proccesses);
.Returns(processes);
Mocker.Resolve<InstallUpdateService>().Start(TARGET_FOLDER);

View file

@ -41,7 +41,7 @@ public ActionResult<QualityDefinitionResource> Update([FromBody] QualityDefiniti
if (model.MinSize.HasValue || model.MaxSize.HasValue || model.PreferredSize.HasValue)
{
_qualityProfileService.UpdateALlSizeLimits(new QualityProfileSizeLimit(model));
_qualityProfileService.UpdateAllSizeLimits(new QualityProfileSizeLimit(model));
}
return Accepted(model.Id);
@ -73,7 +73,7 @@ public object UpdateMany([FromBody] List<QualityDefinitionResource> resource)
if (toUpdate.Any())
{
_qualityProfileService.UpdateALlSizeLimits(toUpdate);
_qualityProfileService.UpdateAllSizeLimits(toUpdate);
}
return Accepted(_qualityDefinitionService.All()