Skip to content

Commit 02a0b2b

Browse files
Merge pull request #955 from RedisInsight/main
new RC
2 parents 00b297a + dcce761 commit 02a0b2b

File tree

8 files changed

+31
-15
lines changed

8 files changed

+31
-15
lines changed

redisinsight/ui/src/components/consents-settings/ConsentOption/ConsentOption.tsx

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import {
66
EuiText,
77
EuiSpacer,
88
} from '@elastic/eui'
9+
import cx from 'classnames'
910
import parse from 'html-react-parser'
1011

1112
import { IConsent } from '../ConsentsSettings'
@@ -32,7 +33,12 @@ const ConsentOption = (props: Props) => {
3233
<EuiFlexItem key={consent.agreementName}>
3334
{isSettingsPage && consent.description && (
3435
<>
35-
<EuiText size="s" className={styles.smallText} color="subdued" style={{ marginTop: '12px' }}>
36+
<EuiText
37+
size="s"
38+
className={styles.smallText}
39+
color="subdued"
40+
style={{ marginTop: '12px' }}
41+
>
3642
{parse(consent.description)}
3743
</EuiText>
3844
<EuiSpacer size="m" />
@@ -51,9 +57,16 @@ const ConsentOption = (props: Props) => {
5157
/>
5258
</EuiFlexItem>
5359
<EuiFlexItem grow={false}>
54-
<EuiText className={styles.label}>{parse(consent.label)}</EuiText>
60+
<EuiText className={cx({ [styles.disabled]: consent?.disabled, [styles.smallText]: true })}>
61+
{parse(consent.label)}
62+
</EuiText>
5563
{!isSettingsPage && consent.description && (
56-
<EuiText size="s" className={styles.smallText} color="subdued" style={{ marginTop: '12px' }}>
64+
<EuiText
65+
size="s"
66+
className={styles.smallText}
67+
color="subdued"
68+
style={{ marginTop: '12px' }}
69+
>
5770
{parse(consent.description)}
5871
</EuiText>
5972
)}

redisinsight/ui/src/components/consents-settings/styles.module.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,10 @@
9696
}
9797
}
9898

99+
.smallText.disabled {
100+
color: var(--disabledLabelColor) !important;
101+
}
102+
99103
:global(.euiOverlayMask) {
100104
background: none !important;
101105
}

redisinsight/ui/src/styles/components/_switch.scss

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,7 @@
1818
}
1919
}
2020
.euiSwitch__button:disabled {
21-
opacity: 50%;
22-
23-
.euiSwitch__icon {
24-
display: none;
25-
}
21+
opacity: 0.5;
2622
}
2723
}
2824

redisinsight/ui/src/styles/themes/dark_theme/_dark_theme.lazy.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@
9696
--browserComponentActive: #{$browserComponentActive};
9797
--browserTreeNodeOpen: #{$browserTreeNodeOpen};
9898
--defaultGreenColor: #{$defaultGreenColor};
99+
--disabledLabelColor: #{$disabledLabelColor};
99100

100101
--iconsDefaultColor: #{$iconsDefaultColor};
101102
--iconsDefaultHoverColor: #{$iconsDefaultHoverColor};

redisinsight/ui/src/styles/themes/dark_theme/_theme_color.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ $iconsDefaultHoverColor: #dfe5ef;
6262
$separatorColor: #3d3d3d;
6363
$separatorNavigationColor: #465282;
6464
$separatorDropdownColor: #8b90a3;
65+
$disabledLabelColor: #898A90;
6566

6667
$buttonSecondaryHoverColor: #364da8;
6768
$buttonSecondaryTextColor: #dfe5ef;

redisinsight/ui/src/styles/themes/light_theme/_light_theme.lazy.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@
9898
--browserComponentActive: #{$browserComponentActive};
9999
--browserTreeNodeOpen: #{$browserTreeNodeOpen};
100100
--defaultGreenColor: #{$defaultGreenColor};
101+
--disabledLabelColor: #{$disabledLabelColor};
101102

