primer_view_components 0.1.6 → 0.1.8

Sign up to get free protection for your applications and to get access to all the features.
Files changed (137) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +22 -0
  3. data/app/assets/javascripts/primer_view_components.js +1 -1
  4. data/app/assets/javascripts/primer_view_components.js.map +1 -1
  5. data/app/assets/styles/primer_view_components.css +3 -3
  6. data/app/assets/styles/primer_view_components.css.map +1 -1
  7. data/app/components/primer/alpha/action_list/divider.rb +1 -1
  8. data/app/components/primer/alpha/action_list/form_wrapper.html.erb +10 -0
  9. data/app/components/primer/alpha/action_list/form_wrapper.rb +61 -0
  10. data/app/components/primer/alpha/action_list/heading.html.erb +2 -2
  11. data/app/components/primer/alpha/action_list/heading.rb +9 -5
  12. data/app/components/primer/alpha/action_list/item.html.erb +41 -36
  13. data/app/components/primer/alpha/action_list/item.rb +16 -2
  14. data/app/components/primer/alpha/action_list.css +1 -1
  15. data/app/components/primer/alpha/action_list.css.json +1 -0
  16. data/app/components/primer/alpha/action_list.css.map +1 -1
  17. data/app/components/primer/alpha/action_list.html.erb +6 -0
  18. data/app/components/primer/alpha/action_list.pcss +42 -37
  19. data/app/components/primer/alpha/action_list.rb +31 -11
  20. data/app/components/primer/alpha/action_menu/action_menu_element.d.ts +7 -1
  21. data/app/components/primer/alpha/action_menu/action_menu_element.js +55 -3
  22. data/app/components/primer/alpha/action_menu/action_menu_element.ts +70 -2
  23. data/app/components/primer/alpha/action_menu/list.rb +9 -11
  24. data/app/components/primer/alpha/action_menu.rb +50 -12
  25. data/app/components/primer/alpha/auto_complete.css +1 -1
  26. data/app/components/primer/alpha/auto_complete.css.map +1 -1
  27. data/app/components/primer/alpha/auto_complete.pcss +2 -2
  28. data/app/components/primer/alpha/banner.css +1 -1
  29. data/app/components/primer/alpha/banner.css.map +1 -1
  30. data/app/components/primer/alpha/banner.pcss +7 -7
  31. data/app/components/primer/alpha/dialog.css +1 -1
  32. data/app/components/primer/alpha/dialog.css.map +1 -1
  33. data/app/components/primer/alpha/dialog.pcss +33 -32
  34. data/app/components/primer/alpha/dialog.rb +4 -0
  35. data/app/components/primer/alpha/dropdown.css +1 -1
  36. data/app/components/primer/alpha/dropdown.css.map +1 -1
  37. data/app/components/primer/alpha/dropdown.pcss +12 -11
  38. data/app/components/primer/alpha/layout.css +1 -1
  39. data/app/components/primer/alpha/layout.css.map +1 -1
  40. data/app/components/primer/alpha/layout.pcss +4 -4
  41. data/app/components/primer/alpha/menu.css +1 -1
  42. data/app/components/primer/alpha/menu.css.map +1 -1
  43. data/app/components/primer/alpha/menu.pcss +20 -20
  44. data/app/components/primer/alpha/nav_list/divider.rb +14 -0
  45. data/app/components/primer/alpha/nav_list/group.html.erb +7 -0
  46. data/app/components/primer/alpha/nav_list/group.rb +24 -11
  47. data/app/components/primer/alpha/nav_list/item.rb +4 -0
  48. data/app/components/primer/alpha/nav_list.d.ts +0 -1
  49. data/app/components/primer/alpha/nav_list.html.erb +9 -4
  50. data/app/components/primer/alpha/nav_list.js +3 -4
  51. data/app/components/primer/alpha/nav_list.rb +87 -10
  52. data/app/components/primer/alpha/nav_list.ts +3 -2
  53. data/app/components/primer/alpha/segmented_control.css +1 -1
  54. data/app/components/primer/alpha/segmented_control.css.json +2 -2
  55. data/app/components/primer/alpha/segmented_control.css.map +1 -1
  56. data/app/components/primer/alpha/segmented_control.pcss +34 -43
  57. data/app/components/primer/alpha/tab_nav.css +1 -1
  58. data/app/components/primer/alpha/tab_nav.css.map +1 -1
  59. data/app/components/primer/alpha/tab_nav.pcss +12 -12
  60. data/app/components/primer/alpha/text_field.css +3 -3
  61. data/app/components/primer/alpha/text_field.css.json +11 -11
  62. data/app/components/primer/alpha/text_field.css.map +1 -1
  63. data/app/components/primer/alpha/text_field.pcss +76 -90
  64. data/app/components/primer/alpha/toggle_switch.css +1 -1
  65. data/app/components/primer/alpha/toggle_switch.css.map +1 -1
  66. data/app/components/primer/alpha/toggle_switch.pcss +9 -9
  67. data/app/components/primer/alpha/underline_nav.css +1 -1
  68. data/app/components/primer/alpha/underline_nav.css.map +1 -1
  69. data/app/components/primer/alpha/underline_nav.pcss +7 -7
  70. data/app/components/primer/beta/auto_complete/item.html.erb +9 -9
  71. data/app/components/primer/beta/auto_complete/item.rb +17 -13
  72. data/app/components/primer/beta/auto_complete.rb +1 -1
  73. data/app/components/primer/beta/avatar.css +1 -1
  74. data/app/components/primer/beta/avatar.css.map +1 -1
  75. data/app/components/primer/beta/avatar.pcss +2 -2
  76. data/app/components/primer/beta/avatar_stack.css +1 -1
  77. data/app/components/primer/beta/avatar_stack.css.map +1 -1
  78. data/app/components/primer/beta/avatar_stack.pcss +5 -5
  79. data/app/components/primer/beta/blankslate.css +1 -1
  80. data/app/components/primer/beta/blankslate.css.map +1 -1
  81. data/app/components/primer/beta/blankslate.pcss +13 -13
  82. data/app/components/primer/beta/border_box.css +1 -1
  83. data/app/components/primer/beta/border_box.css.json +1 -1
  84. data/app/components/primer/beta/border_box.css.map +1 -1
  85. data/app/components/primer/beta/border_box.pcss +41 -39
  86. data/app/components/primer/beta/button.css +1 -1
  87. data/app/components/primer/beta/button.css.json +2 -0
  88. data/app/components/primer/beta/button.css.map +1 -1
  89. data/app/components/primer/beta/button.pcss +34 -25
  90. data/app/components/primer/beta/counter.css +1 -1
  91. data/app/components/primer/beta/counter.css.map +1 -1
  92. data/app/components/primer/beta/counter.pcss +3 -3
  93. data/app/components/primer/beta/flash.css +1 -1
  94. data/app/components/primer/beta/flash.css.map +1 -1
  95. data/app/components/primer/beta/flash.pcss +10 -11
  96. data/app/components/primer/beta/label.css +1 -1
  97. data/app/components/primer/beta/label.css.map +1 -1
  98. data/app/components/primer/beta/label.pcss +2 -2
  99. data/app/components/primer/beta/popover.css +1 -1
  100. data/app/components/primer/beta/popover.css.map +1 -1
  101. data/app/components/primer/beta/popover.pcss +4 -4
  102. data/app/components/primer/beta/state.css +1 -1
  103. data/app/components/primer/beta/state.css.map +1 -1
  104. data/app/components/primer/beta/state.pcss +5 -5
  105. data/app/components/primer/beta/subhead.css +1 -1
  106. data/app/components/primer/beta/subhead.css.map +1 -1
  107. data/app/components/primer/beta/subhead.pcss +4 -4
  108. data/app/components/primer/beta/timeline_item.css +1 -1
  109. data/app/components/primer/beta/timeline_item.css.map +1 -1
  110. data/app/components/primer/beta/timeline_item.pcss +13 -13
  111. data/app/components/primer/beta/truncate.css +1 -1
  112. data/app/components/primer/beta/truncate.css.map +1 -1
  113. data/app/components/primer/beta/truncate.pcss +1 -1
  114. data/app/components/primer/component.rb +3 -96
  115. data/app/lib/primer/attributes_helper.rb +105 -0
  116. data/lib/postcss_mixins/activeIndicatorLine.pcss +1 -1
  117. data/lib/primer/forms/text_field.rb +6 -0
  118. data/lib/primer/view_components/linters/disallow_component_css_counter.rb +1 -1
  119. data/lib/primer/view_components/version.rb +1 -1
  120. data/lib/primer/yard/component_manifest.rb +1 -0
  121. data/previews/primer/alpha/action_menu_preview/multiple_select_form.html.erb +13 -0
  122. data/previews/primer/alpha/action_menu_preview/single_select_form.html.erb +13 -0
  123. data/previews/primer/alpha/action_menu_preview/submitting_forms.html.erb +15 -0
  124. data/previews/primer/alpha/action_menu_preview.rb +46 -2
  125. data/previews/primer/alpha/nav_list_preview/trailing_action.html.erb +10 -10
  126. data/previews/primer/alpha/nav_list_preview.rb +37 -16
  127. data/previews/primer/beta/button_preview/trailing_counter.html.erb +11 -0
  128. data/previews/primer/beta/button_preview.rb +15 -0
  129. data/previews/primer/box_preview.rb +28 -0
  130. data/static/arguments.json +59 -14
  131. data/static/audited_at.json +2 -0
  132. data/static/classes.json +3 -0
  133. data/static/constants.json +21 -1
  134. data/static/info_arch.json +238 -36
  135. data/static/previews.json +58 -0
  136. data/static/statuses.json +2 -0
  137. metadata +12 -2
