-
Notifications
You must be signed in to change notification settings - Fork 452
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into 8488-new-tuf-repository
- Loading branch information
Showing
112 changed files
with
1,573 additions
and
358 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
- Clarify expected behavior of policy host counts, dashboard controls software count, and controls | ||
os updates versions count. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
Allow delivery of bootstrap packages and software installers using signed URLs from CloudFront CDN. To enable, configure server settings: | ||
- s3_software_installers_cloudfront_url | ||
- s3_software_installers_cloudfront_url_signing_public_key_id | ||
- s3_software_installers_cloudfront_url_signing_private_key |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
- Improve readability of success message on email update by never including the sender address. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
- When running a live query from the edit query form, consider the results of the run in calculating | ||
an existing query's performance impact if the user didn't change the query from the stored version. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
- Fleet UI: Added timestamp for software, OS, and vulnerability detail pages for host count last update time |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Fixed issue where deleted Apple config profiles were installing on devices because devices were offline when the profile was added. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
- Display command line installation instructions when a package is generated |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* Fixed reporting of software uninstall results after a host has been locked/unlocked |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
frontend/components/LastUpdatedHostCount/LastUpdatedHostCount.stories.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import { Meta, StoryObj } from "@storybook/react"; | ||
|
||
import LastUpdatedHostCount from "./LastUpdatedHostCount"; | ||
|
||
const meta: Meta<typeof LastUpdatedHostCount> = { | ||
title: "Components/LastUpdatedHostCount", | ||
component: LastUpdatedHostCount, | ||
args: { | ||
hostCount: 40, | ||
}, | ||
}; | ||
|
||
export default meta; | ||
|
||
type Story = StoryObj<typeof LastUpdatedHostCount>; | ||
|
||
export const Basic: Story = {}; | ||
|
||
export const WithLastUpdatedAt: Story = { | ||
args: { | ||
lastUpdatedAt: "2021-01-01T00:00:00Z", | ||
}, | ||
}; |
37 changes: 37 additions & 0 deletions
37
frontend/components/LastUpdatedHostCount/LastUpdatedHostCount.tests.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import React from "react"; | ||
import { fireEvent, render, screen } from "@testing-library/react"; | ||
|
||
import LastUpdatedHostCount from "."; | ||
|
||
describe("Last updated host count", () => { | ||
it("renders host count and updated text", () => { | ||
const currentDate = new Date(); | ||
currentDate.setDate(currentDate.getDate() - 2); | ||
const twoDaysAgo = currentDate.toISOString(); | ||
|
||
render(<LastUpdatedHostCount hostCount={40} lastUpdatedAt={twoDaysAgo} />); | ||
|
||
const hostCount = screen.getByText(/40/i); | ||
const updateText = screen.getByText("Updated 2 days ago"); | ||
|
||
expect(hostCount).toBeInTheDocument(); | ||
expect(updateText).toBeInTheDocument(); | ||
}); | ||
it("renders never if missing timestamp", () => { | ||
render(<LastUpdatedHostCount />); | ||
|
||
const text = screen.getByText("Updated never"); | ||
|
||
expect(text).toBeInTheDocument(); | ||
}); | ||
|
||
it("renders tooltip on hover", async () => { | ||
render(<LastUpdatedHostCount hostCount={0} />); | ||
|
||
await fireEvent.mouseEnter(screen.getByText("Updated never")); | ||
|
||
expect( | ||
screen.getByText(/last time host data was updated/i) | ||
).toBeInTheDocument(); | ||
}); | ||
}); |
34 changes: 34 additions & 0 deletions
34
frontend/components/LastUpdatedHostCount/LastUpdatedHostCount.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import React from "react"; | ||
import LastUpdatedText from "components/LastUpdatedText"; | ||
|
||
const baseClass = "last-updated-host-count"; | ||
|
||
interface ILastUpdatedHostCount { | ||
hostCount?: string | number; | ||
lastUpdatedAt?: string; | ||
} | ||
|
||
const LastUpdatedHostCount = ({ | ||
hostCount, | ||
lastUpdatedAt, | ||
}: ILastUpdatedHostCount): JSX.Element => { | ||
const tooltipContent = ( | ||
<> | ||
The last time host data was updated. <br /> | ||
Click <b>View all hosts</b> to see the most | ||
<br /> up-to-date host count. | ||
</> | ||
); | ||
|
||
return ( | ||
<div className={baseClass}> | ||
<>{hostCount}</> | ||
<LastUpdatedText | ||
lastUpdatedAt={lastUpdatedAt} | ||
customTooltipText={tooltipContent} | ||
/> | ||
</div> | ||
); | ||
}; | ||
|
||
export default LastUpdatedHostCount; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
.last-updated-host-count { | ||
display: flex; | ||
align-items: baseline; | ||
gap: $pad-small; | ||
font-size: $x-small; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export { default } from "./LastUpdatedHostCount"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.