@primer/view-components 0.0.112 → 0.0.114

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 (28) hide show
  1. package/app/assets/javascripts/primer_view_components.js +1 -1
  2. package/app/assets/javascripts/primer_view_components.js.map +1 -1
  3. package/app/assets/styles/primer_view_components.css +3 -1
  4. package/app/assets/styles/primer_view_components.css.map +1 -1
  5. package/app/components/primer/alpha/action_list.css +1 -1
  6. package/app/components/primer/alpha/action_list.css.json +1 -1
  7. package/app/components/primer/alpha/auto_complete.css +1 -1
  8. package/app/components/primer/alpha/banner.css +1 -1
  9. package/app/components/primer/alpha/dialog.css +1 -0
  10. package/app/components/primer/alpha/dialog.css.json +1 -0
  11. package/app/components/primer/alpha/segmented_control.css +1 -1
  12. package/app/components/primer/alpha/text_field.css +3 -0
  13. package/app/components/primer/alpha/text_field.css.json +1 -0
  14. package/app/components/primer/alpha/toggle_switch.d.ts +1 -1
  15. package/app/components/primer/alpha/toggle_switch.js +7 -4
  16. package/app/components/primer/{clipboard_copy.d.ts → beta/clipboard_copy.d.ts} +0 -0
  17. package/app/components/primer/{clipboard_copy.js → beta/clipboard_copy.js} +0 -0
  18. package/app/components/primer/local_time.d.ts +1 -1
  19. package/app/components/primer/local_time.js +1 -1
  20. package/app/components/primer/primer.d.ts +1 -1
  21. package/app/components/primer/primer.js +1 -1
  22. package/app/components/primer/time_ago_component.d.ts +1 -1
  23. package/app/components/primer/time_ago_component.js +1 -1
  24. package/package.json +2 -2
  25. package/static/arguments.json +163 -53
  26. package/static/audited_at.json +7 -4
  27. package/static/constants.json +132 -6
  28. package/static/statuses.json +6 -3
@@ -1387,6 +1387,38 @@
1387
1387
  }
1388
1388
  ]
1389
1389
  },
1390
+ {
1391
+ "component": "ClipboardCopy",
1392
+ "status": "beta",
1393
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/beta/clipboard_copy.rb",
1394
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/beta/clipboard_copy/default/",
1395
+ "parameters": [
1396
+ {
1397
+ "name": "aria-label",
1398
+ "type": "String",
1399
+ "default": "N/A",
1400
+ "description": "String that will be read to screenreaders when the component is focused"
1401
+ },
1402
+ {
1403
+ "name": "value",
1404
+ "type": "String",
1405
+ "default": "`nil`",
1406
+ "description": "Text to copy into the users clipboard when they click the component."
1407
+ },
1408
+ {
1409
+ "name": "for",
1410
+ "type": "String",
1411
+ "default": "N/A",
1412
+ "description": "Element id from where to get the copied value."
1413
+ },
1414
+ {
1415
+ "name": "system_arguments",
1416
+ "type": "Hash",
1417
+ "default": "N/A",
1418
+ "description": "[System arguments](/system-arguments)"
1419
+ }
1420
+ ]
1421
+ },
1390
1422
  {
1391
1423
  "component": "CloseButton",
1392
1424
  "status": "beta",
@@ -1709,6 +1741,26 @@
1709
1741
  }
1710
1742
  ]
1711
1743
  },
1744
+ {
1745
+ "component": "Markdown",
1746
+ "status": "beta",
1747
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/beta/markdown.rb",
1748
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/beta/markdown/default/",
1749
+ "parameters": [
1750
+ {
1751
+ "name": "tag",
1752
+ "type": "Symbol",
1753
+ "default": "`:div`",
1754
+ "description": "One of `:article`, `:div`, or `:td`."
1755
+ },
1756
+ {
1757
+ "name": "system_arguments",
1758
+ "type": "Hash",
1759
+ "default": "N/A",
1760
+ "description": "[System arguments](/system-arguments)"
1761
+ }
1762
+ ]
1763
+ },
1712
1764
  {
1713
1765
  "component": "Popover",
1714
1766
  "status": "beta",
@@ -1743,6 +1795,116 @@
1743
1795
  }
1744
1796
  ]
1745
1797
  },
1798
+ {
1799
+ "component": "RelativeTime",
1800
+ "status": "beta",
1801
+ "source": "https://github.com/primer/view_components/tree/main/app/components/primer/beta/relative_time.rb",
1802
+ "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/beta/relative_time/default/",
1803
+ "parameters": [
1804
+ {
1805
+ "name": "datetime",
1806
+ "type": "Time",
1807
+ "default": "N/A",
1808
+ "description": "The time to be formatted."
1809
+ },
1810
+ {
1811
+ "name": "tense",
1812
+ "type": "Symbol",
1813
+ "default": "`:auto`",
1814
+ "description": "Which tense to use. One of `:auto`, `:future`, or `:past`."
1815
+ },
1816
+ {
1817
+ "name": "prefix",
1818
+ "type": "sring",
1819
+ "default": "`nil`",
1820
+ "description": "What to prefix the relative ime display with."
1821
+ },
1822
+ {
1823
+ "name": "second",
1824
+ "type": "Symbol",
1825
+ "default": "`SECOND_DEFAULT`",
1826
+ "description": "What format seconds should take. One of `nil`, `:numeric`, or `:two_digit`."
1827
+ },
1828
+ {
1829
+ "name": "minute",
1830
+ "type": "Symbol",
1831
+ "default": "`MINUTE_DEFAULT`",
1832
+ "description": "What format minues should take. One of `nil`, `:numeric`, or `:two_digit`."
1833
+ },
1834
+ {
1835
+ "name": "hour",
1836
+ "type": "Symbol",
1837
+ "default": "`HOUR_DEFAULT`",
1838
+ "description": "What format hours should take. One of `nil`, `:numeric`, or `:two_digit`."
1839
+ },
1840
+ {
1841
+ "name": "weekday",
1842
+ "type": "Symbol",
1843
+ "default": "`WEEKDAY_DEFAULT`",
1844
+ "description": "What format weekdays should take. One of `nil`, `:long`, `:narrow`, or `:short`."
1845
+ },
1846
+ {
1847
+ "name": "day",
1848
+ "type": "Symbol",
1849
+ "default": "`DAY_DEFAULT`",
1850
+ "description": "What format days should take. One of `nil`, `:numeric`, or `:two_digit`."
1851
+ },
1852
+ {
1853
+ "name": "month",
1854
+ "type": "Symbol",
1855
+ "default": "`MONTH_DEFAULT`",
1856
+ "description": "What format months should take. One of `nil`, `:long`, `:narrow`, `:numeric`, `:short`, or `:two_digit`."
1857
+ },
1858
+ {
1859
+ "name": "year",
1860
+ "type": "Symbol",
1861
+ "default": "`YEAR_DEFAULT`",
1862
+ "description": "What format years should take. One of `nil`, `:numeric`, or `:two_digit`."
1863
+ },
1864
+ {
1865
+ "name": "time_zone_name",
1866
+ "type": "Symbol",
1867
+ "default": "`TIMEZONENAME_DEFAULT`",
1868
+ "description": "What format the time zone should take. One of `nil`, `:long`, `:long_generic`, `:long_offset`, `:short`, `:short_generic`, or `:short_offset`."
1869
+ },
1870
+ {
1871
+ "name": "threshold",
1872
+ "type": "string",
1873
+ "default": "`nil`",
1874
+ "description": "The threshold at which relative time displays become absolute."
1875
+ },
1876
+ {
1877
+ "name": "precision",
1878
+ "type": "Symbol",
1879
+ "default": "`PRECISION_DEFAULT`",
1880
+ "description": "The precision elapsed time should display. One of `nil`, `:day`, `:hour`, `:minute`, `:month`, `:second`, or `:year`."
1881
+ },
1882
+ {
1883
+ "name": "format",
1884
+ "type": "Symbol",
1885
+ "default": "`nil`",
1886
+ "description": "The format the display should take. One of `:auto`, `:elapsed`, or `:micro`."
1887
+ },
1888
+ {
1889
+ "name": "lang",
1890
+ "type": "string",
1891
+ "default": "`nil`",
1892
+ "description": "The language to use."
1893
+ },
1894
+ {
1895
+ "name": "title",
1896
+ "type": "string",
1897
+ "default": "`nil`",
1898
+ "description": "Provide a custom title to the element."
1899
+ },
1900
+ {
1901
+ "name": "system_arguments",
1902
+ "type": "Hash",
1903
+ "default": "N/A",
1904
+ "description": "[System arguments](/system-arguments)"
1905
+ }
1906
+ ]
1907
+ },
1746
1908
  {
1747
1909
  "component": "Text",
1748
1910
  "status": "beta",
@@ -1793,7 +1955,7 @@
1793
1955
  },