@@ -45,6 +45,12 @@
45
45
  "default": "`:none`",
46
46
  "description": "How items may be selected in the list. One of `:multiple`, `:multiple_checkbox`, `:none`, or `:single`."
47
47
  },
48
+ {
49
+ "name": "form_arguments",
50
+ "type": "Hash",
51
+ "default": "`{}`",
52
+ "description": "Allows an `ActionList` to act as a select list in multi- and single-select modes. 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. *NOTE*: Consider using an {{#link_to_component}}Primer::Alpha::ActionMenu{{/link_to_component}} instead of using this feature directly."
53
+ },
48
54
  {
49
55
  "name": "system_arguments",
50
56
  "type": "Hash",
@@ -91,6 +97,13 @@
91
97
  }
92
98
  ]
93
99
  },
100
+ {
101
+ "name": "id",
102
+ "description": "Returns the value of attribute id.",
103
+ "parameters": [
104
+
105
+ ]
106
+ },
94
107
  {
95
108
  "name": "select_variant",
96
109
  "description": "Returns the value of attribute select_variant.",
@@ -103,6 +116,13 @@
103
116
  "description": "Returns the value of attribute role.",
104
117
  "parameters": [
105
118
 
119
+ ]
120
+ },
121
+ {
122
+ "name": "post_list_content_block",
123
+ "description": "Returns the value of attribute post_list_content_block.",
124
+ "parameters": [
125
+
106
126
  ]
107
127
  }
108
128
  ],
@@ -260,6 +280,12 @@
260
280
  "default": "`{}`",
261
281
  "description": "{{link_to_system_arguments_docs}} used to construct the item's anchor or button tag."
262
282
  },
283
+ {
284
+ "name": "form_arguments",
285
+ "type": "Hash",
286
+ "default": "`{}`",
287
+ "description": "Allows the item to submit a form on click. The URL passed in the `href:` option will be used as the form action. Pass the `method:` option to this hash to control what kind of request is made, One of `:delete`, `:get`, `:head`, `:patch`, `:post`, or `:put`. The `name:` option is required and specifies the desired name of the field that will be included in the params sent to the server on form submission. Specify the `value:` option to send a custom value to the server; otherwise the value of `name:` is sent."
288
+ },
263
289
  {
264
290
  "name": "truncate_label",
265
291
  "type": "Boolean",
@@ -455,12 +481,6 @@
455
481
  "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/action_list/heading.rb",
456
482
  "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/action_list/heading/default/",
457
483
  "parameters": [
458
- {
459
- "name": "id",
460
- "type": "String",
461
- "default": "`self.class.generate_id`",
462
- "description": "The group's identifier (ID attribute in HTML)."
463
- },
464
484
  {
465
485
  "name": "title",
466
486
  "type": "String",
@@ -485,12 +505,6 @@
485
505
  "default": "`:subtle`",
486
506
  "description": "Display a background color if scheme is `filled`."
487
507
  },
488
- {
489
- "name": "tag",
490
- "type": "Integer",
491
- "default": "N/A",
492
- "description": "Semantic tag for the heading."
493
- },
494
508
  {
495
509
  "name": "system_arguments",
496
510
  "type": "Hash",
@@ -503,8 +517,15 @@
503
517
  ],
504
518
  "methods": [
505
519
  {
506
- "name": "id",
507
- "description": "Returns the value of attribute id.",
520
+ "name": "title_id",
521
+ "description": "Returns the value of attribute title_id.",
522
+ "parameters": [
523
+
524
+ ]
525
+ },
526
+ {
527
+ "name": "subtitle_id",
528
+ "description": "Returns the value of attribute subtitle_id.",
508
529
  "parameters": [
509
530
 
510
531
  ]
@@ -517,9 +538,34 @@
517
538
 
518
539
  ]
519
540
  },
541
+ {
542
+ "fully_qualified_name": "Primer::Alpha::ActionList::FormWrapper",
543
+ "description": "Utility component for wrapping ActionLists or individual ActionList::Items in forms.",
544
+ "component": "ActionList::FormWrapper",
545
+ "status": "alpha",
546
+ "a11y_reviewed": false,
547
+ "short_name": "ActionListFormWrapper",
548
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/action_list/form_wrapper.rb",
549
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/action_list/form_wrapper/default/",
550
+ "parameters": [
551
+
552
+ ],
553
+ "slots": [
554
+
555
+ ],
556
+ "methods": [
557
+
558
+ ],
559
+ "previews": [
560
+
561
+ ],
562
+ "subcomponents": [
563
+
564
+ ]
565
+ },
520
566
  {
521
567
  "fully_qualified_name": "Primer::Alpha::ActionList::Divider",
522
- "description": "Group heading rendered above the group contents.",
568
+ "description": "Separator with optional text rendered above groups or between individual items.",
523
569
  "component": "ActionList::Divider",
524
570
  "status": "alpha",
525
571
  "a11y_reviewed": false,
@@ -557,7 +603,7 @@
557
603
  },
558
604
  {
559
605
  "fully_qualified_name": "Primer::Alpha::ActionMenu",
560
- "description": "The ActionMenu should be used when a user can select a single option triggering an action from a list of items. Primer will automatically nest an `Item` within a presentational `<li>` tag.\n\nThe only allowed elements for the `Item` components are: `:a`, `:button`, and `:clipboard-copy`. If one isn't selected, a fallback `:span` will be used. To add functionality, use a `.js` class to create the functionality, or an `onclick` handler.",
606
+ "description": "ActionMenu is used for actions, navigation, to display secondary options, or single/multi select lists. They appear when users interact with buttons, actions, or other controls.\n\nThe only allowed elements for the `Item` components are: `:a`, `:button`, and `:clipboard-copy`. The default is `:button`.",
561
607
  "component": "ActionMenu",
562
608
  "status": "alpha",
563
609
  "a11y_reviewed": false,
@@ -583,6 +629,12 @@
583
629
  "default": "`:outside_bottom`",
584
630
  "description": "One of `:inside_bottom`, `:inside_center`, `:inside_left`, `:inside_right`, `:inside_top`, `:outside_bottom`, `:outside_left`, `:outside_right`, or `:outside_top`.."
585
631
  },
632
+ {
633
+ "name": "size",
634
+ "type": "Symbol",
635
+ "default": "`:auto`",
636
+ "description": "One of `:auto`, `:large`, `:medium`, `:medium_portrait`, `:small`, or `:xlarge`.."
637
+ },
586
638
  {
587
639
  "name": "src",
588
640
  "type": "String",
@@ -611,7 +663,13 @@
611
663
  "name": "select_variant",
612
664
  "type": "Symbol",
613
665
  "default": "`:none`",
614
- "description": ". One of `:multiple`, `:none`, or `:single`.."
666
+ "description": "One of `:multiple`, `:none`, or `:single`."
667
+ },
668
+ {
669
+ "name": "form_arguments",
670
+ "type": "Hash",
671
+ "default": "`{}`",
672
+ "description": "Allows an `ActionMenu` to act as a select list in multi- and single-select modes. 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."
615
673
  },
616
674
  {
617
675
  "name": "system_arguments",
@@ -621,7 +679,30 @@
621
679
  }
622
680
  ],
623
681
  "slots": [
624
-
682
+ {
683
+ "name": "show_button",
684
+ "description": "Button to activate the menu.",
685
+ "parameters": [
686
+ {
687
+ "name": "system_arguments",
688
+ "type": "Hash",
689
+ "default": "N/A",
690
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::Overlay{{/link_to_component}}'s `show_button` slot."
691
+ }
692
+ ]
693
+ },
694
+ {
695
+ "name": "items",
696
+ "description": "Adds a new item to the list.",
697
+ "parameters": [
698
+ {
699
+ "name": "system_arguments",
700
+ "type": "Hash",
701
+ "default": "N/A",
702
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::ActionList::Item{{/link_to_component}}."
703
+ }
704
+ ]
705
+ }
625
706
  ],
626
707
  "methods": [
627
708
  {
@@ -669,13 +750,6 @@
669
750
  }
670
751
  ]
671
752
  },
672
- {
673
- "name": "items",
674
- "description": "Retrieves the list of items.",
675
- "parameters": [
676
-
677
- ]
678
- },
679
753
  {
680
754
  "name": "with_divider",
681
755
  "description": "Adds a divider to the list.",
@@ -705,6 +779,11 @@
705
779
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/default",
706
780
  "name": "default"
707
781
  },
782
+ {
783
+ "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/wide",
784
+ "preview_path": "/lookbook/preview/primer/alpha/action_menu/wide",
785
+ "name": "wide"
786
+ },
708
787
  {
709
788
  "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/with_icon_button",
710
789
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/with_icon_button",
@@ -755,6 +834,16 @@
755
834
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/with_actions",
756
835
  "name": "with_actions"
757
836
  },
837
+ {
838
+ "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/single_select_form",
839
+ "preview_path": "/lookbook/preview/primer/alpha/action_menu/single_select_form",
840
+ "name": "single_select_form"
841
+ },
842
+ {
843
+ "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/multiple_select_form",
844
+ "preview_path": "/lookbook/preview/primer/alpha/action_menu/multiple_select_form",
845
+ "name": "multiple_select_form"
846
+ },
758
847
  {
759
848
  "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/with_disabled_items",
760
849
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/with_disabled_items",
@@ -775,6 +864,11 @@
775
864
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/block_description",
776
865
  "name": "block_description"
777
866
  },
