diff --git a/Gemfile b/Gemfile index ec0284a0d..1cec0dcd5 100644 --- a/Gemfile +++ b/Gemfile @@ -17,7 +17,7 @@ gem 'makara', '~> 0.5' gem 'pghero', '~> 2.8' gem 'dotenv-rails', '~> 2.7' -gem 'aws-sdk-s3', '~> 1.98', require: false +gem 'aws-sdk-s3', '~> 1.99', require: false gem 'fog-core', '<= 2.1.0' gem 'fog-openstack', '~> 0.3', require: false gem 'paperclip', '~> 6.0' @@ -62,7 +62,7 @@ gem 'link_header', '~> 0.0' gem 'mime-types', '~> 3.3.1', require: 'mime/types/columnar' gem 'nokogiri', '~> 1.12' gem 'nsa', '~> 0.2' -gem 'oj', '~> 3.12' +gem 'oj', '~> 3.13' gem 'ox', '~> 2.14' gem 'parslet' gem 'parallel', '~> 1.20' @@ -122,7 +122,7 @@ group :test do gem 'rails-controller-testing', '~> 1.0' gem 'rspec-sidekiq', '~> 3.1' gem 'simplecov', '~> 0.21', require: false - gem 'webmock', '~> 3.13' + gem 'webmock', '~> 3.14' gem 'parallel_tests', '~> 3.7' gem 'rspec_junit_formatter', '~> 0.4' end @@ -136,7 +136,7 @@ group :development do gem 'letter_opener', '~> 1.7' gem 'letter_opener_web', '~> 1.4' gem 'memory_profiler' - gem 'rubocop', '~> 1.18', require: false + gem 'rubocop', '~> 1.19', require: false gem 'rubocop-rails', '~> 2.11', require: false gem 'brakeman', '~> 5.1', require: false gem 'bundler-audit', '~> 0.8', require: false diff --git a/Gemfile.lock b/Gemfile.lock index 0e1042c7c..92cb9b497 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -79,7 +79,7 @@ GEM encryptor (~> 3.0.0) awrence (1.1.1) aws-eventstream (1.1.1) - aws-partitions (1.482.0) + aws-partitions (1.488.0) aws-sdk-core (3.119.0) aws-eventstream (~> 1, >= 1.0.2) aws-partitions (~> 1, >= 1.239.0) @@ -88,7 +88,7 @@ GEM aws-sdk-kms (1.46.0) aws-sdk-core (~> 3, >= 3.119.0) aws-sigv4 (~> 1.1) - aws-sdk-s3 (1.98.0) + aws-sdk-s3 (1.99.0) aws-sdk-core (~> 3, >= 3.119.0) aws-sdk-kms (~> 1) aws-sigv4 (~> 1.1) @@ -112,7 +112,7 @@ GEM concurrent-ruby (~> 1.0, >= 1.0.5) redis (>= 1.0, <= 5.0) builder (3.2.4) - bullet (6.1.4) + bullet (6.1.5) activesupport (>= 3.0.0) uniform_notifier (~> 1.11) bundler-audit (0.8.0) @@ -218,8 +218,8 @@ GEM multipart-post (>= 1.2, < 3) ruby2_keywords faraday-net_http (1.0.1) - fast_blank (1.0.0) - fastimage (2.2.4) + fast_blank (1.0.1) + fastimage (2.2.5) ffi (1.15.0) ffi-compiler (1.0.1) ffi (>= 1.0.0) @@ -332,7 +332,7 @@ GEM activesupport (>= 4) railties (>= 4) request_store (~> 1.0) - loofah (2.10.0) + loofah (2.12.0) crass (~> 1.0.2) nokogiri (>= 1.5.9) mail (2.7.1) @@ -364,7 +364,7 @@ GEM net-ssh (>= 2.6.5, < 7.0.0) net-ssh (6.1.0) nio4r (2.5.7) - nokogiri (1.12.2) + nokogiri (1.12.3) mini_portile2 (~> 2.6.1) racc (~> 1.4) nsa (0.2.8) @@ -372,7 +372,7 @@ GEM concurrent-ruby (~> 1.0, >= 1.0.2) sidekiq (>= 3.5) statsd-ruby (~> 1.4, >= 1.4.0) - oj (3.12.2) + oj (3.13.2) omniauth (1.9.1) hashie (>= 3.4.6) rack (>= 1.6.2, < 3) @@ -397,7 +397,7 @@ GEM mimemagic (~> 0.3.0) terrapin (~> 0.6.0) parallel (1.20.1) - parallel_tests (3.7.0) + parallel_tests (3.7.1) parallel parser (3.0.2.0) ast (~> 2.4.1) @@ -428,7 +428,7 @@ GEM public_suffix (4.0.6) puma (5.4.0) nio4r (~> 2.0) - pundit (2.1.0) + pundit (2.1.1) activesupport (>= 3.0.0) raabro (1.4.0) racc (1.5.2) @@ -477,7 +477,7 @@ GEM rake (>= 0.13) thor (~> 1.0) rainbow (3.0.0) - rake (13.0.3) + rake (13.0.6) rdf (3.1.15) hamster (~> 3.0) link_header (~> 0.0, >= 0.0.8) @@ -508,7 +508,7 @@ GEM rspec-mocks (3.10.2) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.10.0) - rspec-rails (5.0.1) + rspec-rails (5.0.2) actionpack (>= 5.2) activesupport (>= 5.2) railties (>= 5.2) @@ -522,16 +522,16 @@ GEM rspec-support (3.10.2) rspec_junit_formatter (0.4.1) rspec-core (>= 2, < 4, != 2.12.0) - rubocop (1.18.4) + rubocop (1.19.0) parallel (~> 1.10) parser (>= 3.0.0.0) rainbow (>= 2.2.2, < 4.0) regexp_parser (>= 1.8, < 3.0) rexml - rubocop-ast (>= 1.8.0, < 2.0) + rubocop-ast (>= 1.9.1, < 2.0) ruby-progressbar (~> 1.7) unicode-display_width (>= 1.4.0, < 3.0) - rubocop-ast (1.8.0) + rubocop-ast (1.10.0) parser (>= 3.0.1.1) rubocop-rails (2.11.3) activesupport (>= 4.2.0) @@ -595,7 +595,7 @@ GEM stackprof (0.2.17) statsd-ruby (1.5.0) stoplight (2.2.1) - strong_migrations (0.7.7) + strong_migrations (0.7.8) activerecord (>= 5) temple (0.8.2) terminal-table (3.0.0) @@ -630,7 +630,7 @@ GEM unf_ext unf_ext (0.0.7.7) unicode-display_width (1.7.0) - uniform_notifier (1.14.1) + uniform_notifier (1.14.2) warden (1.2.9) rack (>= 2.0.9) webauthn (3.0.0.alpha1) @@ -643,8 +643,8 @@ GEM safety_net_attestation (~> 0.4.0) securecompare (~> 1.0) tpm-key_attestation (~> 0.9.0) - webmock (3.13.0) - addressable (>= 2.3.6) + webmock (3.14.0) + addressable (>= 2.8.0) crack (>= 0.3.2) hashdiff (>= 0.4.0, < 2.0.0) webpacker (5.4.0) @@ -672,7 +672,7 @@ DEPENDENCIES active_record_query_trace (~> 1.8) addressable (~> 2.8) annotate (~> 3.1) - aws-sdk-s3 (~> 1.98) + aws-sdk-s3 (~> 1.99) better_errors (~> 2.9) binding_of_caller (~> 1.0) blurhash (~> 0.1) @@ -731,7 +731,7 @@ DEPENDENCIES net-ldap (~> 0.17) nokogiri (~> 1.12) nsa (~> 0.2) - oj (~> 3.12) + oj (~> 3.13) omniauth (~> 1.9) omniauth-cas (~> 2.0) omniauth-rails_csrf_protection (~> 0.1) @@ -766,7 +766,7 @@ DEPENDENCIES rspec-rails (~> 5.0) rspec-sidekiq (~> 3.1) rspec_junit_formatter (~> 0.4) - rubocop (~> 1.18) + rubocop (~> 1.19) rubocop-rails (~> 2.11) ruby-progressbar (~> 1.11) sanitize (~> 6.0) @@ -788,7 +788,7 @@ DEPENDENCIES twitter-text (~> 3.1.0) tzinfo-data (~> 1.2021) webauthn (~> 3.0.0.alpha1) - webmock (~> 3.13) + webmock (~> 3.14) webpacker (~> 5.4) webpush (~> 0.3) xorcist (~> 1.1) diff --git a/app/javascript/flavours/glitch/components/attachment_list.js b/app/javascript/flavours/glitch/components/attachment_list.js index 68d8d29c7..68b80b19f 100644 --- a/app/javascript/flavours/glitch/components/attachment_list.js +++ b/app/javascript/flavours/glitch/components/attachment_list.js @@ -2,6 +2,8 @@ import React from 'react'; import ImmutablePropTypes from 'react-immutable-proptypes'; import PropTypes from 'prop-types'; import ImmutablePureComponent from 'react-immutable-pure-component'; +import { FormattedMessage } from 'react-intl'; +import classNames from 'classnames'; import Icon from 'flavours/glitch/components/icon'; const filename = url => url.split('/').pop().split('#')[0].split('?')[0]; @@ -16,29 +18,13 @@ export default class AttachmentList extends ImmutablePureComponent { render () { const { media, compact } = this.props; - if (compact) { - return ( -
- -
- ); - } - return ( -
-
- -
+
+ {!compact && ( +
+ +
+ )}