Commit graph

41 commits

Author SHA1 Message Date
Devon Thomson 56bfd0e53d
[Dashboard] [Functional Tests] Unskip by value Example (#116513)
* Unskip dashboard by value example tests
2021-11-09 11:43:09 -05:00
Spencer 4385ac4d83
[eslint] enable type-specific lint rules (#114184)
* [eslint] enable type-specific lint rules

* autofix violations

* duplicate eslint-disable to new export statement

Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-11-03 16:56:17 -06:00
Peter Pisljar 3907d53df5
persistable state docs (#105202) 2021-09-22 13:22:38 +02:00
Tyler Smalley 4681a80317
[DX] Upgrade prettier to v2.4.0 (#112359)
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
2021-09-19 22:34:30 -07:00
Spencer c0395c9ef6
[build_ts_refs] improve caches, allow building a subset of projects (#107981)
* [build_ts_refs] improve caches, allow building a subset of projects

* cleanup project def script and update refs in type check script

* rename browser_bazel config to avoid kebab-case

* remove execInProjects() helper

* list references for tsconfig.types.json for api-extractor workload

* disable composite features of tsconfig.types.json for api-extractor

* set declaration: true to avoid weird debug error

* fix jest tests

Co-authored-by: spalger <spalger@users.noreply.github.com>
2021-08-10 22:12:45 -07:00
Stacey Gammon b9f398875a
Add more information on kibana.json properties, update example plugins (#107600)
* Add more information on kibana.json properties, update example plugin kibana.jsons

* fix auto save fix

* Update anatomy_of_a_plugin.mdx

* Update anatomy_of_a_plugin.mdx

* update based on review comments

* Update anatomy_of_a_plugin.mdx

* Put kibanaVersion back and adjust the explanations of the fields

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-08-09 13:32:07 -04:00
Peter Pisljar 5aa8a0a818
persistable state migrations (#103680) 2021-07-07 22:42:16 +02:00
Brandon Kobel 4584a8b570
Elastic License 2.0 (#90099)
* Updating everything except the license headers themselves

* Applying ESLint rules

* Manually replacing the stragglers
2021-02-03 18:12:39 -08:00
Brandon Kobel 170a2956c8
Updating the License (#88343)
* Updating the Licenses, except for applying eslint, building

* Applying ESLint rules,building @kbn/pm, regenerating api docs
2021-01-19 17:52:56 -08:00
Josh Dover 0af81310b6
Remove dynamic mapped types from UiActions (#87075)
* Remove dynamic mapped types from UiActions

* Remove import between data <-> embeddables

* remove outdated comments, export action types from discover_enhanced

* fix notice.txt

Co-authored-by: restrry <restrry@gmail.com>
2021-01-05 10:11:05 +01:00
Mikhail Shustov 95861a0fb0
[DX] Prettier v2.2 (#83899)
* update prettier with ts version support

* mute type-error

* run prettier on codebase

* fix examples

* fix errors after master merged
2020-11-23 13:17:05 +01:00
Devon Thomson 8c1b2157df
[Time to Visualize] Small Attribute Service Fixes (#82072)
* Removed some dashboard-centric wording from the Attribute Service & removed type argument from save method
2020-11-02 11:25:53 -05:00
Luke Elmers dc56b56201
[docs] Add missing App Arch READMEs. (#82080) 2020-10-29 17:01:33 -06:00
Maja Grubic 13059bdd8f
[Refactor] Move AttributeService from Dashboard to Embeddable plugin (#79830)
* [Refactor] Move AttributeService from Dashboard to Embeddable plugin

* Fix wrong import

* Fixing typescript errors

* Make Dashboard a required dependency

* Fixing circular dependency

* Fix label namespace

* Updating docs

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2020-10-12 14:51:39 +01:00
Maja Grubic 989e9c9702
Refactor attribute service (#78414)
* Making saveMethod mandatory in attribute service

* Making unwrap method mandatory

* Making book embeddable respect new attribute service

* Remove savedObjectsClient from attribute service

* Add checkForDuplicateTitle method to book embeddable

* Make options mandatory on attribute service

* Changing Lens attribute service

* Somw more typescript fixes

* Fixing attribute service typescript and tests

* Fixing typescript errors

* Unsetting feature flag

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2020-10-06 08:31:55 +01:00
Mikhail Shustov ae8f8e1d10
Add TS projects for src/plugins & x-pack/plugins (#78440)
* bump query-string version to remove manual type definitions

* remove manual type declaration

* add kibana_utils tsconfig

* add refs to kibana_utils tsconfig

* add kibana_utils to the project list

* add kibana_react project

* add support for x-pack/tsconfig.refs.json

* add ts project for x-pack licensing plugins

* add glob for ts projects in src/plugins & x-pack/plugins

* add refs to projects in examples

* fix ref paths in x-pack/test

* address mistic comments

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-30 15:02:41 +02:00
Devon Thomson bf93974edc
[Time to Visualize] Panel Title Fixes (#78365)
* [Dashboard][Embeddable] Add placeholder title to embeddable panel, stored 'show panel title' prop in embeddable input.
Co-authored-by: Maja Grubic <maja.grubic@elastic.co>
2020-09-29 15:07:17 -04:00
Mikhail Shustov e7d8ea3927
Extract src/core in a separate TS project (#76785)
* break dependency on data plugin TS code

* move global typings to @kbn/utility-types

* import types from @kbn/utility-types

* remove type dependency on plugins

* add intermediate js files to break dependency on outter TS code

* temp type declaration for query-string

* declare src/core project

* export types to reference in the built d.ts files

* reference core project

* move jest types out of kbn/utility-types due to a clash with mocha types

* fix wrong es_kuery path and ts project paths

* reference core from packages consuming it

* x-pack & oss should use the same lodash version

* Revert "x-pack & oss should use the same lodash version"

This reverts commit 79cec5781e.

* use the same lodash version

* fix @types/lodash TS2300: Duplicate identifier error

* fix wrong imports

* update docs

* update docs

* add a comment why file is needed
2020-09-15 12:41:27 +02:00
Devon Thomson 260643483e
[Dashboard First] Genericize Attribute Service (#76057)
Genericized attribute service, with custom save and unwrap methods and added unit tests.
2020-09-04 13:30:50 -04:00
Mikhail Shustov e9e0ca3782
Introduce TS incremental builds & move src/test_utils to TS project (#76082)
* move test_helpers to the core

* create base tsconfig

* all tsconfigs use the base one

* use test_helpers exposed from the src/core

* move getFieldFormatsRegistry to data plugin

* add test_utils project

* compile types after checkout

* add a stub for platform tsconfig.json

* fix broken import

* fix broken path to the base config

* set tsBuildInfoFile for project without outDir

* do not commit tsbuildinfo file

* do not check output d.ts files

* fix type error

* use separate config to build types

* rollback changes to include paths

* mute import zone error

* rename files to avoid references to tsd

* do not use tsd for type tests

* include all ts files in project

* run buildRefs before type check to ensure the latest version

* store tsbuildinfo locally

* update paths to base config

* comment out core/tsconfig.json

* remove ui path

* fix wrong tsbuildinfo path
2020-09-03 14:20:04 +02:00
Mikhail Shustov 37ec1e1053
Update to TS v4 (#73924)
* bump ts to v4

* MOAR RAM

* fix type errors for OSS

* first pass on x-pack errors

* second pass on x-pack type errors

* 3rd pass on x-pack type-errors

* mute errors if complex cases

* don't delete if spread suffices

* mute other complex cases

* make User fields optional

* fix optional types

* fix tests

* fix typings for time_range

* fix type errors in x-pack/tests

* rebuild kbn-pm

* remove leftovers from master update

* fix alert tests

* [Telemetry Checker] TS4 Fixes

* bump to 4.0.1-rc

* fix new errors in master

* bump typescript-eslint to version supporting TS v4 syntax

* fix merge commit errors

* update to the stable TS version 4.0.2

* bump ts-eslint to version supporting ts v4

* fix typo

* fix type errors after merge

* update ts in another new package.json

* TEMP: remove me

* Revert "TEMP: remove me"

This reverts commit dc0fc3bae6.

* [Telemetry] Update snapshot for new TS4 SyntaxKind

* bump prettier to support TS v4 syntax

* fix prettier rules

* last style change

* fix new type errors

Co-authored-by: Alejandro Fernández Haro <alejandro.haro@elastic.co>
2020-08-27 10:28:02 +02:00
Peter Pisljar 40d8edc2a0
cleaning up embeddable types (#75560) 2020-08-25 09:31:03 +02:00
Devon Thomson 056038caa9
[Dashboard First] Add to Library Action (#75098)
* created an add to library action that turns 'by value' embeddables into 'by reference' embeddables
2020-08-20 10:26:53 -04:00
Devon Thomson 2af2b60b00
[Dashboard First] Unlink from Library Action With ReferenceOrValueEmbeddable (#74905)
* Added an unlink from library action which works with the ReferenceOrValue interface. Once
2020-08-18 10:31:55 -04:00
Devon Thomson 2e5140d67b
[Dashboard First] Decouple Attribute Service and By Value Embeddables (#74302)
* Added an interface that determines if an embeddable can be treated as either by reference or by value
2020-08-12 15:31:44 -04:00
Spencer fa93a81ba6
[kbn/optimizer] implement "requiredBundles" property of KP plugins (#70911)
Co-authored-by: Josh Dover <me@joshdover.com>
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-07-09 18:43:17 -07:00
Devon Thomson 33fd5cf457
[Example] Embeddable by Reference and Value (#68719)
Added an attribute service to embeddable start contract which provides a higher level abstraction for embeddables that can be by reference OR by value. Added an example that uses this service.
2020-07-09 12:22:04 -04:00
Spencer e03f2428b1
[BundleRefPlugin] resolve imports to files too (#69241)
Co-authored-by: spalger <spalger@users.noreply.github.com>
2020-06-16 15:16:35 -07:00
Spencer 7e328417ab
[kbn/optimizer] share all plugin bundles (#68986)
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-06-15 22:15:31 -07:00
Anton Dosov 3d0552e03c
Embed dashboard by value example & some embeddable clean up (#67783)
Added example for using dashboard container by value
1.1 Refactored embeddable explorer e2e test to use new example, removed not needed kbn_tp_embeddable_explorer plugin.
For embeddable explorer examples went away from using getFactoryById() to improve type checks
There is new component a replacement for EmbeddableFactoryRenderer with slightly more flexible api: EmbeddableRenderer.
3.1 We can improve it going forward to support more use case
2020-06-15 17:13:31 +02:00
restrry bf04235dae apply prettier styles 2020-05-22 09:08:58 +02:00
Stacey Gammon b900040cd3
more propagated bad examples (#66920) 2020-05-19 10:12:15 -04:00
Stacey Gammon 976ff05617
KP plugins shouldn't need package.json (#66654)
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-05-15 10:59:42 -04:00
Joe Portner d72de0ea16
Refactor saved object types to use namespaceType (#63217)
Remove `namespaceAgnostic` field that was deprecated in #54605,
use `namespaceType` instead.
2020-04-16 14:37:55 -04:00
Stacey Gammon d0404487f6
Add embeddable via saved object example (#61692)
* Add embeddable via saved object example

* give todoRefEmbed a different name from the by value one

* fix types

* fix order of unmounting

Co-authored-by: Christos Nasikas <christos.nasikas@elastic.co>
2020-04-15 11:10:20 -04:00
Stacey Gammon dfa083dc60
Prep for embed saved object refactor + helper (#62486) 2020-04-06 13:45:46 -04:00
Stacey Gammon bb747abdaf
Switch to embeddable factory interface with optional override (#61165)
* wip

* typescript map embeddable

* More updates

* Address code review comments and update some usages in SIEM and uptime to the new types

* More clean up - carry over some of the SIEM types to maps for render tool tip

* fixes

* fixes

* Address more review comments

* fixes

* fixes

* fix jest test

* Fix visualize embeddable

* fixes after master merge

* Fixes

* Prefix variable with name "custom" to make it more obvious

* Remove layerList from input state

* fixes

* Update src/plugins/dashboard/public/embeddable/dashboard_container_factory.tsx

Co-Authored-By: Vadim Dalecky <streamich@users.noreply.github.com>

* review updates

* fixes

* update maps readme

Co-authored-by: Vadim Dalecky <streamich@users.noreply.github.com>
2020-04-02 14:27:51 -04:00
Pierre Gayvallet 468de51153
Add plugin start contract to getStartServices return value (#61216)
* add plugin own contract as third element of getStartServices result

* adapt plugins code

* update tests

* revert unknown to use void again

* update generated doc

* fix UT

* update mock to allow non-object `pluginStartContract`

* add @typeParam documentation
2020-03-26 10:49:05 +01:00
Stacey Gammon dccfa593dc
Embeddable API cleanup (#60207)
* wip

* Remove test in legacy functional plugin
2020-03-16 15:37:42 -04:00
Stacey Gammon 63cfffbe11
Embeddable add panel examples (#57319)
* Embeddable add panel examples

* add tests

* Fix type error after merge

* address code review comments

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-02-19 15:16:58 -05:00
Stacey Gammon 7e67d1f86c
Embeddable examples on the platform and included with --run-examples flag (#52111)
* Add a new platform embeddable example plugin

* Remove extra hello world test impl.

* cleanup

* code review updates

* Change example to highlight and have parent filter out children

* Fix deep comparison of embeddable prop

* adjust help text
2019-12-16 15:03:46 -05:00