867
+ {
868
+ "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/submitting_forms",
869
+ "preview_path": "/lookbook/preview/primer/alpha/action_menu/submitting_forms",
870
+ "name": "submitting_forms"
871
+ },
778
872
  {
779
873
  "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/inline_description",
780
874
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/inline_description",
@@ -812,7 +906,7 @@
812
906
  "name": "system_arguments",
813
907
  "type": "Hash",
814
908
  "default": "N/A",
815
- "description": "{{link_to_system_arguments_docs}}"
909
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::ActionList{{/link_to_component}}"
816
910
  }
817
911
  ],
818
912
  "slots": [
@@ -846,6 +940,12 @@
846
940
  "name": "with_item",
847
941
  "description": "Adds a new item to the list.",
848
942
  "parameters": [
943
+ {
944
+ "name": "data",
945
+ "type": "Hash",
946
+ "default": "`{}`",
947
+ "description": "When the menu is used as a form input (see the {{#link_to_component}}Primer::Alpha::ActionMenu{{/link_to_component}} docs), the label is submitted to the server by default. However, if the `data: { value: }` or `\"data-value\":` attribute is provided, it will be sent to the server instead."
948
+ },
849
949
  {
850
950
  "name": "system_arguments",
851
951
  "type": "Hash",
@@ -1611,7 +1711,13 @@
1611
1711
  }
1612
1712
  ],
1613
1713
  "methods": [
1714
+ {
1715
+ "name": "id",
1716
+ "description": "The dialog's ID value.",
1717
+ "parameters": [
1614
1718
 
1719
+ ]
1720
+ }
1615
1721
  ],
1616
1722
  "previews": [
1617
1723
  {
@@ -2817,20 +2923,57 @@
2817
2923
  ],
2818
2924
  "slots": [
2819
2925
  {
2820
- "name": "groups",
2821
- "description": "Groups. Each group is a list of links and an optional heading.",
2926
+ "name": "heading",
2927
+ "description": null,
2928
+ "parameters": [
2929
+
2930
+ ]
2931
+ },
2932
+ {
2933
+ "name": "items",
2934
+ "description": "Items.",
2822
2935
  "parameters": [
2823
2936
  {
2824
2937
  "name": "system_arguments",
2825
2938
  "type": "Hash",
2826
2939
  "default": "N/A",
2827
- "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::NavList::Group{{/link_to_component}}."
2940
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::NavList::Item{{/link_to_component}}."
2828
2941
  }
2829
2942
  ]
2830
2943
  }
2831
2944
  ],
2832
2945
  "methods": [
2946
+ {
2947
+ "name": "with_group",
2948
+ "description": "Groups. Each group is a list of links and a (required) heading.",
2949
+ "parameters": [
2950
+ {
2951
+ "name": "system_arguments",
2952
+ "type": "Hash",
2953
+ "default": "N/A",
2954
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::NavList::Group{{/link_to_component}}."
2955
+ }
2956
+ ]
2957
+ },
2958
+ {
2959
+ "name": "with_divider",
2960
+ "description": "Adds a divider to the list of items.",
2961
+ "parameters": [
2962
+ {
2963
+ "name": "system_arguments",
2964
+ "type": "Hash",
2965
+ "default": "N/A",
2966
+ "description": "The arguments accepted by {{#link_to_component}}Primer::Alpha::ActionList::Divider{{/link_to_component}}."
2967
+ }
2968
+ ]
2969
+ },
2970
+ {
2971
+ "name": "render_outer_list?",
2972
+ "description": "Lists that contain top-level items (i.e. items outside of a group) should be wrapped in a <ul>",
2973
+ "parameters": [
2833
2974
 
2975
+ ]
2976
+ }
2834
2977
  ],
2835
2978
  "previews": [
2836
2979
  {
@@ -2843,6 +2986,11 @@
2843
2986
  "preview_path": "/lookbook/preview/primer/alpha/nav_list/default",
2844
2987
  "name": "default"
2845
2988
  },
2989
+ {
2990
+ "inspect_path": "/lookbook/inspect/primer/alpha/nav_list/top_level_items",
2991
+ "preview_path": "/lookbook/preview/primer/alpha/nav_list/top_level_items",
2992
+ "name": "top_level_items"
2993
+ },
2846
2994
  {
2847
2995
  "inspect_path": "/lookbook/inspect/primer/alpha/nav_list/show_more_item",
2848
2996
  "preview_path": "/lookbook/preview/primer/alpha/nav_list/show_more_item",
@@ -3005,6 +3153,42 @@
3005
3153
 
3006
3154
  ]
3007
3155
  },
3156
+ {
3157
+ "fully_qualified_name": "Primer::Alpha::NavList::Divider",
3158
+ "description": "Separator with optional text rendered above groups or between individual items.",
3159
+ "component": "NavList::Divider",
3160
+ "status": "alpha",
3161
+ "a11y_reviewed": false,
3162
+ "short_name": "NavListDivider",
3163
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/alpha/nav_list/divider.rb",
3164
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/alpha/nav_list/divider/default/",
3165
+ "parameters": [
3166
+ {
3167
+ "name": "scheme",
3168
+ "type": "Symbol",
3169
+ "default": "`:subtle`",
3170
+ "description": "Display a background color if scheme is `filled`."
3171
+ },
3172
+ {
3173
+ "name": "system_arguments",
3174
+ "type": "Hash",
3175
+ "default": "N/A",
3176
+ "description": "{{link_to_system_arguments_docs}}"
3177
+ }
3178
+ ],
3179
+ "slots": [
3180
+
3181
+ ],
3182
+ "methods": [
3183
+
3184
+ ],
3185
+ "previews": [
3186
+
3187
+ ],
3188
+ "subcomponents": [
3189
+
3190
+ ]
3191
+ },
3008
3192
  {
3009
3193
  "fully_qualified_name": "Primer::Alpha::NavList::Group",
3010
3194
  "description": "A logical grouping of navigation links with an optional heading.\n\nSee {{#link_to_component}}Primer::Alpha::NavList{{/link_to_component}} for usage examples.",
@@ -5556,13 +5740,7 @@
5556
5740
  }
5557
5741
  ],
5558
5742
  "methods": [
5559
- {
5560
- "name": "description_variant_class",
5561
- "description": "Description variant class.",
5562
- "parameters": [
5563
5743
 
5564
- ]
5565
- }
5566
5744
  ],
5567
5745
  "previews": [
5568
5746
  {
@@ -6440,6 +6618,11 @@
6440
6618
  "preview_path": "/lookbook/preview/primer/beta/button/trailing_action",
6441
6619
  "name": "trailing_action"
6442
6620
  },
6621
+ {
6622
+ "inspect_path": "/lookbook/inspect/primer/beta/button/trailing_counter",
6623
+ "preview_path": "/lookbook/preview/primer/beta/button/trailing_counter",
6624
+ "name": "trailing_counter"
6625
+ },
6443
6626
  {
6444
6627
  "inspect_path": "/lookbook/inspect/primer/beta/button/with_tooltip",
6445
6628
  "preview_path": "/lookbook/preview/primer/beta/button/with_tooltip",
@@ -8315,7 +8498,26 @@
8315
8498
 
8316
8499
  ],
8317
8500
  "previews": [
8318
-
8501
+ {
8502
+ "inspect_path": "/lookbook/inspect/primer/box/playground",
8503
+ "preview_path": "/lookbook/preview/primer/box/playground",
8504
+ "name": "playground"
8505
+ },
8506
+ {
8507
+ "inspect_path": "/lookbook/inspect/primer/box/default",
8508
+ "preview_path": "/lookbook/preview/primer/box/default",
8509
+ "name": "default"
8510
+ },
8511
+ {
8512
+ "inspect_path": "/lookbook/inspect/primer/box/border",
8513
+ "preview_path": "/lookbook/preview/primer/box/border",
8514
+ "name": "border"
8515
+ },
8516
+ {
8517
+ "inspect_path": "/lookbook/inspect/primer/box/border_bottom",
8518
+ "preview_path": "/lookbook/preview/primer/box/border_bottom",
8519
+ "name": "border_bottom"
8520
+ }
8319
8521
  ],
8320
8522
  "subcomponents": [
8321
8523
 
data/static/previews.json CHANGED
@@ -133,6 +133,11 @@
133
133
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/default",
134
134
  "name": "default"
135
135
  },
136
+ {
137
+ "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/wide",
138
+ "preview_path": "/lookbook/preview/primer/alpha/action_menu/wide",
139
+ "name": "wide"
140
+ },
136
141
  {
137
142
  "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/with_icon_button",
138
143
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/with_icon_button",
@@ -183,6 +188,16 @@
183
188
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/with_actions",
184
189
  "name": "with_actions"
185
190
  },
191
+ {
192
+ "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/single_select_form",
193
+ "preview_path": "/lookbook/preview/primer/alpha/action_menu/single_select_form",
194
+ "name": "single_select_form"
195
+ },
196
+ {
197
+ "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/multiple_select_form",
198
+ "preview_path": "/lookbook/preview/primer/alpha/action_menu/multiple_select_form",
199
+ "name": "multiple_select_form"
200
+ },
186
201
  {
187
202
  "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/with_disabled_items",
188
203
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/with_disabled_items",
@@ -203,6 +218,11 @@
203
218
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/block_description",
204
219
  "name": "block_description"
205
220
  },
221
+ {
222
+ "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/submitting_forms",
223
+ "preview_path": "/lookbook/preview/primer/alpha/action_menu/submitting_forms",
224
+ "name": "submitting_forms"
225
+ },
206
226
  {
207
227
  "inspect_path": "/lookbook/inspect/primer/alpha/action_menu/inline_description",
208
228
  "preview_path": "/lookbook/preview/primer/alpha/action_menu/inline_description",
@@ -567,6 +587,34 @@
567
587
  }
568
588
  ]
569
589
  },
