Skip to content

Commit

Permalink
Remove Experimental Tag (#302)
Browse files Browse the repository at this point in the history
* removing experimental tag

Signed-off-by: Sean Li <[email protected]>

* changing components to match mockups

Signed-off-by: Sean Li <[email protected]>

* removing unused imports

Signed-off-by: Sean Li <[email protected]>

---------

Signed-off-by: Sean Li <[email protected]>
  • Loading branch information
sejli authored Oct 5, 2023
1 parent 6fb31c8 commit 7d062c5
Show file tree
Hide file tree
Showing 3 changed files with 144 additions and 482 deletions.
292 changes: 64 additions & 228 deletions public/components/common/__test__/__snapshots__/header.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -21,240 +21,76 @@ exports[`Header component Renders header component 1`] = `
}
}
>
<EuiPageHeader
pageTitle="Compare search results"
>
<header
className="euiPageHeader euiPageHeader--responsive euiPageHeader--center"
<EuiTitle>
<h1
className="euiTitle euiTitle--medium"
>
<EuiPageHeaderContent
pageTitle="Compare search results"
responsive={true}
>
<div
className="euiPageHeaderContent"
Compare search results
</h1>
</EuiTitle>
<EuiText>
<div
className="euiText euiText--medium"
>
<p>
Compare results using the same search text with different queries.
<EuiLink
href="https://opensearch.org/docs/latest/search-plugins/search-relevance"
target="_blank"
>
<EuiFlexGroup
alignItems="flexStart"
className="euiPageHeaderContent__top"
gutterSize="l"
responsive={true}
>
<div
className="euiFlexGroup euiFlexGroup--gutterLarge euiFlexGroup--alignItemsFlexStart euiFlexGroup--directionRow euiFlexGroup--responsive euiPageHeaderContent__top"
>
<EuiFlexItem>
<div
className="euiFlexItem"
>
<EuiTitle
size="l"
>
<h1
className="euiTitle euiTitle--large"
>
Compare search results
</h1>
</EuiTitle>
</div>
</EuiFlexItem>
</div>
</EuiFlexGroup>
<div
className="euiPageHeaderContent__bottom"
<a
className="euiLink euiLink--primary"
href="https://opensearch.org/docs/latest/search-plugins/search-relevance"
rel="noopener noreferrer"
target="_blank"
>
<EuiSpacer>
<div
className="euiSpacer euiSpacer--l"
/>
</EuiSpacer>
<EuiCallOut
iconType="iInCircle"
title="Experimental Feature"
Learn more
<EuiIcon
aria-label="External link"
className="euiLink__externalIcon"
size="s"
type="popout"
>
<div
className="euiCallOut euiCallOut--primary"
<EuiIconEmpty
aria-hidden={true}
aria-label="External link"
className="euiIcon euiIcon--small euiIcon-isLoading euiLink__externalIcon"
focusable="false"
role="img"
style={null}
>
<div
className="euiCallOutHeader"
>
<EuiIcon
aria-hidden="true"
className="euiCallOutHeader__icon"
color="inherit"
size="m"
type="iInCircle"
>
<EuiIconEmpty
aria-hidden={true}
className="euiIcon euiIcon--medium euiIcon--inherit euiIcon-isLoading euiCallOutHeader__icon"
focusable="false"
role="img"
style={null}
>
<svg
aria-hidden={true}
className="euiIcon euiIcon--medium euiIcon--inherit euiIcon-isLoading euiCallOutHeader__icon"
focusable="false"
height={16}
role="img"
style={null}
viewBox="0 0 16 16"
width={16}
xmlns="http://www.w3.org/2000/svg"
/>
</EuiIconEmpty>
</EuiIcon>
<span
className="euiCallOutHeader__title"
>
Experimental Feature
</span>
</div>
<EuiText
color="default"
size="s"
<svg
aria-hidden={true}
aria-label="External link"
className="euiIcon euiIcon--small euiIcon-isLoading euiLink__externalIcon"
focusable="false"
height={16}
role="img"
style={null}
viewBox="0 0 16 16"
width={16}
xmlns="http://www.w3.org/2000/svg"
/>
</EuiIconEmpty>
</EuiIcon>
<EuiScreenReaderOnly>
<span
className="euiScreenReaderOnly"
>
<EuiI18n
default="(opens in a new tab or window)"
token="euiLink.newTarget.screenReaderOnlyText"
>
<div
className="euiText euiText--small"
>
<EuiTextColor
color="default"
component="div"
>
<div
className="euiTextColor euiTextColor--default"
>
<EuiText>
<div
className="euiText euiText--medium"
>
<p>
Compare results using the same search text with different queries. For more information, see the
<EuiLink
href="https://opensearch.org/docs/latest/search-plugins/search-relevance"
target="_blank"
>
<a
className="euiLink euiLink--primary"
href="https://opensearch.org/docs/latest/search-plugins/search-relevance"
rel="noopener noreferrer"
target="_blank"
>
Compare Search Results Documentation
<EuiIcon
aria-label="External link"
className="euiLink__externalIcon"
size="s"
type="popout"
>
<EuiIconEmpty
aria-hidden={true}
aria-label="External link"
className="euiIcon euiIcon--small euiIcon-isLoading euiLink__externalIcon"
focusable="false"
role="img"
style={null}
>
<svg
aria-hidden={true}
aria-label="External link"
className="euiIcon euiIcon--small euiIcon-isLoading euiLink__externalIcon"
focusable="false"
height={16}
role="img"
style={null}
viewBox="0 0 16 16"
width={16}
xmlns="http://www.w3.org/2000/svg"
/>
</EuiIconEmpty>
</EuiIcon>
<EuiScreenReaderOnly>
<span
className="euiScreenReaderOnly"
>
<EuiI18n
default="(opens in a new tab or window)"
token="euiLink.newTarget.screenReaderOnlyText"
>
(opens in a new tab or window)
</EuiI18n>
</span>
</EuiScreenReaderOnly>
</a>
</EuiLink>
. To leave feedback, visit
<EuiLink
href="https://forum.opensearch.org/t/feedback-experimental-feature-compare-search-results/11331"
target="_blank"
>
<a
className="euiLink euiLink--primary"
href="https://forum.opensearch.org/t/feedback-experimental-feature-compare-search-results/11331"
rel="noopener noreferrer"
target="_blank"
>
forums.opensearch.com
<EuiIcon
aria-label="External link"
className="euiLink__externalIcon"
size="s"
type="popout"
>
<EuiIconEmpty
aria-hidden={true}
aria-label="External link"
className="euiIcon euiIcon--small euiIcon-isLoading euiLink__externalIcon"
focusable="false"
role="img"
style={null}
>
<svg
aria-hidden={true}
aria-label="External link"
className="euiIcon euiIcon--small euiIcon-isLoading euiLink__externalIcon"
focusable="false"
height={16}
role="img"
style={null}
viewBox="0 0 16 16"
width={16}
xmlns="http://www.w3.org/2000/svg"
/>
</EuiIconEmpty>
</EuiIcon>
<EuiScreenReaderOnly>
<span
className="euiScreenReaderOnly"
>
<EuiI18n
default="(opens in a new tab or window)"
token="euiLink.newTarget.screenReaderOnlyText"
>
(opens in a new tab or window)
</EuiI18n>
</span>
</EuiScreenReaderOnly>
</a>
</EuiLink>
.
</p>
</div>
</EuiText>
</div>
</EuiTextColor>
</div>
</EuiText>
</div>
</EuiCallOut>
</div>
</div>
</EuiPageHeaderContent>
</header>
</EuiPageHeader>
(opens in a new tab or window)
</EuiI18n>
</span>
</EuiScreenReaderOnly>
</a>
</EuiLink>
</p>
</div>
</EuiText>
</div>
</EuiPanel>
</Header>
Expand Down
42 changes: 16 additions & 26 deletions public/components/common/header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*/

import React from 'react';
import { EuiPageHeader, EuiCallOut, EuiText, EuiLink, EuiPanel } from '@elastic/eui';
import { EuiText, EuiLink, EuiPanel, EuiTitle } from '@elastic/eui';

interface HeaderProps {
children?: React.ReactNode;
Expand All @@ -19,31 +19,21 @@ export const Header = ({ children }: HeaderProps) => {
borderRadius="none"
style={{ borderBottom: '1px solid #D3DAE6' }}
>
<EuiPageHeader pageTitle="Compare search results">
<EuiCallOut title="Experimental Feature" iconType="iInCircle">
<EuiText>
<p>
Compare results using the same search text with different queries. For more
information, see the{' '}
<EuiLink
href="https://opensearch.org/docs/latest/search-plugins/search-relevance"
target="_blank"
>
Compare Search Results Documentation
</EuiLink>
. To leave feedback, visit{' '}
<EuiLink
href="https://forum.opensearch.org/t/feedback-experimental-feature-compare-search-results/11331"
target="_blank"
>
forums.opensearch.com
</EuiLink>
.
</p>
</EuiText>
</EuiCallOut>
{children}
</EuiPageHeader>
<EuiTitle>
<h1>Compare search results</h1>
</EuiTitle>
<EuiText>
<p>
Compare results using the same search text with different queries.{' '}
<EuiLink
href="https://opensearch.org/docs/latest/search-plugins/search-relevance"
target="_blank"
>
Learn more
</EuiLink>
</p>
</EuiText>
{children}
</EuiPanel>
);
};
Loading

0 comments on commit 7d062c5

Please sign in to comment.