102103
--iconsDefaultColor: #{$iconsDefaultColor};
103104
--iconsDefaultHoverColor: #{$iconsDefaultHoverColor};

redisinsight/ui/src/styles/themes/light_theme/_theme_color.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ $iconsDefaultHoverColor: #173369;
5959
$separatorColor: #cdd7e6;
6060
$separatorNavigationColor: #465282;
6161
$separatorDropdownColor: #8b90a3;
62+
$disabledLabelColor: #527298;
6263

6364
$buttonSecondaryHoverColor: #2848d7;
6465
$buttonSecondaryTextColor: #243dac;

tests/e2e/tests/regression/workbench/workbench-pipeline.e2e.ts

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const settingsPage = new SettingsPage();
1111

1212
const getPageUrl = ClientFunction(() => window.location.href);
1313
const externalPageLink = 'https://redis.io/docs/manual/pipelining/';
14-
const pipelineValues = ['-5', '5', '4'];
14+
const pipelineValues = ['-5', '5', '4', '20'];
1515
const commandForSend = '100 scan 0 match * count 5000';
1616

1717
fixture `Workbench Pipeline`
@@ -45,24 +45,23 @@ test('Verify that user can enter only numbers >0 in "Commands in pipeline" input
4545
await t.expect(settingsPage.commandsInPipelineInput.value).eql(pipelineValues[1], 'Value is incorrect');
4646
});
4747
test('Verify that only chosen in pipeline number of commands is loading at the same time in Workbench', async t => {
48-
await settingsPage.changeCommandsInPipeline(pipelineValues[2]);
48+
await settingsPage.changeCommandsInPipeline(pipelineValues[1]);
4949
// Go to Workbench page
5050
await t.click(myRedisDatabasePage.workbenchButton);
5151
await workbenchPage.sendCommandInWorkbench(commandForSend, 0.01);
5252
// Verify that only selected pipeline number of commands are loaded at the same time
53-
await t.expect(workbenchPage.loadedCommand.count).eql(Number(pipelineValues[2]), 'The number of sending commands is incorrect');
53+
await t.expect(workbenchPage.loadedCommand.count).eql(Number(pipelineValues[1]), 'The number of sending commands is incorrect');
5454
});
55-
test('Verify that user can see spinner over Run button and grey preloader for each command', async t => {
56-
let commandForSend = '300 scan 0 match * count 5000';
57-
await settingsPage.changeCommandsInPipeline(pipelineValues[2]);
55+
test.skip('Verify that user can see spinner over Run button and grey preloader for each command', async t => {
56+
await settingsPage.changeCommandsInPipeline(pipelineValues[3]);
5857
// Go to Workbench page
5958
await t.click(myRedisDatabasePage.workbenchButton);
6059
await workbenchPage.sendCommandInWorkbench(commandForSend, 0.01);
6160
// Verify that user can`t start new commands from the Workbench while command(s) is executing
6261
await t.expect(workbenchPage.submitCommandButton.withAttribute('disabled').exists).ok('Run button is not disabled', { timeout: 5000 });
6362
// Verify that user can see spinner over the disabled and shrunk Run button
6463
await t.expect(workbenchPage.runButtonSpinner.exists).ok('Loading spinner is not displayed for Run button', { timeout: 5000 });
65-
await t.expect(workbenchPage.queryCardContainer.find(workbenchPage.cssDeleteCommandButton).withAttribute('disabled').count).eql(4, 'The number of commands is incorrect');
64+
await t.expect(workbenchPage.queryCardContainer.find(workbenchPage.cssDeleteCommandButton).withAttribute('disabled').count).eql(Number(pipelineValues[3]), 'The number of commands is incorrect');
6665
});
6766
test('Verify that user can interact with the Editor while command(s) in progress', async t => {
6867
const valueInEditor = '100';

0 commit comments

Comments
 (0)