590
+ {
591
+ "name": "box",
592
+ "component": "Box",
593
+ "status": "stable",
594
+ "lookup_path": "primer/box",
595
+ "examples": [
596
+ {
597
+ "inspect_path": "/lookbook/inspect/primer/box/playground",
598
+ "preview_path": "/lookbook/preview/primer/box/playground",
599
+ "name": "playground"
600
+ },
601
+ {
602
+ "inspect_path": "/lookbook/inspect/primer/box/default",
603
+ "preview_path": "/lookbook/preview/primer/box/default",
604
+ "name": "default"
605
+ },
606
+ {
607
+ "inspect_path": "/lookbook/inspect/primer/box/border",
608
+ "preview_path": "/lookbook/preview/primer/box/border",
609
+ "name": "border"
610
+ },
611
+ {
612
+ "inspect_path": "/lookbook/inspect/primer/box/border_bottom",
613
+ "preview_path": "/lookbook/preview/primer/box/border_bottom",
614
+ "name": "border_bottom"
615
+ }
616
+ ]
617
+ },
570
618
  {
571
619
  "name": "breadcrumbs",
572
620
  "component": "Breadcrumbs",
@@ -656,6 +704,11 @@
656
704
  "preview_path": "/lookbook/preview/primer/beta/button/trailing_action",
657
705
  "name": "trailing_action"
658
706
  },
