mirror of
https://github.com/sct/overseerr.git
synced 2025-12-29 00:56:55 +01:00
build(deps): bump dependencies (#2454)
* build(deps): bump react-select from 4.3.1 to 5.2.2 * build(deps): bump axios from 0.21.4 to 0.25.0 * build(deps-dev): bump lint-staged from 12.2.1 to 12.2.2 Bumps [lint-staged](https://github.com/okonet/lint-staged) from 12.2.1 to 12.2.2. - [Release notes](https://github.com/okonet/lint-staged/releases) - [Commits](https://github.com/okonet/lint-staged/compare/v12.2.1...v12.2.2) --- updated-dependencies: - dependency-name: lint-staged dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * build(deps-dev): bump typescript from 4.5.4 to 4.5.5 Bumps [typescript](https://github.com/Microsoft/TypeScript) from 4.5.4 to 4.5.5. - [Release notes](https://github.com/Microsoft/TypeScript/releases) - [Commits](https://github.com/Microsoft/TypeScript/commits) --- updated-dependencies: - dependency-name: typescript dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * build(deps-dev): bump eslint-plugin-formatjs from 2.20.3 to 2.20.4 Bumps [eslint-plugin-formatjs](https://github.com/formatjs/formatjs) from 2.20.3 to 2.20.4. - [Release notes](https://github.com/formatjs/formatjs/releases) - [Commits](https://github.com/formatjs/formatjs/compare/eslint-plugin-formatjs@2.20.3...eslint-plugin-formatjs@2.20.4) --- updated-dependencies: - dependency-name: eslint-plugin-formatjs dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * build(deps-dev): bump @commitlint/cli from 16.0.3 to 16.1.0 Bumps [@commitlint/cli](https://github.com/conventional-changelog/commitlint/tree/HEAD/@commitlint/cli) from 16.0.3 to 16.1.0. - [Release notes](https://github.com/conventional-changelog/commitlint/releases) - [Changelog](https://github.com/conventional-changelog/commitlint/blob/master/@commitlint/cli/CHANGELOG.md) - [Commits](https://github.com/conventional-changelog/commitlint/commits/v16.1.0/@commitlint/cli) --- updated-dependencies: - dependency-name: "@commitlint/cli" dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * build(deps): bump @tanem/react-nprogress from 4.0.3 to 4.0.4 Bumps [@tanem/react-nprogress](https://github.com/tanem/react-nprogress) from 4.0.3 to 4.0.4. - [Release notes](https://github.com/tanem/react-nprogress/releases) - [Changelog](https://github.com/tanem/react-nprogress/blob/master/CHANGELOG.md) - [Commits](https://github.com/tanem/react-nprogress/compare/v4.0.3...v4.0.4) --- updated-dependencies: - dependency-name: "@tanem/react-nprogress" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * fix: cleanup comments * build(deps-dev): bump lint-staged from 12.2.1 to 12.3.1 Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Ryan Cohen <ryan@sct.dev>
This commit is contained in:
committed by
GitHub
parent
d7779408d1
commit
5b2a8f682b
@@ -3,10 +3,9 @@ import { Listbox, Transition } from '@headlessui/react';
|
||||
import { AdjustmentsIcon } from '@heroicons/react/outline';
|
||||
import { CheckIcon, ChevronDownIcon } from '@heroicons/react/solid';
|
||||
import { isEqual } from 'lodash';
|
||||
import dynamic from 'next/dynamic';
|
||||
import React, { useEffect, useState } from 'react';
|
||||
import { defineMessages, useIntl } from 'react-intl';
|
||||
import type { OptionsType, OptionTypeBase } from 'react-select';
|
||||
import Select from 'react-select';
|
||||
import useSWR from 'swr';
|
||||
import type {
|
||||
ServiceCommonServer,
|
||||
@@ -19,12 +18,10 @@ import { formatBytes } from '../../../utils/numberHelpers';
|
||||
import { SmallLoadingSpinner } from '../../Common/LoadingSpinner';
|
||||
|
||||
type OptionType = {
|
||||
value: string;
|
||||
value: number;
|
||||
label: string;
|
||||
};
|
||||
|
||||
const Select = dynamic(() => import('react-select'), { ssr: false });
|
||||
|
||||
const messages = defineMessages({
|
||||
advancedoptions: 'Advanced',
|
||||
destinationserver: 'Destination Server',
|
||||
@@ -474,7 +471,7 @@ const AdvancedRequester: React.FC<AdvancedRequesterProps> = ({
|
||||
(isValidating || !serverData || !!serverData?.tags?.length) && (
|
||||
<div className="mb-2">
|
||||
<label htmlFor="tags">{intl.formatMessage(messages.tags)}</label>
|
||||
<Select
|
||||
<Select<OptionType, true>
|
||||
name="tags"
|
||||
options={(serverData?.tags ?? []).map((tag) => ({
|
||||
label: tag.label,
|
||||
@@ -489,22 +486,26 @@ const AdvancedRequester: React.FC<AdvancedRequesterProps> = ({
|
||||
}
|
||||
className="react-select-container react-select-container-dark"
|
||||
classNamePrefix="react-select"
|
||||
value={selectedTags.map((tagId) => {
|
||||
const foundTag = serverData?.tags.find(
|
||||
(tag) => tag.id === tagId
|
||||
);
|
||||
return {
|
||||
value: foundTag?.id,
|
||||
label: foundTag?.label,
|
||||
};
|
||||
})}
|
||||
onChange={(
|
||||
value: OptionTypeBase | OptionsType<OptionType> | null
|
||||
) => {
|
||||
if (!Array.isArray(value)) {
|
||||
return;
|
||||
}
|
||||
setSelectedTags(value?.map((option) => option.value));
|
||||
value={
|
||||
selectedTags
|
||||
.map((tagId) => {
|
||||
const foundTag = serverData?.tags.find(
|
||||
(tag) => tag.id === tagId
|
||||
);
|
||||
|
||||
if (!foundTag) {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
return {
|
||||
value: foundTag.id,
|
||||
label: foundTag.label,
|
||||
};
|
||||
})
|
||||
.filter((option) => option !== undefined) as OptionType[]
|
||||
}
|
||||
onChange={(value) => {
|
||||
setSelectedTags(value.map((option) => option.value));
|
||||
}}
|
||||
noOptionsMessage={() =>
|
||||
intl.formatMessage(messages.notagoptions)
|
||||
|
||||
Reference in New Issue
Block a user