Skip to content

Padawan#59

Merged
dcordz merged 44 commits into
mainfrom
padawan
Sep 18, 2025
Merged

Padawan#59
dcordz merged 44 commits into
mainfrom
padawan

Conversation

@dcordz

@dcordz dcordz commented Mar 13, 2025

Copy link
Copy Markdown
Contributor

No description provided.

@dcordz dcordz requested a review from Copilot April 2, 2025 23:34

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR, titled "Padawan," introduces several UI and backend improvements with refinements in type safety, layout consistency, and controller behavior. Key changes include:

  • Updates in React components to add type safety and improve UI elements and layout.
  • Modifications in Rails controllers to adjust authentication and meta tag handling.
  • Minor dependency and configuration updates (e.g., Ruby version and RuboCop configurations).

Reviewed Changes

Copilot reviewed 109 out of 112 changed files in this pull request and generated no comments.

Show a summary per file
File Description
app/frontend/components/dialogs/ContactLegislatorDialog.tsx Added type assertion for user and refined conditional checks.
app/frontend/components/bill/creator/BillOfTheWeekCreator.tsx Adjusted component layout and styling for sticky positioning.
app/frontend/components/bill/charts/DistrictVotesChart.tsx Removed the empty-check for district scores.
app/frontend/components/bill/BillComponent.tsx Altered conditional rendering logic for mobile charts.
app/frontend/components/bill/BillArgumentsOrganization.tsx Updated button variant and image style for responsive display.
app/frontend/components/bill/BillArguments.tsx Incorporated Accordion for mobile rendering and adjusted organization argument displays.
app/controllers/sway_locales_controller.rb Modified locales payload to include all locales when no user is signed in.
app/controllers/sitemap_controller.rb Introduced a new controller to render XML sitemap without authentication.
app/controllers/legislators_controller.rb Added before_actions for setting a legislator and skipping auth for show action.
app/controllers/concerns/default_meta_taggable.rb Added a title tag to meta tags configuration.
app/controllers/buckets/assets_controller.rb Adjusted admin verification filtering in the assets controller.
app/controllers/bills_controller.rb Updated bill retrieval and meta title logic using current_session.
Gemfile, .rubocop/*, .github/workflows/rspec.yml Updated Ruby version and RuboCop configuration settings for consistency.
Files not reviewed (3)
  • .node-version: Language not supported
  • .nvmrc: Language not supported
  • .ruby-version: Language not supported
Comments suppressed due to low confidence (3)

app/frontend/components/bill/charts/DistrictVotesChart.tsx:15

  • Removal of the check for an empty districtScore may result in runtime errors when districtScore is undefined; consider adding a guard to handle this case.
if (isEmpty(districtScore)) {

app/frontend/components/bill/BillArguments.tsx:101

  • "supportingOrg" is referenced but not defined in this context; ensure the proper organization object is passed or mapped before calling renderOrgSummary.
renderOrgSummary(supportingOrg.organization, supportingOrg)

app/controllers/buckets/assets_controller.rb:9

  • Removing the 'only: %i[create]' restriction applies the admin check to all actions; verify that this change is intended and does not inadvertently secure non-sensitive actions.
before_action :verify_is_admin

@dcordz dcordz merged commit 88e93de into main Sep 18, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants