aboutsummaryrefslogtreecommitdiffstats
path: root/gui-clamp/ui-react/src/components/menu
diff options
context:
space:
mode:
Diffstat (limited to 'gui-clamp/ui-react/src/components/menu')
-rw-r--r--gui-clamp/ui-react/src/components/menu/MenuBar.js11
-rw-r--r--gui-clamp/ui-react/src/components/menu/MenuBar.test.js7
-rw-r--r--gui-clamp/ui-react/src/components/menu/__snapshots__/MenuBar.test.js.snap80
3 files changed, 29 insertions, 69 deletions
diff --git a/gui-clamp/ui-react/src/components/menu/MenuBar.js b/gui-clamp/ui-react/src/components/menu/MenuBar.js
index 769edb0..5ac5f88 100644
--- a/gui-clamp/ui-react/src/components/menu/MenuBar.js
+++ b/gui-clamp/ui-react/src/components/menu/MenuBar.js
@@ -37,24 +37,20 @@ const StyledLink = styled(Link)`
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ${ props => props.theme.menuHighlightedBackgroundColor };
color: ${ props => props.theme.menuHighlightedFontColor };
- }
-`;
+ }`;
const StyledNavLink = styled(Nav.Link)`
color: ${ props => props.theme.menuFontColor };
background-color: ${ props => props.theme.menuBackgroundColor };
font-weight: normal;
padding: .25rem 1.5rem;
-
:hover {
background-color: ${ props => props.theme.menuHighlightedBackgroundColor };
color: ${ props => props.theme.menuHighlightedFontColor };
- }
-`;
+ }`;
const StyledNavDropdown = styled(NavDropdown)`
color: ${ props => props.theme.menuFontColor };
@@ -67,8 +63,7 @@ const StyledNavDropdown = styled(NavDropdown)`
:hover {
font-weight: bold;
}
- }
-`;
+ }`;
export default class MenuBar extends React.Component {
state = {
diff --git a/gui-clamp/ui-react/src/components/menu/MenuBar.test.js b/gui-clamp/ui-react/src/components/menu/MenuBar.test.js
index bd55687..df1a17a 100644
--- a/gui-clamp/ui-react/src/components/menu/MenuBar.test.js
+++ b/gui-clamp/ui-react/src/components/menu/MenuBar.test.js
@@ -72,7 +72,7 @@ describe('Verify MenuBar', () => {
it('Finds POLICY Framework Menu', () => {
const component = shallow(<MenuBar />).childAt(4).dive();
- expect(component.find({ tile: 'TOSCA Control Loop' }));
+ expect(component.find({ tile: 'TOSCA Automation Composition' }));
});
it('Finds POLICY Framework Menu', () => {
@@ -84,4 +84,9 @@ describe('Verify MenuBar', () => {
const component = shallow(<MenuBar />);
expect(component.find('Styled(NavLink)').length).toEqual(2);
});
+
+ it('Finds StyledNavDropdown', () => {
+ const component = shallow(<MenuBar />);
+ expect(component.find('Styled(NavDropdown)').length).toEqual(6);
+ });
});
diff --git a/gui-clamp/ui-react/src/components/menu/__snapshots__/MenuBar.test.js.snap b/gui-clamp/ui-react/src/components/menu/__snapshots__/MenuBar.test.js.snap
index 86ae72d..336628d 100644
--- a/gui-clamp/ui-react/src/components/menu/__snapshots__/MenuBar.test.js.snap
+++ b/gui-clamp/ui-react/src/components/menu/__snapshots__/MenuBar.test.js.snap
@@ -31,7 +31,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -40,8 +39,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -100,7 +98,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -109,8 +106,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -168,7 +164,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -177,8 +172,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -237,7 +231,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -246,8 +239,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -302,7 +294,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -311,8 +302,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -367,7 +357,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -376,8 +365,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -432,7 +420,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -441,8 +428,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -500,7 +486,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -509,8 +494,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -565,7 +549,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -574,8 +557,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -634,7 +616,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -643,8 +624,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -699,7 +679,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -708,8 +687,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -764,7 +742,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -773,8 +750,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -829,7 +805,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -838,8 +813,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -897,7 +871,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -906,8 +879,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -962,7 +934,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -971,8 +942,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -1036,7 +1006,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -1045,8 +1014,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -1109,7 +1077,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -1118,8 +1085,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -1174,7 +1140,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -1183,8 +1148,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -1239,7 +1203,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -1248,8 +1211,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},
@@ -1319,7 +1281,6 @@ exports[`Verify MenuBar Test the render method 1`] = `
text-align: inherit;
white-space: nowrap;
border: 0;
-
:hover {
text-decoration: none;
background-color: ",
@@ -1328,8 +1289,7 @@ exports[`Verify MenuBar Test the render method 1`] = `
color: ",
[Function],
";
- }
-",
+ }",
],
"staticRulesId": "",
},