Skip to content

Commit

Permalink
chore: orval types
Browse files Browse the repository at this point in the history
  • Loading branch information
FredrikOseberg committed Jan 30, 2024
1 parent c7a666e commit b2dc4ce
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { FlagsChart } from './FlagsChart/FlagsChart';
import { useExecutiveDashboard } from 'hooks/api/getters/useExecutiveSummary/useExecutiveSummary';
import { UserStats } from './UserStats/UserStats';
import { FlagStats } from './FlagStats/FlagStats';
import FlagsProjectChart from './FlagsProjectChart/FlagsProjectChartComponent';
import { FlagsProjectChart } from './FlagsProjectChart/FlagsProjectChart';

const StyledGrid = styled(Box)(({ theme }) => ({
display: 'grid',
Expand All @@ -32,8 +32,6 @@ export const ExecutiveDashboard: VFC = () => {
).toFixed(1);
};

console.log(executiveDashboardData);

return (
<>
<Box sx={(theme) => ({ paddingBottom: theme.spacing(4) })}>
Expand All @@ -54,6 +52,7 @@ export const ExecutiveDashboard: VFC = () => {
<UsersChart userTrends={executiveDashboardData.userTrends} />
<FlagsChart flagTrends={executiveDashboardData.flagTrends} />
</StyledGrid>

<FlagsProjectChart
projectFlagTrends={executiveDashboardData.projectFlagTrends}
/>
Expand Down
3 changes: 3 additions & 0 deletions frontend/src/openapi/models/executiveSummarySchema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
*/
import type { ExecutiveSummarySchemaFlags } from './executiveSummarySchemaFlags';
import type { ExecutiveSummarySchemaFlagTrendsItem } from './executiveSummarySchemaFlagTrendsItem';
import type { ExecutiveSummarySchemaProjectFlagTrendsItem } from './executiveSummarySchemaProjectFlagTrendsItem';
import type { ExecutiveSummarySchemaUsers } from './executiveSummarySchemaUsers';
import type { ExecutiveSummarySchemaUserTrendsItem } from './executiveSummarySchemaUserTrendsItem';

Expand All @@ -16,6 +17,8 @@ export interface ExecutiveSummarySchema {
flags: ExecutiveSummarySchemaFlags;
/** How number of flags changed over time */
flagTrends: ExecutiveSummarySchemaFlagTrendsItem[];
/** How number of flags per project changed over time */
projectFlagTrends: ExecutiveSummarySchemaProjectFlagTrendsItem[];
/** High level user count statistics */
users: ExecutiveSummarySchemaUsers;
/** How number of users changed over time */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export type ExecutiveSummarySchemaFlagTrendsItem = {
/** A UTC date when the stats were captured. Time is the very end of a given day. */
date: string;
/** The number of time calculated potentially stale flags on a particular day */
potentiallyStale?: number;
potentiallyStale: number;
/** The number of user marked stale flags on a particular day */
stale: number;
/** The number of all flags on a particular day */
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/**
* Generated by Orval
* Do not edit manually.
* See `gen:api` script in package.json
*/

export type ExecutiveSummarySchemaProjectFlagTrendsItem = {
/** The number of active flags on a particular day */
active: number;
/** A UTC date when the stats were captured. Time is the very end of a given day. */
date: string;
/** The number of time calculated potentially stale flags on a particular day */
potentiallyStale: number;
/** Project id of the project the flag trends belong to */
project: string;
/** The number of user marked stale flags on a particular day */
stale: number;
/** The number of all flags on a particular day */
total: number;
};
1 change: 1 addition & 0 deletions frontend/src/openapi/models/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -497,6 +497,7 @@ export * from './eventsSchemaVersion';
export * from './executiveSummarySchema';
export * from './executiveSummarySchemaFlagTrendsItem';
export * from './executiveSummarySchemaFlags';
export * from './executiveSummarySchemaProjectFlagTrendsItem';
export * from './executiveSummarySchemaUserTrendsItem';
export * from './executiveSummarySchemaUsers';
export * from './exportFeatures404';
Expand Down

0 comments on commit b2dc4ce

Please sign in to comment.