From 528b3027d61f35a9ddd97e79f621b7919698348d Mon Sep 17 00:00:00 2001 From: dnoneill Date: Fri, 20 Sep 2024 16:00:36 -0400 Subject: [PATCH] move svgs to components --- .../images/blacklight/arrow-alt-circle-left.svg | 1 - .../images/blacklight/arrow-alt-circle-right.svg | 1 - app/assets/images/blacklight/arrow_back_ios.svg | 1 - .../images/blacklight/arrow_forward_ios.svg | 1 - app/assets/images/blacklight/check.svg | 1 - app/assets/images/blacklight/check_circle.svg | 1 - app/assets/images/blacklight/chevron_right.svg | 1 - app/assets/images/blacklight/close.svg | 1 - app/assets/images/blacklight/edit.svg | 1 - app/assets/images/blacklight/error.svg | 1 - app/assets/images/blacklight/highlight_off.svg | 1 - app/assets/images/blacklight/info.svg | 1 - app/assets/images/blacklight/warning.svg | 1 - app/assets/images/blacklight/zoom_in.svg | 1 - app/assets/images/blacklight/zoom_out.svg | 1 - .../spotlight/browse_group_categories_block.scss | 8 ++++---- .../icons/arrow_alt_circle_left_component.rb | 15 +++++++++++++++ .../icons/arrow_alt_circle_right_component.rb | 15 +++++++++++++++ .../blacklight/icons/arrow_back_ios_component.rb | 15 +++++++++++++++ .../icons/arrow_forward_ios_component.rb | 15 +++++++++++++++ .../blacklight/icons/check_circle_component.rb | 15 +++++++++++++++ .../blacklight/icons/check_component.rb | 15 +++++++++++++++ .../blacklight/icons/chevron_right_component.rb | 15 +++++++++++++++ .../blacklight/icons/close_component.rb | 15 +++++++++++++++ app/components/blacklight/icons/edit_component.rb | 15 +++++++++++++++ .../blacklight/icons/error_component.rb | 14 ++++++++++++++ .../blacklight/icons/highlight_off_component.rb | 15 +++++++++++++++ app/components/blacklight/icons/info_component.rb | 15 +++++++++++++++ .../blacklight/icons/warning_component.rb | 14 ++++++++++++++ .../blacklight/icons/zoom_in_component.rb | 15 +++++++++++++++ .../blacklight/icons/zoom_out_component.rb | 15 +++++++++++++++ .../_browse_group_categories_block.html.erb | 4 ++-- 32 files changed, 229 insertions(+), 21 deletions(-) delete mode 100644 app/assets/images/blacklight/arrow-alt-circle-left.svg delete mode 100644 app/assets/images/blacklight/arrow-alt-circle-right.svg delete mode 100644 app/assets/images/blacklight/arrow_back_ios.svg delete mode 100644 app/assets/images/blacklight/arrow_forward_ios.svg delete mode 100644 app/assets/images/blacklight/check.svg delete mode 100644 app/assets/images/blacklight/check_circle.svg delete mode 100644 app/assets/images/blacklight/chevron_right.svg delete mode 100644 app/assets/images/blacklight/close.svg delete mode 100644 app/assets/images/blacklight/edit.svg delete mode 100644 app/assets/images/blacklight/error.svg delete mode 100644 app/assets/images/blacklight/highlight_off.svg delete mode 100644 app/assets/images/blacklight/info.svg delete mode 100644 app/assets/images/blacklight/warning.svg delete mode 100644 app/assets/images/blacklight/zoom_in.svg delete mode 100644 app/assets/images/blacklight/zoom_out.svg create mode 100644 app/components/blacklight/icons/arrow_alt_circle_left_component.rb create mode 100644 app/components/blacklight/icons/arrow_alt_circle_right_component.rb create mode 100644 app/components/blacklight/icons/arrow_back_ios_component.rb create mode 100644 app/components/blacklight/icons/arrow_forward_ios_component.rb create mode 100644 app/components/blacklight/icons/check_circle_component.rb create mode 100644 app/components/blacklight/icons/check_component.rb create mode 100644 app/components/blacklight/icons/chevron_right_component.rb create mode 100644 app/components/blacklight/icons/close_component.rb create mode 100644 app/components/blacklight/icons/edit_component.rb create mode 100644 app/components/blacklight/icons/error_component.rb create mode 100644 app/components/blacklight/icons/highlight_off_component.rb create mode 100644 app/components/blacklight/icons/info_component.rb create mode 100644 app/components/blacklight/icons/warning_component.rb create mode 100644 app/components/blacklight/icons/zoom_in_component.rb create mode 100644 app/components/blacklight/icons/zoom_out_component.rb diff --git a/app/assets/images/blacklight/arrow-alt-circle-left.svg b/app/assets/images/blacklight/arrow-alt-circle-left.svg deleted file mode 100644 index 8fa131bc7..000000000 --- a/app/assets/images/blacklight/arrow-alt-circle-left.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/app/assets/images/blacklight/arrow-alt-circle-right.svg b/app/assets/images/blacklight/arrow-alt-circle-right.svg deleted file mode 100644 index 4d864c77c..000000000 --- a/app/assets/images/blacklight/arrow-alt-circle-right.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/app/assets/images/blacklight/arrow_back_ios.svg b/app/assets/images/blacklight/arrow_back_ios.svg deleted file mode 100644 index deb272127..000000000 --- a/app/assets/images/blacklight/arrow_back_ios.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/arrow_forward_ios.svg b/app/assets/images/blacklight/arrow_forward_ios.svg deleted file mode 100644 index 5c04fc0c6..000000000 --- a/app/assets/images/blacklight/arrow_forward_ios.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/check.svg b/app/assets/images/blacklight/check.svg deleted file mode 100644 index e4ebb41eb..000000000 --- a/app/assets/images/blacklight/check.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/check_circle.svg b/app/assets/images/blacklight/check_circle.svg deleted file mode 100644 index 69c179677..000000000 --- a/app/assets/images/blacklight/check_circle.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/chevron_right.svg b/app/assets/images/blacklight/chevron_right.svg deleted file mode 100644 index acabc296a..000000000 --- a/app/assets/images/blacklight/chevron_right.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/close.svg b/app/assets/images/blacklight/close.svg deleted file mode 100644 index 081494612..000000000 --- a/app/assets/images/blacklight/close.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/edit.svg b/app/assets/images/blacklight/edit.svg deleted file mode 100644 index 1a7d71c7c..000000000 --- a/app/assets/images/blacklight/edit.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/error.svg b/app/assets/images/blacklight/error.svg deleted file mode 100644 index d30cc3a7a..000000000 --- a/app/assets/images/blacklight/error.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/highlight_off.svg b/app/assets/images/blacklight/highlight_off.svg deleted file mode 100644 index 1d9608e65..000000000 --- a/app/assets/images/blacklight/highlight_off.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/info.svg b/app/assets/images/blacklight/info.svg deleted file mode 100644 index eb2424b57..000000000 --- a/app/assets/images/blacklight/info.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/warning.svg b/app/assets/images/blacklight/warning.svg deleted file mode 100644 index dfcf997c6..000000000 --- a/app/assets/images/blacklight/warning.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/app/assets/images/blacklight/zoom_in.svg b/app/assets/images/blacklight/zoom_in.svg deleted file mode 100644 index d257598e3..000000000 --- a/app/assets/images/blacklight/zoom_in.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/app/assets/images/blacklight/zoom_out.svg b/app/assets/images/blacklight/zoom_out.svg deleted file mode 100644 index dce0a4eba..000000000 --- a/app/assets/images/blacklight/zoom_out.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/app/assets/stylesheets/spotlight/browse_group_categories_block.scss b/app/assets/stylesheets/spotlight/browse_group_categories_block.scss index e3797b661..63f9837b5 100644 --- a/app/assets/stylesheets/spotlight/browse_group_categories_block.scss +++ b/app/assets/stylesheets/spotlight/browse_group_categories_block.scss @@ -33,7 +33,7 @@ cursor: pointer; } - .blacklight-icon-arrow-alt-circle-left, .blacklight-icon-arrow-alt-circle-right { + .blacklight-icons-arrow-alt-circle-left, .blacklight-icons-arrow-alt-circle-right { display: inline-block; fill: $gray-600; height: 44px; @@ -49,7 +49,7 @@ } [aria-disabled="true"] { - .blacklight-icon-arrow-alt-circle-left, .blacklight-icon-arrow-alt-circle-right { + .blacklight-icons-arrow-alt-circle-left, .blacklight-icons-arrow-alt-circle-right { fill: $gray-400; &:hover,&:focus { @@ -66,7 +66,7 @@ @media screen and (min-width: breakpoint-min("md")) { .browse-group-categories-controls { - .blacklight-icon-arrow-alt-circle-left, .blacklight-icon-arrow-alt-circle-right { + .blacklight-icons-arrow-alt-circle-left, .blacklight-icons-arrow-alt-circle-right { height: 32px; width: 32px; } @@ -81,7 +81,7 @@ } [dir="rtl"] { - .browse-group-categories-block .blacklight-icon-arrow-alt-circle-left, .blacklight-icon-arrow-alt-circle-right{ + .browse-group-categories-block .blacklight-icons-arrow-alt-circle-left, .blacklight-icons-arrow-alt-circle-right{ transform: rotate(180deg); } // Hack to override overflow issue not fixed in RTL upstream in tiny-slider diff --git a/app/components/blacklight/icons/arrow_alt_circle_left_component.rb b/app/components/blacklight/icons/arrow_alt_circle_left_component.rb new file mode 100644 index 000000000..ce278d12f --- /dev/null +++ b/app/components/blacklight/icons/arrow_alt_circle_left_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for ArrowAltCircleLeft + class ArrowAltCircleLeftComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/arrow_alt_circle_right_component.rb b/app/components/blacklight/icons/arrow_alt_circle_right_component.rb new file mode 100644 index 000000000..b6e012e75 --- /dev/null +++ b/app/components/blacklight/icons/arrow_alt_circle_right_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for ArrowAltCircleRight + class ArrowAltCircleRightComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/arrow_back_ios_component.rb b/app/components/blacklight/icons/arrow_back_ios_component.rb new file mode 100644 index 000000000..f5a5f7079 --- /dev/null +++ b/app/components/blacklight/icons/arrow_back_ios_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for ArrowBackIos + class ArrowBackIosComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/arrow_forward_ios_component.rb b/app/components/blacklight/icons/arrow_forward_ios_component.rb new file mode 100644 index 000000000..4882cfd5b --- /dev/null +++ b/app/components/blacklight/icons/arrow_forward_ios_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for ArrowForwardIos + class ArrowForwardIosComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/check_circle_component.rb b/app/components/blacklight/icons/check_circle_component.rb new file mode 100644 index 000000000..f6b9967a3 --- /dev/null +++ b/app/components/blacklight/icons/check_circle_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for CheckCircle + class CheckCircleComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/check_component.rb b/app/components/blacklight/icons/check_component.rb new file mode 100644 index 000000000..75d0bbdf8 --- /dev/null +++ b/app/components/blacklight/icons/check_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for Check + class CheckComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/chevron_right_component.rb b/app/components/blacklight/icons/chevron_right_component.rb new file mode 100644 index 000000000..910883c8b --- /dev/null +++ b/app/components/blacklight/icons/chevron_right_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for ChevronRight + class ChevronRightComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/close_component.rb b/app/components/blacklight/icons/close_component.rb new file mode 100644 index 000000000..e97a2ff1a --- /dev/null +++ b/app/components/blacklight/icons/close_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for Close + class CloseComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/edit_component.rb b/app/components/blacklight/icons/edit_component.rb new file mode 100644 index 000000000..355013875 --- /dev/null +++ b/app/components/blacklight/icons/edit_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for Edit + class EditComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/error_component.rb b/app/components/blacklight/icons/error_component.rb new file mode 100644 index 000000000..626014ba4 --- /dev/null +++ b/app/components/blacklight/icons/error_component.rb @@ -0,0 +1,14 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for Error + class ErrorComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/highlight_off_component.rb b/app/components/blacklight/icons/highlight_off_component.rb new file mode 100644 index 000000000..a2b766718 --- /dev/null +++ b/app/components/blacklight/icons/highlight_off_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for HighlightOff + class HighlightOffComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/info_component.rb b/app/components/blacklight/icons/info_component.rb new file mode 100644 index 000000000..0f43507ad --- /dev/null +++ b/app/components/blacklight/icons/info_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for Info + class InfoComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/warning_component.rb b/app/components/blacklight/icons/warning_component.rb new file mode 100644 index 000000000..4ddd7caca --- /dev/null +++ b/app/components/blacklight/icons/warning_component.rb @@ -0,0 +1,14 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for Warning + class WarningComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/zoom_in_component.rb b/app/components/blacklight/icons/zoom_in_component.rb new file mode 100644 index 000000000..408432710 --- /dev/null +++ b/app/components/blacklight/icons/zoom_in_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for ZoomIn + class ZoomInComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/components/blacklight/icons/zoom_out_component.rb b/app/components/blacklight/icons/zoom_out_component.rb new file mode 100644 index 000000000..83ec0efab --- /dev/null +++ b/app/components/blacklight/icons/zoom_out_component.rb @@ -0,0 +1,15 @@ +# frozen_string_literal: true + +module Blacklight + module Icons + # Icon for ZoomOut + class ZoomOutComponent < Blacklight::Icons::IconComponent + self.svg = <<~SVG + + + + + SVG + end + end +end diff --git a/app/views/spotlight/sir_trevor/blocks/_browse_group_categories_block.html.erb b/app/views/spotlight/sir_trevor/blocks/_browse_group_categories_block.html.erb index 163f8ff92..fa90ae02a 100644 --- a/app/views/spotlight/sir_trevor/blocks/_browse_group_categories_block.html.erb +++ b/app/views/spotlight/sir_trevor/blocks/_browse_group_categories_block.html.erb @@ -11,10 +11,10 @@ <% if group.searches.count > 1 %> <% end %>