primer_view_components 0.43.6 → 0.44.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (118) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +20 -0
  3. data/app/assets/javascripts/components/primer/alpha/tree_view/tree_view.d.ts +39 -0
  4. data/app/assets/javascripts/components/primer/alpha/tree_view/tree_view_icon_pair_element.d.ts +15 -0
  5. data/app/assets/javascripts/components/primer/alpha/tree_view/tree_view_include_fragment_element.d.ts +9 -0
  6. data/app/assets/javascripts/components/primer/alpha/tree_view/tree_view_roving_tab_index.d.ts +3 -0
  7. data/app/assets/javascripts/components/primer/alpha/tree_view/tree_view_sub_tree_node_element.d.ts +42 -0
  8. data/app/assets/javascripts/components/primer/primer.d.ts +4 -0
  9. data/app/assets/javascripts/components/primer/shared_events.d.ts +15 -0
  10. data/app/assets/javascripts/primer_view_components.js +1 -1
  11. data/app/assets/javascripts/primer_view_components.js.map +1 -1
  12. data/app/assets/styles/primer_view_components.css +1 -1
  13. data/app/assets/styles/primer_view_components.css.map +1 -1
  14. data/app/components/primer/alpha/file_tree_view/directory_node.html.erb +5 -0
  15. data/app/components/primer/alpha/file_tree_view/directory_node.rb +24 -0
  16. data/app/components/primer/alpha/file_tree_view/file_node.html.erb +2 -0
  17. data/app/components/primer/alpha/file_tree_view/file_node.rb +14 -0
  18. data/app/components/primer/alpha/file_tree_view.rb +15 -0
  19. data/app/components/primer/alpha/select_panel_element.js +1 -2
  20. data/app/components/primer/alpha/select_panel_element.ts +1 -3
  21. data/app/components/primer/alpha/skeleton_box.css +1 -0
  22. data/app/components/primer/alpha/skeleton_box.css.json +6 -0
  23. data/app/components/primer/alpha/skeleton_box.css.map +1 -0
  24. data/app/components/primer/alpha/skeleton_box.html.erb +1 -0
  25. data/app/components/primer/alpha/skeleton_box.pcss +30 -0
  26. data/app/components/primer/alpha/skeleton_box.rb +29 -0
  27. data/app/components/primer/alpha/tree_view/icon.html.erb +1 -0
  28. data/app/components/primer/alpha/tree_view/icon.rb +22 -0
  29. data/app/components/primer/alpha/tree_view/icon_pair.html.erb +13 -0
  30. data/app/components/primer/alpha/tree_view/icon_pair.rb +42 -0
  31. data/app/components/primer/alpha/tree_view/leading_action.html.erb +3 -0
  32. data/app/components/primer/alpha/tree_view/leading_action.rb +18 -0
  33. data/app/components/primer/alpha/tree_view/leaf_node.html.erb +18 -0
  34. data/app/components/primer/alpha/tree_view/leaf_node.rb +96 -0
  35. data/app/components/primer/alpha/tree_view/loading_failure_message.html.erb +13 -0
  36. data/app/components/primer/alpha/tree_view/loading_failure_message.rb +31 -0
  37. data/app/components/primer/alpha/tree_view/node.html.erb +32 -0
  38. data/app/components/primer/alpha/tree_view/node.rb +194 -0
  39. data/app/components/primer/alpha/tree_view/skeleton_loader.html.erb +23 -0
  40. data/app/components/primer/alpha/tree_view/skeleton_loader.rb +36 -0
  41. data/app/components/primer/alpha/tree_view/spinner_loader.html.erb +20 -0
  42. data/app/components/primer/alpha/tree_view/spinner_loader.rb +33 -0
  43. data/app/components/primer/alpha/tree_view/sub_tree.html.erb +21 -0
  44. data/app/components/primer/alpha/tree_view/sub_tree.rb +113 -0
  45. data/app/components/primer/alpha/tree_view/sub_tree_container.html.erb +3 -0
  46. data/app/components/primer/alpha/tree_view/sub_tree_container.rb +39 -0
  47. data/app/components/primer/alpha/tree_view/sub_tree_node.html.erb +49 -0
  48. data/app/components/primer/alpha/tree_view/sub_tree_node.rb +188 -0
  49. data/app/components/primer/alpha/tree_view/tree_view.d.ts +39 -0
  50. data/app/components/primer/alpha/tree_view/tree_view.js +363 -0
  51. data/app/components/primer/alpha/tree_view/tree_view.ts +396 -0
  52. data/app/components/primer/alpha/tree_view/tree_view_icon_pair_element.d.ts +15 -0
  53. data/app/components/primer/alpha/tree_view/tree_view_icon_pair_element.js +62 -0
  54. data/app/components/primer/alpha/tree_view/tree_view_icon_pair_element.ts +56 -0
  55. data/app/components/primer/alpha/tree_view/tree_view_include_fragment_element.d.ts +9 -0
  56. data/app/components/primer/alpha/tree_view/tree_view_include_fragment_element.js +28 -0
  57. data/app/components/primer/alpha/tree_view/tree_view_include_fragment_element.ts +28 -0
  58. data/app/components/primer/alpha/tree_view/tree_view_roving_tab_index.d.ts +3 -0
  59. data/app/components/primer/alpha/tree_view/tree_view_roving_tab_index.js +130 -0
  60. data/app/components/primer/alpha/tree_view/tree_view_roving_tab_index.ts +161 -0
  61. data/app/components/primer/alpha/tree_view/tree_view_sub_tree_node_element.d.ts +42 -0
  62. data/app/components/primer/alpha/tree_view/tree_view_sub_tree_node_element.js +418 -0
  63. data/app/components/primer/alpha/tree_view/tree_view_sub_tree_node_element.ts +470 -0
  64. data/app/components/primer/alpha/tree_view/visual.html.erb +14 -0
  65. data/app/components/primer/alpha/tree_view/visual.rb +27 -0
  66. data/app/components/primer/alpha/tree_view.css +1 -0
  67. data/app/components/primer/alpha/tree_view.css.json +52 -0
  68. data/app/components/primer/alpha/tree_view.css.map +1 -0
  69. data/app/components/primer/alpha/tree_view.html.erb +12 -0
  70. data/app/components/primer/alpha/tree_view.pcss +373 -0
  71. data/app/components/primer/alpha/tree_view.rb +439 -0
  72. data/app/components/primer/beta/breadcrumbs.css +1 -1
  73. data/app/components/primer/beta/breadcrumbs.css.json +0 -1
  74. data/app/components/primer/beta/breadcrumbs.css.map +1 -1
  75. data/app/components/primer/beta/breadcrumbs.pcss +2 -8
  76. data/app/components/primer/beta/progress_bar.css +1 -1
  77. data/app/components/primer/beta/progress_bar.css.map +1 -1
  78. data/app/components/primer/beta/progress_bar.pcss +3 -2
  79. data/app/components/primer/beta/spinner.html.erb +1 -1
  80. data/app/components/primer/beta/spinner.rb +2 -0
  81. data/app/components/primer/primer.d.ts +4 -0
  82. data/app/components/primer/primer.js +4 -0
  83. data/app/components/primer/primer.pcss +2 -0
  84. data/app/components/primer/primer.ts +4 -0
  85. data/app/components/primer/shared_events.d.ts +15 -0
  86. data/app/components/primer/shared_events.ts +19 -0
  87. data/app/controllers/primer/view_components/tree_view_items.json +293 -0
  88. data/app/controllers/primer/view_components/tree_view_items_controller.rb +55 -0
  89. data/app/forms/check_box_with_nested_form.rb +10 -10
  90. data/app/forms/radio_button_with_nested_form.rb +16 -16
  91. data/app/views/primer/view_components/tree_view_items/async_alpha.html_fragment.erb +23 -0
  92. data/app/views/primer/view_components/tree_view_items/index.html_fragment.erb +24 -0
  93. data/config/routes.rb +2 -0
  94. data/lib/primer/view_components/version.rb +2 -2
  95. data/previews/primer/alpha/file_tree_view_preview/default.html.erb +16 -0
  96. data/previews/primer/alpha/file_tree_view_preview/playground.html.erb +4 -0
  97. data/previews/primer/alpha/file_tree_view_preview.rb +69 -0
  98. data/previews/primer/alpha/skeleton_box_preview.rb +20 -0
  99. data/previews/primer/alpha/tree_view_preview/async_alpha.html.erb +12 -0
  100. data/previews/primer/alpha/tree_view_preview/buttons.html.erb +10 -0
  101. data/previews/primer/alpha/tree_view_preview/default.html.erb +24 -0
  102. data/previews/primer/alpha/tree_view_preview/empty.html.erb +10 -0
  103. data/previews/primer/alpha/tree_view_preview/form_input.html.erb +14 -0
  104. data/previews/primer/alpha/tree_view_preview/leaf_node_playground.html.erb +15 -0
  105. data/previews/primer/alpha/tree_view_preview/links.html.erb +17 -0
  106. data/previews/primer/alpha/tree_view_preview/loading_failure.html.erb +36 -0
  107. data/previews/primer/alpha/tree_view_preview/loading_skeleton.html.erb +12 -0
  108. data/previews/primer/alpha/tree_view_preview/loading_spinner.html.erb +12 -0
  109. data/previews/primer/alpha/tree_view_preview/playground.html.erb +4 -0
  110. data/previews/primer/alpha/tree_view_preview.rb +208 -0
  111. data/static/arguments.json +450 -0
  112. data/static/audited_at.json +17 -0
  113. data/static/classes.json +15 -0
  114. data/static/constants.json +101 -0
  115. data/static/info_arch.json +1348 -0
  116. data/static/previews.json +232 -0
  117. data/static/statuses.json +17 -0
  118. metadata +87 -6