1794
1956
  {
1795
1957
  "component": "Button",
1796
- "status": "beta",
1958
+ "status": "deprecated",
1797
1959
  "source": "https://github.com/primer/view_components/tree/main/app/components/primer/button_component.rb",
1798
1960
  "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/button/default/",
1799
1961
  "parameters": [
@@ -1853,38 +2015,6 @@
1853
2015
  }
1854
2016
  ]
1855
2017
  },
1856
- {
1857
- "component": "ClipboardCopy",
1858
- "status": "beta",
1859
- "source": "https://github.com/primer/view_components/tree/main/app/components/primer/clipboard_copy.rb",
1860
- "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/clipboard_copy/default/",
1861
- "parameters": [
1862
- {
1863
- "name": "aria-label",
1864
- "type": "String",
1865
- "default": "N/A",
1866
- "description": "String that will be read to screenreaders when the component is focused"
1867
- },
1868
- {
1869
- "name": "value",
1870
- "type": "String",
1871
- "default": "`nil`",
1872
- "description": "Text to copy into the users clipboard when they click the component."
1873
- },
1874
- {
1875
- "name": "for",
1876
- "type": "String",
1877
- "default": "N/A",
1878
- "description": "Element id from where to get the copied value."
1879
- },
1880
- {
1881
- "name": "system_arguments",
1882
- "type": "Hash",
1883
- "default": "N/A",
1884
- "description": "[System arguments](/system-arguments)"
1885
- }
1886
- ]
1887
- },
1888
2018
  {
1889
2019
  "component": "DropdownMenu",
1890
2020
  "status": "deprecated",
@@ -2105,26 +2235,6 @@
2105
2235
  }
2106
2236
  ]
2107
2237
  },
2108
- {
2109
- "component": "Markdown",
2110
- "status": "beta",
2111
- "source": "https://github.com/primer/view_components/tree/main/app/components/primer/markdown.rb",
2112
- "lookbook": "https://primer.style/view-components/lookbook/inspect/primer/markdown/default/",
2113
- "parameters": [
2114
- {
2115
- "name": "tag",
2116
- "type": "Symbol",
2117
- "default": "`:div`",
2118
- "description": "One of `:article`, `:div`, or `:td`."
2119
- },
2120
- {
2121
- "name": "system_arguments",
2122
- "type": "Hash",
2123
- "default": "N/A",
2124
- "description": "[System arguments](/system-arguments)"
2125
- }
2126
- ]
2127
- },
2128
2238
  {
2129
2239
  "component": "Menu",
2130
2240
  "status": "alpha",
@@ -7,10 +7,10 @@
7
7
  "Primer::Alpha::AutoComplete::Item": "",
8
8
  "Primer::Alpha::Banner": "",
9
9
  "Primer::Alpha::ButtonMarketing": "",
10
- "Primer::Alpha::Dialog": "",
11
- "Primer::Alpha::Dialog::Body": "",
12
- "Primer::Alpha::Dialog::Footer": "",
13
- "Primer::Alpha::Dialog::Header": "",
10
+ "Primer::Alpha::Dialog": "2022-10-10",
11
+ "Primer::Alpha::Dialog::Body": "2022-10-10",
12
+ "Primer::Alpha::Dialog::Footer": "2022-10-10",
13
+ "Primer::Alpha::Dialog::Header": "2022-10-10",
14
14
  "Primer::Alpha::Dropdown": "",
15
15
  "Primer::Alpha::Dropdown::Menu": "",
16
16
  "Primer::Alpha::Dropdown::Menu::Item": "",
@@ -45,6 +45,7 @@
45
45
  "Primer::Beta::Breadcrumbs::Item": "",
46
46
  "Primer::Beta::Button": "",
47
47
  "Primer::Beta::ButtonGroup": "",
48
+ "Primer::Beta::ClipboardCopy": "",
48
49
  "Primer::Beta::CloseButton": "",
49
50
  "Primer::Beta::Counter": "",
50
51
  "Primer::Beta::Details": "",
@@ -53,8 +54,10 @@
53
54
  "Primer::Beta::IconButton": "",
54
55
  "Primer::Beta::Label": "",
55
56
  "Primer::Beta::Link": "",
57
+ "Primer::Beta::Markdown": "",
56
58
  "Primer::Beta::Popover": "",
57
59
  "Primer::Beta::ProgressBar": "",
60
+ "Primer::Beta::RelativeTime": "",
58
61
  "Primer::Beta::Text": "",
59
62
  "Primer::Beta::Truncate": "",
60
63
  "Primer::Beta::Truncate::TruncateText": "",
@@ -558,6 +558,8 @@
558
558
  },
559
559
  "Primer::Beta::ButtonGroup": {
560
560
  },
561
+ "Primer::Beta::ClipboardCopy": {
562
+ },
561
563
  "Primer::Beta::CloseButton": {
562
564
  "DEFAULT_TYPE": "button",
563
565
  "TYPE_OPTIONS": [
@@ -707,6 +709,14 @@
707
709
  "span"
708
710
  ]
709
711
  },
712
+ "Primer::Beta::Markdown": {
713
+ "DEFAULT_TAG": "div",
714
+ "TAG_OPTIONS": [
715
+ "div",
716
+ "article",
717
+ "td"
718
+ ]
719
+ },
710
720
  "Primer::Beta::Popover": {
711
721
  "CARET_DEFAULT": "top",
712
722
  "CARET_MAPPINGS": {
@@ -738,6 +748,128 @@
738
748
  "large"
739
749
  ]
740
750
  },
751
+ "Primer::Beta::RelativeTime": {
752
+ "DAY_DEFAULT": null,
753
+ "DAY_MAPPINGS": {
754
+ "": null,
755
+ "numeric": "numeric",
756
+ "two_digit": "2-digit"
757
+ },
758
+ "DAY_OPTIONS": [
759
+ null,
760
+ "numeric",
761
+ "two_digit"
762
+ ],
763
+ "FORMAT_DEFAULT": "auto",
764
+ "FORMAT_OPTIONS": [
765
+ "auto",
766
+ "micro",
767
+ "elapsed"
768
+ ],
769
+ "HOUR_DEFAULT": null,
770
+ "HOUR_MAPPINGS": {
771
+ "": null,
772
+ "numeric": "numeric",
773
+ "two_digit": "2-digit"
774
+ },
775
+ "HOUR_OPTIONS": [
776
+ null,
777
+ "numeric",
778
+ "two_digit"
779
+ ],
780
+ "MINUTE_DEFAULT": null,
781
+ "MINUTE_MAPPINGS": {
782
+ "": null,
783
+ "numeric": "numeric",
784
+ "two_digit": "2-digit"
785
+ },
786
+ "MINUTE_OPTIONS": [
787
+ null,
788
+ "numeric",
789
+ "two_digit"
790
+ ],
791
+ "MONTH_DEFAULT": null,
792
+ "MONTH_MAPPINGS": {
793
+ "": null,
794
+ "numeric": "numeric",
795
+ "two_digit": "2-digit",
796
+ "short": "short",
797
+ "long": "long",
798
+ "narrow": "narrow"
799
+ },
800
+ "MONTH_OPTIONS": [
801
+ null,
802
+ "numeric",
803
+ "two_digit",
804
+ "short",
805
+ "long",
806
+ "narrow"
807
+ ],
808
+ "PRECISION_DEFAULT": null,
809
+ "PRECISION_OPTIONS": [
810
+ null,
811
+ "second",
812
+ "minute",
813
+ "hour",
814
+ "day",
815
+ "month",
816
+ "year"
817
+ ],
818
+ "SECOND_DEFAULT": null,
819
+ "SECOND_MAPPINGS": {
820
+ "": null,
821
+ "numeric": "numeric",
822
+ "two_digit": "2-digit"
823
+ },
824
+ "SECOND_OPTIONS": [
825
+ null,
826
+ "numeric",
827
+ "two_digit"
828
+ ],
829
+ "TENSE_DEFAULT": "auto",
830
+ "TENSE_OPTIONS": [
831
+ "auto",
832
+ "past",
833
+ "future"
834
+ ],
835
+ "TIMEZONENAME_DEFAULT": null,
836
+ "TIMEZONENAME_OPTIONS": [
837
+ null,
838
+ "long",
839
+ "short",
840
+ "short_offset",
841
+ "long_offset",
842
+ "short_generic",
843
+ "long_generic"
844
+ ],
845
+ "TIMEZONE_MAPPINGS": {
846
+ "": null,
847
+ "long": "long",
848
+ "short": "short",
849
+ "short_offset": "shortOffset",
850
+ "long_offset": "longOffset",
851
+ "short_generic": "shortGeneric",
852
+ "long_generic": "longGeneric"
853
+ },
854
+ "WEEKDAY_DEFAULT": null,
855
+ "WEEKDAY_OPTIONS": [
856
+ null,
857
+ "long",
858
+ "short",
859
+ "narrow"
860
+ ],
861
+ "YEAR_DEFAULT": null,
862
+ "YEAR_MAPPINGS": {
863
+ "": null,
864
+ "numeric": "numeric",
865
+ "two_digit": "2-digit"
866
+ },
867
+ "YEAR_OPTIONS": [
868
+ null,
869
+ "numeric",
870
+ "two_digit"
871
+ ]
872
+ },
741
873
  "Primer::Beta::Text": {
742
874
  "DEFAULT_TAG": "span"
743
875
  },
@@ -863,12 +995,6 @@
863
995
  ]
864
996
  },
865
997
  "Primer::Markdown": {
866
- "DEFAULT_TAG": "div",
867
- "TAG_OPTIONS": [
868
- "div",
869
- "article",
870
- "td"
871
- ]
872
998
  },
873
999
  "Primer::MenuComponent": {
874
1000
  "HEADING_TAG_FALLBACK": "h2",
@@ -45,6 +45,7 @@
45
45
  "Primer::Beta::Breadcrumbs::Item": "alpha",
46
46
  "Primer::Beta::Button": "beta",
47
47
  "Primer::Beta::ButtonGroup": "beta",
48
+ "Primer::Beta::ClipboardCopy": "beta",
48
49
  "Primer::Beta::CloseButton": "beta",
49
50
  "Primer::Beta::Counter": "beta",
50
51
  "Primer::Beta::Details": "beta",
@@ -53,16 +54,18 @@
53
54
  "Primer::Beta::IconButton": "beta",
54
55
  "Primer::Beta::Label": "beta",
55
56
  "Primer::Beta::Link": "beta",
57
+ "Primer::Beta::Markdown": "beta",
56
58
  "Primer::Beta::Popover": "beta",
57
59
  "Primer::Beta::ProgressBar": "beta",
60
+ "Primer::Beta::RelativeTime": "beta",
58
61
  "Primer::Beta::Text": "beta",
59
62
  "Primer::Beta::Truncate": "beta",
60
63
  "Primer::Beta::Truncate::TruncateText": "alpha",
61
64
  "Primer::BlankslateComponent": "deprecated",
62
65
  "Primer::Box": "stable",
63
66
  "Primer::BoxComponent": "deprecated",
64
- "Primer::ButtonComponent": "beta",
65
- "Primer::ClipboardCopy": "beta",
67
+ "Primer::ButtonComponent": "deprecated",
68
+ "Primer::ClipboardCopy": "deprecated",
66
69
  "Primer::ConditionalWrapper": "alpha",
67
70
  "Primer::Content": "stable",
68
71
  "Primer::Dropdown": "deprecated",
@@ -75,7 +78,7 @@
75
78
  "Primer::LayoutComponent": "alpha",
76
79
  "Primer::LinkComponent": "deprecated",
77
80
  "Primer::LocalTime": "alpha",
78
- "Primer::Markdown": "beta",
81
+ "Primer::Markdown": "deprecated",
79
82
  "Primer::MenuComponent": "alpha",
80
83
  "Primer::Navigation::TabComponent": "alpha",
81
84
  "Primer::OcticonComponent": "beta",