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

[Embeddable] Flexible Titling System #148680

Closed
Tracked by #144752
ThomThomson opened this issue Jan 10, 2023 · 3 comments
Closed
Tracked by #144752

[Embeddable] Flexible Titling System #148680

ThomThomson opened this issue Jan 10, 2023 · 3 comments
Labels
Feature:Embeddables Relating to the Embeddable system impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. loe:large Large Level of Effort Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas

Comments

@ThomThomson
Copy link
Contributor

What should we do?

Currently, title, description, and hidePanelTitles are fundamental pieces of every embeddable, and must be stored in the input and / or output of the embeddable. Every embeddable must have one and only one title, and must store it in the same way.

There are many cases where embeddables may not have titles, or may have a different requirement for showing titles internally. In order to allow flexibility for these use cases, we should use an interface and methods instead of tightly coupling titles to every embeddable type.

How is this done?

  • Create an interface for titling that has getters and setters for description, title, hideTitles.
  • Create a type guard that checks if an embeddable extends that interface
  • Extend that interface in all embeddables which are expected to be titleable.
  • Check the type guard and use the methods everywhere titles are interacted with in Kibana.
@ThomThomson ThomThomson added Feature:Embedding Embedding content via iFrame Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas loe:large Large Level of Effort impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. labels Jan 10, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-presentation (Team:Presentation)

@teresaalvarezsoler
Copy link

@ThomThomson this seems related with the embeddable refactor, can we close it?

@ThomThomson
Copy link
Contributor Author

Yes good call, this was completed in #172017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Embeddables Relating to the Embeddable system impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. loe:large Large Level of Effort Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas
Projects
None yet
Development

No branches or pull requests

3 participants