Skip to content

Commit

Permalink
Remove DropdownMenuComponent (#1783)
Browse files Browse the repository at this point in the history
Co-authored-by: Jon Rohan <yes@jonrohan.codes>
Co-authored-by: Jon Rohan <rohan@github.com>
Co-authored-by: Cameron Dutro <camertron@gmail.com>
  • Loading branch information
4 people authored Jan 25, 2023
1 parent 716abfb commit 7337d5e
Show file tree
Hide file tree
Showing 16 changed files with 12 additions and 188 deletions.
5 changes: 5 additions & 0 deletions .changeset/large-pandas-divide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/view-components": patch
---

Remove the deprecated `Primer::DropdownMenuComponent`.
3 changes: 3 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ source "https://rubygems.org"
gemspec
rails_version = (ENV["RAILS_VERSION"] || "7.0.3").to_s

# remove when https://github.com/rails/rails/pull/47142 is merged
gem "rack", "~> 2.0"

gem "rack-cors"
gem "rake", "~> 13.0"

Expand Down
1 change: 1 addition & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,7 @@ DEPENDENCIES
primer_view_components!
pry
puma (~> 5.6.4)
rack (~> 2.0)
rack-cors
railties (= 7.0.3)
rake (~> 13.0)
Expand Down
8 changes: 0 additions & 8 deletions app/components/primer/dropdown_menu_component.html.erb

This file was deleted.

58 changes: 0 additions & 58 deletions app/components/primer/dropdown_menu_component.rb

This file was deleted.

54 changes: 0 additions & 54 deletions docs/content/guides/primer_dropdown_menu_component.md

This file was deleted.

1 change: 0 additions & 1 deletion docs/content/migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,5 @@ components.
| Deprecated Component | Replacement Component | Guide |
|----------------------|-----------------------|-------|
| [`Primer::ButtonComponent`](https://primer.style/view-components/components/button) | [`Primer::Beta::Button`](https://primer.style/view-components/components/beta/button) | [Upgrade to Primer::Beta::Button](https://primer.style/view-components/guides/primer_button_component) |
| [`Primer::DropdownMenuComponent`](https://primer.style/view-components/components/dropdownmenu) | [`Primer::Alpha::Dropdown`](https://primer.style/view-components/components/alpha/dropdown) | [Upgrade to Primer::Alpha::Dropdown](https://primer.style/view-components/guides/primer_dropdown_menu_component) |
| [`Primer::LocalTime`](https://primer.style/view-components/components/localtime) | [`Primer::Beta::RelativeTime`](https://primer.style/view-components/components/beta/relativetime) | [Upgrade to Primer::Beta::RelativeTime](https://primer.style/view-components/guides/primer_local_time) |
| [`Primer::TimeAgoComponent`](https://primer.style/view-components/components/timeago) | [`Primer::Beta::RelativeTime`](https://primer.style/view-components/components/beta/relativetime) | [Upgrade to Primer::Beta::RelativeTime](https://primer.style/view-components/guides/primer_time_ago) |
6 changes: 3 additions & 3 deletions docs/contributors/deprecations.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ options.

```yml
- component: [string]
autocorrect: [boolean]
replacement: [string]
autocorrect: [boolean]
replacement: [string]
guide: [string]
```
Expand Down Expand Up @@ -97,7 +97,7 @@ configurations for more information.
4. A non-autocorrectable deprecation, without a replacement component, and with a guide to alternatives

```yml
- component: "Primer::DropdownMenuComponent"
- component: "Primer::DeprecatedComponent"
autocorrect: false
guide: "https://example.com/dropdown_menu_alternatives"
```
Expand Down
2 changes: 0 additions & 2 deletions docs/src/@primer/gatsby-theme-doctocat/nav.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,6 @@
url: "/components/box"
- title: ButtonComponent
url: "/components/button"
- title: DropdownMenuComponent
url: "/components/dropdownmenu"
- title: IconButton
url: "/components/iconbutton"
- title: LocalTime
Expand Down
5 changes: 0 additions & 5 deletions lib/primer/deprecations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,6 @@ deprecations:
replacement: "Primer::Beta::Button"
guide: "https://primer.style/view-components/guides/primer_button_component"

- component: "Primer::DropdownMenuComponent"
autocorrect: false
replacement: "Primer::Beta::Dropdown"
guide: "https://primer.style/view-components/guides/primer_dropdown_menu_component"

- component: "Primer::Dropdown"
autocorrect: true
replacement: "Primer::Alpha::Dropdown"
Expand Down
1 change: 0 additions & 1 deletion lib/tasks/docs.rake
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ namespace :docs do
Primer::Beta::Details,
Primer::Alpha::Dialog,
Primer::Alpha::Dropdown,
Primer::DropdownMenuComponent,
Primer::Beta::Flash,
Primer::Beta::Heading,
Primer::Alpha::HiddenTextExpander,
Expand Down
1 change: 0 additions & 1 deletion static/audited_at.json
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,6 @@
"Primer::Dropdown": "",
"Primer::Dropdown::Menu": "",
"Primer::Dropdown::Menu::Item": "",
"Primer::DropdownMenuComponent": "",
"Primer::HellipButton": "",
"Primer::IconButton": "",
"Primer::LabelComponent": "",
Expand Down
16 changes: 0 additions & 16 deletions static/constants.json
Original file line number Diff line number Diff line change
Expand Up @@ -1041,22 +1041,6 @@
},
"Primer::Dropdown::Menu::Item": {
},
"Primer::DropdownMenuComponent": {
"DIRECTION_DEFAULT": "se",
"DIRECTION_OPTIONS": [
"se",
"sw",
"w",
"e",
"ne",
"s"
],
"SCHEME_DEFAULT": "default",
"SCHEME_MAPPINGS": {
"default": "",
"dark": "dropdown-menu-dark"
}
},
"Primer::HellipButton": {
},
"Primer::IconButton": {
Expand Down
1 change: 0 additions & 1 deletion static/statuses.json
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,6 @@
"Primer::Dropdown": "deprecated",
"Primer::Dropdown::Menu": "deprecated",
"Primer::Dropdown::Menu::Item": "deprecated",
"Primer::DropdownMenuComponent": "deprecated",
"Primer::HellipButton": "deprecated",
"Primer::IconButton": "deprecated",
"Primer::LabelComponent": "deprecated",
Expand Down
1 change: 0 additions & 1 deletion test/components/component_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ class PrimerComponentTest < Minitest::Test
end
end],
[Primer::Alpha::Dropdown::Menu, {}],
[Primer::DropdownMenuComponent, {}],
[Primer::Beta::Flash, {}],
[Primer::Beta::Heading, { tag: :h1 }],
[Primer::Alpha::HiddenTextExpander, { "aria-label": "No action" }],
Expand Down
37 changes: 0 additions & 37 deletions test/components/dropdown_menu_component_test.rb

This file was deleted.

0 comments on commit 7337d5e

Please sign in to comment.