Skip to content

Commit 1e6a0b9

Browse files
authored
Merge pull request #1162 from RedisInsight/fe/feature/RI-3329_survey-link
#RI-3329 - add survey link
2 parents 7fdc939 + 9024939 commit 1e6a0b9

File tree

15 files changed

+126
-17
lines changed

15 files changed

+126
-17
lines changed
Lines changed: 9 additions & 0 deletions
Loading

redisinsight/ui/src/components/bottom-group-components/components/bottom-group-minimized/BottomGroupMinimized.tsx

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import cx from 'classnames'
33
import { EuiBadge, EuiFlexGroup, EuiFlexItem, EuiIcon } from '@elastic/eui'
44
import { useDispatch, useSelector } from 'react-redux'
55
import { useParams } from 'react-router-dom'
6+
import { EXTERNAL_LINKS } from 'uiSrc/constants/links'
67

78
import {
89
clearSearchingCommand,
@@ -14,6 +15,7 @@ import {
1415
} from 'uiSrc/slices/cli/cli-settings'
1516
import { sendEventTelemetry, TelemetryEvent } from 'uiSrc/telemetry'
1617
import { monitorSelector, toggleHideMonitor, toggleMonitor } from 'uiSrc/slices/cli/monitor'
18+
import SurveyIcon from 'uiSrc/assets/img/survey_icon.svg'
1719

1820
import styles from '../../styles.module.scss'
1921

@@ -67,6 +69,12 @@ const BottomGroupMinimized = () => {
6769
dispatch(toggleMonitor())
6870
}
6971

72+
const onClickSurvey = () => {
73+
sendEventTelemetry({
74+
event: TelemetryEvent.USER_SURVEY_LINK_CLICKED
75+
})
76+
}
77+
7078
return (
7179
<div className={styles.containerMinimized}>
7280
<EuiFlexGroup
@@ -117,6 +125,19 @@ const BottomGroupMinimized = () => {
117125
</EuiBadge>
118126
</EuiFlexItem>
119127
</EuiFlexGroup>
128+
<a
129+
className={styles.surveyLink}
130+
target="_blank"
131+
rel="noreferrer"
132+
href={EXTERNAL_LINKS.userSurvey}
133+
onClick={onClickSurvey}
134+
data-testid="user-survey-link"
135+
>
136+
<>
137+
<EuiIcon type={SurveyIcon} className={styles.surveyIcon} />
138+
<span>We need your opinion. Please take our survey.</span>
139+
</>
140+
</a>
120141
</div>
121142
)
122143
}

redisinsight/ui/src/components/bottom-group-components/styles.module.scss

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,31 @@
1111
}
1212

1313
.containerMinimized {
14+
display: flex;
15+
align-items: center;
1416
height: 26px;
1517
line-height: 26px;
1618
border: 1px solid var(--euiColorLightShade);
19+
20+
.surveyLink {
21+
display: flex;
22+
align-items: center;
23+
height: 100%;
24+
padding: 0 12px;
25+
color: var(--htmlColor) !important;
26+
font: normal normal normal 12px/18px Graphik, sans-serif;
27+
28+
&:hover {
29+
background-color: var(--euiColorSecondary);
30+
color: var(--euiColorPrimaryText) !important;
31+
}
32+
}
33+
34+
.surveyIcon {
35+
margin-right: 8px;
36+
width: 18px;
37+
height: 18px;
38+
}
1739
}
1840

1941
.componentBadgeItem {

redisinsight/ui/src/components/navigation-menu/components/notifications-center/styles.module.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@
167167
display: block;
168168
margin-right: 30px;
169169
margin-bottom: 12px;
170-
font: normal normal 500 18px/24px Graphik;
170+
font: normal normal 500 18px/24px Graphik, sans-serif;
171171
}
172172

173173
.notificationDate {

redisinsight/ui/src/constants/links.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@ export const EXTERNAL_LINKS = {
22
githubRepo: 'https://github.com/RedisInsight/RedisInsight',
33
githubIssues: 'https://github.com/RedisInsight/RedisInsight/issues',
44
releaseNotes: 'https://github.com/RedisInsight/RedisInsight/releases',
5+
userSurvey: 'https://www.surveymonkey.com/r/redisinsight',
56
}

redisinsight/ui/src/pages/slowLog/components/Actions/styles.module.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
}
4040

4141
.popoverTitle {
42-
font: normal normal 500 13px/22px Graphik;
42+
font: normal normal 500 13px/22px Graphik, sans-serif;
4343
color: var(--euiColorFullShade) !important;
4444
}
4545

redisinsight/ui/src/pages/slowLog/components/styles.module.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
padding: 18px;
5050

5151
.noFoundTitle {
52-
font: normal normal 500 18px/24px Graphik;
52+
font: normal normal 500 18px/24px Graphik, sans-serif;
5353
margin-bottom: 12px;
5454
}
5555

redisinsight/ui/src/pages/workbench/components/enablement-area/EnablementArea/components/Group/styles.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
border-bottom: 1px solid transparent;
55
transition: border-color 0.2s ease-in-out;
66
.group-header {
7-
font: normal normal medium 11px/15px Graphik;
7+
font: normal normal medium 11px/15px Graphik, sans-serif;
88
letter-spacing: -0.12px;
99
overflow: hidden;
1010
white-space: nowrap;

redisinsight/ui/src/pages/workbench/components/enablement-area/EnablementArea/components/InternalPage/styles/_typography.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
h1, h2, h3, h4, h5, h6 {
55
color: var(--euiColorGhost);
6-
font: normal normal 500 14px/24px Graphik;
6+
font: normal normal 500 14px/24px Graphik, sans-serif;
77
margin-bottom: ($margin-size-pace * 3 + px);
88
margin-top: ($margin-size-pace * 3 + px);
99
letter-spacing: 0;

redisinsight/ui/src/telemetry/events.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,4 +181,6 @@ export enum TelemetryEvent {
181181
BULK_ACTIONS_OPENED = 'BULK_ACTIONS_OPENED',
182182
BULK_ACTIONS_WARNING = 'BULK_ACTIONS_WARNING',
183183
BULK_ACTIONS_CANCELLED = 'BULK_ACTIONS_CANCELLED',
184+
185+
USER_SURVEY_LINK_CLICKED = 'USER_SURVEY_LINK_CLICKED'
184186
}

0 commit comments

Comments
 (0)