kibana/packages
Wafaa Nasr 77867e162f
Exceptions List component (#140985)
* add components with a draft exception-list-details to test

* fix jest config in xPack=> security=> Public

* fix tests

* fix header test and use RTL

* covert meta test to use RTL and header

* fix utlity messageid

* fix messageid in utilty

* create osCondition, entryContent and entryContent.helper from Conditions.tsx

* comment test until fixing all

* create package with first components + test + jest config

* add constants for url

* [CI] Auto-commit changed files from 'node scripts/generate codeowners'

* disable tests until finishing moving rest of components or fix it+ add securityLinkAnchorComponent temp;

* add exceptionList-components +fixning build issues

* add exceptionList-components +fixning build issues

* fix translations id + pass comments as props

* move utiitly out of package until moving all + fixing css

* copy non-js/ts files through babel

* remove list-details-components

* apply comments

* apply comments in references

* fix meta tests

* update tests + add some descriptions

* fix camelcase file name in  Readme

* fix camelcase file name in  Readme

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: spalger <spencer@elastic.co>
2022-09-28 20:36:05 +02:00
..
analytics add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
content-management [TableListView] Group title description and tags (#140947) 2022-09-23 05:21:41 -07:00
core Move RequestHandlerContext types and implementation to packages (#141759) 2022-09-27 23:59:09 -07:00
home add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-ace add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-alerts add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-ambient-storybook-types Update Storybook to 6.5 (#139334) 2022-09-22 19:23:21 -07:00
kbn-ambient-ui-types add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-analytics add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-apm-config-loader [pkgs/manifest] allow owner to be an array of users/teams (#140740) 2022-09-14 09:39:01 -07:00
kbn-apm-synthtrace [APM] Generate Service metrics with synthrace (#141739) 2022-09-27 15:20:19 +02:00
kbn-apm-utils add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-axe-config add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-babel-plugin-synthetic-packages add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-babel-preset Update dependency core-js to ^3.25.1 (main) (#140776) 2022-09-16 07:28:22 +09:30
kbn-bazel-packages [Table list view] Improve UX (phase 1) (#135892) 2022-09-19 12:29:23 +02:00
kbn-bazel-runner add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-chart-icons add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-ci-stats-core add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-ci-stats-performance-metrics add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-ci-stats-reporter add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-cli-dev-mode add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-coloring add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-config add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-config-mocks Fix another static version snapshot in tests (#141345) 2022-09-23 00:19:27 -07:00
kbn-config-schema add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-crypto add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-crypto-browser add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-datemath add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-dev-cli-errors add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-dev-cli-runner [ftr] add first-class support for playwrite journeys (#140680) 2022-09-22 01:06:46 -07:00
kbn-dev-proc-runner [ftr] support redirecting server logs to a file (#140334) 2022-09-09 10:44:00 -07:00
kbn-dev-utils add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-doc-links [Enterprise Search] Doclinks for 8.5 (#141515) 2022-09-23 07:35:45 -07:00
kbn-docs-utils add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-ebt-tools add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-es [ftr] support redirecting server logs to a file (#140334) 2022-09-09 10:44:00 -07:00
kbn-es-archiver add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-es-errors add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-es-query [Dashboard] [Controls] Fix dashboard to dashboard drilldowns where source dashboard has controls (#140548) 2022-09-21 13:30:45 -07:00
kbn-es-types Move src/core/types/elasticsearch to @kbn/es-types (#140522) 2022-09-20 10:32:13 +02:00
kbn-eslint-config add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-eslint-plugin-disable add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-eslint-plugin-eslint add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-eslint-plugin-imports add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-expect add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-failed-test-reporter-cli [journeys] restart ES for each journey, fix flakiness (#141530) 2022-09-26 08:56:31 -07:00
kbn-field-types add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-find-used-node-modules add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-flot-charts add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-ftr-common-functional-services [stack_functional_integration] remove esArchiver service (#141842) 2022-09-26 12:50:28 -07:00
kbn-ftr-screenshot-filename [ftr] add first-class support for playwrite journeys (#140680) 2022-09-22 01:06:46 -07:00
kbn-generate [pkgs/manifest] allow owner to be an array of users/teams (#140740) 2022-09-14 09:39:01 -07:00
kbn-get-repo-files add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-handlebars add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-hapi-mocks add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-i18n add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-i18n-react add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-import-resolver add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-interpreter add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-io-ts-utils add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-jest-serializers add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-journeys [journeys] restart ES for each journey, fix flakiness (#141530) 2022-09-26 08:56:31 -07:00
kbn-kibana-manifest-schema [pkgs/manifest] allow owner to be an array of users/teams (#140740) 2022-09-14 09:39:01 -07:00
kbn-logging add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-logging-mocks add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-managed-vscode-config add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-managed-vscode-config-cli add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-mapbox-gl add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-monaco add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-optimizer [Response Ops] [Connectors] Move connectors type UI components to stack_connectors plugin (#140444) 2022-09-27 10:44:04 -04:00
kbn-optimizer-webpack-helpers add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-osquery-io-ts-types [Osquery] Response Actions fixes (#141041) 2022-09-23 21:13:26 +02:00
kbn-performance-testing-dataset-extractor [ftr] add first-class support for playwrite journeys (#140680) 2022-09-22 01:06:46 -07:00
kbn-plugin-discovery add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-plugin-generator add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-plugin-helpers add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-react-field add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-repo-source-classifier add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-repo-source-classifier-cli add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-rule-data-utils add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-safer-lodash-set add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-securitysolution-autocomplete [Security Solution] Value list exceptions (#133254) 2022-09-19 22:41:28 +02:00
kbn-securitysolution-es-utils add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-securitysolution-exception-list-components Exceptions List component (#140985) 2022-09-28 20:36:05 +02:00
kbn-securitysolution-hook-utils add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-securitysolution-io-ts-alerting-types [Security Solution] Don't mute rules when bulk editing rule actions (#140626) 2022-09-27 18:29:34 +02:00
kbn-securitysolution-io-ts-list-types [Security Solution] Value list exceptions (#133254) 2022-09-19 22:41:28 +02:00
kbn-securitysolution-io-ts-types [Security Solution] Don't mute rules when bulk editing rule actions (#140626) 2022-09-27 18:29:34 +02:00
kbn-securitysolution-io-ts-utils add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-securitysolution-list-api [Security Solution] Value list exceptions (#133254) 2022-09-19 22:41:28 +02:00
kbn-securitysolution-list-constants [Security Solution] Value list exceptions (#133254) 2022-09-19 22:41:28 +02:00
kbn-securitysolution-list-hooks [Security Solution] Value list exceptions (#133254) 2022-09-19 22:41:28 +02:00
kbn-securitysolution-list-utils [Security Solution] Value list exceptions (#133254) 2022-09-19 22:41:28 +02:00
kbn-securitysolution-rules add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-securitysolution-t-grid add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-securitysolution-utils add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-server-http-tools add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-server-route-repository add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-shared-svg add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-shared-ux-utility add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-some-dev-log add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-sort-package-json add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-spec-to-console add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-std add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-stdio-dev-helpers add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-storybook Update Storybook to 6.5 (#139334) 2022-09-22 19:23:21 -07:00
kbn-synthetic-package-map add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-telemetry-tools @kbn/telemetry-tools ensures alphabetical order (#140970) 2022-09-19 09:32:23 -07:00
kbn-test [stack_functional_integration] remove esArchiver service (#141842) 2022-09-26 12:50:28 -07:00
kbn-test-jest-helpers [Table list view] Improve UX (phase 1) (#135892) 2022-09-19 12:29:23 +02:00
kbn-test-subj-selector modernize test-subj-selector (#140847) 2022-09-15 22:08:51 -07:00
kbn-timelion-grammar add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-tinymath add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-tooling-log add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-type-summarizer add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-type-summarizer-cli add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-type-summarizer-core add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-typed-react-router-config [Profiling] Add Profiling application (#140722) 2022-09-15 19:24:41 +02:00
kbn-ui-framework add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-ui-shared-deps-npm add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-ui-shared-deps-src add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-ui-theme add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-user-profile-components Add no assignees option to user profiles selectable (#140036) 2022-09-14 16:52:34 +01:00
kbn-utility-types add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-utility-types-jest add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-utils add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
kbn-yarn-lock-validator add kibana.jsonc files to existing packages (#138965) 2022-09-08 13:31:57 -07:00
shared-ux [SharedUX] Removing TODOs from KibanaPageTemplate (#141043) 2022-09-22 14:39:53 +02:00
BUILD.bazel Exceptions List component (#140985) 2022-09-28 20:36:05 +02:00
README.md [kbn/pm] rewrite to avoid needing a build process (#136207) 2022-07-18 08:46:13 -07:00

Kibana-related packages

This folder contains packages that are intended for use in Kibana and Kibana plugins.

tl;dr:

  • Don't publish to npm registry
  • Always use the @kbn namespace
  • Always set "private": true in package.json

Using these packages

We no longer publish these packages to the npm registry. Now, instead of specifying a version when including these packages, we rely on yarn workspaces, which sets up a symlink to the package.

For example if you want to use the @kbn/i18n package in Kibana itself, you can specify the dependency like this:

"@kbn/i18n": "1.0.0"

However, if you want to use this from a Kibana plugin, you need to use a link: dependency and account for the relative location of the Kibana repo, so it would instead be:

"@kbn/i18n": "link:../../kibana/packages/kbn-i18n"

Creating a new package

Create a new sub-folder. The name of the folder should mirror the name in the package's package.json. E.g. if the name is @kbn/i18n the folder name should be kbn-i18n.

All new packages should use the @kbn namespace, and should be marked with "private": true.

Unit tests for a package

Currently there is only one tool being used in order to test packages which is Jest. Below we will explain how it should be done.

Jest

A package should follow the pattern of having .test.js files as siblings of the source code files, and these run by Jest.

A package using the .test.js naming convention will have those tests automatically picked up by Jest and run by the unit test runner, currently mapped to the Kibana test script in the root package.json.

  • yarn test runs all unit tests.
  • yarn jest runs all Jest tests in Kibana.

In order for the plugin or package to use Jest, a jest.config.js file must be present in it's root. However, there are safeguards for this in CI should a test file be added without a corresponding config file.


Each package can also specify its own test script in the package's package.json, for cases where you'd prefer to run the tests from the local package directory.