@@ -3988,6 +3988,148 @@
3988
3988
  }
3989
3989
  ]
3990
3990
  },
3991
+ {
3992
+ "fully_qualified_name": "Primer::Alpha::FileTreeView",
3993
+ "description": "",
3994
+ "accessibility_docs": null,
3995
+ "is_form_component": false,
3996
+ "is_published": true,
3997
+ "requires_js": false,
3998
+ "component": "FileTreeView",
3999
+ "status": "alpha",
4000
+ "a11y_reviewed": false,
4001
+ "short_name": "FileTreeView",
4002
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/file_tree_view.rb",
4003
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/file_tree_view/default/",
4004
+ "parameters": [
4005
+ {
4006
+ "name": "node_variant",
4007
+ "type": "Symbol",
4008
+ "default": "`:div`",
4009
+ "description": "The variant to use for this node. One of `:anchor`, `:button`, or `:div`."
4010
+ },
4011
+ {
4012
+ "name": "form_arguments",
4013
+ "type": "Hash",
4014
+ "default": "`{}`",
4015
+ "description": "These arguments allow the selections made within a `TreeView` to be submitted to the server as part of a Rails form. Pass the `builder:` and `name:` options to this hash. `builder:` should be an instance of `ActionView::Helpers::FormBuilder`, which are created by the standard Rails `#form_with` and `#form_for` helpers. The `name:` option is the desired name of the field that will be included in the params sent to the server on form submission."
4016
+ },
4017
+ {
4018
+ "name": "system_arguments",
4019
+ "type": "Hash",
4020
+ "default": "N/A",
4021
+ "description": "{{link_to_system_arguments_docs}}."
4022
+ }
4023
+ ],
4024
+ "slots": [
4025
+ {
4026
+ "name": "nodes",
4027
+ "description": null,
4028
+ "parameters": []
4029
+ }
4030
+ ],
4031
+ "methods": [],
4032
+ "previews": [
4033
+ {
4034
+ "preview_path": "primer/alpha/file_tree_view/default",
4035
+ "name": "default",
4036
+ "snapshot": "interactive",
4037
+ "skip_rules": {
4038
+ "wont_fix": [
4039
+ "region"
4040
+ ],
4041
+ "will_fix": [
4042
+ "color-contrast"
4043
+ ]
4044
+ }
4045
+ },
4046
+ {
4047
+ "preview_path": "primer/alpha/file_tree_view/playground",
4048
+ "name": "playground",
4049
+ "snapshot": "false",
4050
+ "skip_rules": {
4051
+ "wont_fix": [
4052
+ "region"
4053
+ ],
4054
+ "will_fix": [
4055
+ "color-contrast"
4056
+ ]
4057
+ }
4058
+ }
4059
+ ],
4060
+ "subcomponents": [
4061
+ {
4062
+ "fully_qualified_name": "Primer::Alpha::FileTreeView::FileNode",
4063
+ "description": "",
4064
+ "accessibility_docs": null,
4065
+ "is_form_component": false,
4066
+ "is_published": true,
4067
+ "requires_js": false,
4068
+ "component": "FileTreeView::FileNode",
4069
+ "status": "alpha",
4070
+ "a11y_reviewed": false,
4071
+ "short_name": "FileTreeViewFileNode",
4072
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/file_tree_view/file_node.rb",
4073
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/file_tree_view/file_node/default/",
4074
+ "parameters": [],
4075
+ "slots": [
4076
+ {
4077
+ "name": "leading_visual",
4078
+ "description": null,
4079
+ "parameters": []
4080
+ },
4081
+ {
4082
+ "name": "leading_action",
4083
+ "description": null,
4084
+ "parameters": []
4085
+ },
4086
+ {
4087
+ "name": "trailing_visual",
4088
+ "description": null,
4089
+ "parameters": []
4090
+ }
4091
+ ],
4092
+ "methods": [],
4093
+ "previews": [],
4094
+ "subcomponents": []
4095
+ },
4096
+ {
4097
+ "fully_qualified_name": "Primer::Alpha::FileTreeView::DirectoryNode",
4098
+ "description": "",
4099
+ "accessibility_docs": null,
4100
+ "is_form_component": false,
4101
+ "is_published": true,
4102
+ "requires_js": false,
4103
+ "component": "FileTreeView::DirectoryNode",
4104
+ "status": "alpha",
4105
+ "a11y_reviewed": false,
4106
+ "short_name": "FileTreeViewDirectoryNode",
4107
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/file_tree_view/directory_node.rb",
4108
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/file_tree_view/directory_node/default/",
4109
+ "parameters": [],
4110
+ "slots": [
4111
+ {
4112
+ "name": "leading_visual",
4113
+ "description": null,
4114
+ "parameters": []
4115
+ },
4116
+ {
4117
+ "name": "leading_action",
4118
+ "description": null,
4119
+ "parameters": []
4120
+ },
4121
+ {
4122
+ "name": "trailing_visual",
4123
+ "description": null,
4124
+ "parameters": []
4125
+ }
4126
+ ],
4127
+ "methods": [],
4128
+ "previews": [],
4129
+ "subcomponents": []
4130
+ }
4131
+ ]
4132
+ },
3991
4133
  {
3992
4134
  "fully_qualified_name": "Primer::Alpha::FormButton",
3993
4135
  "description": "A button input rendered using the HTML `<button type=\"button\">` tag.\n\nThis component wraps the Primer button component and supports the same slots and arguments.",
@@ -7835,6 +7977,71 @@
7835
7977
  }
7836
7978
  ]
7837
7979
  },
7980
+ {
7981
+ "fully_qualified_name": "Primer::Alpha::SkeletonBox",
7982
+ "description": "A SkeletonBox provides a placeholder for non-text, non-Avatar elements (e.g., hero images)\nthat are still loading. You can adjust width and height to match the content's dimensions.",
7983
+ "accessibility_docs": null,
7984
+ "is_form_component": false,
7985
+ "is_published": true,
7986
+ "requires_js": false,
7987
+ "component": "SkeletonBox",
7988
+ "status": "alpha",
7989
+ "a11y_reviewed": false,
7990
+ "short_name": "SkeletonBox",
7991
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/skeleton_box.rb",
7992
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/skeleton_box/default/",
7993
+ "parameters": [
7994
+ {
7995
+ "name": "height",
7996
+ "type": "String",
7997
+ "default": "`nil`",
7998
+ "description": "Any valid CSS height."
7999
+ },
8000
+ {
8001
+ "name": "width",
8002
+ "type": "String",
8003
+ "default": "`nil`",
8004
+ "description": "Any valid CSS width."
8005
+ },
8006
+ {
8007
+ "name": "system_arguments",
8008
+ "type": "Hash",
8009
+ "default": "N/A",
8010
+ "description": "{{link_to_system_arguments_docs}}"
8011
+ }
8012
+ ],
8013
+ "slots": [],
8014
+ "methods": [],
8015
+ "previews": [
8016
+ {
8017
+ "preview_path": "primer/alpha/skeleton_box/default",
8018
+ "name": "default",
8019
+ "snapshot": "false",
8020
+ "skip_rules": {
8021
+ "wont_fix": [
8022
+ "region"
8023
+ ],
8024
+ "will_fix": [
8025
+ "color-contrast"
8026
+ ]
8027
+ }
8028
+ },
8029
+ {
8030
+ "preview_path": "primer/alpha/skeleton_box/playground",
8031
+ "name": "playground",
8032
+ "snapshot": "false",
8033
+ "skip_rules": {
8034
+ "wont_fix": [
8035
+ "region"
8036
+ ],
8037
+ "will_fix": [
8038
+ "color-contrast"
8039
+ ]
8040
+ }
8041
+ }
8042
+ ],
8043
+ "subcomponents": []
8044
+ },
7838
8045
  {
7839
8046
  "fully_qualified_name": "Primer::Alpha::Stack",
7840
8047
  "description": "Stack is a layout component that creates responsive horizontal and vertical flows.",
@@ -9711,6 +9918,1147 @@
9711
9918
  ],
