kibana/packages/kbn-language-documentation-popover
Luke Elmers b6287708f6
Adds AGPL 3.0 license (#192025)
Updates files outside of x-pack to be triple-licensed under Elastic
License 2.0, AGPL 3.0, or SSPL 1.0.
2024-09-06 19:02:41 -06:00
..
.storybook Adds AGPL 3.0 license (#192025) 2024-09-06 19:02:41 -06:00
src Adds AGPL 3.0 license (#192025) 2024-09-06 19:02:41 -06:00
index.ts Adds AGPL 3.0 license (#192025) 2024-09-06 19:02:41 -06:00
jest.config.js Adds AGPL 3.0 license (#192025) 2024-09-06 19:02:41 -06:00
kibana.jsonc Move esql code to the new kibana-esql team (#179454) 2024-03-27 07:47:08 +01:00
package.json Adds AGPL 3.0 license (#192025) 2024-09-06 19:02:41 -06:00
README.md [ES|QL] Increase discoverability (#188898) 2024-08-05 17:40:06 +02:00
tsconfig.json [ES|QL] Use the shared ux Markdown component (#174320) 2024-02-12 10:47:36 +02:00

Shareable language documentation popover

This is a stateless shareable component that can be used to render documentation for a language as a popover.

It can be used in every application that would like to add an in-app documentation. The component consists of:

  • A sidebar navigation with a search
  • A details page
<LanguageDocumentationPopover language={language} sections={documentationSections} onHelpMenuVisibilityChange={onHelpMenuVisibilityChange} isHelpMenuOpen={isHelpMenuOpen} />

The properties are typed as:

 export interface LanguageDocumentationSections {
  groups: Array<{
    label: string;
    description?: string;
    items: Array<{ label: string; description?: JSX.Element }>;
  }>;
  initialSection: JSX.Element;
}