This commit is contained in:
Anthony Stirling 2025-09-25 22:13:46 +01:00
parent 3c26e68436
commit 75452e373b
4 changed files with 8 additions and 8 deletions

View File

@ -642,18 +642,18 @@ export function useFlatToolRegistry(): ToolRegistry {
subcategoryId: SubcategoryId.ADVANCED_FORMATTING, subcategoryId: SubcategoryId.ADVANCED_FORMATTING,
synonyms: getSynonyms(t, "overlayPdfs"), synonyms: getSynonyms(t, "overlayPdfs"),
}, },
replaceColorPdf: { replaceColor: {
icon: <LocalIcon icon="format-color-fill-rounded" width="1.5rem" height="1.5rem" />, icon: <LocalIcon icon="format-color-fill-rounded" width="1.5rem" height="1.5rem" />,
name: t("home.replaceColorPdf.title", "Replace & Invert Color"), name: t("home.replaceColor.title", "Replace & Invert Color"),
component: ReplaceColor, component: ReplaceColor,
description: t("home.replaceColorPdf.desc", "Replace or invert colors in PDF documents"), description: t("home.replaceColor.desc", "Replace or invert colors in PDF documents"),
categoryId: ToolCategoryId.ADVANCED_TOOLS, categoryId: ToolCategoryId.ADVANCED_TOOLS,
subcategoryId: SubcategoryId.ADVANCED_FORMATTING, subcategoryId: SubcategoryId.ADVANCED_FORMATTING,
maxFiles: -1, maxFiles: -1,
endpoints: ["replace-invert-pdf"], endpoints: ["replace-invert-pdf"],
operationConfig: replaceColorOperationConfig, operationConfig: replaceColorOperationConfig,
settingsComponent: ReplaceColorSettings, settingsComponent: ReplaceColorSettings,
synonyms: getSynonyms(t, "replaceColorPdf"), synonyms: getSynonyms(t, "replaceColor"),
}, },
addImage: { addImage: {
icon: <LocalIcon icon="image-rounded" width="1.5rem" height="1.5rem" />, icon: <LocalIcon icon="image-rounded" width="1.5rem" height="1.5rem" />,

View File

@ -21,7 +21,7 @@ export const useReplaceColorParameters = (): ReplaceColorParametersHook => {
return useBaseParameters({ return useBaseParameters({
defaultParameters, defaultParameters,
endpointName: 'replace-invert-pdf', endpointName: 'replace-invert-pdf',
validateFn: (params) => { validateFn: () => {
// All parameters are always valid as they have defaults // All parameters are always valid as they have defaults
return true; return true;
}, },

View File

@ -49,7 +49,7 @@ export const TOOL_IDS = [
'validateSignature', 'validateSignature',
'read', 'read',
'automate', 'automate',
'replaceColorPdf', 'replaceColor',
'showJS', 'showJS',
'devApi', 'devApi',
'devFolderScanning', 'devFolderScanning',

View File

@ -76,7 +76,7 @@ export const URL_TO_TOOL_MAP: Record<string, ToolId> = {
'/extract-images': 'extractImages', '/extract-images': 'extractImages',
'/adjust-contrast': 'adjustContrast', '/adjust-contrast': 'adjustContrast',
'/fake-scan': 'fakeScan', '/fake-scan': 'fakeScan',
'/replace-color-pdf': 'replaceColorPdf', '/replace-color-pdf': 'replaceColor',
// Metadata and info // Metadata and info
'/change-metadata': 'changeMetadata', '/change-metadata': 'changeMetadata',
@ -116,7 +116,7 @@ export const URL_TO_TOOL_MAP: Record<string, ToolId> = {
'/view-pdf': 'read', '/view-pdf': 'read',
'/get-info-on-pdf': 'getPdfInfo', '/get-info-on-pdf': 'getPdfInfo',
'/remove-image-pdf': 'removeImage', '/remove-image-pdf': 'removeImage',
'/replace-and-invert-color-pdf': 'replaceColorPdf', '/replace-and-invert-color-pdf': 'replaceColor',
'/pipeline': 'automate', '/pipeline': 'automate',
'/extract-image-scans': 'scannerImageSplit', '/extract-image-scans': 'scannerImageSplit',
'/show-javascript': 'showJS', '/show-javascript': 'showJS',