toolbar-button.component.yml

Same filename in other branches
  1. 11.x core/modules/navigation/components/toolbar-button/toolbar-button.component.yml
core/modules/navigation/components/toolbar-button/toolbar-button.component.yml

File

core/modules/navigation/components/toolbar-button/toolbar-button.component.yml

View source
  1. # This is so your IDE knows about the syntax for fixes and autocomplete.
  2. $schema: https://git.drupalcode.org/project/drupal/-/raw/HEAD/core/assets/schemas/v1/metadata.schema.json
  3. # The human readable name.
  4. name: Toolbar button
  5. # Status can be: "experimental", "stable", "deprecated", "obsolete".
  6. status: experimental
  7. # Schema for the props. We support www.json-schema.org. Learn more about the
  8. # syntax there.
  9. props:
  10. # Props are always an object with keys. Each key is a variable in your
  11. # component template.
  12. type: object
  13. properties:
  14. action:
  15. type: string
  16. title: Action
  17. description: Hidden button action text.
  18. modifiers:
  19. type: array
  20. title: Modifier classes.
  21. description:
  22. Button modifiers.
  23. https://en.bem.info/methodology/css/#modifiers
  24. items:
  25. type: string
  26. enum:
  27. - collapsible
  28. - dark
  29. - expand--down
  30. - expand--side
  31. - large
  32. - non-interactive
  33. - small-offset
  34. - weight--400
  35. extra_classes:
  36. type: array
  37. title: Extra classes.
  38. description:
  39. External modifiers added from the placement context.
  40. https://en.bem.info/methodology/css/#mixes
  41. items:
  42. type: string
  43. html_tag:
  44. type: string
  45. title: HTML tag
  46. # Limit the available options by using enums.
  47. enum:
  48. - a
  49. - button
  50. - span
  51. # Provide a default value
  52. default: button
  53. icon:
  54. title: Icon
  55. type: string
  56. text:
  57. title: Text
  58. description: Text of button.
  59. type: string
  60. slots:
  61. content:
  62. title: Content
  63. description: Content of button.

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.