diff --git a/.codeclimate.yml b/.codeclimate.yml index 65826a4e1..87fc4371a 100644 --- a/.codeclimate.yml +++ b/.codeclimate.yml @@ -63,3 +63,4 @@ exclude_paths: - "decidim-ephemeral_participation/app/permissions/decidim/ephemeral_participation/ephemeral_participation_permissions.rb" - "app/services/decidim_legacy_routes.rb" - "app/helpers/concerns/decidim/paginate_helper_override.rb" +- "app/permissions/concerns/decidim/initiatives/admin/permissions_override.rb" diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 858340b64..a276d8c02 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -8,7 +8,7 @@ env: jobs: lint: name: Lint code - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 env: DATABASE_USERNAME: postgres DATABASE_PASSWORD: postgres diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 1aa98c1a3..66c106dea 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -8,7 +8,7 @@ env: jobs: test: name: Test - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 services: postgres: image: postgres:11 @@ -47,3 +47,10 @@ jobs: mkdir node_modules bundle exec rspec name: Run specs + - uses: actions/upload-artifact@v4 + if: always() + with: + name: screenshots + path: ./tmp/screenshots + if-no-files-found: ignore + overwrite: true diff --git a/.github/workflows/test_census_sms.yml b/.github/workflows/test_census_sms.yml index 700b6a936..84332e458 100644 --- a/.github/workflows/test_census_sms.yml +++ b/.github/workflows/test_census_sms.yml @@ -8,7 +8,7 @@ env: jobs: test: name: Test Census SMS - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 services: postgres: image: postgres:11 @@ -47,3 +47,10 @@ jobs: mkdir node_modules bundle exec rspec decidim-census_sms name: Run specs + - uses: actions/upload-artifact@v4 + if: always() + with: + name: screenshots + path: ./tmp/screenshots + if-no-files-found: ignore + overwrite: true diff --git a/.github/workflows/test_stats.yml b/.github/workflows/test_stats.yml index a4254bc6d..e53d2e195 100644 --- a/.github/workflows/test_stats.yml +++ b/.github/workflows/test_stats.yml @@ -8,7 +8,7 @@ env: jobs: test: name: Test Stats - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 services: postgres: image: postgres:11 @@ -47,3 +47,10 @@ jobs: mkdir node_modules bundle exec rspec decidim-stats name: Run specs + - uses: actions/upload-artifact@v4 + if: always() + with: + name: screenshots + path: ./tmp/screenshots + if-no-files-found: ignore + overwrite: true diff --git a/.github/workflows/test_valid_auth.yml b/.github/workflows/test_valid_auth.yml deleted file mode 100644 index 1c302645d..000000000 --- a/.github/workflows/test_valid_auth.yml +++ /dev/null @@ -1,49 +0,0 @@ -name: Test Valid Auth -on: [push] - -env: - RUBY_VERSION: 3.1.1 - NODE_VERSION: 18.17.1 - -jobs: - test: - name: Test Valid Auth - runs-on: ubuntu-latest - services: - postgres: - image: postgres:11 - ports: ["5432:5432"] - options: >- - --health-cmd pg_isready - --health-interval 10s - --health-timeout 5s - --health-retries 5 - env: - POSTGRES_PASSWORD: postgres - redis: - image: redis:3.2-alpine - ports: ["6379:6379"] - env: - DATABASE_USERNAME: postgres - DATABASE_PASSWORD: postgres - DATABASE_HOST: localhost - RAILS_ENV: test - steps: - - uses: actions/checkout@v2.0.0 - with: - fetch-depth: 1 - - uses: ruby/setup-ruby@v1 - with: - ruby-version: ${{ env.RUBY_VERSION }} - bundler-cache: true - - uses: nanasess/setup-chromedriver@v2 - - run: bundle exec rake db:test:prepare - name: Setup database - - name: Precompile assets - run: | - npm install - bundle exec rake assets:precompile - - run: | - mkdir node_modules - bundle exec rspec decidim-valid_auth - name: Run specs diff --git a/Gemfile b/Gemfile index 7486bcf9d..c23cc5a58 100644 --- a/Gemfile +++ b/Gemfile @@ -2,21 +2,22 @@ source "https://rubygems.org" -DECIDIM_VERSION = "0.28.3" +DECIDIM_VERSION = { git: "https://github.com/AjuntamentdeBarcelona/decidim", branch: "release/0.28-stable-bcn" }.freeze ruby RUBY_VERSION gem "decidim", DECIDIM_VERSION gem "decidim-initiatives", DECIDIM_VERSION gem "decidim-sortitions", DECIDIM_VERSION +gem "decidim-templates", DECIDIM_VERSION gem "decidim-census_sms", path: "decidim-census_sms" gem "decidim-dataviz", path: "decidim-dataviz" gem "decidim-ephemeral_participation", path: "decidim-ephemeral_participation" # Installed but not used anymore gem "decidim-stats", path: "decidim-stats" -gem "decidim-valid_auth", path: "decidim-valid_auth" gem "decidim-decidim_awesome", git: "https://github.com/decidim-ice/decidim-module-decidim_awesome" +gem "decidim-internal_evaluation", git: "https://github.com/AjuntamentdeBarcelona/decidim-internal-evaluation-module", branch: "release/0.28-stable" gem "decidim-kids", git: "https://github.com/AjuntamentdeBarcelona/decidim-module-kids" gem "decidim-navigation_maps", git: "https://github.com/Platoniq/decidim-module-navigation_maps" gem "decidim-term_customizer", git: "https://github.com/mainio/decidim-module-term_customizer" diff --git a/Gemfile.lock b/Gemfile.lock index 056c28f41..6ebd3b570 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,3 +1,197 @@ +GIT + remote: https://github.com/AjuntamentdeBarcelona/decidim + revision: 4bfc73be0724b60918f93867ae0a03d662aea1fd + branch: release/0.28-stable-bcn + specs: + decidim (0.28.4) + decidim-accountability (= 0.28.4) + decidim-admin (= 0.28.4) + decidim-api (= 0.28.4) + decidim-assemblies (= 0.28.4) + decidim-blogs (= 0.28.4) + decidim-budgets (= 0.28.4) + decidim-comments (= 0.28.4) + decidim-core (= 0.28.4) + decidim-debates (= 0.28.4) + decidim-forms (= 0.28.4) + decidim-generators (= 0.28.4) + decidim-meetings (= 0.28.4) + decidim-pages (= 0.28.4) + decidim-participatory_processes (= 0.28.4) + decidim-proposals (= 0.28.4) + decidim-sortitions (= 0.28.4) + decidim-surveys (= 0.28.4) + decidim-system (= 0.28.4) + decidim-verifications (= 0.28.4) + decidim-accountability (0.28.4) + decidim-comments (= 0.28.4) + decidim-core (= 0.28.4) + decidim-admin (0.28.4) + active_link_to (~> 1.0) + decidim-core (= 0.28.4) + devise (~> 4.7) + devise-i18n (~> 1.2) + devise_invitable (~> 2.0, >= 2.0.9) + decidim-api (0.28.4) + commonmarker (~> 0.23.0, >= 0.23.9) + decidim-core (= 0.28.4) + graphql (~> 2.0.0) + graphql-docs (~> 3.0.1) + rack-cors (~> 1.0) + decidim-assemblies (0.28.4) + decidim-core (= 0.28.4) + decidim-blogs (0.28.4) + decidim-admin (= 0.28.4) + decidim-comments (= 0.28.4) + decidim-core (= 0.28.4) + decidim-budgets (0.28.4) + decidim-comments (= 0.28.4) + decidim-core (= 0.28.4) + decidim-comments (0.28.4) + decidim-core (= 0.28.4) + redcarpet (~> 3.5, >= 3.5.1) + decidim-core (0.28.4) + active_link_to (~> 1.0) + acts_as_list (~> 1.0) + batch-loader (~> 1.2) + browser (~> 2.7) + carrierwave (~> 2.2.5, >= 2.2.5) + cells-erb (~> 0.1.0) + cells-rails (~> 0.1.3) + charlock_holmes (~> 0.7) + date_validator (~> 0.12.0) + devise (~> 4.7) + devise-i18n (~> 1.2, < 1.11.1) + diffy (~> 3.3) + doorkeeper (~> 5.6, >= 5.6.6) + doorkeeper-i18n (~> 4.0) + file_validators (~> 3.0) + fog-local (~> 0.6) + foundation_rails_helper (~> 4.0) + geocoder (~> 1.8) + hashdiff (>= 0.4.0, < 2.0.0) + invisible_captcha (~> 0.12) + kaminari (~> 1.2, >= 1.2.1) + loofah (~> 2.19, >= 2.19.1) + mime-types (>= 1.16, < 4.0) + mini_magick (~> 4.9) + net-smtp (~> 0.3.1) + omniauth (~> 2.0) + omniauth-facebook (~> 5.0) + omniauth-google-oauth2 (~> 1.0) + omniauth-rails_csrf_protection (~> 1.0) + omniauth-twitter (~> 1.4) + paper_trail (~> 12.0) + pg (~> 1.4.0, < 2) + pg_search (~> 2.2) + premailer-rails (~> 1.10) + psych (~> 4.0) + rack (~> 2.2, >= 2.2.6.4) + rack-attack (~> 6.0) + rails (~> 6.1.7, >= 6.1.7.4) + rails-i18n (~> 6.0) + ransack (~> 3.2.1) + redis (~> 4.1) + request_store (~> 1.5.0) + rubyXL (~> 3.4) + rubyzip (~> 2.0) + shakapacker (~> 7.1.0) + valid_email2 (~> 4.0) + web-push (~> 3.0) + wisper (~> 2.0) + decidim-debates (0.28.4) + decidim-comments (= 0.28.4) + decidim-core (= 0.28.4) + decidim-dev (0.28.4) + bullet (~> 7.0) + byebug (~> 11.0) + capybara (~> 3.39) + decidim (= 0.28.4) + erb_lint (~> 0.4.0) + factory_bot_rails (~> 6.2) + faker (~> 3.2) + i18n-tasks (~> 1.0) + nokogiri (~> 1.14, >= 1.14.3) + parallel_tests (~> 4.2) + puma (~> 6.2, >= 6.3.1) + rails-controller-testing (~> 1.0) + rspec (~> 3.12) + rspec-cells (~> 0.3.7) + rspec-html-matchers (~> 0.10) + rspec-rails (~> 6.0) + rspec-retry (~> 0.6.2) + rspec_junit_formatter (~> 0.6.0) + rubocop (~> 1.50.0) + rubocop-faker (~> 1.1) + rubocop-rails (~> 2.19) + rubocop-rspec (~> 2.20) + selenium-webdriver (~> 4.9) + simplecov (~> 0.22.0) + simplecov-cobertura (~> 2.1.0) + spring (~> 2.0) + spring-watcher-listen (~> 2.0) + w3c_rspec_validators (~> 0.3.0) + webmock (~> 3.18) + wisper-rspec (~> 1.0) + decidim-forms (0.28.4) + decidim-core (= 0.28.4) + wicked_pdf (~> 2.1) + wkhtmltopdf-binary (~> 0.12) + decidim-generators (0.28.4) + decidim-core (= 0.28.4) + decidim-initiatives (0.28.4) + decidim-admin (= 0.28.4) + decidim-comments (= 0.28.4) + decidim-core (= 0.28.4) + decidim-verifications (= 0.28.4) + hexapdf (~> 0.32.0) + wicked_pdf (~> 2.1) + wkhtmltopdf-binary (~> 0.12) + decidim-meetings (0.28.4) + decidim-core (= 0.28.4) + decidim-forms (= 0.28.4) + icalendar (~> 2.5) + decidim-pages (0.28.4) + decidim-core (= 0.28.4) + decidim-participatory_processes (0.28.4) + decidim-core (= 0.28.4) + decidim-proposals (0.28.4) + decidim-comments (= 0.28.4) + decidim-core (= 0.28.4) + doc2text (~> 0.4.6) + redcarpet (~> 3.5, >= 3.5.1) + decidim-sortitions (0.28.4) + decidim-admin (= 0.28.4) + decidim-comments (= 0.28.4) + decidim-core (= 0.28.4) + decidim-proposals (= 0.28.4) + decidim-surveys (0.28.4) + decidim-core (= 0.28.4) + decidim-forms (= 0.28.4) + decidim-system (0.28.4) + active_link_to (~> 1.0) + decidim-core (= 0.28.4) + devise (~> 4.7) + devise-i18n (~> 1.2) + devise_invitable (~> 2.0, >= 2.0.9) + decidim-templates (0.28.4) + decidim-core (= 0.28.4) + decidim-forms (= 0.28.4) + decidim-proposals (= 0.28.4) + decidim-verifications (0.28.4) + decidim-core (= 0.28.4) + +GIT + remote: https://github.com/AjuntamentdeBarcelona/decidim-internal-evaluation-module + revision: cf5eb7f00f957881ade8360a69655e92d95ceff0 + branch: release/0.28-stable + specs: + decidim-internal_evaluation (0.0.1) + decidim-core (~> 0.28.0) + decidim-proposals (~> 0.28.0) + decidim-templates (~> 0.28.0) + deface (~> 1.9) + GIT remote: https://github.com/AjuntamentdeBarcelona/decidim-module-kids revision: df16cf4de13c306348761d850d19815c8221874e @@ -18,7 +212,7 @@ GIT GIT remote: https://github.com/decidim-ice/decidim-module-decidim_awesome - revision: 84374037d34a3ac80dc18406834169c65869f11b + revision: a8d21e4e178f1965a6e3e73cf0c781cb78661e32 specs: decidim-decidim_awesome (0.11.2) decidim-admin (>= 0.28.0, < 0.29) @@ -60,49 +254,43 @@ PATH decidim-core (~> 0.28.0) decidim-proposals (~> 0.28.0) -PATH - remote: decidim-valid_auth - specs: - decidim-valid_auth (0.0.3) - decidim-verifications (~> 0.28.0) - GEM remote: https://rubygems.org/ specs: - actioncable (6.1.7.8) - actionpack (= 6.1.7.8) - activesupport (= 6.1.7.8) + actioncable (6.1.7.9) + actionpack (= 6.1.7.9) + activesupport (= 6.1.7.9) nio4r (~> 2.0) websocket-driver (>= 0.6.1) - actionmailbox (6.1.7.8) - actionpack (= 6.1.7.8) - activejob (= 6.1.7.8) - activerecord (= 6.1.7.8) - activestorage (= 6.1.7.8) - activesupport (= 6.1.7.8) + actionmailbox (6.1.7.9) + actionpack (= 6.1.7.9) + activejob (= 6.1.7.9) + activerecord (= 6.1.7.9) + activestorage (= 6.1.7.9) + activesupport (= 6.1.7.9) mail (>= 2.7.1) - actionmailer (6.1.7.8) - actionpack (= 6.1.7.8) - actionview (= 6.1.7.8) - activejob (= 6.1.7.8) - activesupport (= 6.1.7.8) + actionmailer (6.1.7.9) + actionpack (= 6.1.7.9) + actionview (= 6.1.7.9) + activejob (= 6.1.7.9) + activesupport (= 6.1.7.9) mail (~> 2.5, >= 2.5.4) rails-dom-testing (~> 2.0) - actionpack (6.1.7.8) - actionview (= 6.1.7.8) - activesupport (= 6.1.7.8) + actionpack (6.1.7.9) + actionview (= 6.1.7.9) + activesupport (= 6.1.7.9) rack (~> 2.0, >= 2.0.9) rack-test (>= 0.6.3) rails-dom-testing (~> 2.0) rails-html-sanitizer (~> 1.0, >= 1.2.0) - actiontext (6.1.7.8) - actionpack (= 6.1.7.8) - activerecord (= 6.1.7.8) - activestorage (= 6.1.7.8) - activesupport (= 6.1.7.8) + actiontext (6.1.7.9) + actionpack (= 6.1.7.9) + activerecord (= 6.1.7.9) + activestorage (= 6.1.7.9) + activesupport (= 6.1.7.9) nokogiri (>= 1.8.5) - actionview (6.1.7.8) - activesupport (= 6.1.7.8) + actionview (6.1.7.9) + activesupport (= 6.1.7.9) builder (~> 3.1) erubi (~> 1.4) rails-dom-testing (~> 2.0) @@ -110,31 +298,32 @@ GEM active_link_to (1.0.5) actionpack addressable - activejob (6.1.7.8) - activesupport (= 6.1.7.8) + activejob (6.1.7.9) + activesupport (= 6.1.7.9) globalid (>= 0.3.6) - activemodel (6.1.7.8) - activesupport (= 6.1.7.8) - activerecord (6.1.7.8) - activemodel (= 6.1.7.8) - activesupport (= 6.1.7.8) - activestorage (6.1.7.8) - actionpack (= 6.1.7.8) - activejob (= 6.1.7.8) - activerecord (= 6.1.7.8) - activesupport (= 6.1.7.8) + activemodel (6.1.7.9) + activesupport (= 6.1.7.9) + activerecord (6.1.7.9) + activemodel (= 6.1.7.9) + activesupport (= 6.1.7.9) + activestorage (6.1.7.9) + actionpack (= 6.1.7.9) + activejob (= 6.1.7.9) + activerecord (= 6.1.7.9) + activesupport (= 6.1.7.9) marcel (~> 1.0) mini_mime (>= 1.1.0) - activesupport (6.1.7.8) + activesupport (6.1.7.9) concurrent-ruby (~> 1.0, >= 1.0.2) i18n (>= 1.6, < 2) minitest (>= 5.1) tzinfo (~> 2.0) zeitwerk (~> 2.3) - acts_as_list (1.1.0) - activerecord (>= 4.2) - addressable (2.8.6) - public_suffix (>= 2.0.2, < 6.0) + acts_as_list (1.2.3) + activerecord (>= 6.1) + activesupport (>= 6.1) + addressable (2.8.7) + public_suffix (>= 2.0.2, < 7.0) ast (2.4.2) aws-eventstream (1.3.0) aws-partitions (1.896.0) @@ -158,20 +347,20 @@ GEM base64 (0.2.0) batch-loader (1.5.0) bcrypt (3.1.20) - better_html (2.0.2) + better_html (2.1.1) actionview (>= 6.0) activesupport (>= 6.0) ast (~> 2.0) erubi (~> 1.4) parser (>= 2.4) smart_properties - bigdecimal (3.1.6) + bigdecimal (3.1.8) bindex (0.8.1) bootsnap (1.18.3) msgpack (~> 1.2) browser (2.7.1) - builder (3.2.4) - bullet (7.1.6) + builder (3.3.0) + bullet (7.2.0) activesupport (>= 3.0.0) uniform_notifier (~> 1.11) byebug (11.1.3) @@ -184,7 +373,7 @@ GEM rack-test (>= 0.6.3) regexp_parser (>= 1.5, < 3.0) xpath (~> 3.2) - carrierwave (2.2.5) + carrierwave (2.2.6) activemodel (>= 5.0.0) activesupport (>= 5.0.0) addressable (~> 2.6) @@ -203,7 +392,7 @@ GEM cells-rails (0.1.5) actionpack (>= 5.0) cells (>= 4.1.6, < 5.0.0) - charlock_holmes (0.7.7) + charlock_holmes (0.7.9) chef-utils (18.1.0) concurrent-ruby cmdparse (3.0.7) @@ -212,14 +401,15 @@ GEM simplecov colorize (0.8.1) commonmarker (0.23.10) - concurrent-ruby (1.2.3) + concurrent-ruby (1.3.4) connection_pool (2.4.1) crack (1.0.0) bigdecimal rexml crass (1.0.6) - css_parser (1.16.0) + css_parser (1.19.1) addressable + csv (3.3.0) dalli (3.2.8) database_cleaner (2.0.2) database_cleaner-active_record (>= 2, < 3) @@ -231,179 +421,6 @@ GEM date_validator (0.12.0) activemodel (>= 3) activesupport (>= 3) - decidim (0.28.3) - decidim-accountability (= 0.28.3) - decidim-admin (= 0.28.3) - decidim-api (= 0.28.3) - decidim-assemblies (= 0.28.3) - decidim-blogs (= 0.28.3) - decidim-budgets (= 0.28.3) - decidim-comments (= 0.28.3) - decidim-core (= 0.28.3) - decidim-debates (= 0.28.3) - decidim-forms (= 0.28.3) - decidim-generators (= 0.28.3) - decidim-meetings (= 0.28.3) - decidim-pages (= 0.28.3) - decidim-participatory_processes (= 0.28.3) - decidim-proposals (= 0.28.3) - decidim-sortitions (= 0.28.3) - decidim-surveys (= 0.28.3) - decidim-system (= 0.28.3) - decidim-verifications (= 0.28.3) - decidim-accountability (0.28.3) - decidim-comments (= 0.28.3) - decidim-core (= 0.28.3) - decidim-admin (0.28.3) - active_link_to (~> 1.0) - decidim-core (= 0.28.3) - devise (~> 4.7) - devise-i18n (~> 1.2) - devise_invitable (~> 2.0, >= 2.0.9) - decidim-api (0.28.3) - commonmarker (~> 0.23.0, >= 0.23.9) - decidim-core (= 0.28.3) - graphql (~> 2.0.0) - graphql-docs (~> 3.0.1) - rack-cors (~> 1.0) - decidim-assemblies (0.28.3) - decidim-core (= 0.28.3) - decidim-blogs (0.28.3) - decidim-admin (= 0.28.3) - decidim-comments (= 0.28.3) - decidim-core (= 0.28.3) - decidim-budgets (0.28.3) - decidim-comments (= 0.28.3) - decidim-core (= 0.28.3) - decidim-comments (0.28.3) - decidim-core (= 0.28.3) - redcarpet (~> 3.5, >= 3.5.1) - decidim-core (0.28.3) - active_link_to (~> 1.0) - acts_as_list (~> 1.0) - batch-loader (~> 1.2) - browser (~> 2.7) - carrierwave (~> 2.2.5, >= 2.2.5) - cells-erb (~> 0.1.0) - cells-rails (~> 0.1.3) - charlock_holmes (~> 0.7) - date_validator (~> 0.12.0) - devise (~> 4.7) - devise-i18n (~> 1.2, < 1.11.1) - diffy (~> 3.3) - doorkeeper (~> 5.6, >= 5.6.6) - doorkeeper-i18n (~> 4.0) - file_validators (~> 3.0) - fog-local (~> 0.6) - foundation_rails_helper (~> 4.0) - geocoder (~> 1.8) - hashdiff (>= 0.4.0, < 2.0.0) - invisible_captcha (~> 0.12) - kaminari (~> 1.2, >= 1.2.1) - loofah (~> 2.19, >= 2.19.1) - mime-types (>= 1.16, < 4.0) - mini_magick (~> 4.9) - net-smtp (~> 0.3.1) - omniauth (~> 2.0) - omniauth-facebook (~> 5.0) - omniauth-google-oauth2 (~> 1.0) - omniauth-rails_csrf_protection (~> 1.0) - omniauth-twitter (~> 1.4) - paper_trail (~> 12.0) - pg (~> 1.4.0, < 2) - pg_search (~> 2.2) - premailer-rails (~> 1.10) - psych (~> 4.0) - rack (~> 2.2, >= 2.2.6.4) - rack-attack (~> 6.0) - rails (~> 6.1.7, >= 6.1.7.4) - rails-i18n (~> 6.0) - ransack (~> 3.2.1) - redis (~> 4.1) - request_store (~> 1.5.0) - rubyXL (~> 3.4) - rubyzip (~> 2.0) - shakapacker (~> 7.1.0) - valid_email2 (~> 4.0) - web-push (~> 3.0) - wisper (~> 2.0) - decidim-debates (0.28.3) - decidim-comments (= 0.28.3) - decidim-core (= 0.28.3) - decidim-dev (0.28.3) - bullet (~> 7.0) - byebug (~> 11.0) - capybara (~> 3.39) - decidim (= 0.28.3) - erb_lint (~> 0.4.0) - factory_bot_rails (~> 6.2) - faker (~> 3.2) - i18n-tasks (~> 1.0) - nokogiri (~> 1.14, >= 1.14.3) - parallel_tests (~> 4.2) - puma (~> 6.2, >= 6.3.1) - rails-controller-testing (~> 1.0) - rspec (~> 3.12) - rspec-cells (~> 0.3.7) - rspec-html-matchers (~> 0.10) - rspec-rails (~> 6.0) - rspec-retry (~> 0.6.2) - rspec_junit_formatter (~> 0.6.0) - rubocop (~> 1.50.0) - rubocop-faker (~> 1.1) - rubocop-rails (~> 2.19) - rubocop-rspec (~> 2.20) - selenium-webdriver (~> 4.9) - simplecov (~> 0.22.0) - simplecov-cobertura (~> 2.1.0) - spring (~> 2.0) - spring-watcher-listen (~> 2.0) - w3c_rspec_validators (~> 0.3.0) - webmock (~> 3.18) - wisper-rspec (~> 1.0) - decidim-forms (0.28.3) - decidim-core (= 0.28.3) - wicked_pdf (~> 2.1) - wkhtmltopdf-binary (~> 0.12) - decidim-generators (0.28.3) - decidim-core (= 0.28.3) - decidim-initiatives (0.28.3) - decidim-admin (= 0.28.3) - decidim-comments (= 0.28.3) - decidim-core (= 0.28.3) - decidim-verifications (= 0.28.3) - hexapdf (~> 0.32.0) - wicked_pdf (~> 2.1) - wkhtmltopdf-binary (~> 0.12) - decidim-meetings (0.28.3) - decidim-core (= 0.28.3) - decidim-forms (= 0.28.3) - icalendar (~> 2.5) - decidim-pages (0.28.3) - decidim-core (= 0.28.3) - decidim-participatory_processes (0.28.3) - decidim-core (= 0.28.3) - decidim-proposals (0.28.3) - decidim-comments (= 0.28.3) - decidim-core (= 0.28.3) - doc2text (~> 0.4.6) - redcarpet (~> 3.5, >= 3.5.1) - decidim-sortitions (0.28.3) - decidim-admin (= 0.28.3) - decidim-comments (= 0.28.3) - decidim-core (= 0.28.3) - decidim-proposals (= 0.28.3) - decidim-surveys (0.28.3) - decidim-core (= 0.28.3) - decidim-forms (= 0.28.3) - decidim-system (0.28.3) - active_link_to (~> 1.0) - decidim-core (= 0.28.3) - devise (~> 4.7) - devise-i18n (~> 1.2) - devise_invitable (~> 2.0, >= 2.0.9) - decidim-verifications (0.28.3) - decidim-core (= 0.28.3) declarative-builder (0.1.0) declarative-option (< 0.2.0) declarative-option (0.1.0) @@ -430,7 +447,7 @@ GEM nokogiri (>= 1.13.2, < 1.17.0) rubyzip (~> 2.3.0) docile (1.4.0) - doorkeeper (5.6.9) + doorkeeper (5.7.1) railties (>= 5) doorkeeper-i18n (4.0.1) dotenv (3.1.0) @@ -446,27 +463,29 @@ GEM smart_properties erbse (0.1.4) temple - erubi (1.12.0) + erubi (1.13.0) escape_utils (1.2.2) - excon (0.109.0) + excon (0.112.0) extended-markdown-filter (0.7.0) html-pipeline (~> 2.9) - factory_bot (6.4.6) + factory_bot (6.5.0) activesupport (>= 5.0.0) factory_bot_rails (6.4.3) factory_bot (~> 6.4) railties (>= 5.0.0) faker (3.2.3) i18n (>= 1.8.11, < 2) - faraday (2.9.0) - faraday-net_http (>= 2.0, < 3.2) - faraday-net_http (3.1.0) + faraday (2.12.0) + faraday-net_http (>= 2.0, < 3.4) + json + logger + faraday-net_http (3.3.0) net-http ffi (1.16.3) file_validators (3.0.0) activemodel (>= 3.2) mime-types (>= 1.0) - fog-core (2.4.0) + fog-core (2.5.0) builder excon (~> 0.71) formatador (>= 0.2, < 2.0) @@ -481,13 +500,15 @@ GEM activesupport (>= 4.1, < 7.1) railties (>= 4.1, < 7.1) gemoji (3.0.1) - geocoder (1.8.2) + geocoder (1.8.3) + base64 (>= 0.1.0) + csv (>= 3.0.0) geom2d (0.4.1) get_process_mem (0.2.7) ffi (~> 1.0) globalid (1.2.1) activesupport (>= 6.1) - graphql (2.0.29) + graphql (2.0.31) base64 graphql-docs (3.0.1) commonmarker (~> 0.16) @@ -497,23 +518,23 @@ GEM graphql (~> 2.0) html-pipeline (~> 2.9) sass (~> 3.4) - hashdiff (1.1.0) + hashdiff (1.1.1) hashie (5.0.0) hexapdf (0.32.2) cmdparse (~> 3.0, >= 3.0.3) geom2d (~> 0.3) openssl (>= 2.2.1) - highline (3.0.1) + highline (3.1.1) + reline html-pipeline (2.14.3) activesupport (>= 2) nokogiri (>= 1.4) htmlentities (4.3.4) - i18n (1.14.4) + i18n (1.14.6) concurrent-ruby (~> 1.0) - i18n-tasks (1.0.13) + i18n-tasks (1.0.14) activesupport (>= 4.0.2) ast (>= 2.1.0) - better_html (>= 1.0, < 3.0) erubi highline (>= 2.0.0) i18n @@ -521,17 +542,19 @@ GEM rails-i18n rainbow (>= 2.2.2, < 4.0) terminal-table (>= 1.5.1) - icalendar (2.10.1) + icalendar (2.10.3) ice_cube (~> 0.16) - ice_cube (0.16.4) - image_processing (1.12.2) + ostruct + ice_cube (0.17.0) + image_processing (1.13.0) mini_magick (>= 4.9.5, < 5) ruby-vips (>= 2.0.17, < 3) invisible_captcha (0.13.0) rails (>= 3.2.0) + io-console (0.7.2) jmespath (1.6.2) - json (2.7.1) - jwt (2.8.1) + json (2.7.2) + jwt (2.9.3) base64 kaminari (1.2.2) activesupport (>= 4.1.0) @@ -561,6 +584,7 @@ GEM listen (3.9.0) rb-fsevent (~> 0.10, >= 0.10.3) rb-inotify (~> 0.9, >= 0.9.10) + logger (1.6.1) lograge (0.14.0) actionpack (>= 4) activesupport (>= 4) @@ -582,13 +606,14 @@ GEM mixlib-cli (~> 2.1, >= 2.1.1) mixlib-config (>= 2.2.1, < 4) mixlib-shellout - method_source (1.0.0) - mime-types (3.5.2) + method_source (1.1.0) + mime-types (3.6.0) + logger mime-types-data (~> 3.2015) - mime-types-data (3.2024.0305) - mini_magick (4.12.0) + mime-types-data (3.2024.1001) + mini_magick (4.13.2) mini_mime (1.1.5) - minitest (5.22.3) + minitest (5.25.1) mixlib-cli (2.1.8) mixlib-config (3.0.27) tomlrb @@ -599,7 +624,7 @@ GEM multi_xml (0.6.0) net-http (0.4.1) uri - net-imap (0.4.10) + net-imap (0.4.17) date net-protocol net-pop (0.1.2) @@ -608,12 +633,12 @@ GEM timeout net-smtp (0.3.4) net-protocol - nio4r (2.7.0) - nokogiri (1.16.2-aarch64-linux) + nio4r (2.7.3) + nokogiri (1.16.7-aarch64-linux) racc (~> 1.4) - nokogiri (1.16.2-arm64-darwin) + nokogiri (1.16.7-arm64-darwin) racc (~> 1.4) - nokogiri (1.16.2-x86_64-linux) + nokogiri (1.16.7-x86_64-linux) racc (~> 1.4) oauth (1.1.0) oauth-tty (~> 1.0, >= 1.0.1) @@ -634,18 +659,19 @@ GEM rack-protection omniauth-facebook (5.0.0) omniauth-oauth2 (~> 1.2) - omniauth-google-oauth2 (1.1.1) - jwt (>= 2.0) - oauth2 (~> 2.0.6) + omniauth-google-oauth2 (1.2.0) + jwt (>= 2.9) + oauth2 (~> 2.0) omniauth (~> 2.0) - omniauth-oauth2 (~> 1.8.0) - omniauth-oauth (1.2.0) + omniauth-oauth2 (~> 1.8) + omniauth-oauth (1.2.1) oauth omniauth (>= 1.0, < 3) + rack (>= 1.6.2, < 4) omniauth-oauth2 (1.8.0) oauth2 (>= 1.4, < 3) omniauth (~> 2.0) - omniauth-rails_csrf_protection (1.0.1) + omniauth-rails_csrf_protection (1.0.2) actionpack (>= 4.2) omniauth (~> 2.0) omniauth-twitter (1.4.0) @@ -655,23 +681,24 @@ GEM origami (2.1.0) colorize (~> 0.7) orm_adapter (0.5.0) + ostruct (0.6.0) paper_trail (12.3.0) activerecord (>= 5.2) request_store (~> 1.1) - parallel (1.24.0) - parallel_tests (4.5.2) + parallel (1.26.3) + parallel_tests (4.7.2) parallel - parser (3.3.0.5) + parser (3.3.5.0) ast (~> 2.4.1) racc pg (1.4.6) - pg_search (2.3.6) - activerecord (>= 5.2) - activesupport (>= 5.2) + pg_search (2.3.7) + activerecord (>= 6.1) + activesupport (>= 6.1) polyglot (0.3.5) - premailer (1.23.0) + premailer (1.27.0) addressable - css_parser (>= 1.12.0) + css_parser (>= 1.19.0) htmlentities (>= 4.0.0) premailer-rails (1.12.0) actionmailer (>= 3) @@ -680,14 +707,14 @@ GEM progressbar (1.13.0) psych (4.0.6) stringio - public_suffix (5.0.4) + public_suffix (6.0.1) puma (6.4.2) nio4r (~> 2.0) puma_worker_killer (0.3.1) get_process_mem (~> 0.2) puma (>= 2.7) - racc (1.7.3) - rack (2.2.8.1) + racc (1.8.1) + rack (2.2.10) rack-attack (6.7.0) rack (>= 1.0, < 4) rack-cors (1.1.1) @@ -702,20 +729,20 @@ GEM rack (>= 1.3) rack-timeout (0.6.3) rack_password (1.3) - rails (6.1.7.8) - actioncable (= 6.1.7.8) - actionmailbox (= 6.1.7.8) - actionmailer (= 6.1.7.8) - actionpack (= 6.1.7.8) - actiontext (= 6.1.7.8) - actionview (= 6.1.7.8) - activejob (= 6.1.7.8) - activemodel (= 6.1.7.8) - activerecord (= 6.1.7.8) - activestorage (= 6.1.7.8) - activesupport (= 6.1.7.8) + rails (6.1.7.9) + actioncable (= 6.1.7.9) + actionmailbox (= 6.1.7.9) + actionmailer (= 6.1.7.9) + actionpack (= 6.1.7.9) + actiontext (= 6.1.7.9) + actionview (= 6.1.7.9) + activejob (= 6.1.7.9) + activemodel (= 6.1.7.9) + activerecord (= 6.1.7.9) + activestorage (= 6.1.7.9) + activesupport (= 6.1.7.9) bundler (>= 1.15.0) - railties (= 6.1.7.8) + railties (= 6.1.7.9) sprockets-rails (>= 2.0.0) rails-controller-testing (1.0.5) actionpack (>= 5.0.1.rc1) @@ -737,32 +764,34 @@ GEM rails_autoscale_agent (0.12.0) rails_serve_static_assets (0.0.5) rails_stdout_logging (0.0.5) - railties (6.1.7.8) - actionpack (= 6.1.7.8) - activesupport (= 6.1.7.8) + railties (6.1.7.9) + actionpack (= 6.1.7.9) + activesupport (= 6.1.7.9) method_source rake (>= 12.2) thor (~> 1.0) rainbow (3.1.1) - rake (13.1.0) + rake (13.2.1) ransack (3.2.1) activerecord (>= 6.1.5) activesupport (>= 6.1.5) i18n rb-fsevent (0.11.2) - rb-inotify (0.10.1) + rb-inotify (0.11.1) ffi (~> 1.0) redcarpet (3.6.0) redis (4.8.1) redis-client (0.21.0) connection_pool - regexp_parser (2.9.0) + regexp_parser (2.9.2) + reline (0.5.10) + io-console (~> 0.5) request_store (1.5.1) rack (>= 1.4) responders (3.1.1) actionpack (>= 5.2) railties (>= 5.2) - rexml (3.2.6) + rexml (3.3.8) rspec (3.13.0) rspec-core (~> 3.13.0) rspec-expectations (~> 3.13.0) @@ -781,14 +810,14 @@ GEM rspec-mocks (3.13.0) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.13.0) - rspec-rails (6.1.1) + rspec-rails (6.1.5) actionpack (>= 6.1) activesupport (>= 6.1) railties (>= 6.1) - rspec-core (~> 3.12) - rspec-expectations (~> 3.12) - rspec-mocks (~> 3.12) - rspec-support (~> 3.12) + rspec-core (~> 3.13) + rspec-expectations (~> 3.13) + rspec-mocks (~> 3.13) + rspec-support (~> 3.13) rspec-retry (0.6.2) rspec-core (> 3.3) rspec-support (3.13.1) @@ -823,9 +852,10 @@ GEM rubocop-capybara (~> 2.17) rubocop-factory_bot (~> 2.22) ruby-progressbar (1.13.0) - ruby-vips (2.2.1) + ruby-vips (2.2.2) ffi (~> 1.12) - rubyXL (3.4.25) + logger + rubyXL (3.4.27) nokogiri (>= 1.10.8) rubyzip (>= 1.3.0) rubyzip (2.3.2) @@ -838,8 +868,9 @@ GEM ffi (~> 1.9) scout_apm (5.3.7) parser - selenium-webdriver (4.18.1) + selenium-webdriver (4.25.0) base64 (~> 0.2) + logger (~> 1.4) rexml (~> 3.2, >= 3.2.5) rubyzip (>= 1.2.2, < 3.0) websocket (~> 1.0) @@ -882,31 +913,31 @@ GEM sprockets (4.2.1) concurrent-ruby (~> 1.0) rack (>= 2.2.4, < 4) - sprockets-rails (3.4.2) - actionpack (>= 5.2) - activesupport (>= 5.2) + sprockets-rails (3.5.2) + actionpack (>= 6.1) + activesupport (>= 6.1) sprockets (>= 3.0.0) ssrf_filter (1.1.2) stackprof (0.2.26) statsd-ruby (1.5.0) - stringio (3.1.0) + stringio (3.1.1) temple (0.10.3) terminal-table (3.0.2) unicode-display_width (>= 1.1.1, < 3) - thor (1.3.1) - tilt (2.3.0) + thor (1.3.2) + tilt (2.4.0) timeout (0.4.1) tomlrb (2.0.3) tzinfo (2.0.6) concurrent-ruby (~> 1.0) uber (0.1.0) - unicode-display_width (2.5.0) + unicode-display_width (2.6.0) uniform_notifier (1.16.0) - uri (0.13.0) + uri (0.13.1) valid_email2 (4.0.6) activemodel (>= 3.2) mail (~> 2.5) - version_gem (1.1.3) + version_gem (1.1.4) w3c_rspec_validators (0.3.0) rails rspec @@ -925,11 +956,11 @@ GEM web-push (3.0.1) jwt (~> 2.0) openssl (~> 3.0) - webmock (3.23.0) + webmock (3.24.0) addressable (>= 2.8.0) crack (>= 0.3.2) hashdiff (>= 0.4.0, < 2.0.0) - websocket (1.2.10) + websocket (1.2.11) websocket-driver (0.7.6) websocket-extensions (>= 0.1.0) websocket-extensions (0.1.5) @@ -940,7 +971,7 @@ GEM wkhtmltopdf-binary (0.12.6.6) xpath (3.2.0) nokogiri (~> 1.8) - zeitwerk (2.6.13) + zeitwerk (2.6.18) PLATFORMS aarch64-linux @@ -956,19 +987,20 @@ DEPENDENCIES codecov dalli database_cleaner - decidim (= 0.28.3) + decidim! decidim-census_sms! decidim-dataviz! decidim-decidim_awesome! - decidim-dev (= 0.28.3) + decidim-dev! decidim-ephemeral_participation! - decidim-initiatives (= 0.28.3) + decidim-initiatives! + decidim-internal_evaluation! decidim-kids! decidim-navigation_maps! - decidim-sortitions (= 0.28.3) + decidim-sortitions! decidim-stats! + decidim-templates! decidim-term_customizer! - decidim-valid_auth! dotenv-rails faker foreman diff --git a/README.md b/README.md index e0f0df906..f7f1ce826 100644 --- a/README.md +++ b/README.md @@ -9,9 +9,7 @@ Citizen Participation and Open Government Application. [![[CI] Lint](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/lint.yml/badge.svg)](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/lint.yml) [![[CI] Test](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/test.yml/badge.svg)](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/test.yml) [![[CI] Test Census SMS](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/test_census_sms.yml/badge.svg)](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/test_census_sms.yml) -[![[CI] Test Ephemeral Participation](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/test_ephemeral_participation.yml/badge.svg)](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/test_ephemeral_participation.yml) [![[CI] Test Stats](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/test_stats.yml/badge.svg)](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/test_stats.yml) -[![[CI] Test Valid Auth](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/test_valid_auth.yml/badge.svg)](https://github.com/AjuntamentdeBarcelona/decidim-barcelona/actions/workflows/test_valid_auth.yml) [![Code Climate](https://codeclimate.com/github/AjuntamentdeBarcelona/decidim-barcelona/badges/gpa.svg)](https://codeclimate.com/github/AjuntamentdeBarcelona/decidim-barcelona) This is the opensource code repository for "decidim-barcelona", based on [Decidim](https://github.com/AjuntamentdeBarcelona/decidim). diff --git a/app/packs/entrypoints/decidim_barcelona_email.scss b/app/packs/entrypoints/decidim_barcelona_email.scss index 0c95ab6a7..06c51c1ac 100644 --- a/app/packs/entrypoints/decidim_barcelona_email.scss +++ b/app/packs/entrypoints/decidim_barcelona_email.scss @@ -1,2 +1 @@ - -@import "stylesheets/email.scss"; \ No newline at end of file +@import "stylesheets/email.scss"; diff --git a/app/packs/images/bcn-logo-mobile.svg b/app/packs/images/bcn-logo-mobile.svg new file mode 100644 index 000000000..e8394d940 --- /dev/null +++ b/app/packs/images/bcn-logo-mobile.svg @@ -0,0 +1,4 @@ + diff --git a/app/packs/images/bcn-logo.svg b/app/packs/images/bcn-logo.svg new file mode 100644 index 000000000..27e7a2c29 --- /dev/null +++ b/app/packs/images/bcn-logo.svg @@ -0,0 +1,6 @@ + diff --git a/app/packs/stylesheets/decidim/decidim_application.scss b/app/packs/stylesheets/decidim/decidim_application.scss index 6a1261577..f4d4f6194 100644 --- a/app/packs/stylesheets/decidim/decidim_application.scss +++ b/app/packs/stylesheets/decidim/decidim_application.scss @@ -29,3 +29,137 @@ } } } + +.main-header__language-container > #trigger-dropdown-language-chooser { + gap: 0.1rem !important; + flex-direction: column; + padding: 0.25rem 0.5rem; + + span { + display: block; + font-weight: 400; + color: rgb(var(--secondary-rgb) / 1); + font-size: 14px; + } + + svg { + fill: rgb(var(--secondary-rgb) / 1); + } +} + +.main-footer__language { + z-index: 1000; +} + +.main-header__language-container > #trigger-dropdown-language-chooser:hover { + background-color: #f3f4f7 !important; + border-radius: 0.25rem; + text-decoration: underline; + text-decoration-color: rgb(var(--secondary-rgb) / 1); +} + +#dropdown-menu-language-chooser { + margin-left: 0 !important; + margin-right: 0 !important; + align-items: center !important; +} + +#dropdown-menu-language-chooser > ul > li > a { + font-size: 14px; + padding: 0.5rem; +} + +.mobile_menu__language-container { + padding-top: 12px; + padding-bottom: 12px; +} + +.brand-bar { + padding-top: 0.2rem !important; + padding-bottom: 0.2rem !important; + display: flex; + flex-direction: row; + justify-content: space-between; + width: auto; +} + +.bcn-cat-link > a { + font-weight: 600; + font-size: 20px; + color: black; + line-height: 35px; + letter-spacing: -0.5px; + background-size: 0; + text-decoration: none; + font-family: "Source Sans Pro"; +} + +.logo-mobile { + display: none; +} + +.logo-desktop { + padding-right: 0; +} + +.bcn-cat-link > a:hover { + text-decoration: underline; +} + +body > div.layout-container > header > div.brand-bar > div.bcn-logo > a > span { + display: none; +} + +@media screen and (max-width: 1279px) { + .brand-bar { + padding-right: 1rem !important; + } +} + +@media screen and (max-width: 1024px) { + .logo-desktop { + display: none; + } + + .logo-mobile { + display: block; + } +} + +@media (min-width: 768px) { + .main-header__language-container > #trigger-dropdown-language-chooser { + display: flex !important; + } +} + +@media (max-width: 1023px) { + .main-header__language-container > #trigger-dropdown-language-chooser { + flex-direction: row !important; + } + + #trigger-dropdown-language-chooser > svg { + display: none; + } + + #trigger-dropdown-language-chooser > div > svg { + display: none; + } + + #dropdown-menu-main-mobile > div.main-header__language-container { + display: flex; + flex-direction: row; + width: 10rem; + margin: auto; + color: rgb(168 44 44) !important; + font-weight: 600 !important; + } + + #dropdown-menu-language-chooser > ul > li > a, + #dropdown-menu-language-chooser > ul > li, + #trigger-dropdown-language-chooser > div > span, + #trigger-dropdown-language-chooser { + padding: 0 !important; + font-size: 1rem !important; + font-weight: 600 !important; + } +} diff --git a/app/packs/stylesheets/email.scss b/app/packs/stylesheets/email.scss index dd5360584..aa5a7d47e 100644 --- a/app/packs/stylesheets/email.scss +++ b/app/packs/stylesheets/email.scss @@ -7,6 +7,48 @@ /* 1 - Foundation settings --------- */ +$email-primary: #ffe27f; +$email-secondary: #4869ad; +$email-tertiary: #73caea; + +$email-dark-0: #666d7a; +$email-dark-100: #2c2930; + +$email-neutral-0: #fff; +$email-neutral-100: #fefefe; +$email-neutral-200: #f4f4f4; +$email-neutral-250: #f3f3f3; +$email-neutral-300: #ebebeb; +$email-neutral-350: #e5e5e5; +$email-neutral-400: #cbcbcb; +$email-neutral-450: #cacaca; +$email-neutral-500: #919191; +$email-neutral-550: #8a8a8a; +$email-neutral-600: #777; +$email-neutral-700: #666; +$email-neutral-800: #444; +$email-neutral-900: #000; +$email-neutral-1000: #0a0a0a; + +$email-success-0: #e1faea; +$email-success-100: #3adb76; +$email-success-200: #23bf5d; +$email-success-300: #1b9448; + +$email-alert-0: #fce6e2; +$email-alert-100: #ec5840; +$email-alert-200: #e23317; +$email-alert-300: #b42912; + +$email-warning-0: #fff3d9; +$email-warning-100: #ffae00; +$email-warning-200: #cc8b00; +$email-warning-300: #996800; + +$email-link-0: #def0fc; +$email-link-100: #5295ad; +$email-link-200: #147dc2; + .wrapper { width: 100%; } @@ -101,12 +143,12 @@ td { @media only screen { html { min-height: 100%; - background: #f3f3f3; + background: $email-neutral-250; } } table.body { - background: #f3f3f3; + background: $email-neutral-250; height: 100%; width: 100%; } @@ -1015,7 +1057,7 @@ p, td, th, a { - color: #0a0a0a; + color: $email-neutral-1000; font-family: Helvetica, Arial, sans-serif; font-weight: normal; padding: 0; @@ -1084,29 +1126,29 @@ p.subheader { margin-bottom: 8px; font-weight: normal; line-height: 1.4; - color: #8a8a8a; + color: $email-neutral-550; } small { font-size: 80%; - color: #cacaca; + color: $email-neutral-450; } a { - color: #5295ad; + color: $email-link-100; text-decoration: none; } a:hover { - color: #147dc2; + color: $email-link-200; } a:active { - color: #147dc2; + color: $email-link-200; } a:visited { - color: #5295ad; + color: $email-link-100; } h1 a, @@ -1121,25 +1163,25 @@ h5 a, h5 a:visited, h6 a, h6 a:visited { - color: #5295ad; + color: $email-link-100; } pre { - background: #f3f3f3; + background: $email-neutral-250; margin: 30px 0; } pre code { - color: #cacaca; + color: $email-neutral-450; } pre code span.callout { - color: #8a8a8a; + color: $email-neutral-550; font-weight: bold; } pre code span.callout-strong { - color: #ff6908; + color: $email-alert-100; font-weight: bold; } @@ -1152,7 +1194,7 @@ table.hr th { max-width: 580px; border-top: 0; border-right: 0; - border-bottom: 1px solid #0a0a0a; + border-bottom: 1px solid $email-neutral-1000; border-left: 0; margin: 20px auto; clear: both; @@ -1173,7 +1215,7 @@ span.preheader { visibility: hidden; mso-hide: all !important; font-size: 1px; - color: #f3f3f3; + color: $email-neutral-250; line-height: 1px; max-height: 0; max-width: 0; @@ -1189,24 +1231,24 @@ table.button { table.button table td { text-align: left; - color: #fefefe; - background: #c24b29; - border: 2px solid #c24b29; + color: $email-neutral-100; + background: $primary; + border: 2px solid $primary; } table.button table td a { font-family: Helvetica, Arial, sans-serif; font-size: 16px; - color: #fefefe; + color: $email-neutral-900 !important; text-decoration: none; display: inline-block; padding: 8px 16px; - border: 0 solid #c24b29; + border: 0 solid $primary; border-radius: 3px; } table.button.radius table td { - border-radius: 3px; + border-radius: 4px; border: none; } @@ -1227,7 +1269,7 @@ table.button.small table tr td a:visited, table.button.large:hover table tr td a, table.button.large:active table tr td a, table.button.large table tr td a:visited { - color: #fefefe; + color: $email-neutral-100; } table.button.tiny table td, @@ -1290,97 +1332,97 @@ table.button.expanded center { table.button:hover table td, table.button:visited table td, table.button:active table td { - background: #147dc2; - color: #fefefe; + background: $primary; + color: $email-neutral-100; } table.button:hover table a, table.button:visited table a, table.button:active table a { - border: 0 solid #147dc2; + border: 0 solid $email-link-200; } table.button.secondary table td { - background: #777; - color: #fefefe; - border: 0 solid #777; + background: $email-neutral-600; + color: $email-neutral-100; + border: 0 solid $email-neutral-600; } table.button.secondary table a { - color: #fefefe; - border: 0 solid #777; + color: $email-neutral-100; + border: 0 solid $email-neutral-600; } table.button.secondary:hover table td { - background: #919191; - color: #fefefe; + background: $email-neutral-500; + color: $email-neutral-100; } table.button.secondary:hover table a { - border: 0 solid #919191; + border: 0 solid $email-neutral-500; } table.button.secondary:hover table td a { - color: #fefefe; + color: $email-neutral-100; } table.button.secondary:active table td a { - color: #fefefe; + color: $email-neutral-100; } table.button.secondary table td a:visited { - color: #fefefe; + color: $email-neutral-100; } table.button.success table td { - background: #3adb76; - border: 0 solid #3adb76; + background: $email-success-100; + border: 0 solid $email-success-100; } table.button.success table a { - border: 0 solid #3adb76; + border: 0 solid $email-success-100; } table.button.success:hover table td { - background: #23bf5d; + background: $email-success-200; } table.button.success:hover table a { - border: 0 solid #23bf5d; + border: 0 solid $email-success-200; } table.button.alert table td { - background: #ec5840; - border: 0 solid #ec5840; + background: $email-alert-100; + border: 0 solid $email-alert-100; } table.button.alert table a { - border: 0 solid #ec5840; + border: 0 solid $email-alert-100; } table.button.alert:hover table td { - background: #e23317; + background: $email-alert-200; } table.button.alert:hover table a { - border: 0 solid #e23317; + border: 0 solid $email-alert-200; } table.button.warning table td { - background: #ffae00; - border: 0 solid #ffae00; + background: $email-warning-100; + border: 0 solid $email-warning-100; } table.button.warning table a { - border: 0 solid #ffae00; + border: 0 solid $email-warning-100; } table.button.warning:hover table td { - background: #cc8b00; + background: $email-warning-200; } table.button.warning:hover table a { - border: 0 solid #cc8b00; + border: 0 solid $email-warning-200; } table.callout { @@ -1389,43 +1431,43 @@ table.callout { th.callout-inner { width: 100%; - border: 1px solid #cbcbcb; + border: 1px solid $email-neutral-400; padding: 10px; - background: #fefefe; + background: $email-neutral-100; } th.callout-inner.primary { - background: #def0fc; - border: 1px solid #444; - color: #0a0a0a; + background: $email-link-0; + border: 1px solid $email-neutral-800; + color: $email-neutral-1000; } th.callout-inner.secondary { - background: #ebebeb; - border: 1px solid #444; - color: #0a0a0a; + background: $email-neutral-300; + border: 1px solid $email-neutral-800; + color: $email-neutral-1000; } th.callout-inner.success { - background: #e1faea; - border: 1px solid #1b9448; - color: #fefefe; + background: $email-success-0; + border: 1px solid $email-success-300; + color: $email-neutral-100; } th.callout-inner.warning { - background: #fff3d9; - border: 1px solid #996800; - color: #fefefe; + background: $email-warning-0; + border: 1px solid $email-warning-300; + color: $email-neutral-100; } th.callout-inner.alert { - background: #fce6e2; - border: 1px solid #b42912; - color: #fefefe; + background: $email-alert-0; + border: 1px solid $email-alert-300; + color: $email-neutral-100; } .thumbnail { - border: solid 4px #fefefe; + border: solid 4px $email-neutral-100; box-shadow: 0 0 0 1px rgba(10, 10, 10, 0.2); display: inline-block; line-height: 0; @@ -1452,7 +1494,7 @@ table.menu th.menu-item { table.menu td.menu-item a, table.menu th.menu-item a { - color: #5295ad; + color: $email-link-100; } table.menu.vertical td.menu-item, @@ -1724,11 +1766,11 @@ body.outlook p { table.body th.decidim-bar, table.body td.decidim-bar { padding: 10px 0; - background-color: #f3f3f3; + background-color: $email-primary; } table.body { - background-color: #f3f3f3; + background-color: $email-neutral-250; margin: 20px 0; } @@ -1742,7 +1784,7 @@ table.body { } .cityhall-bar { - background-color: #2c2930; + background-color: $email-dark-100; } .cityhall-logo { @@ -1753,12 +1795,12 @@ table.body { .footnote, .headnote { padding-top: 10px; - color: #666; + color: $email-neutral-700; font-size: 12px; } table.container.main { - background: #fefefe; + background: $email-neutral-100; } .custom-button { @@ -1794,7 +1836,7 @@ td { margin-bottom: 32px; font-size: 16px; font-weight: bold; - color: #2c2930; + color: $email-dark-100; display: inline-block; width: 49%; @@ -1809,16 +1851,16 @@ td { } .email-content-notifications { - background-color: #f4f4f4; + background-color: $email-neutral-200; border-radius: 5px; - border: 1px #e5e5e5; + border: 1px $email-neutral-350; padding: 16px; margin: 32px 0; } .email-content-notification { p a { - color: #327f9b; + color: $email-link-100; font-weight: bold; text-decoration: underline; } @@ -1826,15 +1868,15 @@ td { .email-element-separator { margin: 24px 0; - color: #e5e5e5; - border-color: #e5e5e5; + color: $email-neutral-350; + border-color: $email-neutral-350; height: 0; border-style: solid; border-width: 1px; } .email-notification-date { - color: #666d7a; + color: $email-dark-0; display: block; margin-bottom: 10px; } @@ -1850,7 +1892,7 @@ td { text-align: center; display: inline-block; padding: 10px; - color: #5295ad; + color: $email-link-100; text-decoration: none; } } diff --git a/app/permissions/concerns/decidim/initiatives/admin/permissions_override.rb b/app/permissions/concerns/decidim/initiatives/admin/permissions_override.rb index aa227f763..d6d535853 100644 --- a/app/permissions/concerns/decidim/initiatives/admin/permissions_override.rb +++ b/app/permissions/concerns/decidim/initiatives/admin/permissions_override.rb @@ -10,8 +10,8 @@ def initiative_admin_user_action? return unless permission_action.subject == :initiative case permission_action.action - when :read - toggle_allow(Decidim::Initiatives.print_enabled) + when :print + toggle_allow(Decidim::Initiatives.print_enabled && user.admin?) when :publish, :discard toggle_allow(initiative.validating?) when :unpublish diff --git a/app/views/decidim/accountability/results/_scope_filters.html.erb b/app/views/decidim/accountability/results/_scope_filters.html.erb index 7c648c9d6..8a1002278 100644 --- a/app/views/decidim/accountability/results/_scope_filters.html.erb +++ b/app/views/decidim/accountability/results/_scope_filters.html.erb @@ -5,7 +5,7 @@ <% if current_component.has_subscopes? && !hide_subscopes %>