mirror of
https://github.com/fleetdm/fleet
synced 2026-05-24 01:18:42 +00:00
update host details cert card (#29827)
Relates to [#29324](https://github.com/fleetdm/fleet/issues/29324) updates certificates card UI on the host details and my devices page. changes some copy and adds a new Keychain column.  - [x] Changes file added for user-visible changes in `changes/`, `orbit/changes/` or `ee/fleetd-chrome/changes`. See [Changes files](https://github.com/fleetdm/fleet/blob/main/docs/Contributing/guides/committing-changes.md#changes-files) for more information. - [x] Manual QA for all new/changed functionality
This commit is contained in:
parent
cca4d2440d
commit
03a7b27633
5 changed files with 27 additions and 2 deletions
2
changes/issue-29827-update-ui-for-certs
Normal file
2
changes/issue-29827-update-ui-for-certs
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
- update Certificates card on the host details and my device page to show a new
|
||||
keychain column
|
||||
|
|
@ -24,6 +24,8 @@ const DEFAULT_HOST_CERTIFICATE_MOCK: IHostCertificate = {
|
|||
organizational_unit: "Test Inc.",
|
||||
common_name: "Test Biz",
|
||||
},
|
||||
source: "system",
|
||||
username: "",
|
||||
};
|
||||
|
||||
export const createMockHostCertificate = (
|
||||
|
|
|
|||
|
|
@ -23,6 +23,8 @@ export interface IHostCertificate {
|
|||
organizational_unit: string;
|
||||
common_name: string;
|
||||
};
|
||||
source: string;
|
||||
username: string;
|
||||
}
|
||||
|
||||
export const CERTIFICATES_DEFAULT_SORT: IListSort = {
|
||||
|
|
|
|||
|
|
@ -66,8 +66,8 @@ const CertificatesTable = ({
|
|||
|
||||
const helpText = showHelpText ? (
|
||||
<p>
|
||||
Showing certificates in the system keychain. To get all certificates, you
|
||||
can query the certificates table.{" "}
|
||||
Showing certificates in the system and login (user) keychain. To get all
|
||||
certificates, you can query the certificates table.{" "}
|
||||
<CustomLink
|
||||
text="Learn more"
|
||||
url="https://fleetdm.com/learn-more-about/certificates-query"
|
||||
|
|
|
|||
|
|
@ -10,6 +10,8 @@ import TextCell from "components/TableContainer/DataTable/TextCell";
|
|||
import ViewAllHostsLink from "components/ViewAllHostsLink";
|
||||
import StatusIndicator from "components/StatusIndicator";
|
||||
import { IIndicatorValue } from "components/StatusIndicator/StatusIndicator";
|
||||
import TooltipTruncatedTextCell from "components/TableContainer/DataTable/TooltipTruncatedTextCell";
|
||||
import TooltipWrapper from "components/TooltipWrapper";
|
||||
|
||||
type IHostCertificatesTableConfig = Column<IHostCertificate>;
|
||||
|
||||
|
|
@ -22,6 +24,23 @@ const generateTableConfig = (): IHostCertificatesTableConfig[] => {
|
|||
),
|
||||
Cell: (cellProps) => <TextCell value={cellProps.cell.value} />,
|
||||
},
|
||||
{
|
||||
accessor: "source",
|
||||
disableSortBy: true,
|
||||
Header: "Keychain",
|
||||
Cell: (cellProps) => {
|
||||
if (cellProps.cell.value === "system") {
|
||||
return <TextCell value="System" />;
|
||||
}
|
||||
return (
|
||||
<TooltipWrapper
|
||||
tipContent={cellProps.cell.row.original.username || "Unknown user"}
|
||||
>
|
||||
User
|
||||
</TooltipWrapper>
|
||||
);
|
||||
},
|
||||
},
|
||||
{
|
||||
accessor: "not_valid_after",
|
||||
Header: (cellProps) => (
|
||||
|
|
|
|||
Loading…
Reference in a new issue