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

feat(dashboard-renderer): stub out support for EntityLink [MA-2716] #1245

Closed
wants to merge 2 commits into from

Conversation

mihai-peteu
Copy link
Contributor

Comment on lines 3 to 12
export default (routeParams: string[]): string => {
// TODO: may have to pass in geo from consuming app
const activeGeoCode = 'us'

const parsedRouteParams = routeParams.map(rp => rp.replace('{geo}', activeGeoCode))

// TODO: replace `{idTuple0}` and `{idTuple1}` with actual record ID vales

return useExternalLinkCreator(parsedRouteParams)
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if this isn't going to be shared amongst other charts in the dashboard, the logic could all be stashed inside generateEntityUrl in TopNTableRenderer most likely.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't need use external link creator here

The host app is supposed to do this, the host app supplies the output of external link creator to the dashboard and the renderer replaces the appropriate ids

import type { AnalyticsExploreRecord, DisplayBlob, ExploreResultV4, QueryResponseMeta } from '@kong-ui-public/analytics-utilities'
import type { AnalyticsChartColors, SimpleChartOptions } from '../../src/types'
import { SeededRandom } from '../utils/SeedRandom'
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@filipgutica this is my fault, I forgot to update the import in a previous PR 😬 Without this fix, the SimpleChart demo doesn't load.

@filipgutica filipgutica self-requested a review March 14, 2024 21:04
@filipgutica filipgutica force-pushed the feat/ma-2716-slottable-links-topn branch from 13a1ff3 to 921c516 Compare March 14, 2024 21:05
@filipgutica filipgutica self-assigned this Mar 14, 2024
@mihai-peteu mihai-peteu deleted the feat/ma-2716-slottable-links-topn branch March 19, 2024 17:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants