
META-INF.resources.js.components.ObjectDetails.AllowFriendlyURLContainer.tsx Maven / Gradle / Ivy
The newest version!
/**
* SPDX-FileCopyrightText: (c) 2025 Liferay, Inc. https://liferay.com
* SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
*/
import {Text} from '@clayui/core';
import {ClayCheckbox} from '@clayui/form';
import ClayIcon from '@clayui/icon';
import {ClayTooltipProvider} from '@clayui/tooltip';
import React from 'react';
import {hasLegacySeparator} from './SeparatorContainer';
import './AllowFriendlyURLContainer.scss';
interface AllowFriendlyURLContainerProps {
disabled?: boolean;
onSubmit?: (editedObjectDefinition?: Partial) => void;
setValues: (values: Partial) => void;
values: Partial;
}
export function AllowFriendlyURLContainer({
disabled,
onSubmit,
setValues,
values,
}: AllowFriendlyURLContainerProps) {
return (
<>
{
event.stopPropagation();
if (onSubmit) {
onSubmit();
}
}}
onChange={({target: {checked}}) => {
setValues({
enableFriendlyURLCustomization: checked,
});
}}
/>
{Liferay.Language.get(
"when-enabled,-users-can-override-an-entry's-friendly-url"
)}
>
);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy