Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Backport 4.4-1.2-wzd] Modify agent overview page #4571

Merged
merged 1 commit into from
Sep 22, 2022
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ All notable changes to the Wazuh app project will be documented in this file.
- Fixed nested fields filtering in dashboards tables and KPIs [#4425](https://github.com/wazuh/wazuh-kibana-app/pull/4425)
- Fixed nested field rendering in security alerts table details [#4428](https://github.com/wazuh/wazuh-kibana-app/pull/4428)
- Fixed a bug where the Wazuh logo was used instead of the custom one [#4539](https://github.com/wazuh/wazuh-kibana-app/pull/4539)
- Fixed rendering problems of the `Agent Overview` section in low resolutions [#4516](https://github.com/wazuh/wazuh-kibana-app/pull/4516)

## Wazuh v4.3.8 - OpenSearch Dashboards 1.2.0 - Revision 4309

Expand Down
33 changes: 25 additions & 8 deletions public/components/common/modules/module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,13 @@
padding-top: 105px;
}

.wz-module.wz-module-welcome .wz-module-body{
padding-top: 109px !important;
.wz-module.wz-module-welcome{
.wz-module-agent-body{
padding-top: 50px !important;
}
.wz-module-body{
padding-top: 109px !important;
}
}

.wz-module.wz-module-showing-agent .wz-module-body{
Expand Down Expand Up @@ -111,19 +116,23 @@ discover-app-w .sidebar-container {
padding-top: 189px !important;
}
@media only screen and (max-width: 767px){
.wz-module-header-agent h1{
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
.wz-module.wz-module-welcome .wz-module-agent-body{
padding-top: 0px !important;
}
.wz-module-header-agent{
height: auto;
h1{
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
}
}

.wz-module-body {
margin-top: -160px;
}

.wz-module-header-agent-wrapper, .wz-module-header-nav-wrapper{
position: relative;
padding-left: 0px;
}

.wz-module-header-nav-wrapper{
Expand All @@ -137,5 +146,13 @@ discover-app-w .sidebar-container {
.wz-module-body-agent-info > .euiFlexGroup > .euiFlexItem {
max-width: unset!important;
}

.wz-module-header-agent-title .euiFlexItem{
align-items: flex-start!important;
}
.wz-agent-empty-item .euiFlexItem{
margin-top: 0px!important;
margin-bottom:0px!important;
}
}
}
41 changes: 24 additions & 17 deletions public/components/common/welcome/agents-welcome.js
Original file line number Diff line number Diff line change
Expand Up @@ -267,9 +267,17 @@ class AgentsWelcome extends Component {
<span style={{ display: 'inline-flex' }}>
<EuiTitle size="s">
<h1>
<WzTextWithTooltipIfTruncated position='top' elementStyle={{ maxWidth: "150px" }}>
{this.state.widthWindow >= 768?(
<WzTextWithTooltipIfTruncated position='top' elementStyle={{ maxWidth: "150px" }}>
{this.props.agent.name}
</WzTextWithTooltipIfTruncated>
</WzTextWithTooltipIfTruncated>
):
(
<WzTextWithTooltipIfTruncated position='top'>
{this.props.agent.name}
</WzTextWithTooltipIfTruncated>
)
}
</h1>
</EuiTitle>
</span>
Expand Down Expand Up @@ -308,7 +316,9 @@ class AgentsWelcome extends Component {
</EuiPopover>
</EuiFlexItem>
}
<div className="wz-agent-empty-item">
<EuiFlexItem></EuiFlexItem>
</div>
<EuiFlexItem grow={false} style={{ marginTop: 7 }}>
<EuiButtonEmpty
iconType="inspect"
Expand Down Expand Up @@ -536,28 +546,25 @@ class AgentsWelcome extends Component {

return (
<div className="wz-module wz-module-welcome">
<div className='wz-module-header-agent-wrapper'>
<div className='wz-module-header-agent wz-module-header-agent-main'>
<div className='wz-module-header-agent wz-module-header-agent-wrapper'>
<div className='wz-module-header-agent-main'>
{title}
</div>
</div>
<div>
<div className='wz-module-header-nav-wrapper'>
<div className='wz-module-header-nav'>
<div style={{ margin: '0 16px' }}>
<EuiPanel grow paddingSize='s' className="wz-welcome-page-agent-info">
<AgentInfo agent={this.props.agent} isCondensed={false} hideActions={true} {...this.props}></AgentInfo>
</EuiPanel>
</div>
</div>
</div>
</div>
<div className='wz-module-body wz-module-agents-padding-responsive'>
<div className='wz-module-agent-body wz-module-agents-padding-responsive'>
<EuiPage>
<EuiPageBody component="div">

<div className='wz-module-header-nav'>
<div>
<EuiPanel grow paddingSize='s' className="wz-welcome-page-agent-info">
<AgentInfo agent={this.props.agent} isCondensed={false} hideActions={true} {...this.props}></AgentInfo>
</EuiPanel>
</div>
</div>
<EuiFlexGroup>
<EuiFlexItem />
<EuiFlexItem style={{ alignItems: 'flex-end', marginTop: 6, marginBottom: 10 }}> {/* DatePicker */}
<EuiFlexItem style={{ alignItems: 'flex-end', marginTop: 10, marginBottom: 10 }}> {/* DatePicker */}
<WzDatePicker condensed={true} onTimeChange={() => { }} />
</EuiFlexItem>
</EuiFlexGroup>
Expand Down