Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ export const PrivateSourcesSidebar = () => {
: PRIVATE_VIEW_ONLY_PAGE_DESCRIPTION;

const {
contentSource: { id = '', name = '' },
contentSource: { id = '' },
} = useValues(SourceLogic);

const navItems = [{ id, name, items: useSourceSubNav() }];
const navItems = [{ id, name: '', items: useSourceSubNav() }];

return (
<>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ export const Overview: React.FC = () => {
const [isModalVisible, setIsModalVisible] = useState(false);
const closeModal = () => setIsModalVisible(false);
const handleSyncClick = () => setIsModalVisible(true);
const showSyncTriggerCallout = !custom && isIndexedSource && isOrganization;

const onSyncConfirm = () => {
initializeSourceSynchronization(id);
Expand Down Expand Up @@ -491,7 +492,7 @@ export const Overview: React.FC = () => {
<EuiText size="s">
<FormattedMessage
id="xpack.enterpriseSearch.workplaceSearch.sources.synchronizationCallout"
defaultMessage="Configure {syncFrequencyLink} or permissions {blockTimeWindowsLink}."
defaultMessage="Configure {syncFrequencyLink} or {blockTimeWindowsLink}."
values={{
syncFrequencyLink: (
<EuiLinkTo to={getContentSourcePath(SYNC_FREQUENCY_PATH, id, isOrganization)}>
Expand Down Expand Up @@ -586,7 +587,7 @@ export const Overview: React.FC = () => {
)}
</>
)}
{isIndexedSource && isOrganization && syncTriggerCallout}
{showSyncTriggerCallout && syncTriggerCallout}
</EuiFlexGroup>
</EuiFlexItem>
</EuiFlexGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export const useSourceSubNav = () => {
if (!id) return undefined;

const isCustom = serviceType === CUSTOM_SERVICE_TYPE;
const showSynchronization = isIndexedSource && isOrganization;
const showSynchronization = isIndexedSource && isOrganization && !isCustom;

const navItems: Array<EuiSideNavItemType<unknown>> = [
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,6 @@ export const Security: React.FC = () => {
};

const headerActions = [
<EuiButtonEmpty disabled={!unsavedChanges || dataLoading} onClick={resetState}>
{RESET_BUTTON}
</EuiButtonEmpty>,
<EuiButton
disabled={!hasPlatinumLicense || !unsavedChanges || dataLoading}
onClick={showConfirmModal}
Expand All @@ -86,6 +83,9 @@ export const Security: React.FC = () => {
>
{SAVE_SETTINGS_BUTTON}
</EuiButton>,
<EuiButtonEmpty disabled={!unsavedChanges || dataLoading} onClick={resetState}>
{RESET_BUTTON}
</EuiButtonEmpty>,
];

const allSourcesToggle = (
Expand Down