Epic: https://github.com/elastic/kibana/issues/144943
## Summary
Moving the existing CellActions implementation to a new home. The
`kbn-cell-actions` package contains components and hooks that are going
to be used by solutions to show data cell actions with a consistent UI
across them.
Security Solution is going to start using it by migrating all
"hover-actions" to the unified implementation, but the usage is not
restricted to it. Any plugin can register and attach its own actions to
a trigger via uiActions, and use this package to render the CellActions
components in a consistent way.
The initial implementation was placed in the uiActions plugin itself due
to a types constraints
(https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions/public/cell_actions),
the constraint has been solved so we are creating the package for it as
planned.
This PR only moves that implementation to the new package, with small
directory changes. The exported components are not being used anywhere
currently, so the implementation may change during the migration phase.
### Checklist
Delete any items that are not applicable to this PR.
- [x] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)
- [x]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
## Summary
Files management UI that rounds out the files MVP. This is UI is
intended to be progressively enhanced and provides a way for system
administrators get some insight and manage the files created and stored
in Kibana.
## To reviewers
* This is UI for retrieval and deletion of files (the R+D of CRUD)
* Creating and deleting tags to be supported in a future version
* This UI is intended to form part of the broader content management
experience
* We use the `TableListView` component as far as possible
## How to test
1. Start Kibana with `yarn start --run-examples`
2. Go to the "Developer Examples" from the left nav menu
3. Go to the "Files example" plugin
4. Click the "Upload file" button, upload a few different image types
(PNG, JPG and WEBP)
5. Go to "Stack management" > "Files"
6. Behold your files in the management UI
7. (Bonus) check that the UI and API `GET /api/files/find`, `GET
/api/files/metrics` and `DELETE /api/files/blobs` are not accessible to
non-admin or appropriately privileged users (i.e., those with "Files
management" access).
## List of functionality
- [x] List all saved objects (scoped to admin)
- [x] Is able to bulk-delete files
- [x] Shows basic storage diagnostics
- [x] Is able to search and filter files
## Screenshots
<details>
<summary>screenshots</summary>
<img width="1545" alt="Screenshot 2022-11-08 at 13 56 54"
src="https://user-images.githubusercontent.com/8155004/200570783-cfefdbf3-c5ff-4ece-ba24-48a455fcca75.png">
<img width="910" alt="Screenshot 2022-11-10 at 12 52 35"
src="https://user-images.githubusercontent.com/8155004/201083812-bc9f25f5-b423-43a6-9229-5e2a4cdd943a.png">
<img width="451" alt="Screenshot 2022-11-10 at 12 37 07"
src="https://user-images.githubusercontent.com/8155004/201081039-832a1980-684c-4abb-bb05-0c7c6a849d4d.png">
<img width="959" alt="Screenshot 2022-11-08 at 13 57 15"
src="https://user-images.githubusercontent.com/8155004/200570797-f122cff5-7043-4e01-9b51-d5663c1b26d6.png">
<img width="500" alt="Screenshot 2022-11-08 at 13 57 38"
src="https://user-images.githubusercontent.com/8155004/200570801-35cdbd99-0256-4dee-9f78-2f6ad853305f.png">
</details>
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
* [Discover] Create unifiedHistogram plugin
* [Discover] Move discover resizable panels to unifiedHistogram
* [Discover] Replace DiscoverPanels with unifiedHistogram Panels
* [CI] Auto-commit changed files from 'node scripts/build_plugin_list_docs'
* [Discover] Fix types and limtis.yml for unifiedHistogram
* [Discover] Begin migrating layout and chart to unified_histogram
* [Discover] Update i18n keys from discover to unifiedHistogram
* [Discover] Update data-test-subj tags from discover to unifiedHistogram
* [Discover] Update classNames, ids, and scss to change discover to unifiedHistogram
* [Discover] Remove more references to discover from unifiedHistogram
* [Discover] Replace DiscoverServices with UnifiedHistogramServices
* [Discover] Replacing CHART_HIDDEN_KEY with chartHiddenKey prop
* [Discover] Add missing tsconfig references
* [Discover] Remove remaining references to discover from unifiedHistogram
* [Discover] Migrate HitsCounter to unifiedHistogram
* [Discover] Continue removing discover dependencies from unifiedHistogram
* [Discover] Replace SCSS with emotion
* [Discover] Changing PANELS_MODE to be internal
* [Discover] Clean up types
* [Discover] Clean up props and types
* [Discover] Update layout to use Chart component
* [Discover] Update discover_main_content
* [CI] Auto-commit changed files from 'node scripts/precommit_hook.js --ref HEAD~1..HEAD --fix'
* [Discover] Update discover_main_content to use UnifiedHistogramLayout, clean up unifiedHistogram implementation and props, add missing bundles
* [Discover] Fix missing styles in unifiedHistogram
* [Discover] Fix issue where mouse can get out of sync with the resize handle with the Discover resizable layout
* [Discover] Fix some Jest tests
* [Discover] Update discoverQueryHits to unifiedHistogramQueryHits in tests
* [Discover] Finish decoupling discover_main_content from unified histogram layout
* [Discover] Create useDiscoverHistogram hook and remove old histogram dependencies from Discover
* [Discover] Move functions to create chart data from discover to unifiedHistogram
* [Discover] Continue fixing broken Jest tests
* Revert unifiedHistogram.reloadSavedSearchButton removal
* [Discover] Add missing type export and a better suspense fallback
* [Discover] Make callback names consistent
* [Discover] Continue cleanup and add documentation to unifiedHistogram
* [Discover] Update genChartAggConfigs to take object
* [Discover] Update UnifiedHistogramHitsContext.number to total
* [Discover] Cleanup imports
* [Discover] Add support for hiding the entire top panel in the unified histogram by leaving all context props undefined
* [Discover] Fix broken discover_layout unit tests
* [Discover] Clean up naming in discover_main_content
* [Discover] Continue fixing Jest tests and adding new tests
* [Discover] Finish writing Jest tests
* [Discover] Fix conflicts with getVisualizeInformation and triggerVisualizeActions after merge
* [Discover] Fix hiding reset chart height button when default chart height
* [Discover] Update CODEOWNER file
* [Discover] Removed types for @link comments
* [Discover] Fix broken discover_layout.test.tsx file
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
* 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>
* [Guided onboarding] Smashed commit of all POC work for guided onboarding and guided onboarding example plugins
* [Guided onboarding] Fixed type errors
* [Guided onboarding] Removed guidedOnboardingExample limit
* [Guided onboarding] Fixed a functonal test for exposed configs
* [Guided onboarding] Fixed plugin limit
* [Guided onboarding] Added more information to the example plugin
* [Guided onboarding] Fixed no-console error
* [CI] Auto-commit changed files from 'node scripts/eslint --no-cache --fix'
* [Guided onboarding] Fixed snake case errors
* move guided_onboarding out of x-pack
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Alison Goryachev <alison.goryachev@elastic.co>
* [Discover] Add initial support for tags to saved search modal
* [Discover] Add tags to savedSearch types
* [Discover] Finish initial support for adding tags to saved searches
* [Discover] Start to convert saved object finder to a table in order to support tags
* [Discover] Add support for displaying saved search tags in open search flyout
* [CI] Auto-commit changed files from 'node scripts/precommit_hook.js --ref HEAD~1..HEAD --fix'
* [Discover] Continue support for tags in saved object finder
* [Discover] Clean up saved object finder
* [Discover] Finish initial support for tags in saved object finder
* [Discover] Update SimpleSavedObject constructor to SimpleSavedObjectImpl
* [Discover] Remove orig files
* [Discover] Saved search tag type registration and telemetry
* [Discover] Create new saved_objects_finder plugin
* [Discover] Continue work creating saved_objects_finder plugin
* [Discover] Revert some changes in saved_objects
* [Discover] Revert some changes in saved_objects again
* [CI] Auto-commit changed files from 'node scripts/eslint --no-cache --fix'
* [Discover] Update saved_objects_finder i18n keys
* [Discover] Update docs
* [Discover] Add plugins to saved_object_finder and fix broken types
* [Discover] Finish creating saved_objects_finder plugin and use it in Discover
* [Discover] Update SavedObjectFinderProps type export, and update x-pack telemetry
* [Discover] Fix broken jest tests
* [Discover] Update saved_objects_finder API
* [Discover] Remove unused translations
* [Discover] Fix issue with initial saved object finder fetch
* [Discover] Fix some of the saved object finder jest tests
* [Discover] Clean up finder after merge
* [Discover] Fixing saved_object_finder.tsx
* [Discover] Add savedObjectsTaggingOss reference to saved_search plugin
* [Discover] Fix broken open_search_panel test
* [Discover] Removed allowed types from saved object finder
* [Discover] Removing type column when there's only one saved object type, and adjusting column widths
* [Discover] Fix issue where visible types were entirely removed, fixed pageSizeOptions
* [Discover] Add showFilter to open_search_panel's saved_objects_finder, fallback to all available types when no type filter is applied to saved_objects_finder, hide type column and filter button when there is only one type in metadata list
* [Discover] Fix remaining saved_object_finder Jest tests
* [Discover] Update snapshot
* [Discover] Fix failing functional tests
* [Discover] Add tagging Jest tests for saved_objects_finder
* [Discover] Fix small bugs in saved_object_finder, update Jest tests, add functional tests for Discover saved search tagging
* [Discover] Removed unused variable in functional test
* [Discover] Update Discover Jest tests with tagging tests
* [Discover] Remove translations
* [Discover] Updating saved_objects_finder to use static export vs preconfigured component, adding lazy load support
* [Discover] Move saved_object_finder service deps to a 'services' prop, fix broken open_search_panel Jest test
* [Discover] Fix broken Jest test
* [Discover] Fix broken Jest test from merge
* [Discover] Fix discover tags integration test description
* - Updated tags prop to be `string | undefined`
- Type imports cleanup
- Added loading indicator for saved object finder
- Changed `savedObjectsPlugin.settings.getListingLimit()` to `uiSettings.get(LISTING_LIMIT_SETTING)`
- Removed old saved object finder comment
- Removed tag changes from transform plugin
- Change code owners of saved_objects_finder to Data Discovery
* [Discover] Fixed LISTING_LIMIT_SETTING import
* [Discover] Revert tags saving change that introduced a bug
* [CI] Auto-commit changed files from 'node scripts/build_plugin_list_docs'
* [Discover] Try again to fix LISTING_LIMIT_SETTINGS import
* [Discover] Fix failing snapshot
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
* Creates packages for shared types: core-deprecations-common and core-deprecations-common-internal, moves types accordingly, updates src/core/public|server imports
* Moves more internal types to package
* Changes widely used internal deprecations-related types to public types, moves these to publically accessible packages
* Updates import, updates bazel build file
* Creates package core-deprecations-browser-internal and moves implementation and tests into package
* Updates imports of public deprecations implementations
* Creates package core-deprecations-browser-mocks, moves mock and deletes core-deprecations-common-internal
* Updates types in src/core
* Updates README's and build bazel files for core's client-side deprecations service
* Updates imports
* exports shared DeprecationsDetails from core/server
* Adds deprecations to i18n rc
* replace targetted core packages with top level packages for core in i18nrc file, cleans up tsconfig and bazel build files, addresses prefered style in core
* Add event annotation service structure
* adding annotation layer to lens. passing event annotation service
* simplify initial Dimensions
* add annotations to lens
* no datasource layer
* group the annotations into numerical icons
* color icons in tooltip, add the annotation icon, fix date interval bug
* display old time axis for annotations
* error in annotation dimension when date histogram is removed
* refactor: use the same methods for annotations and reference lines
* wip
* only check activeData for dataLayers
* added new icons for annotations
* refactor icons
* uniqueLabels
* unique Labels
* diff config from args
* change timestamp format
* added expression event_annotation_group
* names refactor
* ea service adding help descriptions
* rotate icon
* added tests
* fix button problem
* dnd problem
* dnd fix
* tests for dimension trigger
* tests for unique labels
* [CI] Auto-commit changed files from 'node scripts/build_plugin_list_docs'
* type
* add new button test
* remove noDatasource from config (only needed when initializing a layer or dimension in getSupportedLayers)
* addressing Joe's and Michael comments
* remove hexagon and square, address Stratoula's feedback
* stroke for icons & icon fill
* fix tests
* fix small things
* align the set with tsvb
* align IconSelect
* fix i18nrc
* Update src/plugins/event_annotation/public/event_annotation_service/index.tsx
Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
* refactor empty button
* CR
* date cr
* remove DimensionEditorSection
* change to emptyShade for traingle fill
* Update x-pack/plugins/lens/public/app_plugin/app.scss
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
* Added config for mosaic/pie/donut/treemap/waffle.
* Added sortPredicate functionality for waffle/mosaic/treemap/pie/donut
* Added Donut handling.
* Refactored get_color.
* Merged color computation for lens and vis_types.
* Added isFlatLegend support.
* Added showValuesInLegend for waffle and fixed tests.
* Removed not used position, which is equivalent to labels.show = false.
* legendDisplay added.
* Added migrations for pieVis addLegend argument.
* Added startFromSecondLargestSlice and support of correct formatters.
* Updated docs.
* Added functionality for truncate.
* Added unit tests for pie and partial for donut/waffle.
* Addressed issue with label truncation by default.
* Addressed issue with formatters.
* Added tests for accessor.test.ts
* Added support of formatter by meta data from columns at splitChartAccessors.
* Added tests for filterOutConfig.
* Added tests for getFormatters.
* Added tests for getAvailableFormatter.
* Added tests for getFormatter.
* Added tests for get_split_dimension_accessor.
* Add is legend scenario.
* Added tests for legend.
* Replaced sortPredicate, relying on the internal terms params, with the mosaic one.
* Fixed pie snapshot and added new snapshot for treemap.
* Added snapshots for mosaicVis.
* Added snapshot to waffleVis.
* Updated unit tests for *_vis_function's.
* Added storybook.
* Added snapshots for partition vis component.
* Added expression error on providing both, splitColumn && splitRow.
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
* [WIP] Combine visualizations and visualize plugins
* Revert some changes and do some refactoring
* Refactor some code
* Fix some tests
* Fix functional tests and some jest test cases
* Update telemetry
* Fix get_visualization_instance.test and plugin-list.asciidoc
* Refactor some code
* fix CI
* Add visualizations to vis_default_editor tsconfig
* Revert changes related to telemetry and permissions
* Add dashboard to timeseries tsconfig.json
* Update limits file
* Update translation keys
* Add capabilitiesProvider back to server and replace visEditorsRegistry getter and setter with service
* Update mocks.ts
* Revert changes related to visEditorsRegistry
* Get rid of visEditorsRegistry getter and setter
* Remove dashboard from timeseries/tsconfig.json
* Return back dashboard dependency to timeseries/tsconfig.json, rename applicaion folder to visualize_app and APP_NAME to VISUALIZE_APP_NAME, revert types.ts
* Remove comma in .i18nrc.json
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
* gauge_expression
* fix
* CI fix
* make plugin required to use its methods
* move non-types from types
* share icon
* bundle, plugin
* load gaugeComponent async
* fix types
* async heatmap
* don't use d3
* optimizations
* feedback
* types
* adjusting the tests to the new max
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
* [WIP][Heatmap] Creates implementation with elastic-charts
* Fix types and connection with vislib
* Add coloring options
* Brush, click events, coloring etc
* Cleaning up the expression function
* Add legend picker, fix sorting and other fixes
* Further fixes
* Use the shared expression to Lens and cleanup
* PrepareLogTables for new expression function
* Use common renderer and expression function with lens
* Fix i18n
* Small tweaks
* Add unit tests
* Adds a unit test to the heatmap component
* update plugin list
* Fix types
* Fix types
* update limits
* Change to the expression function
* Cleanup translations
* Refactor to use vis
* Fix types
* further cleanup of the translations
* register new setting
* Fix sorting for histogram
* Adds functional tests for the new nisualize heatmap
* Cleanup
* Fix
* Apply PR comments
* Address PR comments
* Fix i18n
* Fix i18n
* Makes the <Heatmap /> id dynamic
* reverse
* fix translation file
* Apply design PR comments
* Fix package
* More fixes
* Fix brush problem
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
* initial pass at moving data views into own plugin
* require expressions plugin, fix META_FIELDS reference
* bundle limits and localization
* fix integration test
* update plugin list and jest config
* type fixes
* search fixes
* fix localization
* fix mocks
* fix mocks
* fix stub
* type fixes
* fix import on test file
* path fixes
* remove shorted dotted from data plugin
* more todo removal
* eslint fixes
* eslint fix
* simplify data views server plugin
* simplify data views server plugin
* simplify data views server plugin
* fix imports on api routes
* fix imports on api routes
* update plugin list
* ts fixes
* ts fixes
* add deprecation notice
* fix circular dependency and api integration test
* fix circular dependency and api integration test
* rename types for better clarity
* path fixes
* jest.config and tsconfig cleanup
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>