707
+ {
708
+ "inspect_path": "/lookbook/inspect/primer/beta/button/trailing_counter",
709
+ "preview_path": "/lookbook/preview/primer/beta/button/trailing_counter",
710
+ "name": "trailing_counter"
711
+ },
659
712
  {
660
713
  "inspect_path": "/lookbook/inspect/primer/beta/button/with_tooltip",
661
714
  "preview_path": "/lookbook/preview/primer/beta/button/with_tooltip",
@@ -1298,6 +1351,11 @@
1298
1351
  "preview_path": "/lookbook/preview/primer/alpha/nav_list/default",
1299
1352
  "name": "default"
1300
1353
  },
1354
+ {
1355
+ "inspect_path": "/lookbook/inspect/primer/alpha/nav_list/top_level_items",
1356
+ "preview_path": "/lookbook/preview/primer/alpha/nav_list/top_level_items",
1357
+ "name": "top_level_items"
1358
+ },
1301
1359
  {
1302
1360
  "inspect_path": "/lookbook/inspect/primer/alpha/nav_list/show_more_item",
1303
1361
  "preview_path": "/lookbook/preview/primer/alpha/nav_list/show_more_item",
data/static/statuses.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "Primer::Alpha::ActionList": "alpha",
3
3
  "Primer::Alpha::ActionList::Divider": "alpha",
4
+ "Primer::Alpha::ActionList::FormWrapper": "alpha",
4
5
  "Primer::Alpha::ActionList::Heading": "alpha",
5
6
  "Primer::Alpha::ActionList::Item": "alpha",
6
7
  "Primer::Alpha::ActionMenu": "alpha",
@@ -30,6 +31,7 @@
30
31
  "Primer::Alpha::Menu": "alpha",
31
32
  "Primer::Alpha::MultiInput": "alpha",
32
33
  "Primer::Alpha::NavList": "alpha",
34
+ "Primer::Alpha::NavList::Divider": "alpha",
33
35
  "Primer::Alpha::NavList::Group": "alpha",
34
36
  "Primer::Alpha::NavList::Item": "alpha",
35
37
  "Primer::Alpha::Navigation::Tab": "alpha",
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: primer_view_components
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.6
4
+ version: 0.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - GitHub Open Source
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-04-17 00:00:00.000000000 Z
11
+ date: 2023-05-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: actionview
@@ -401,6 +401,8 @@ files:
401
401
  - app/components/primer/alpha/action_list.pcss
402
402
  - app/components/primer/alpha/action_list.rb
403
403
  - app/components/primer/alpha/action_list/divider.rb
404
+ - app/components/primer/alpha/action_list/form_wrapper.html.erb
405
+ - app/components/primer/alpha/action_list/form_wrapper.rb
404
406
  - app/components/primer/alpha/action_list/heading.html.erb
405
407
  - app/components/primer/alpha/action_list/heading.rb
406
408
  - app/components/primer/alpha/action_list/item.html.erb
@@ -487,6 +489,8 @@ files:
487
489
  - app/components/primer/alpha/nav_list.js
488
490
  - app/components/primer/alpha/nav_list.rb
489
491
  - app/components/primer/alpha/nav_list.ts
492
+ - app/components/primer/alpha/nav_list/divider.rb
493
+ - app/components/primer/alpha/nav_list/group.html.erb
490
494
  - app/components/primer/alpha/nav_list/group.rb
491
495
  - app/components/primer/alpha/nav_list/item.html.erb
492
496
  - app/components/primer/alpha/nav_list/item.rb
@@ -748,6 +752,7 @@ files:
748
752
  - app/forms/submit_button_form.rb
749
753
  - app/forms/text_field_and_checkbox_form.rb
750
754
  - app/helpers/primer/form_helper.rb
755
+ - app/lib/primer/attributes_helper.rb
751
756
  - app/lib/primer/audited/dsl.rb
752
757
  - app/lib/primer/class_name_helper.rb
753
758
  - app/lib/primer/css/layout.css
@@ -941,7 +946,10 @@ files:
941
946
  - previews/primer/alpha/action_menu_preview.rb
942
947
  - previews/primer/alpha/action_menu_preview/align_end.html.erb
943
948
  - previews/primer/alpha/action_menu_preview/content_labels.html.erb
949
+ - previews/primer/alpha/action_menu_preview/multiple_select_form.html.erb
944
950
  - previews/primer/alpha/action_menu_preview/opens_dialog.html.erb
951
+ - previews/primer/alpha/action_menu_preview/single_select_form.html.erb
952
+ - previews/primer/alpha/action_menu_preview/submitting_forms.html.erb
945
953
  - previews/primer/alpha/auto_complete_preview.rb
946
954
  - previews/primer/alpha/banner_preview.rb
947
955
  - previews/primer/alpha/banner_preview/with_action_button.html.erb
@@ -1011,6 +1019,7 @@ files:
1011
1019
  - previews/primer/beta/button_preview/invisible_all_visuals.html.erb
1012
1020
  - previews/primer/beta/button_preview/leading_visual.html.erb
1013
1021
  - previews/primer/beta/button_preview/trailing_action.html.erb
1022
+ - previews/primer/beta/button_preview/trailing_counter.html.erb
1014
1023
  - previews/primer/beta/button_preview/trailing_visual.html.erb
1015
1024
  - previews/primer/beta/button_preview/with_tooltip.html.erb
1016
1025
  - previews/primer/beta/clipboard_copy_preview.rb
@@ -1035,6 +1044,7 @@ files:
1035
1044
  - previews/primer/beta/text_preview.rb
1036
1045
  - previews/primer/beta/timeline_item_preview.rb
1037
1046
  - previews/primer/beta/truncate_preview.rb
1047
+ - previews/primer/box_preview.rb
1038
1048
  - previews/primer/forms/forms_preview.rb
1039
1049
  - previews/primer/forms/forms_preview/after_content_form.html.erb
1040
1050
  - previews/primer/forms/forms_preview/array_check_box_group_form.html.erb