9712
9919
  "subcomponents": []
9713
9920
  },
9921
+ {
9922
+ "fully_qualified_name": "Primer::Alpha::TreeView",
9923
+ "description": "TreeView is a hierarchical list of items that may have a parent-child relationship where children\ncan be toggled into view by expanding or collapsing their parent item.\n\n## Terminology\n\nConsider the following tree structure:\n\nsrc\n├ button.rb\n└ action_list\n ├ item.rb\n └ header.rb\n\n1. **Node**. A node is an item in the tree. Nodes can either be \"leaf\" nodes (i.e. have no children), or \"sub-tree\"\nnodes, which do have children. In the example above, button.rb, item.rb, and header.rb are all leaf nodes, while\naction_list is a sub-tree node.\n2. **Path**. A node's path is like its ID. It's an array of strings containing the current node's label and all the\nlabels of its ancestors, in order. In the example above, header.rb's path is [\"src\", \"action_list\", \"header.rb\"].\n\n## Static nodes\n\nThe `TreeView` component allows items to be provided statically or loaded dynamically from the server.\nProviding items statically is done using the `leaf` and `sub_tree` slots:\n\n```erb\n<%= render(Primer::Alpha::TreeView.new) do |tree| %>\n <% tree.with_sub_tree(label: \"Directory\") do |sub_tree| %>\n <% sub_tree.with_leaf(label: \"File 1\")\n <% end %>\n <% tree.with_leaf(label: \"File 2\") %>\n<% end %>\n```\n\n## Dynamic nodes\n\nTree nodes can also be fetched dynamically from the server and will require creating a Rails controller action\nto respond with the list of nodes. Unlike other Primer components, `TreeView` allows the programmer to specify\nloading behavior on a per-sub-tree basis, i.e. each sub-tree must specify how its nodes are loaded. To load nodes\ndynamically for a given sub-tree, configure it with either a loading spinner or a loading skeleton, and provide\nthe URL to fetch nodes from:\n\n```erb\n<%= render(Primer::Alpha::TreeView.new) do |tree| %>\n <% tree.with_sub_tree(label: \"Directory\") do |sub_tree| %>\n <% sub_tree.with_loading_spinner(src: primer_view_components.tree_view_items_path) %>\n <% end %>\n<% end %>\n```\n\nDefine a controller action to serve the list of nodes. The `TreeView` component automatically includes the\nsub-tree's path as a GET parameter, encoded as a JSON array.\n\n```ruby\nclass TreeViewItemsController < ApplicationController\n def show\n @path = JSON.parse(params[:path])\n @results = get_tree_items(starting_at: path)\n end\nend\n```\n\nResponses must be HTML fragments, eg. have a content type of `text/html+fragment`. This content type isn't\navailable by default in Rails, so you may have to register it eg. in an initializer:\n\n```ruby\nMime::Type.register(\"text/fragment+html\", :html_fragment)\n```\n\nRender a `Primer::Alpha::TreeView::SubTree` in the action's template, tree_view_items/show.html_fragment.erb:\n\n```erb\n<%= render(Primer::Alpha::TreeView::SubTree.new(path: @path, node_variant: :div)) do |tree| %>\n <% tree.with_leaf(...) %>\n <% tree.with_sub_tree(...) do |sub_tree| %>\n ...\n <% end %>\n<% end %>\n```\n\n## Multi-select mode\n\nPassing `select_variant: :multiple` to both sub-tree and leaf nodes will add a check box to the left of the node's\nlabel. These check boxes behave according to the value of a second argument, `select_strategy:`.\n\nThe default select strategy, `:descendants`, will cause all child nodes to be checked when the node is checked.\nThis includes both sub-tree and leaf nodes. When the node is unchecked, all child nodes will also be unchecked.\nUnchecking a child node of a checked parent will cause the parent to enter a mixed or indeterminate state, which\nis represented by a horizontal line icon instead of a check mark. This icon indicates that some children are\nchecked, but not all.\n\nA secondary select strategy, `:self`, is provided to allow disabling the automatic checking of child nodes. When\n`select_strategy: :self` is specified, checking sub-tree nodes does not check child nodes, and sub-tree nodes\ncannot enter a mixed or indeterminate state.\n\nNodes can be checked via the keyboard by pressing the space key.\n\n## Node tags\n\n`TreeView`s support three different node variants, `:anchor`, `:button`, and `:div` (the default), which controls\nwhich HTML tag is used to construct the nodes. The `:anchor` and `:button` variants correspond to `<a>` and\n`<button>` tags respectively, which are browser-native elements. Anchors and buttons can be activated (i.e.\n\"clicked\") using the mouse or keyboard via the enter or space keys. The node variant must be the same for all\nnodes in the tree, and is therefore specified at the root level, eg. `TreeView.new(node_variant: :anchor)`.\n\nTrees with node variants other than `:div` cannot have check boxes, i.e. cannot be put into multi-select mode.\n\nTrees with node variants other than `:div` do not emit the `treeViewNodeActivated` or `treeViewBeforeNodeActivated`\nevents, since it is assumed any behavior associated with these variants is user- or browser-defined.\n\n## Interaction behavior matrix\n\n|Interaction |Select variant|Tag |Result |\n|:---------------|:-------------|:------------|:--------------------------|\n|Enter/space |none |div |Expands/collapses |\n|Enter/space |none |anchor/button|Activates anchor/button |\n|Enter/space |multiple |div |Checks or unchecks |\n|Enter/space |multiple |anchor/button|N/A (not allowed) |\n|Left/right arrow|none |div |Expands/collapses |\n|Left/right arrow|none |anchor/button|Expands/collapses |\n|Left/right arrow|multiple |div |Expands/collapses |\n|Left/right arrow|multiple |anchor/button|N/A (not allowed) |\n|Click |none |div |Expands/collapses |\n|Click |multiple |div |Checks or unchecks |\n|Click |multiple |anchor/button|N/A (not allowed) |\n\n## JavaScript API\n\n`TreeView`s render a `<tree-view>` custom element that exposes behavior to the client.\n\n|Name |Notes |\n|:-----------------------------------------------------------------|:-------------------------------------------------------------------------------------------------------------------------------------------------|\n|`getNodePath(node: Element): string[]` |Returns the path to the given node. |\n|`getNodeType(node: Element): TreeViewNodeType | null` |Returns either `\"leaf\"` or `\"sub-tree\"`. |\n|`markCurrentAtPath(path: string[])` |Marks the node as the \"current\" node, which appears visually distinct from other nodes. |\n|`get currentNode(): HTMLLIElement | null` |Returns the current node. |\n|`expandAtPath(path: string[])` |Expands the sub-tree at `path`. |\n|`collapseAtPath(path: string[])` |Collapses the sub-tree at `path`. |\n|`toggleAtPath(path: string[])` |If the sub-tree at `path` is collapsed, this function expands it, and vice-versa. |\n|`checkAtPath(path: string[])` |If the node at `path` has a checkbox, this function checks it. |\n|`uncheckAtPath(path: string[])` |If the node at `path` has a checkbox, this function unchecks it. |\n|`toggleCheckedAtPath(path: string[])` |If the sub-tree at `path` is checked, this function unchecks it, and vice-versa. |\n|`checkedValueAtPath(path: string[]): TreeViewCheckedValue` |Returns `\"true\"` (all child nodes are checked), `\"false\"` (no child nodes are checked), or `\"mixed\"` (some child nodes are checked, some are not).|\n|`nodeAtPath(path: string[], selector?: string): Element | null` |Returns the node for the given `path`, either a leaf node or sub-tree node. |\n|`subTreeAtPath(path: string[]): TreeViewSubTreeNodeElement | null`|Returns the sub-tree at the given `path`, if it exists. |\n|`leafAtPath(path: string[]): HTMLLIElement | null` |Returns the leaf node at the given `path`, if it exists. |\n|`getNodeCheckedValue(node: Element): TreeViewCheckedValue` |The same as `checkedValueAtPath`, but accepts a node instead of a path. |\n\n### Events\n\nThe events enumerated below include node information by way of the `TreeViewNodeInfo` object, which has the\nfollowing signature:\n\n```typescript\ntype TreeViewNodeType = 'leaf' | 'sub-tree'\ntype TreeViewCheckedValue = 'true' | 'false' | 'mixed'\n\ntype TreeViewNodeInfo = {\n node: Element\n type: TreeViewNodeType\n path: string[]\n checkedValue: TreeViewCheckedValue\n previousCheckedValue: TreeViewCheckedValue\n}\n```\n\n|Name |Type |Bubbles |Cancelable |\n|:----------------------------|:------------------------------------------|:-------|:----------|\n|`treeViewNodeActivated` |`CustomEvent<TreeViewNodeInfo>` |Yes |No |\n|`treeViewBeforeNodeActivated`|`CustomEvent<TreeViewNodeInfo>` |Yes |Yes |\n|`treeViewNodeExpanded` |`CustomEvent<TreeViewNodeInfo>>` |Yes |No |\n|`treeViewNodeCollapsed` |`CustomEvent<TreeViewNodeInfo>>` |Yes |No |\n|`treeViewNodeChecked` |`CustomEvent<TreeViewNodeInfo[]>` |Yes |Yes |\n|`treeViewBeforeNodeChecked` |`CustomEvent<TreeViewNodeInfo[]>` |Yes |No |\n\n_Item activation_\n\nThe `<tree-view>` element fires an `treeViewNodeActivated` event whenever a node is activated (eg. clicked)\nvia the mouse or keyboard.\n\nThe `treeViewBeforeNodeActivated` event fires before a node is activated. Canceling this event will prevent the\nnode from being activated.\n\n```typescript\ndocument.querySelector(\"select-panel\").addEventListener(\n \"treeViewBeforeNodeActivated\",\n (event: CustomEvent<TreeViewNodeInfo>) => {\n event.preventDefault() // Cancel the event to prevent activation (eg. expanding/collapsing)\n }\n)\n```\n\n_Item checking/unchecking_\n\nThe `tree-view` element fires a `treeViewNodeChecked` event whenever a node is checked or unchecked.\n\nThe `treeViewBeforeNodeChecked` event fires before a node is checked or unchecked. Canceling this event will\nprevent the check/uncheck operation.\n\n```typescript\ndocument.querySelector(\"select-panel\").addEventListener(\n \"treeViewBeforeNodeChecked\",\n (event: CustomEvent<TreeViewNodeInfo[]>) => {\n event.preventDefault() // Cancel the event to prevent activation (eg. expanding/collapsing)\n }\n)\n```\n\nBecause checking or unchecking a sub-tree results in the checking or unchecking of all its children recursively,\nboth the `treeViewNodeChecked` and `treeViewBeforeNodeChecked` events provide an array of `TreeViewNodeInfo`\nobjects, which contain entries for every modified node in the tree.",
9924
+ "accessibility_docs": null,
9925
+ "is_form_component": false,
9926
+ "is_published": true,
9927
+ "requires_js": false,
9928
+ "component": "TreeView",
9929
+ "status": "alpha",
9930
+ "a11y_reviewed": false,
9931
+ "short_name": "TreeView",
9932
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view.rb",
9933
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/default/",
9934
+ "parameters": [
9935
+ {
9936
+ "name": "node_variant",
9937
+ "type": "Symbol",
9938
+ "default": "`:div`",
9939
+ "description": "The variant to use for this node. One of `:anchor`, `:button`, or `:div`."
9940
+ },
9941
+ {
9942
+ "name": "form_arguments",
9943
+ "type": "Hash",
9944
+ "default": "`{}`",
9945
+ "description": "These arguments allow the selections made within a `TreeView` to be submitted to the server as part of a Rails form. Pass the `builder:` and `name:` options to this hash. `builder:` should be an instance of `ActionView::Helpers::FormBuilder`, which are created by the standard Rails `#form_with` and `#form_for` helpers. The `name:` option is the desired name of the field that will be included in the params sent to the server on form submission."
9946
+ },
9947
+ {
9948
+ "name": "system_arguments",
9949
+ "type": "Hash",
9950
+ "default": "N/A",
9951
+ "description": "{{link_to_system_arguments_docs}}."
9952
+ }
9953
+ ],
9954
+ "slots": [
9955
+ {
9956
+ "name": "nodes",
9957
+ "description": null,
9958
+ "parameters": []
9959
+ }
9960
+ ],
9961
+ "methods": [
9962
+ {
9963
+ "name": "with_leaf",
9964
+ "description": "Adds an leaf node to the tree. Leaf nodes are nodes that do not have children.",
9965
+ "parameters": [
9966
+ {
9967
+ "name": "component_klass",
9968
+ "type": "Class",
9969
+ "default": "N/A",
9970
+ "description": "The class to use instead of the default {{#link_to_component}}Primer::Alpha::TreeView::LeafNode{{/link_to_component}}"
9971
+ },
9972
+ {
9973
+ "name": "system_arguments",
9974
+ "type": "Hash",
9975
+ "default": "N/A",
9976
+ "description": "These arguments are forwarded to {{#link_to_component}}Primer::Alpha::TreeView::LeafNode{{/link_to_component}}, or whatever class is passed as the `component_klass` argument."
9977
+ }
9978
+ ],
9979
+ "return_types": []
9980
+ },
9981
+ {
9982
+ "name": "with_sub_tree",
9983
+ "description": "Adds a sub-tree node to the tree. Sub-trees are nodes that have children, which can be both leaf nodes and other sub-trees.",
9984
+ "parameters": [
9985
+ {
9986
+ "name": "component_klass",
9987
+ "type": "Class",
9988
+ "default": "N/A",
9989
+ "description": "The class to use instead of the default {{#link_to_component}}Primer::Alpha::TreeView::SubTreeNode{{/link_to_component}}"
9990
+ },
9991
+ {
9992
+ "name": "system_arguments",
9993
+ "type": "Hash",
9994
+ "default": "N/A",
9995
+ "description": "These arguments are forwarded to {{#link_to_component}}Primer::Alpha::TreeView::SubTreeNode{{/link_to_component}}, or whatever class is passed as the `component_klass` argument."
9996
+ }
9997
+ ],
9998
+ "return_types": []
9999
+ },
10000
+ {
10001
+ "name": "node_variant",
10002
+ "description": "Returns the value of attribute node_variant.",
10003
+ "parameters": [],
10004
+ "return_types": []
10005
+ }
10006
+ ],
10007
+ "previews": [
10008
+ {
10009
+ "preview_path": "primer/alpha/tree_view/default",
10010
+ "name": "default",
10011
+ "snapshot": "interactive",
10012
+ "skip_rules": {
10013
+ "wont_fix": [
10014
+ "region"
10015
+ ],
10016
+ "will_fix": [
10017
+ "color-contrast"
10018
+ ]
10019
+ }
10020
+ },
10021
+ {
10022
+ "preview_path": "primer/alpha/tree_view/playground",
10023
+ "name": "playground",
10024
+ "snapshot": "false",
10025
+ "skip_rules": {
10026
+ "wont_fix": [
10027
+ "region"
10028
+ ],
10029
+ "will_fix": [
10030
+ "color-contrast"
10031
+ ]
10032
+ }
10033
+ },
10034
+ {
10035
+ "preview_path": "primer/alpha/tree_view/empty",
10036
+ "name": "empty",
10037
+ "snapshot": "interactive",
10038
+ "skip_rules": {
10039
+ "wont_fix": [
10040
+ "region"
10041
+ ],
10042
+ "will_fix": [
10043
+ "color-contrast"
10044
+ ]
10045
+ }
10046
+ },
10047
+ {
10048
+ "preview_path": "primer/alpha/tree_view/loading_failure",
10049
+ "name": "loading_failure",
10050
+ "snapshot": "interactive",
10051
+ "skip_rules": {
10052
+ "wont_fix": [
10053
+ "region"
10054
+ ],
10055
+ "will_fix": [
10056
+ "color-contrast"
10057
+ ]
10058
+ }
10059
+ },
10060
+ {
10061
+ "preview_path": "primer/alpha/tree_view/loading_spinner",
10062
+ "name": "loading_spinner",
10063
+ "snapshot": "interactive",
10064
+ "skip_rules": {
10065
+ "wont_fix": [
10066
+ "region"
10067
+ ],
10068
+ "will_fix": [
10069
+ "color-contrast"
10070
+ ]
10071
+ }
10072
+ },
10073
+ {
10074
+ "preview_path": "primer/alpha/tree_view/loading_skeleton",
10075
+ "name": "loading_skeleton",
10076
+ "snapshot": "interactive",
10077
+ "skip_rules": {
10078
+ "wont_fix": [
10079
+ "region"
10080
+ ],
10081
+ "will_fix": [
10082
+ "color-contrast"
10083
+ ]
10084
+ }
10085
+ },
10086
+ {
10087
+ "preview_path": "primer/alpha/tree_view/async_alpha",
10088
+ "name": "async_alpha",
10089
+ "snapshot": "false",
10090
+ "skip_rules": {
10091
+ "wont_fix": [
10092
+ "region"
10093
+ ],
10094
+ "will_fix": [
10095
+ "color-contrast"
10096
+ ]
10097
+ }
10098
+ },
10099
+ {
10100
+ "preview_path": "primer/alpha/tree_view/leaf_node_playground",
10101
+ "name": "leaf_node_playground",
10102
+ "snapshot": "false",
10103
+ "skip_rules": {
10104
+ "wont_fix": [
10105
+ "region"
10106
+ ],
10107
+ "will_fix": [
10108
+ "color-contrast"
10109
+ ]
10110
+ }
10111
+ },
10112
+ {
10113
+ "preview_path": "primer/alpha/tree_view/links",
10114
+ "name": "links",
10115
+ "snapshot": "false",
10116
+ "skip_rules": {
10117
+ "wont_fix": [
10118
+ "region"
10119
+ ],
10120
+ "will_fix": [
10121
+ "color-contrast"
10122
+ ]
10123
+ }
10124
+ },
10125
+ {
10126
+ "preview_path": "primer/alpha/tree_view/buttons",
10127
+ "name": "buttons",
10128
+ "snapshot": "false",
10129
+ "skip_rules": {
10130
+ "wont_fix": [
10131
+ "region"
10132
+ ],
10133
+ "will_fix": [
10134
+ "color-contrast"
10135
+ ]
10136
+ }
10137
+ },
10138
+ {
10139
+ "preview_path": "primer/alpha/tree_view/auto_expansion",
10140
+ "name": "auto_expansion",
10141
+ "snapshot": "false",
10142
+ "skip_rules": {
10143
+ "wont_fix": [
10144
+ "region"
10145
+ ],
10146
+ "will_fix": [
10147
+ "color-contrast"
10148
+ ]
10149
+ }
10150
+ },
10151
+ {
10152
+ "preview_path": "primer/alpha/tree_view/form_input",
10153
+ "name": "form_input",
10154
+ "snapshot": "false",
10155
+ "skip_rules": {
10156
+ "wont_fix": [
10157
+ "region"
10158
+ ],
10159
+ "will_fix": [
10160
+ "color-contrast"
10161
+ ]
10162
+ }
10163
+ }
10164
+ ],
10165
+ "subcomponents": [
10166
+ {
10167
+ "fully_qualified_name": "Primer::Alpha::TreeView::Visual",
10168
+ "description": "A `TreeView` visual, either leading or trailing.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10169
+ "accessibility_docs": null,
10170
+ "is_form_component": false,
10171
+ "is_published": true,
10172
+ "requires_js": false,
10173
+ "component": "TreeView::Visual",
10174
+ "status": "alpha",
10175
+ "a11y_reviewed": false,
10176
+ "short_name": "TreeViewVisual",
10177
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/visual.rb",
10178
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/visual/default/",
10179
+ "parameters": [
10180
+ {
10181
+ "name": "id",
10182
+ "type": "String",
10183
+ "default": "N/A",
10184
+ "description": "This visual's HTML ID."
10185
+ },
10186
+ {
10187
+ "name": "visual",
10188
+ "type": "ViewComponent::Base",
10189
+ "default": "N/A",
10190
+ "description": "A renderable component like an instance of {{#link_to_component}}Primer::Beta::Octicon{{/link_to_component}} to render as the visual."
10191
+ },
10192
+ {
10193
+ "name": "label",
10194
+ "type": "String",
10195
+ "default": "`nil`",
10196
+ "description": "Text describing this visual that will be visible only to screen readers."
10197
+ }
10198
+ ],
10199
+ "slots": [],
10200
+ "methods": [],
10201
+ "previews": [],
10202
+ "subcomponents": []
10203
+ },
10204
+ {
10205
+ "fully_qualified_name": "Primer::Alpha::TreeView::SubTreeContainer",
10206
+ "description": "This component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10207
+ "accessibility_docs": null,
10208
+ "is_form_component": false,
10209
+ "is_published": true,
10210
+ "requires_js": false,
10211
+ "component": "TreeView::SubTreeContainer",
10212
+ "status": "alpha",
10213
+ "a11y_reviewed": false,
10214
+ "short_name": "TreeViewSubTreeContainer",
10215
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/sub_tree_container.rb",
10216
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/sub_tree_container/default/",
10217
+ "parameters": [
10218
+ {
10219
+ "name": "path",
10220
+ "type": "Array<String>",
10221
+ "default": "N/A",
10222
+ "description": "The path to this node."
10223
+ },
10224
+ {
10225
+ "name": "expanded",
10226
+ "type": "Boolean",
10227
+ "default": "`false`",
10228
+ "description": "Whether or not this sub-tree node renders expanded."
10229
+ },
10230
+ {
10231
+ "name": "system_arguments",
10232
+ "type": "Hash",
10233
+ "default": "N/A",
10234
+ "description": "{{link_to_system_arguments_docs}}"
10235
+ }
10236
+ ],
10237
+ "slots": [],
10238
+ "methods": [
10239
+ {
10240
+ "name": "path",
10241
+ "description": "The path to this node",
10242
+ "parameters": [],
10243
+ "return_types": [
10244
+ "Array<String>"
10245
+ ]
10246
+ },
10247
+ {
10248
+ "name": "expanded",
10249
+ "description": "Whether or not this sub-tree node renders expanded.",
10250
+ "parameters": [],
10251
+ "return_types": [
10252
+ "Boolean"
10253
+ ]
10254
+ },
10255
+ {
10256
+ "name": "expanded?",
10257
+ "description": "Whether or not this sub-tree node renders expanded.",
10258
+ "parameters": [],
10259
+ "return_types": [
10260
+ "Boolean"
10261
+ ]
10262
+ }
10263
+ ],
10264
+ "previews": [],
10265
+ "subcomponents": []
10266
+ },
10267
+ {
10268
+ "fully_qualified_name": "Primer::Alpha::TreeView::SubTree",
10269
+ "description": "A `TreeView` sub-tree.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10270
+ "accessibility_docs": null,
10271
+ "is_form_component": false,
10272
+ "is_published": true,
10273
+ "requires_js": false,
10274
+ "component": "TreeView::SubTree",
10275
+ "status": "alpha",
10276
+ "a11y_reviewed": false,
10277
+ "short_name": "TreeViewSubTree",
10278
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/sub_tree.rb",
10279
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/sub_tree/default/",
10280
+ "parameters": [
10281
+ {
10282
+ "name": "node_variant",
10283
+ "type": "Symbol",
10284
+ "default": "N/A",
10285
+ "description": "The variant to use for this node. One of `:anchor`, `:button`, or `:div`."
10286
+ },
10287
+ {
10288
+ "name": "system_arguments",
10289
+ "type": "Hash",
10290
+ "default": "N/A",
10291
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::SubTreeContainer{{/link_to_component}}."
10292
+ }
10293
+ ],
10294
+ "slots": [
10295
+ {
10296
+ "name": "nodes",
10297
+ "description": null,
10298
+ "parameters": []
10299
+ },
10300
+ {
10301
+ "name": "loader",
10302
+ "description": null,
10303
+ "parameters": []
10304
+ },
10305
+ {
10306
+ "name": "no_items_message",
10307
+ "description": "The message to display if this sub-tree contains no children.",
10308
+ "parameters": []
10309
+ }
10310
+ ],
10311
+ "methods": [
10312
+ {
10313
+ "name": "with_leaf",
10314
+ "description": "Adds an leaf node to the tree. Leaf nodes are nodes that do not have children.",
10315
+ "parameters": [
10316
+ {
10317
+ "name": "component_klass",
10318
+ "type": "Class",
10319
+ "default": "N/A",
10320
+ "description": "The class to use instead of the default {{#link_to_component}}Primer::Alpha::TreeView::LeafNode{{/link_to_component}}"
10321
+ },
10322
+ {
10323
+ "name": "system_arguments",
10324
+ "type": "Hash",
10325
+ "default": "N/A",
10326
+ "description": "These arguments are forwarded to {{#link_to_component}}Primer::Alpha::TreeView::LeafNode{{/link_to_component}}, or whatever class is passed as the `component_klass` argument."
10327
+ }
10328
+ ],
10329
+ "return_types": []
10330
+ },
10331
+ {
10332
+ "name": "with_sub_tree",
10333
+ "description": "Adds a sub-tree node to the tree. Sub-trees are nodes that have children, which can be both leaf nodes and other sub-trees.",
10334
+ "parameters": [
10335
+ {
10336
+ "name": "component_klass",
10337
+ "type": "Class",
10338
+ "default": "N/A",
10339
+ "description": "The class to use instead of the default {{#link_to_component}}Primer::Alpha::TreeView::SubTreeNode{{/link_to_component}}"
10340
+ },
10341
+ {
10342
+ "name": "system_arguments",
10343
+ "type": "Hash",
10344
+ "default": "N/A",
10345
+ "description": "These arguments are forwarded to {{#link_to_component}}Primer::Alpha::TreeView::SubTreeNode{{/link_to_component}}, or whatever class is passed as the `component_klass` argument."
10346
+ }
10347
+ ],
10348
+ "return_types": []
10349
+ },
10350
+ {
10351
+ "name": "with_loading_spinner",
10352
+ "description": "Adds a loader to this sub-tree that displays a skeleton animation while nodes are fetched from the server.",
10353
+ "parameters": [
10354
+ {
10355
+ "name": "system_arguments",
10356
+ "type": "Hash",
10357
+ "default": "N/A",
10358
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::SkeletonLoader{{/link_to_component}}."
10359
+ }
10360
+ ],
10361
+ "return_types": []
10362
+ },
10363
+ {
10364
+ "name": "node_variant",
10365
+ "description": "Returns the value of attribute node_variant.",
10366
+ "parameters": [],
10367
+ "return_types": []
10368
+ }
10369
+ ],
10370
+ "previews": [],
10371
+ "subcomponents": []
10372
+ },
10373
+ {
10374
+ "fully_qualified_name": "Primer::Alpha::TreeView::SpinnerLoader",
10375
+ "description": "Renders a loading spinner for a `TreeView` sub-tree node.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10376
+ "accessibility_docs": null,
10377
+ "is_form_component": false,
10378
+ "is_published": true,
10379
+ "requires_js": false,
10380
+ "component": "TreeView::SpinnerLoader",
10381
+ "status": "alpha",
10382
+ "a11y_reviewed": false,
10383
+ "short_name": "TreeViewSpinnerLoader",
10384
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/spinner_loader.rb",
10385
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/spinner_loader/default/",
10386
+ "parameters": [
10387
+ {
10388
+ "name": "src",
10389
+ "type": "String",
10390
+ "default": "N/A",
10391
+ "description": "The URL to fetch nodes from."
10392
+ },
10393
+ {
10394
+ "name": "system_arguments",
10395
+ "type": "Hash",
10396
+ "default": "N/A",
10397
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::SubTreeContainer{{/link_to_component}}."
10398
+ }
10399
+ ],
10400
+ "slots": [
10401
+ {
10402
+ "name": "loading_failure_message",
10403
+ "description": "The failure message that appears if loading nodes from the server fails.",
10404
+ "parameters": [
10405
+ {
10406
+ "name": "system_arguments",
10407
+ "type": "Hash",
10408
+ "default": "N/A",
10409
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::LoadingFailureMessage{{/link_to_component}}."
10410
+ }
10411
+ ]
10412
+ }
10413
+ ],
10414
+ "methods": [],
10415
+ "previews": [],
10416
+ "subcomponents": []
10417
+ },
10418
+ {
10419
+ "fully_qualified_name": "Primer::Alpha::TreeView::SkeletonLoader",
10420
+ "description": "Renders a loading skeleton for a `TreeView` sub-tree node.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10421
+ "accessibility_docs": null,
10422
+ "is_form_component": false,
10423
+ "is_published": true,
10424
+ "requires_js": false,
10425
+ "component": "TreeView::SkeletonLoader",
10426
+ "status": "alpha",
10427
+ "a11y_reviewed": false,
10428
+ "short_name": "TreeViewSkeletonLoader",
10429
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/skeleton_loader.rb",
10430
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/skeleton_loader/default/",
10431
+ "parameters": [
10432
+ {
10433
+ "name": "src",
10434
+ "type": "String",
10435
+ "default": "N/A",
10436
+ "description": "The URL to fetch nodes from."
10437
+ },
10438
+ {
10439
+ "name": "count",
10440
+ "type": "Integer",
10441
+ "default": "`3`",
10442
+ "description": "The number of skeleton nodes to render."
10443
+ },
10444
+ {
10445
+ "name": "system_arguments",
10446
+ "type": "Hash",
10447
+ "default": "N/A",
10448
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::SubTreeContainer{{/link_to_component}}."
10449
+ }
10450
+ ],
10451
+ "slots": [
10452
+ {
10453
+ "name": "loading_failure_message",
10454
+ "description": "The failure message that appears if loading nodes from the server fails.",
10455
+ "parameters": [
10456
+ {
10457
+ "name": "system_arguments",
10458
+ "type": "Hash",
10459
+ "default": "N/A",
10460
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::LoadingFailureMessage{{/link_to_component}}."
10461
+ }
10462
+ ]
10463
+ }
10464
+ ],
10465
+ "methods": [],
10466
+ "previews": [],
10467
+ "subcomponents": []
10468
+ },
10469
+ {
10470
+ "fully_qualified_name": "Primer::Alpha::TreeView::Node",
10471
+ "description": "A generic `TreeView` node.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10472
+ "accessibility_docs": null,
10473
+ "is_form_component": false,
10474
+ "is_published": true,
10475
+ "requires_js": false,
10476
+ "component": "TreeView::Node",
10477
+ "status": "alpha",
10478
+ "a11y_reviewed": false,
10479
+ "short_name": "TreeViewNode",
10480
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/node.rb",
10481
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/node/default/",
10482
+ "parameters": [
10483
+ {
10484
+ "name": "path",
10485
+ "type": "Array<String>",
10486
+ "default": "N/A",
10487
+ "description": "The node's \"path,\" i.e. this node's label and the labels of all its ancestors. This node should be reachable by traversing the tree following this path."
10488
+ },
10489
+ {
10490
+ "name": "node_variant",
10491
+ "type": "Symbol",
10492
+ "default": "N/A",
10493
+ "description": "The node variant to use for the node's content, i.e. the `:button` or `:div`. One of `:anchor`, `:button`, or `:div`."
10494
+ },
10495
+ {
10496
+ "name": "href",
10497
+ "type": "String",
10498
+ "default": "`nil`",
10499
+ "description": "The URL to use as the `href` attribute for this node. If set to a truthy value, the `tag:` parameter is ignored and assumed to be `:a`."
10500
+ },
10501
+ {
10502
+ "name": "current",
10503
+ "type": "Boolean",
10504
+ "default": "`false`",
10505
+ "description": "Whether or not this node is the current node. The current node is styled differently than regular nodes and is the first element that receives focus when tabbing to the `TreeView` component."
10506
+ },
10507
+ {
10508
+ "name": "select_variant",
10509
+ "type": "Symbol",
10510
+ "default": "`:none`",
10511
+ "description": "Controls the type of checkbox that appears. One of `:multiple` or `:none`."
10512
+ },
10513
+ {
10514
+ "name": "checked",
10515
+ "type": "Boolean | String",
10516
+ "default": "`false`",
10517
+ "description": "The checked state of the node's checkbox. One of `false`, `mixed`, or `true`."
10518
+ },
10519
+ {
10520
+ "name": "disabled",
10521
+ "type": "Boolean",
10522
+ "default": "`false`",
10523
+ "description": "Whether or not the node can be activated. Passing `false` here will cause the node to appear visually disabled but it is still keyboard-focusable."
10524
+ },
10525
+ {
10526
+ "name": "value",
10527
+ "type": "String",
10528
+ "default": "`nil`",
10529
+ "description": "If this node is checked, this value will be sent to the server on form submission."
10530
+ },
10531
+ {
10532
+ "name": "content_arguments",
10533
+ "type": "Hash",
10534
+ "default": "N/A",
10535
+ "description": "Arguments attached to the node's content, i.e the `<button>` or `<a>` element. {{link_to_system_arguments_docs}}"
10536
+ }
10537
+ ],
10538
+ "slots": [
10539
+ {
10540
+ "name": "leading_action",
10541
+ "description": "Generic leading action slot",
10542
+ "parameters": []
10543
+ },
10544
+ {
10545
+ "name": "leading_visual",
10546
+ "description": "Generic leading visual slot",
10547
+ "parameters": []
10548
+ },
10549
+ {
10550
+ "name": "trailing_visual",
10551
+ "description": "Generic trailing visual slot",
10552
+ "parameters": []
10553
+ },
10554
+ {
10555
+ "name": "toggle",
10556
+ "description": "Generic toggle button slot",
10557
+ "parameters": []
10558
+ },
10559
+ {
10560
+ "name": "text_content",
10561
+ "description": "Generic text content slot (for node's label)",
10562
+ "parameters": []
10563
+ }
10564
+ ],
10565
+ "methods": [
10566
+ {
10567
+ "name": "current",
10568
+ "description": "Wether or not this node is the current node.",
10569
+ "parameters": [],
10570
+ "return_types": [
10571
+ "Boolean"
10572
+ ]
10573
+ },
10574
+ {
10575
+ "name": "current?",
10576
+ "description": "Wether or not this node is the current node.",
10577
+ "parameters": [],
10578
+ "return_types": [
10579
+ "Boolean"
10580
+ ]
10581
+ },
10582
+ {
10583
+ "name": "checked",
10584
+ "description": "This node's checked state.",
10585
+ "parameters": [],
10586
+ "return_types": [
10587
+ "String"
10588
+ ]
10589
+ },
10590
+ {
10591
+ "name": "select_variant",
10592
+ "description": "This node's select variant (i.e. check box variant).",
10593
+ "parameters": [],
10594
+ "return_types": [
10595
+ "Symbol"
10596
+ ]
10597
+ },
10598
+ {
10599
+ "name": "node_variant",
10600
+ "description": "This node's variant, eg. `:button`, `:div`, etc.",
10601
+ "parameters": [],
10602
+ "return_types": [
10603
+ "Symbol"
10604
+ ]
10605
+ },
10606
+ {
10607
+ "name": "disabled",
10608
+ "description": "Whether or not this node is disabled, i.e. cannot be activated.",
10609
+ "parameters": [],
10610
+ "return_types": [
10611
+ "Boolean"
10612
+ ]
10613
+ },
10614
+ {
10615
+ "name": "disabled?",
10616
+ "description": "Whether or not this node is disabled, i.e. cannot be activated.",
10617
+ "parameters": [],
10618
+ "return_types": [
10619
+ "Boolean"
10620
+ ]
10621
+ },
10622
+ {
10623
+ "name": "level",
10624
+ "description": "The numeric depth of this node.",
10625
+ "parameters": [],
10626
+ "return_types": [
10627
+ "Integer"
10628
+ ]
10629
+ },
10630
+ {
10631
+ "name": "merge_system_arguments!",
10632
+ "description": "Merges the given arguments into the current hash of system arguments provided when the component was\ninitially constructed. This method can be used to add additional arguments just before rendering.",
10633
+ "parameters": [
10634
+ {
10635
+ "name": "other_arguments",
10636
+ "type": "Hash",
10637
+ "default": "N/A",
10638
+ "description": "The other hash of system arguments to merge into the current one."
10639
+ }
10640
+ ],
10641
+ "return_types": []
10642
+ }
10643
+ ],
10644
+ "previews": [],
10645
+ "subcomponents": []
10646
+ },
10647
+ {
10648
+ "fully_qualified_name": "Primer::Alpha::TreeView::LoadingFailureMessage",
10649
+ "description": "A `TreeView` loading failure message.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10650
+ "accessibility_docs": null,
10651
+ "is_form_component": false,
10652
+ "is_published": true,
10653
+ "requires_js": false,
10654
+ "component": "TreeView::LoadingFailureMessage",
10655
+ "status": "alpha",
10656
+ "a11y_reviewed": false,
10657
+ "short_name": "TreeViewLoadingFailureMessage",
10658
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/loading_failure_message.rb",
10659
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/loading_failure_message/default/",
10660
+ "parameters": [
10661
+ {
10662
+ "name": "text",
10663
+ "type": "String",
10664
+ "default": "`Something went wrong`",
10665
+ "description": "The failure message to display."
10666
+ },
10667
+ {
10668
+ "name": "retry_button_label",
10669
+ "type": "String",
10670
+ "default": "`Retry`",
10671
+ "description": "The text shown on the retry button."
10672
+ },
10673
+ {
10674
+ "name": "system_arguments",
10675
+ "type": "Hash",
10676
+ "default": "N/A",
10677
+ "description": "{{link_to_system_arguments_docs}}"
10678
+ }
10679
+ ],
10680
+ "slots": [],
10681
+ "methods": [],
10682
+ "previews": [],
10683
+ "subcomponents": []
10684
+ },
10685
+ {
10686
+ "fully_qualified_name": "Primer::Alpha::TreeView::LeadingAction",
10687
+ "description": "The leading action for `TreeView` nodes.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10688
+ "accessibility_docs": null,
10689
+ "is_form_component": false,
10690
+ "is_published": true,
10691
+ "requires_js": false,
10692
+ "component": "TreeView::LeadingAction",
10693
+ "status": "alpha",
10694
+ "a11y_reviewed": false,
10695
+ "short_name": "TreeViewLeadingAction",
10696
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/leading_action.rb",
10697
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/leading_action/default/",
10698
+ "parameters": [
10699
+ {
10700
+ "name": "action",
10701
+ "type": "ViewComponent::Base",
10702
+ "default": "N/A",
10703
+ "description": "A component or other renderable to use as the action button etc."
10704
+ }
10705
+ ],
10706
+ "slots": [],
10707
+ "methods": [],
10708
+ "previews": [],
10709
+ "subcomponents": []
10710
+ },
10711
+ {
10712
+ "fully_qualified_name": "Primer::Alpha::TreeView::IconPair",
10713
+ "description": "A pair of icons for a `TreeView` sub-tree that displays distinct icons when the sub-tree is\nexpanded and collapsed.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10714
+ "accessibility_docs": null,
10715
+ "is_form_component": false,
10716
+ "is_published": true,
10717
+ "requires_js": false,
10718
+ "component": "TreeView::IconPair",
10719
+ "status": "alpha",
10720
+ "a11y_reviewed": false,
10721
+ "short_name": "TreeViewIconPair",
10722
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/icon_pair.rb",
10723
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/icon_pair/default/",
10724
+ "parameters": [
10725
+ {
10726
+ "name": "expanded",
10727
+ "type": "Boolean",
10728
+ "default": "`false`",
10729
+ "description": "If true, the expanded icon is shown and the collapsed icon is hidden, etc."
10730
+ },
10731
+ {
10732
+ "name": "system_arguments",
10733
+ "type": "Hash",
10734
+ "default": "N/A",
10735
+ "description": "{{link_to_system_arguments_docs}}"
10736
+ }
10737
+ ],
10738
+ "slots": [
10739
+ {
10740
+ "name": "expanded_icon",
10741
+ "description": "The expanded icon.",
10742
+ "parameters": [
10743
+ {
10744
+ "name": "system_arguments",
10745
+ "type": "Hash",
10746
+ "default": "N/A",
10747
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::Icon{{/link_to_component}}."
10748
+ }
10749
+ ]
10750
+ },
10751
+ {
10752
+ "name": "collapsed_icon",
10753
+ "description": "The collapsed icon.",
10754
+ "parameters": [
10755
+ {
10756
+ "name": "system_arguments",
10757
+ "type": "Hash",
10758
+ "default": "N/A",
10759
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::Icon{{/link_to_component}}."
10760
+ }
10761
+ ]
10762
+ }
10763
+ ],
10764
+ "methods": [
10765
+ {
10766
+ "name": "expanded",
10767
+ "description": "Whether or not this icon is expanded.",
10768
+ "parameters": [],
10769
+ "return_types": [
10770
+ "Boolean"
10771
+ ]
10772
+ },
10773
+ {
10774
+ "name": "expanded?",
10775
+ "description": "Whether or not this icon is expanded.",
10776
+ "parameters": [],
10777
+ "return_types": [
10778
+ "Boolean"
10779
+ ]
10780
+ }
10781
+ ],
10782
+ "previews": [],
10783
+ "subcomponents": []
10784
+ },
10785
+ {
10786
+ "fully_qualified_name": "Primer::Alpha::TreeView::Icon",
10787
+ "description": "An icon for a `TreeView` node.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10788
+ "accessibility_docs": null,
10789
+ "is_form_component": false,
10790
+ "is_published": true,
10791
+ "requires_js": false,
10792
+ "component": "TreeView::Icon",
10793
+ "status": "alpha",
10794
+ "a11y_reviewed": false,
10795
+ "short_name": "TreeViewIcon",
10796
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/icon.rb",
10797
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/icon/default/",
10798
+ "parameters": [
10799
+ {
10800
+ "name": "system_arguments",
10801
+ "type": "Hash",
10802
+ "default": "N/A",
10803
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Beta::Octicon{{/link_to_component}}."
10804
+ }
10805
+ ],
10806
+ "slots": [],
10807
+ "methods": [],
10808
+ "previews": [],
10809
+ "subcomponents": []
10810
+ },
10811
+ {
10812
+ "fully_qualified_name": "Primer::Alpha::TreeView::LeafNode",
10813
+ "description": "A `TreeView` leaf node.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10814
+ "accessibility_docs": null,
10815
+ "is_form_component": false,
10816
+ "is_published": true,
10817
+ "requires_js": false,
10818
+ "component": "TreeView::LeafNode",
10819
+ "status": "alpha",
10820
+ "a11y_reviewed": false,
10821
+ "short_name": "TreeViewLeafNode",
10822
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/leaf_node.rb",
10823
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/leaf_node/default/",
10824
+ "parameters": [
10825
+ {
10826
+ "name": "label",
10827
+ "type": "String",
10828
+ "default": "N/A",
10829
+ "description": "The node's label, i.e. it's textual content."
10830
+ },
10831
+ {
10832
+ "name": "system_arguments",
10833
+ "type": "Hash",
10834
+ "default": "N/A",
10835
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::Node{{/link_to_component}}."
10836
+ }
10837
+ ],
10838
+ "slots": [
10839
+ {
10840
+ "name": "leading_visual",
10841
+ "description": null,
10842
+ "parameters": []
10843
+ },
10844
+ {
10845
+ "name": "leading_action",
10846
+ "description": null,
10847
+ "parameters": []
10848
+ },
10849
+ {
10850
+ "name": "trailing_visual",
10851
+ "description": null,
10852
+ "parameters": []
10853
+ }
10854
+ ],
10855
+ "methods": [
10856
+ {
10857
+ "name": "with_leading_visual_icon",
10858
+ "description": "Adds a leading visual icon rendered to the left of the node's label.",
10859
+ "parameters": [
10860
+ {
10861
+ "name": "label",
10862
+ "type": "String",
10863
+ "default": "`nil`",
10864
+ "description": "A label describing the visual, displayed only to screen readers."
10865
+ },
10866
+ {
10867
+ "name": "system_arguments",
10868
+ "type": "Hash",
10869
+ "default": "N/A",
10870
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::Icon{{/link_to_component}}."
10871
+ }
10872
+ ],
10873
+ "return_types": []
10874
+ },
10875
+ {
10876
+ "name": "with_leading_action_button",
10877
+ "description": "Adds a leading action rendered to the left of the node's label and any leading visuals or checkboxes.",
10878
+ "parameters": [
10879
+ {
10880
+ "name": "system_arguments",
10881
+ "type": "Hash",
10882
+ "default": "N/A",
10883
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Beta::IconButton{{/link_to_component}}."
10884
+ }
10885
+ ],
10886
+ "return_types": []
10887
+ },
10888
+ {
10889
+ "name": "with_trailing_visual_icon",
10890
+ "description": "Adds a trailing visual icon rendered to the right of the node's label.",
10891
+ "parameters": [
10892
+ {
10893
+ "name": "label",
10894
+ "type": "String",
10895
+ "default": "`nil`",
10896
+ "description": "A label describing the visual, displayed only to screen readers."
10897
+ },
10898
+ {
10899
+ "name": "system_arguments",
10900
+ "type": "Hash",
10901
+ "default": "N/A",
10902
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::Icon{{/link_to_component}}."
10903
+ }
10904
+ ],
10905
+ "return_types": []
10906
+ }
10907
+ ],
10908
+ "previews": [],
10909
+ "subcomponents": []
10910
+ },
10911
+ {
10912
+ "fully_qualified_name": "Primer::Alpha::TreeView::SubTreeNode",
10913
+ "description": "A `TreeView` sub-tree node.\n\nThis component is part of the {{#link_to_component}}Primer::Alpha::TreeView{{/link_to_component}} component and should\nnot be used directly.",
10914
+ "accessibility_docs": null,
10915
+ "is_form_component": false,
10916
+ "is_published": true,
10917
+ "requires_js": false,
10918
+ "component": "TreeView::SubTreeNode",
10919
+ "status": "alpha",
10920
+ "a11y_reviewed": false,
10921
+ "short_name": "TreeViewSubTreeNode",
10922
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/tree_view/sub_tree_node.rb",
10923
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/tree_view/sub_tree_node/default/",
10924
+ "parameters": [
10925
+ {
10926
+ "name": "label",
10927
+ "type": "String",
10928
+ "default": "N/A",
10929
+ "description": "The node's label, i.e. it's textual content."
10930
+ },
10931
+ {
10932
+ "name": "path",
10933
+ "type": "Array<String>",
10934
+ "default": "N/A",
10935
+ "description": "The node's \"path,\" i.e. this node's label and the labels of all its ancestors. This node should be reachable by traversing the tree following this path."
10936
+ },
10937
+ {
10938
+ "name": "node_variant",
10939
+ "type": "Symbol",
10940
+ "default": "N/A",
10941
+ "description": "The variant to use for this node. One of `:anchor`, `:button`, or `:div`."
10942
+ },
10943
+ {
10944
+ "name": "sub_tree_component_klass",
10945
+ "type": "Class",
10946
+ "default": "`SubTree`",
10947
+ "description": "The class to use for the sub-tree instead of the default {{#link_to_component}}Primer::Alpha::TreeView::SubTree{{/link_to_component}}"
10948
+ },
10949
+ {
10950
+ "name": "expanded",
10951
+ "type": "Boolean",
10952
+ "default": "`false`",
10953
+ "description": "Whether or not this sub-tree should be rendered expanded."
10954
+ },
10955
+ {
10956
+ "name": "select_strategy",
10957
+ "type": "Symbol",
10958
+ "default": "`:mixed_descendants`",
10959
+ "description": "What should happen when this sub-tree node is checked. One of `:descendants`, `:mixed_descendants`, or `:self`."
10960
+ },
10961
+ {
10962
+ "name": "system_arguments",
10963
+ "type": "Hash",
10964
+ "default": "N/A",
10965
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::Node{{/link_to_component}}."
10966
+ }
10967
+ ],
10968
+ "slots": [
10969
+ {
10970
+ "name": "leading_visual",
10971
+ "description": null,
10972
+ "parameters": []
10973
+ },
10974
+ {
10975
+ "name": "leading_action",
10976
+ "description": null,
10977
+ "parameters": []
10978
+ },
10979
+ {
10980
+ "name": "trailing_visual",
10981
+ "description": null,
10982
+ "parameters": []
10983
+ }
10984
+ ],
10985
+ "methods": [
10986
+ {
10987
+ "name": "with_leading_visual_icon",
10988
+ "description": "Adds a leading visual icon rendered to the left of the node's label.",
10989
+ "parameters": [
10990
+ {
10991
+ "name": "label",
10992
+ "type": "String",
10993
+ "default": "`nil`",
10994
+ "description": "A label describing the visual, displayed only to screen readers."
10995
+ },
10996
+ {
10997
+ "name": "system_arguments",
10998
+ "type": "Hash",
10999
+ "default": "N/A",
11000
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::Icon{{/link_to_component}}."
11001
+ }
11002
+ ],
11003
+ "return_types": []
11004
+ },
11005
+ {
11006
+ "name": "with_leading_visual_icons",
11007
+ "description": "Adds a pair of leading visual icon rendered to the left of the node's label.",
11008
+ "parameters": [
11009
+ {
11010
+ "name": "label",
11011
+ "type": "String",
11012
+ "default": "`nil`",
11013
+ "description": "A label describing the visual, displayed only to screen readers."
11014
+ },
11015
+ {
11016
+ "name": "system_arguments",
11017
+ "type": "Hash",
11018
+ "default": "N/A",
11019
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::IconPair{{/link_to_component}}."
11020
+ }
11021
+ ],
11022
+ "return_types": []
11023
+ },
11024
+ {
11025
+ "name": "with_leading_action_button",
11026
+ "description": "Adds a leading action rendered to the left of the node's label and any leading visuals or checkboxes.",
11027
+ "parameters": [
11028
+ {
11029
+ "name": "system_arguments",
11030
+ "type": "Hash",
11031
+ "default": "N/A",
11032
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Beta::IconButton{{/link_to_component}}."
11033
+ }
11034
+ ],
11035
+ "return_types": []
11036
+ },
11037
+ {
11038
+ "name": "with_trailing_visual_icon",
11039
+ "description": "Adds a trailing visual icon rendered to the right of the node's label.",
11040
+ "parameters": [
11041
+ {
11042
+ "name": "label",
11043
+ "type": "String",
11044
+ "default": "`nil`",
11045
+ "description": "A label describing the visual, displayed only to screen readers."
11046
+ },
11047
+ {
11048
+ "name": "system_arguments",
11049
+ "type": "Hash",
11050
+ "default": "N/A",
11051
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::TreeView::Icon{{/link_to_component}}."
11052
+ }
11053
+ ],
11054
+ "return_types": []
11055
+ }
11056
+ ],
11057
+ "previews": [],
11058
+ "subcomponents": []
11059
+ }
11060
+ ]
11061
+ },
9714
11062
  {
9715
11063
  "fully_qualified_name": "Primer::Alpha::UnderlineNav",
9716
11064
  "description": "Use `UnderlineNav` to style navigation links with a minimal\nunderlined selected state, typically placed at the top\nof the page.\n\nFor panel navigation, use {{#link_to_component}}Primer::Alpha::UnderlinePanels{{/link_to_component}} instead.",