Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade CONSUL DEMOCRACY to version 2.0.1 #145

Merged
merged 739 commits into from
Sep 5, 2023
Merged

Upgrade CONSUL DEMOCRACY to version 2.0.1 #145

merged 739 commits into from
Sep 5, 2023
This pull request is big! We’re only showing the most recent 250 commits.

Commits on Feb 16, 2023

  1. Remove usages of the top-bar-right class

    This is one of Foundation's classes that only applies when its
    parent element is a flex container, which isn't the case here since
    commit dcec003.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    7016172 View commit details
    Browse the repository at this point in the history
  2. Remove unused style inside top-bar-left

    There isn't a `ul` element here, so this rule doesn't apply.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    6b01dc5 View commit details
    Browse the repository at this point in the history
  3. Remove usage of top-bar-left class

    We don't need it since it's only used for flexbox styles, and we
    already have a `flex-grow` rule for the `h1` element which does the
    same thing.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    c553e15 View commit details
    Browse the repository at this point in the history
  4. Don't load Foundation styles for the top-bar

    We're going to change these styles in order to fix a bug, and the
    Foundation styles were getting in the way. Besides, we were overwriting
    some rules and so now we're removing 6 properties while we're also
    adding 6, so it isn't like the Foundation styles were helping us.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    86dd34d View commit details
    Browse the repository at this point in the history
  5. Fix menu on "wide" small screens

    The menu didn't look properly on these screens since commit dcec003.
    
    On small screens with enough horizontal space to show the menu button,
    the logo, and the contents of the menu, all three elements were shown on
    the same row, which looked broken.
    
    Now the contents of the menu are shown below the menu button.
    
    Note that, to force this, we're making the contents of the menu 100%
    wide. That means links would take the 100% of the space, which would
    make it easy to click on a link while trying to scroll when using
    touchscreens. So we're making the links as wide as their text, which
    also has a disadvantage: it's harder to click on narrow links like
    "SDG".
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    045ac64 View commit details
    Browse the repository at this point in the history
  6. Adjust order of elements on small screens

    We're changing the order of the elements in the HTML so the menu button
    appears next to the menu it opens, with no logo between them, which IMHO
    makes sense and makes it easier to understand the layout for people
    using screen readers.
    
    A small advantage of this approach is that on very narrow screens or
    Consul applications having a very long word for "Menu", the menu button
    appeared on top, the logo appeared below it, and the contents of the
    menu appeared below the logo. Now the logo appears on top, the menu
    button appears below it, and the contents of the menu appear below the
    menu button.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    b50b7ad View commit details
    Browse the repository at this point in the history
  7. Move menu button to the left in the admin section

    So now it uses the same interface and styles as the main layout. On
    small screens, it's easier to play with the menu when the button is on
    the left because the menu it opens is aligned to the left.
    
    Note that now we can get rid of the title-bar class; we didn't use the
    styles in the public area since commit dcec003, and we were overriding
    all the Foundation styles in the admin area with the exception of the
    padding, which we no longer need.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    b489923 View commit details
    Browse the repository at this point in the history
  8. Extract component to render the responsive menu

    We were using the same code for the button in both the public and admin
    headers, so we're removing the duplication.
    
    Since the menu and the button must go together, and the contents of the
    menu are different for different layouts, we're passing these contents
    using a block.
    
    Note the ID of the menu was `responsive-menu` in the public section but
    `responsive_menu` in the admin section. Since we usually use underscores
    for IDs and dashes for classes, we're keeping the one with the
    underscore.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    49cb6e0 View commit details
    Browse the repository at this point in the history
  9. Remove redundant admin-top-bar element

    We weren't using the `admin-top-bar` class since commit e6c1cf7, and
    we can always use the `.admin .top-bar` selector if we need to. And the
    `row expanded` classes basically give an element a width of 100%, which
    is already the default width for block elements.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    2ac338f View commit details
    Browse the repository at this point in the history
  10. Render components instead of partials in headers

    We were using partials to render components in order to ease the
    transition of custom code from earlier versions of Consul. However,
    that was back in Consul 1.4, and now these views looked a bit messy
    since they sometimes rendered components and sometimes they
    rendered partials.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    bbd4d3e View commit details
    Browse the repository at this point in the history
  11. Extract component for remote translations button

    So we're consistent with the rest of the code in the header, which
    renders components and not partials.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    efc69e8 View commit details
    Browse the repository at this point in the history
  12. Use CSS to define alignment in translations message

    That way it's possible to override the style without changing the HTML,
    which is the hardest code to customize and maintain.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    1778a75 View commit details
    Browse the repository at this point in the history
  13. Fix background width in remote translations message

    The `overflow: hidden` applied to the `.callout` selector made the full
    width background invisible, meaning this section hasn't looked properly
    on very large screens since  commit 701378d.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    9bca73b View commit details
    Browse the repository at this point in the history
  14. Simplify styles for the remote translations message

    Instead of adding all the styles of a callout and then overwriting half
    of them, we can simply add the half we need.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    fb2b88b View commit details
    Browse the repository at this point in the history
  15. Simplify styles for the remote translations button

    We can use the `link` mixin. Note this mixin uses anchor-color instead
    of brand-color; by default, they're both the same, so we probably meant
    anchor-color here.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    3b125d9 View commit details
    Browse the repository at this point in the history
  16. Remove unnecessary styles in top bar

    Not sure why these properties were added, but they no longer seem to be
    necessary.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    27d9859 View commit details
    Browse the repository at this point in the history
  17. Unify spacing styles in public and admin top bars

    The top bar padding was different on small screens when we were in the
    admin section, so we're now applying the same padding everywhere.
    
    Note we're still applying extra padding on medium/large screens because
    in the public section we display our logo image, which has some blank
    space. In the admin section we're emulating this blank space with
    padding; we might change it in the future if we change our logo.
    
    Also note we're using `0.8rem` instead of `$line-height / 2`. The reason
    is tricky: there's a spec testing the reorder feature with drag and drop
    in the poll questions answers administration, and that test fails when
    the drop space is right at the bottom of the screen, which is what
    happens when we use the `$line-height / 2` padding. A proper solution
    would be to remove the inaccessible drag and drop feature and use a
    different method to reorder the answers.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    f8df900 View commit details
    Browse the repository at this point in the history
  18. Move remote translations concern methods to the model

    This way it'll be easier to change the code.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    d09a47a View commit details
    Browse the repository at this point in the history
  19. Move remote translations controller methods to the model

    Now that all the code related to this model is in the same place,
    changing it will be easier.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    26cc75a View commit details
    Browse the repository at this point in the history
  20. Use remote translations objects instead of hashes

    This way we can simplify the code dealing with the translatable
    association.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    2f0327a View commit details
    Browse the repository at this point in the history
  21. Make the translation button condition more readable

    I was finding this part hard to follow, but after changing the name of
    the condition suddenly I understood what was going on.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    fe3c9d4 View commit details
    Browse the repository at this point in the history
  22. Fix crash translating an already translated text

    The page was crashing when at least part of the content of the page had
    been translated between the request showing the remote translations
    button and the moment people pressed the button.
    javierm committed Feb 16, 2023
    Configuration menu
    Copy the full SHA
    2b9f9ed View commit details
    Browse the repository at this point in the history

Commits on Feb 17, 2023

  1. Merge pull request consuldemocracy#5072 from consul/top_bar_adjustments

    Fix menu on "wide" small screens
    javierm authored Feb 17, 2023
    Configuration menu
    Copy the full SHA
    0448280 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5073 from consul/remote_translatio…

    …ns_crash
    
    Fix crash translating an already translated text
    javierm authored Feb 17, 2023
    Configuration menu
    Copy the full SHA
    169b1b1 View commit details
    Browse the repository at this point in the history
  3. Move login items tests to the component

    This way we reduce the number of system tests or, in some cases,
    requests during system tests, making the tests faster.
    
    We're still testing the interaction with the menu when users have the
    right permissions.
    javierm committed Feb 17, 2023
    Configuration menu
    Copy the full SHA
    465d2d6 View commit details
    Browse the repository at this point in the history
  4. Unify specs testing access to admin menu items

    In most sections, we had two specs testing what happens after accessing
    one of the privileged areas. We're grouping the expectations and so
    we've only got one test per area, making these tests faster.
    javierm committed Feb 17, 2023
    Configuration menu
    Copy the full SHA
    2e9c4de View commit details
    Browse the repository at this point in the history
  5. Show always poll officer menu to officers

    Since the change on commit cbbe188 we added a Poll.current.any?
    condition to show the officing link on admin menu to officers.
    
    That condition doesn't have much sense since Poll results only can be
    added after a poll has ended, and there may be only one active poll.
    decabeza authored and javierm committed Feb 17, 2023
    Configuration menu
    Copy the full SHA
    1ff2144 View commit details
    Browse the repository at this point in the history
  6. Merge pull request consuldemocracy#5024 from consul/poll_officer_menu

    Always show poll officer menu to officers
    javierm authored Feb 17, 2023
    Configuration menu
    Copy the full SHA
    4debff7 View commit details
    Browse the repository at this point in the history
  7. Don't cache related actions in investments view

    We've experienced some caching issues with this code for years. We've
    fixed some of them in commits 9979b53 and 3645c33, but we're still
    running into other issues. In order to really cache this section, we'd
    need to cache:
    
    * Whether or not the investment should show the aside and vote/support
      buttons (we could do it by caching its budget)
    * Whether its budget is balloting or finished (we could do it by caching
      its budget)
    * Whether the current user is following the investment
    * Whether the `remove_investments_supports` feature is enabled
    * Whether the `community` feature is enabled
    * The value of the `org_name` setting
    * The value of the `twitter_handle` setting
    
    We weren't caching all these elements, meaning that (for instance), we
    didn't display the button to vote when a budget moved into the voting
    phase if we had already cached this section without the button.
    
    And chances are the list is incomplete. So, instead of trying to take
    into account every single possible factor that should make us expire the
    cache, we're restricting the cache so it only affects the content of the
    investment. This is similar to what we do in the investments index,
    where we cache the content of the investment but we don't cache the
    vote/support buttons.
    javierm committed Feb 17, 2023
    Configuration menu
    Copy the full SHA
    02e8ffc View commit details
    Browse the repository at this point in the history
  8. Split test in budget valuation component

    We're going to add more cases and the test for the link to the evaluate
    would become too big, so we're splitting it.
    javierm committed Feb 17, 2023
    Configuration menu
    Copy the full SHA
    d5cb01b View commit details
    Browse the repository at this point in the history
  9. Show link to evaluate after evaluation has finished

    This way it's still possible to access the "evaluation finished" filter
    in the valuation investments index.
    javierm committed Feb 17, 2023
    Configuration menu
    Copy the full SHA
    ed4b03c View commit details
    Browse the repository at this point in the history
  10. Add scope to get investments visible to a valuator

    Using this method makes it more obvious that we're loading the same
    investments in the budgets index as in the investments index.
    javierm committed Feb 17, 2023
    Configuration menu
    Copy the full SHA
    1649b91 View commit details
    Browse the repository at this point in the history
  11. Simplify investment params filters in valuation

    We weren't allowing the `budget_id` parameter and then we were adding it
    manually. We were also allowing other parameters that aren't used in the
    valuation section.
    
    So we're allowing budget and heading, which are the only parameter we're
    offering filters for in the user interface. Note the `budget_id`
    parameter doesn't seem to make sense because we're already inside a
    `@budget.investments` statement, but the `budget_id` parameter is
    required by the `scoped_filter` method.
    javierm committed Feb 17, 2023
    Configuration menu
    Copy the full SHA
    b6ed114 View commit details
    Browse the repository at this point in the history
  12. Remove unnecessary condition in valuation investments

    The budget is loaded using a method which raises an exception if it
    isn't found, so `@budget.present?` will always return true.
    javierm committed Feb 17, 2023
    Configuration menu
    Copy the full SHA
    54fbdf4 View commit details
    Browse the repository at this point in the history

Commits on Feb 20, 2023

  1. Merge pull request consuldemocracy#5077 from consul/investment_cache

    Don't cache related actions in investments view
    javierm authored Feb 20, 2023
    Configuration menu
    Copy the full SHA
    d1edcce View commit details
    Browse the repository at this point in the history
  2. Simplify data in budget admin stats tests

    We don't need groups to create headings since commit 20b1085, and
    `let!` was used as a substitute for instance variables in commit
    91c21b0, but it isn't necessary in this case.
    javierm committed Feb 20, 2023
    Configuration menu
    Copy the full SHA
    915999d View commit details
    Browse the repository at this point in the history
  3. Extract component for balloting budget admin stats

    We're also moving the tests, but we're keeping one system test in order
    to test the controller and the navigation to get to this page.
    
    Note we're slightly changing the order of the methods in the component;
    the order of the instance variables was `user_`, `vote_`, `vote_`,
    `user_`, which was hard to follow.
    javierm committed Feb 20, 2023
    Configuration menu
    Copy the full SHA
    76b0839 View commit details
    Browse the repository at this point in the history
  4. Use consistent method names in admin stats component

    We had one method called `vote_count_by_heading` and another one called
    `user_count_by_district`, when here districts refer to headings.
    javierm committed Feb 20, 2023
    Configuration menu
    Copy the full SHA
    4445119 View commit details
    Browse the repository at this point in the history
  5. Fix invalid HTML in budget stats tables

    The <th> elements should be inside <tr> elements.
    
    Since we're changing this code, we're also adding <thead> and <tbody>
    tags because that's what we usually do and it makes it easier to select
    <tr> tags from either the table head or the table body using CSS or
    JavaScript.
    javierm committed Feb 20, 2023
    Configuration menu
    Copy the full SHA
    698fc75 View commit details
    Browse the repository at this point in the history
  6. Show admin heading stats for the current budget

    To get the heading where a user voted, we were relying on the
    `balloted_heading_id` field.
    
    Our guess is this was done so the total number of users is the same as
    the sum of users who voted on a heading. That is, if 2000 people voted
    just on the "All city" heading, 1000 voted just on the "North district"
    heading, and 500 people voted on both, instead of showing "3500 people
    voted in total, 2500 voted in all city, 1500 voted in north district",
    we show something like "3500 people voted in total, 2250 voted in all
    city, and 1250 voted in north district".
    
    However, this approach has some disadvantages.
    
    The first disadvantage is, the stats aren't correct. In the case above,
    2500 voted on the "All city heading", so the statistics for this heading
    don't show reality.
    
    The second one is we weren't considering the last heading where users
    voted inside the budget being displayed, but the last heading where
    users voted, period. That means that, if all the people above voted on a
    later budget, the stats for the budget above would become "3500 people
    voted in total, 0 voted in all city, and 0 voted in north district".
    That also means we were including headings from previous budgets in the
    statistics for more recent budgets when people hadn't voted on the
    recent ones.
    
    So we're removing the `balloted_heading_id` since its data is lost once
    people vote on a new budget. And, in order to show the right stats and
    simplify the code, we're no longer trying to add votes just to one
    heading when users vote on several headings.
    
    Co-Authored-By: Julian Nicolas Herrero <[email protected]>
    javierm and microweb10 committed Feb 20, 2023
    Configuration menu
    Copy the full SHA
    dd28163 View commit details
    Browse the repository at this point in the history
  7. Extract component for supporting budget admin stats

    This is consistent with the component for balloting stats. We're about
    to change both components, and the changes are easier to follow if
    they're similar.
    
    We're also using consistent names in methods.
    javierm committed Feb 20, 2023
    Configuration menu
    Copy the full SHA
    b536a7c View commit details
    Browse the repository at this point in the history
  8. Use budget stats model to calculate admin stats

    This way we reduce duplication.
    javierm committed Feb 20, 2023
    Configuration menu
    Copy the full SHA
    e51e034 View commit details
    Browse the repository at this point in the history
  9. Merge pull request consuldemocracy#4985 from consul/fix_budget_stats

    Show admin heading stats for the current budget
    javierm authored Feb 20, 2023
    Configuration menu
    Copy the full SHA
    1b61eff View commit details
    Browse the repository at this point in the history
  10. Merge pull request consuldemocracy#5078 from consul/link_to_evaluate

    Show link to evaluate investments with valuation finished
    javierm authored Feb 20, 2023
    Configuration menu
    Copy the full SHA
    f7dfe30 View commit details
    Browse the repository at this point in the history
  11. Show valuator group investments to their valuators

    When accessing the valuation area, we were only displaying the
    investments directly assigned to the current valuator, but we weren't
    displaying the investments assigned to that valuator's group.
    
    Using the `assigned_investments_ids` method, which takes the valuator
    group into account, solves the issue.
    
    We've also found an issue on our development machines: since we don't
    have a unique index per `investment_id` and `valuator_id` in the
    `budget_valuator_assignments` table, we've found duplicate records on
    this table. When that happened, we were displaying the same investment
    several times.
    
    Since now we no longer join this table in the query returning the
    investment, this issue is also solved, and we're adding a test for it.
    We can now remove the call to the `distinct` method when calculating the
    number of investments per heading.
    javierm committed Feb 20, 2023
    Configuration menu
    Copy the full SHA
    45b9ecc View commit details
    Browse the repository at this point in the history
  12. Merge pull request consuldemocracy#5082 from consul/valuation_group_i…

    …nvestments
    
    Show valuator group investments to group valuators
    javierm authored Feb 20, 2023
    Configuration menu
    Copy the full SHA
    2dc10f4 View commit details
    Browse the repository at this point in the history

Commits on Feb 21, 2023

  1. Fix flaky spec in budget supports admin stats

    The test that was not passing sometimes since commit 915999d because
    we no longer created the budget before visiting the page that loads it.
    So now we're forcing its creation with `let!`.
    taitus authored and javierm committed Feb 21, 2023
    Configuration menu
    Copy the full SHA
    1ea5b69 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5083 from consul/fix-specs

    Fix flaky spec in budget supports admin stats
    javierm authored Feb 21, 2023
    Configuration menu
    Copy the full SHA
    c1d70ef View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    cd99f2a View commit details
    Browse the repository at this point in the history
  4. Add description to legislation questions

    decabeza authored and javierm committed Feb 21, 2023
    Configuration menu
    Copy the full SHA
    8000277 View commit details
    Browse the repository at this point in the history

Commits on Feb 22, 2023

  1. Remove duplicated keys

    In the images.yml file we have a duplicate key with the same translation,
    so we can remove it.
    
    In the admin.yml file we have a duplicate key with different translation.
    
    This translation is only used in 2 places in the application:
    - In the administration table for collaborative legislation proposal index.
    - In the <% provide :title do %> of the same page.
    
    Although it is true that now the second translation (Title) is applied in
    both cases, I think it makes more sense to use the first one (Proposals)
    in the page title because it seems to make more sense and be more useful
    to use "Proposals" instead of “Title”.
    
    In order not to modify the behavior in the translation shown in the
    administration table, we add human_attribute_name to obtain the expected
    result.
    taitus committed Feb 22, 2023
    Configuration menu
    Copy the full SHA
    484e1da View commit details
    Browse the repository at this point in the history
  2. Use human_attribute_name in admin tables

    To be consistent with the previous commit we update the text that appears
    in the administration tables for discussions and proposals. Now instead of
    "Proposals" and "Discussions" will appear "Title" which makes more sense
    and is more consistent.
    taitus committed Feb 22, 2023
    Configuration menu
    Copy the full SHA
    f100e01 View commit details
    Browse the repository at this point in the history
  3. Merge pull request consuldemocracy#5084 from consul/check-translation…

    …s-keys
    
    Remove duplicate keys
    taitus authored Feb 22, 2023
    Configuration menu
    Copy the full SHA
    0f52180 View commit details
    Browse the repository at this point in the history
  4. Fix broken h3 tag

    Since we're now allowing <h2> and <h3> tags in the description, we
    remove the broken <h3> tag from quiz-question class. Since its content
    is also in the <title> element, and in order to be consistent with other
    show actions in the public area, we change this tag to <h1>.
    
    We add <h2> tag in the "Share" heading and we replace the broken <h4>
    tag above adding new styles.
    taitus committed Feb 22, 2023
    Configuration menu
    Copy the full SHA
    d96a917 View commit details
    Browse the repository at this point in the history
  5. Do not show money with hidden money

    decabeza authored and taitus committed Feb 22, 2023
    Configuration menu
    Copy the full SHA
    9ef90b1 View commit details
    Browse the repository at this point in the history

Commits on Feb 23, 2023

  1. Merge pull request consuldemocracy#4997 from consul/legislation_question

    Add description to Legislation questions
    taitus authored Feb 23, 2023
    Configuration menu
    Copy the full SHA
    a26f05f View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#4900 from consul/ballot_hidden_money

    Do not show money with hidden money
    taitus authored Feb 23, 2023
    Configuration menu
    Copy the full SHA
    8f01a25 View commit details
    Browse the repository at this point in the history

Commits on Mar 1, 2023

  1. Remove API documentation

    It's already present in the consul/docs repository.
    
    We're keeping the examples folder for now because it isn't in the
    consul/docs repository yet.
    javierm committed Mar 1, 2023
    Configuration menu
    Copy the full SHA
    ae8975d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    8b7a9d1 View commit details
    Browse the repository at this point in the history
  3. Remove unused images in doc folder

    We added them in commit 2e4601b, but it looks that they've never been
    used.
    javierm committed Mar 1, 2023
    Configuration menu
    Copy the full SHA
    fcaba88 View commit details
    Browse the repository at this point in the history
  4. Remove README in the doc folder

    This documentation is obsolete and there's documentation in the official
    consulproject website containing user guides like this one.
    javierm committed Mar 1, 2023
    Configuration menu
    Copy the full SHA
    e4992ff View commit details
    Browse the repository at this point in the history
  5. Fix API examples

    We were getting many errors when trying to run them, from uninitialized
    constant `HTTP` to undefined method `headers`.
    
    We might move these examples to the documentation repository in the
    future, but we need to look for possible side-effects first.
    javierm committed Mar 1, 2023
    Configuration menu
    Copy the full SHA
    56e42f2 View commit details
    Browse the repository at this point in the history
  6. Merge pull request consuldemocracy#4983 from sashashura/patch-1

    GitHub Workflows security hardening
    javierm authored Mar 1, 2023
    Configuration menu
    Copy the full SHA
    4425f0f View commit details
    Browse the repository at this point in the history

Commits on Mar 3, 2023

  1. Merge pull request consuldemocracy#5087 from consul/doc_folder

    Clean up doc folder
    javierm authored Mar 3, 2023
    Configuration menu
    Copy the full SHA
    462792d View commit details
    Browse the repository at this point in the history

Commits on Mar 4, 2023

  1. Run test coverage just on the master branch

    Since we changed the way we integrate coveralls in commit 8ed8cc8,
    we're getting 6 additional checks displayed in our pull requests.
    
    We don't need these checks, and they only add noise. The only reason we
    use coveralls is to know the test coverage in our master branch.
    
    So we're changing the code so coveralls only runs on the master branch.
    
    There's also a chance that the test suite will be faster because it
    doesn't need to keep track of the coverage, although I haven't noticed any
    significant differences during my tests.
    
    I haven't found a more elegant way to say that a certain step should
    only be run on push on master, so I'm setting the environment variable
    we were already using.
    javierm committed Mar 4, 2023
    Configuration menu
    Copy the full SHA
    c614b0b View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5054 from consul/coverage_on_master

    Run test coverage just on the master branch
    javierm authored Mar 4, 2023
    Configuration menu
    Copy the full SHA
    9226320 View commit details
    Browse the repository at this point in the history

Commits on Mar 9, 2023

  1. Include SentencesParser inside the right class

    We were including it in the Object class, making its methods
    available everywhere.
    javierm authored and taitus committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    b030a19 View commit details
    Browse the repository at this point in the history
  2. Replace instance variable usage with a method

    We usually use this approach because methods are easier to override and
    stub.
    javierm authored and taitus committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    63d0e31 View commit details
    Browse the repository at this point in the history
  3. Change gem from TranslatorText to BingTranslator

    TranslatorText isn't compatible with Ruby 3, so we need to use a
    different gem.
    
    The 'translator-text' gem response was an array of one or more objects.
    Now with the 'bing_translator' gem the response is an array with one or
    several translated texts.
    
    We remove the concept of object in the code. And we also remove the
    "create_response" method from the specs since it is no longer necessary
    to emulate that object and we can simply use arrays with texts to emulate
    the new response.
    taitus committed Mar 9, 2023
    Configuration menu
    Copy the full SHA
    c64b49b View commit details
    Browse the repository at this point in the history

Commits on Mar 10, 2023

  1. Bump rack from 2.2.6.2 to 2.2.6.3

    Bumps [rack](https://github.com/rack/rack) from 2.2.6.2 to 2.2.6.3.
    - [Release notes](https://github.com/rack/rack/releases)
    - [Changelog](https://github.com/rack/rack/blob/main/CHANGELOG.md)
    - [Commits](rack/rack@v2.2.6.2...v2.2.6.3)
    
    ---
    updated-dependencies:
    - dependency-name: rack
      dependency-type: indirect
    ...
    
    Signed-off-by: dependabot[bot] <[email protected]>
    dependabot[bot] authored and javierm committed Mar 10, 2023
    Configuration menu
    Copy the full SHA
    f188a03 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5090 from consul/dependabot/bundle…

    …r/rack-2.2.6.3
    
    Bump rack from 2.2.6.2 to 2.2.6.3
    javierm authored Mar 10, 2023
    Configuration menu
    Copy the full SHA
    33c62cc View commit details
    Browse the repository at this point in the history

Commits on Mar 15, 2023

  1. Allow translate locales that need to be mapping

    It has been detected that for the :pt-BR, :zh-CN and :zh-TW locales,
    the translate button was being displayed, but when requesting the
    translation, the remote translation validation failed due to:
    
    '''
    validates :locale, inclusion: { in: ->(_) {
         RemoteTranslations::Microsoft::AvailableLocales.available_locales }}
    '''
    
    That available_locales method did not contemplate these 3 languages
    in the format used by the application.
    
    To solve this problem the api response is mapped to return all
    locales in the format expected by the application.
    
    Add remote translation model test to ensure that a remote translation
    is valid when its locale is pt-BR.
    
    Co-Authored-By: Javi Martín <[email protected]>
    taitus and javierm committed Mar 15, 2023
    Configuration menu
    Copy the full SHA
    306e735 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5089 from consul/bing-translator

    Use Bing Translator instead of TranslatorText
    taitus authored Mar 15, 2023
    Configuration menu
    Copy the full SHA
    9bbde19 View commit details
    Browse the repository at this point in the history

Commits on Mar 16, 2023

  1. Bump rack from 2.2.6.3 to 2.2.6.4

    Bumps [rack](https://github.com/rack/rack) from 2.2.6.3 to 2.2.6.4.
    - [Release notes](https://github.com/rack/rack/releases)
    - [Changelog](https://github.com/rack/rack/blob/main/CHANGELOG.md)
    - [Commits](rack/rack@v2.2.6.3...v2.2.6.4)
    
    ---
    updated-dependencies:
    - dependency-name: rack
      dependency-type: indirect
    ...
    
    Signed-off-by: dependabot[bot] <[email protected]>
    dependabot[bot] authored and javierm committed Mar 16, 2023
    Configuration menu
    Copy the full SHA
    35153ad View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5092 from consul/dependabot/bundle…

    …r/rack-2.2.6.4
    
    Bump rack from 2.2.6.3 to 2.2.6.4
    javierm authored Mar 16, 2023
    Configuration menu
    Copy the full SHA
    448e957 View commit details
    Browse the repository at this point in the history

Commits on Mar 20, 2023

  1. Explicitly enable ERB linters

    I thought SelfClosingTag was enabled since it was on the list and the
    `enabled: false` got lost among all the `enabled: true`. ERB Lint 0.1
    and later will also add RequireInputAutocomplete as a default linter,
    and we're not interested in it, at least for now.
    
    So, just like we do for Rubocop, we're disabling all linters and
    enabling the ones we use explicitly.
    javierm committed Mar 20, 2023
    Configuration menu
    Copy the full SHA
    4ddcfde View commit details
    Browse the repository at this point in the history
  2. Bump erb_lint from 0.0.37 to 0.3.1

    We also need to update pronto-erb_lint since the old version depended on
    erb_lint 0.0.x.
    javierm committed Mar 20, 2023
    Configuration menu
    Copy the full SHA
    09a62d6 View commit details
    Browse the repository at this point in the history
  3. Enable CommentSyntax ERB Linter

    It's a default linter in erb_lint 0.3.0, and it's useful during
    development since I'm always unsure about the right way to add ERB
    comments.
    javierm committed Mar 20, 2023
    Configuration menu
    Copy the full SHA
    99b0ef0 View commit details
    Browse the repository at this point in the history
  4. Merge pull request consuldemocracy#5093 from consul/bump_erb_lint

    Bump erb_lint from 0.0.37 to 0.3.1
    javierm authored Mar 20, 2023
    Configuration menu
    Copy the full SHA
    3957404 View commit details
    Browse the repository at this point in the history

Commits on Mar 21, 2023

  1. Use only one server when deploying to preproduction

    It doesn't make much sense that by default we use one server on
    production on two servers on preproduction.
    
    Note we're keeping `server1` instead of using just `server` in order to
    keep compatibility with existing installation.
    javierm committed Mar 21, 2023
    Configuration menu
    Copy the full SHA
    b115b0c View commit details
    Browse the repository at this point in the history
  2. Unify deploy secret keys for the main server

    We were using `server` on staging but `server1` and `server2` on
    preproduction and production.
    
    The reason behind it is we've always used one server on staging but
    sometimes we've used several servers on preproduction and production.
    
    However, this is a bit of a mess on installations which have only one
    server on preproduction or production and need to use the `server` key
    for the staging environments but `server1` for other environments.
    
    So, in order to keep compatibility with existing Consul installations,
    we're now allowing either `server` or `server1` on any environment.
    javierm committed Mar 21, 2023
    Configuration menu
    Copy the full SHA
    8aa113a View commit details
    Browse the repository at this point in the history
  3. Simplify deploy secrets example configuration file

    So now it's similar to our database example file.
    javierm committed Mar 21, 2023
    Configuration menu
    Copy the full SHA
    bbf6a31 View commit details
    Browse the repository at this point in the history

Commits on Mar 28, 2023

  1. Disable scroll wheel for zooming in favor of map zoom buttons

    It's causing annoying behaviour for desktop users when scrolling
    the page to the bottom and there is more content below the
    map.
    
    The behaviour of touchable devices does not seem to be
    affected by this change and keeps behaving the same.
    Senen committed Mar 28, 2023
    Configuration menu
    Copy the full SHA
    3341c45 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5095 from consul/one_server_on_pre…

    …production
    
    Use only one server when deploying to preproduction
    javierm authored Mar 28, 2023
    Configuration menu
    Copy the full SHA
    26f806b View commit details
    Browse the repository at this point in the history
  3. Merge pull request consuldemocracy#5097 from consul/map_scroll_wheel

    Disable scroll wheel for zooming in favor of map zoom buttons
    Senen authored Mar 28, 2023
    Configuration menu
    Copy the full SHA
    8e0acb8 View commit details
    Browse the repository at this point in the history

Commits on Apr 13, 2023

  1. Specify translation class name in dummy test class

    These tests were failing with Ruby 3.0 because we were getting an error
    when loading the `translations` association of the dummy class:
    
    ```
    NameError:
      uninitialized constant
      DummyBanner::#<Class:0x000055630e4dccd8>::Translation
    ```
    
    Specifying the `class_name` of the `translations` association solves the
    issue.
    javierm committed Apr 13, 2023
    Configuration menu
    Copy the full SHA
    4d11d8a View commit details
    Browse the repository at this point in the history
  2. Upgrade Ruby to version 3.0.6

    Note the structure of the Gemfile changes slightly because Ruby 3.0
    includes a new version of the Bundler gem.
    javierm committed Apr 13, 2023
    Configuration menu
    Copy the full SHA
    6c8445e View commit details
    Browse the repository at this point in the history
  3. Update Style/RedundantFreeze rule for Ruby 3.0

    In Ruby 3.0, Regexp and Range literals are frozen objects, and so we
    don't need to freeze them.
    javierm committed Apr 13, 2023
    Configuration menu
    Copy the full SHA
    b911284 View commit details
    Browse the repository at this point in the history
  4. Add Style/HashExcept Rubocop rule

    We were already using it because Rails adds the `Hash#except` method for
    Ruby 2.7 and earlier, but since the method wasn't part of Ruby itself,
    the Rubocop rule only works with Ruby 3.0 and later.
    javierm committed Apr 13, 2023
    Configuration menu
    Copy the full SHA
    f298715 View commit details
    Browse the repository at this point in the history
  5. Merge pull request consuldemocracy#5074 from consul/ruby3.0

    Upgrade Ruby to version 3.0.6
    javierm authored Apr 13, 2023
    Configuration menu
    Copy the full SHA
    03a12ea View commit details
    Browse the repository at this point in the history

Commits on Apr 14, 2023

  1. Bump leaflet from 1.5.1 to 1.9.3

    Newer versions have more capabilities and also fix lot of errors,
    usability and accessibility issues.
    
    Note that we're using an external gem to rails-assets.org as it's
    not supports the rails-assets pipeline. This gems wraps the
    original one and make the code work with the default rails assets
    pipeline as usual.
    Senen committed Apr 14, 2023
    Configuration menu
    Copy the full SHA
    dd368ad View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    c3439ab View commit details
    Browse the repository at this point in the history
  3. Merge pull request consuldemocracy#5096 from consul/bump_leaflet

    Bump Leaflet from 1.5.1 to 1.9.3
    Senen authored Apr 14, 2023
    Configuration menu
    Copy the full SHA
    33f5f4c View commit details
    Browse the repository at this point in the history

Commits on Apr 18, 2023

  1. Update test to test exactly what we want to test

    Since this test was added in commit 78c6a30 the
    "current_password" was filled with an incorrect value.
    
    This test did not fail because in previous versions of the
    "devise-security" gem if this "current_password" was not valid
    a "self.valid?" was performed which caused the error we are testing.
    
    In version 0.17 (as can be seen in the following commit
    devise-security/devise-security@41a99b67fe0)
    if the "current_password" is not valid, related errors are still added
     but the "self.valid?" code is removed, which is what causes the
    expected error "must be different than the current password"
    to appear in the "new password" field.
    
    By adding a correct "current_password" in the test, we avoid this validation
    for the "current_password" (which no longer includes the expected error)
    and follow the natural flow of devise that does end up intercepting the error
    for the new password entered.
    taitus authored and javierm committed Apr 18, 2023
    Configuration menu
    Copy the full SHA
    79d6530 View commit details
    Browse the repository at this point in the history
  2. Bump devise-security from 0.16.0 to 0.17.0

    Bumps [devise-security](https://github.com/devise-security/devise-security) from 0.16.0 to 0.17.0.
    - [Release notes](https://github.com/devise-security/devise-security/releases)
    - [Commits](devise-security/devise-security@v0.16.0...v0.17.0)
    
    ---
    updated-dependencies:
    - dependency-name: devise-security
      dependency-type: direct:production
      update-type: version-update:semver-minor
    ...
    
    Signed-off-by: dependabot[bot] <[email protected]>
    dependabot[bot] authored and javierm committed Apr 18, 2023
    Configuration menu
    Copy the full SHA
    0d8def3 View commit details
    Browse the repository at this point in the history

Commits on Apr 20, 2023

  1. Bump nokogiri from 1.13.10 to 1.14.3

    Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.13.10 to 1.14.3.
    - [Release notes](https://github.com/sparklemotion/nokogiri/releases)
    - [Changelog](https://github.com/sparklemotion/nokogiri/blob/main/CHANGELOG.md)
    - [Commits](sparklemotion/nokogiri@v1.13.10...v1.14.3)
    
    ---
    updated-dependencies:
    - dependency-name: nokogiri
      dependency-type: indirect
    ...
    
    Signed-off-by: dependabot[bot] <[email protected]>
    dependabot[bot] authored and javierm committed Apr 20, 2023
    Configuration menu
    Copy the full SHA
    a93b768 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5102 from consul/dependabot/bundle…

    …r/nokogiri-1.14.3
    
    Bump nokogiri from 1.13.10 to 1.14.3
    javierm authored Apr 20, 2023
    Configuration menu
    Copy the full SHA
    e421484 View commit details
    Browse the repository at this point in the history

Commits on Apr 21, 2023

  1. Merge pull request consuldemocracy#4931 from consul/dependabot/bundle…

    …r/master/devise-security-0.17.0
    
    Bump devise-security from 0.16.0 to 0.17.0
    taitus authored Apr 21, 2023
    Configuration menu
    Copy the full SHA
    17d7451 View commit details
    Browse the repository at this point in the history
  2. Extract component to render my ballot

    This is the only part of the sidebar that needs to be re-rendered after
    an AJAX request adding or removing investments to a ballot, so having a
    separate view just for it will make it easier to simplify the code.
    javierm committed Apr 21, 2023
    Configuration menu
    Copy the full SHA
    d0be5c4 View commit details
    Browse the repository at this point in the history

Commits on Apr 27, 2023

  1. Only re-render my ballot after voting

    We were rendering the whole sidebar again, which wasn't necessary since
    most of it remains unchanged. This resulted in complicated code to pass
    the necessary information to render the same map that was already
    rendered. Furthermore, when users had been moving the map around or
    zooming out, we were resetting the map to its default settings after
    voting, which was potentially annoying.
    
    This also fixes the wrong investments being displayed in the map after
    voting; only the investments on the current page were displayed in this
    case while the index displayed all of them.
    javierm committed Apr 27, 2023
    Configuration menu
    Copy the full SHA
    4954038 View commit details
    Browse the repository at this point in the history

Commits on Apr 28, 2023

  1. Merge pull request consuldemocracy#5107 from consul/fix_map_investmen…

    …ts_after_voting
    
    Fix wrong investments on the map after voting
    javierm authored Apr 28, 2023
    Configuration menu
    Copy the full SHA
    eaf28ef View commit details
    Browse the repository at this point in the history
  2. Avoid removing other proposals map locations

    It was possible to remove a map location from a different proposal (even
    one created by a different author) by modifying the hidden `id`
    parameter in the form.
    
    So we're making sure the map location we destroy is the one associated
    to the proposal we're updating.
    
    Since we're now using the `@proposal` instance variable in the
    `destroy_map_location_association` method, we're calling that method
    after loading the resource with cancancan.
    javierm committed Apr 28, 2023
    Configuration menu
    Copy the full SHA
    65ed778 View commit details
    Browse the repository at this point in the history
  3. Rename map_location variable containing parameters

    When it was named `map_location`, I constantly thought it was an object
    instead of a hash.
    javierm committed Apr 28, 2023
    Configuration menu
    Copy the full SHA
    6105de3 View commit details
    Browse the repository at this point in the history
  4. Merge pull request consuldemocracy#5109 from consul/fix_removing_diff…

    …erent_map_location
    
    Avoid removing other proposals map locations
    javierm authored Apr 28, 2023
    Configuration menu
    Copy the full SHA
    2f8717a View commit details
    Browse the repository at this point in the history

Commits on May 4, 2023

  1. Remove unused legislation proposals map action

    The only view that linked to this action was never used and so it was
    deleted in commit 0bacd5b.
    
    Since now the proposals controller is the only one place rendering the
    `shared/map` partial, we're moving it to the proposals views.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    b0b7d0f View commit details
    Browse the repository at this point in the history
  2. Simplify map location coordinates helpers

    We're calling this method after setting the map location with
    `map_location = MapLocation.new if map_location.nil?`, so the condition
    `map_location.present?` is always going to be true.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    c7de42a View commit details
    Browse the repository at this point in the history
  3. Extract component to render a map

    This way it'll be easier to refactor it.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    9cc3c55 View commit details
    Browse the repository at this point in the history
  4. Simplify method names in map component

    Since we aren't using helpers anymore, we don't need the `map_location`
    prefix.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    19adae9 View commit details
    Browse the repository at this point in the history
  5. Remove editable parameter in render_map

    The calls to `render_map` are confusing since there are so many
    parameters. We can assume that the map is editable if we pass the remove
    marker label.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    deb965b View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    aa5f523 View commit details
    Browse the repository at this point in the history
  7. Make remove marker label parameter optional

    We were passing `nil` in some calls, which was confusing.
    
    Since now we've got two optional parameters, we're using named
    parameters.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    e00aa80 View commit details
    Browse the repository at this point in the history
  8. Simplify code setting marker data in maps

    We were probably setting them separately to avoid having blank data
    attributes in the HTML. However, when a data attribute is `nil`, Rails
    doesn't write it in the HTML in the first place.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    84fff2e View commit details
    Browse the repository at this point in the history
  9. Use Rails methods to get map location input IDs

    We were manually generating the IDs in order to pass them as data
    attributes in the HTML in a component where we don't have access to the
    form which has the inputs.
    
    However, these data attributes only make sense when there's a form
    present, so we can pass the form as a parameter and use it to get the
    IDs.
    
    We can now define a map as editable when there's an associated form,
    which makes sense IMHO.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    b9518d6 View commit details
    Browse the repository at this point in the history
  10. Remove redundant value assignments in map fields

    Rails forms automatically take the value from the object related to the
    form.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    c667582 View commit details
    Browse the repository at this point in the history
  11. Remove duplicate i18n text to remove marker

    We had two different keys with the same text and were passing it as a
    parameter. Since the text is the same in any case, we don't need a
    parameter for it.
    
    Note we are using the `proposals` i18n key instead of creating a new one
    in a `shared` namespace one because creating a new key would mean that
    we'd lose the already existing translations in Crowdin.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    e752111 View commit details
    Browse the repository at this point in the history
  12. Extract functions to get coordinates in map JS

    We had 130 lines long function, and we're trying to reduce its size so
    it's easier to follow the code.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    00cd91c View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    4087066 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    f8053c9 View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    2e8bc11 View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    74d165a View commit details
    Browse the repository at this point in the history
  17. Don't overwrite marker when creating investment markers

    The `marker` variable is like a global variable inside the
    `initializeMap` function, so assigning it inside the `createMarker`
    function was changing its value in other places.
    
    So we're using different variable names like `newMarker` in order to
    make the code easier to follow. Now we "only" change the `marker`
    variable in functions that modify the marker.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    21ce768 View commit details
    Browse the repository at this point in the history
  18. Configuration menu
    Copy the full SHA
    b068062 View commit details
    Browse the repository at this point in the history
  19. Remove unused HTML class in link to remove marker

    It isn't used since commit c34aa54.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    f4ef641 View commit details
    Browse the repository at this point in the history
  20. Make map location HTML class names consistent

    We were using `map_location` in one place and
    `location-map-remove-marker` in another one. We usually use dashes in
    HTML class names, we don't say "location map" anywhere else.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    a145fdb View commit details
    Browse the repository at this point in the history
  21. Set remove marker link margin-bottom in CSS

    We were setting the margin-top property in CSS but the margin-bottom
    property by adding a div with a `.margin-bottom` HTML class.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    59ed975 View commit details
    Browse the repository at this point in the history
  22. Use a button instead of a link to remove a marker

    Using a button for interactive elements is better, as explained in
    commit 5311daa.
    
    Since buttons with "type=button" do nothing by default, we no longer
    need to call `preventDefault()` when clicking it.
    javierm committed May 4, 2023
    Configuration menu
    Copy the full SHA
    8b14522 View commit details
    Browse the repository at this point in the history

Commits on May 5, 2023

  1. Merge pull request consuldemocracy#5108 from consul/map_refactoring

    Simplify the code rendering the map
    javierm authored May 5, 2023
    Configuration menu
    Copy the full SHA
    0ef1882 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5111 from consul/remove_marker_acc…

    …essibility
    
    Use a button instead of a link to remove a marker
    javierm authored May 5, 2023
    Configuration menu
    Copy the full SHA
    287f483 View commit details
    Browse the repository at this point in the history

Commits on May 19, 2023

  1. Configuration menu
    Copy the full SHA
    e51f240 View commit details
    Browse the repository at this point in the history

Commits on May 22, 2023

  1. Update wkhtmltopdf-binary gem

    In order to add compatibility to ubuntu 22.04 we update the
    wkhtmltopdf-binary gem.  The gem version 0.12.6.5 only
    supports up to ubuntu 20.04.
    taitus committed May 22, 2023
    Configuration menu
    Copy the full SHA
    26a158f View commit details
    Browse the repository at this point in the history
  2. Bump audited from 5.0.2 to 5.3.3

    Bumps [audited](https://github.com/collectiveidea/audited) from 5.0.2 to 5.3.3.
    - [Release notes](https://github.com/collectiveidea/audited/releases)
    - [Changelog](https://github.com/collectiveidea/audited/blob/main/CHANGELOG.md)
    - [Commits](collectiveidea/audited@v5.0.2...v5.3.3)
    
    ---
    updated-dependencies:
    - dependency-name: audited
      dependency-type: direct:production
    ...
    
    Signed-off-by: dependabot[bot] <[email protected]>
    dependabot[bot] authored and taitus committed May 22, 2023
    Configuration menu
    Copy the full SHA
    14d4abe View commit details
    Browse the repository at this point in the history

Commits on May 23, 2023

  1. Merge pull request consuldemocracy#5113 from consul/proposals_notific…

    …ations
    
    Show email digest only if proposals are enabled
    Senen authored May 23, 2023
    Configuration menu
    Copy the full SHA
    c52d287 View commit details
    Browse the repository at this point in the history

Commits on May 24, 2023

  1. Update spec

    Configure the database before starting the browser with a call to `visit`
    taitus committed May 24, 2023
    Configuration menu
    Copy the full SHA
    81b7f30 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    d655acc View commit details
    Browse the repository at this point in the history

Commits on May 29, 2023

  1. Merge pull request consuldemocracy#5114 from consul/bump-wkhtmltopdf-…

    …binary
    
    Bump wkhtmltopdf-binary from 0.12.6.5 to 0.12.6.6
    taitus authored May 29, 2023
    Configuration menu
    Copy the full SHA
    0b7dfb2 View commit details
    Browse the repository at this point in the history
  2. Configure airbrake as Errbit documentation says

    Quoting `errbit/errbit/blob/main/app/views/apps/_configuration_instructions.html.erb`
    
    > airbrake.io supports various features that are out of scope for Errbit.
    Senen committed May 29, 2023
    Configuration menu
    Copy the full SHA
    b85df50 View commit details
    Browse the repository at this point in the history
  3. Remove unused code

    In the commit: 315c579 this code was added, but at that time this field
    was no longer in use, even though it existed in the database.
    
    I don't know why this line was added, but there seems to be no point in
    keeping it.
    taitus committed May 29, 2023
    Configuration menu
    Copy the full SHA
    2425d0e View commit details
    Browse the repository at this point in the history
  4. Remove the unused field from the database.

    In the PR consuldemocracy#1140 this field was added in commit ad697cd, but in this same
    PR in commit 28d12fe all the related functionality that had been added was
    removed but the field was not removed.
    taitus committed May 29, 2023
    Configuration menu
    Copy the full SHA
    0d93764 View commit details
    Browse the repository at this point in the history
  5. Merge pull request consuldemocracy#5115 from consul/remove-unused-field

    Remove unused field and related code
    taitus authored May 29, 2023
    Configuration menu
    Copy the full SHA
    0c1e860 View commit details
    Browse the repository at this point in the history
  6. Add new column to show activation status

    iraline authored and taitus committed May 29, 2023
    Configuration menu
    Copy the full SHA
    2dc32c6 View commit details
    Browse the repository at this point in the history
  7. Merge pull request consuldemocracy#4854 from iraline/activation_status

    Show account activation status for each user in the admin section
    taitus authored May 29, 2023
    Configuration menu
    Copy the full SHA
    1462ae7 View commit details
    Browse the repository at this point in the history
  8. Move geozone form partial to a component

    That way it'll be easier to refactor it.
    javierm committed May 29, 2023
    Configuration menu
    Copy the full SHA
    c6c0907 View commit details
    Browse the repository at this point in the history
  9. Move budget headings form partial to a component

    This way it'll be easier to test it.
    javierm committed May 29, 2023
    Configuration menu
    Copy the full SHA
    ca013cf View commit details
    Browse the repository at this point in the history
  10. Move geozones index view to a component

    This way we simplify the header and it will be easier to add more code
    and tests.
    javierm committed May 29, 2023
    Configuration menu
    Copy the full SHA
    882cc85 View commit details
    Browse the repository at this point in the history
  11. Remove text-center class in heading price header

    Not sure why it was added in commit 9fb5019, but it made the table
    look funny on some screens, particularly after adding the extra field
    we're about to add.
    javierm committed May 29, 2023
    Configuration menu
    Copy the full SHA
    60d5268 View commit details
    Browse the repository at this point in the history
  12. Move investments sidebar map view to a component

    This way we remove some logic from the (huge) investments controller
    class.
    javierm committed May 29, 2023
    Configuration menu
    Copy the full SHA
    727e849 View commit details
    Browse the repository at this point in the history

Commits on May 31, 2023

  1. Remove redundant HTML map classes

    The `map` class is applied to the map element by LeafletJS; using it in
    the container led to hacks like adding an `inline` class to fix the fact
    that the container was using the `height` rule of the `.map` elements.
    
    Even though we don't add styles for them, I'm adding the `budgets-map`
    and `budget-investments-map` HTML classes so these elements can still be
    easily selected with CSS and JavaScript.
    javierm committed May 31, 2023
    Configuration menu
    Copy the full SHA
    106dee0 View commit details
    Browse the repository at this point in the history
  2. Remove obsolete check for the budget presence

    This check isn't necessary since commit 7e3dd47, since now we check
    that the budget is present before creating the components which call
    this method.
    javierm committed May 31, 2023
    Configuration menu
    Copy the full SHA
    fb0caa3 View commit details
    Browse the repository at this point in the history
  3. Add notices when creating and updating geozones

    Just like we do in pretty much every section in the admin area.
    javierm committed May 31, 2023
    Configuration menu
    Copy the full SHA
    d1f1e1d View commit details
    Browse the repository at this point in the history
  4. Add polygon geographies to Budgets' map

    Note that in the budgets wizard test we now create district with no
    associated geozone, so the text "all city" will appear in the districts
    table too, meaning we can't use `within "section", text: "All city" do`
    anymore since it would result in an ambiguous match.
    
    Co-Authored-By: Julian Herrero <[email protected]>
    Co-Authored-By: Javi Martín <[email protected]>
    3 people committed May 31, 2023
    Configuration menu
    Copy the full SHA
    de13e78 View commit details
    Browse the repository at this point in the history
  5. Include heading geozone in investments sidebar map

    Note that, in this case, we aren't binding a popup to the polygon
    because the link would point to the same page we're already in.
    javierm committed May 31, 2023
    Configuration menu
    Copy the full SHA
    a9029be View commit details
    Browse the repository at this point in the history
  6. Merge pull request consuldemocracy#3907 from consul/polygon_geographies

    Add polygon geographies to Budgets' map
    javierm authored May 31, 2023
    Configuration menu
    Copy the full SHA
    1392733 View commit details
    Browse the repository at this point in the history

Commits on Jun 5, 2023

  1. Merge pull request consuldemocracy#5119 from consul/airbrake_setup_fo…

    …r_errbit
    
    Fix integration between `Errbit` and the `airbrake` gem
    Senen authored Jun 5, 2023
    Configuration menu
    Copy the full SHA
    ae4cf31 View commit details
    Browse the repository at this point in the history
  2. Fix cached secrets when running tests

    When running multiple specs that have to overwrite the rails secrets,
    it can happen that the condition:
    "@cached_rails_secrets != Rails.application.secrets"
    is not met and unexpected secrets are returned.
    
    We have found this case while experimenting with tests related to the
    Tenant secrets. In one case, assigning cached rails secrets to nil resulted in
    a failure to detect when the 'rails.application.secrets' had changed.
    taitus committed Jun 5, 2023
    Configuration menu
    Copy the full SHA
    4de3991 View commit details
    Browse the repository at this point in the history

Commits on Jun 6, 2023

  1. Merge pull request consuldemocracy#5123 from consul/fix-current-secrets

    Fix cached tenant secrets when running tests
    javierm authored Jun 6, 2023
    Configuration menu
    Copy the full SHA
    a480c5d View commit details
    Browse the repository at this point in the history

Commits on Jun 7, 2023

  1. Allow to change the application name for deployments

    When someone installs CONSUL with the installer using
    a custom `app_name`, the deployment configuration file
    must use the same application name; otherwise, the
    Capistrano task to update the crontab will duplicate the
    crontab entries with different names causing unexpected
    errors.
    
    Below is an example of the issue. The first set of crontab
    entries was created during installation using a custom
    app_name. The second set of entries are duplicated
    during the first deployment with a wrong application
    name in the config/deploy.rb file.
    
    ```
    deploy@ubuntu:~$ crontab -l
    * * * * * /bin/bash -l -c 'date > ~/cron-test.txt'
    0 5 * * * /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230529101753 && RAILS_ENV=production bundle exec rake -s sitemap:refresh --silent'
    0 1 * * * /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230529101753 && RAILS_ENV=production bundle exec rake files:remove_old_cached_attachments --silent'
    0 3 * * * /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230529101753 && RAILS_ENV=production bundle exec rake votes:reset_hot_score --silent'
    0 0,2,4,6,8,10,12,14,16,18,20,22 * * * /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230529101753 && RAILS_ENV=production bundle exec rake -s stats:generate --silent'
    @reboot /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230529101753 && bundle exec puma -C config/puma/production.rb'
    @reboot /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230529101753 && RAILS_ENV=production bin/delayed_job -n 2 restart'
    
    * * * * * /bin/bash -l -c 'date > ~/cron-test.txt'
    0 5 * * * /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230530112702 && RAILS_ENV=production bundle exec rake -s sitemap:refresh --silent'
    0 1 * * * /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230530112702 && RAILS_ENV=production bundle exec rake files:remove_old_cached_attachments --silent'
    0 3 * * * /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230530112702 && RAILS_ENV=production bundle exec rake votes:reset_hot_score --silent'
    0 0,2,4,6,8,10,12,14,16,18,20,22 * * * /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230530112702 && RAILS_ENV=production bundle exec rake -s stats:generate --silent'
    @reboot /bin/bash -l -c 'cd /home/deploy/participacyl/releases/20230530112702 && bundle exec puma -C config/puma/production.rb'
    ```
    Senen committed Jun 7, 2023
    Configuration menu
    Copy the full SHA
    d7bc82a View commit details
    Browse the repository at this point in the history

Commits on Jun 12, 2023

  1. Configuration menu
    Copy the full SHA
    b3c294b View commit details
    Browse the repository at this point in the history
  2. Remove metadata from images

    Currently in the application we never show the original image, we always
    show one of its variants.
    
    This change removes the metadata of both the variants and the original
    version so that if at some point we decide to show the original version,
    we will no longer have to remember to remove the metadata.
    taitus authored and javierm committed Jun 12, 2023
    Configuration menu
    Copy the full SHA
    78ee456 View commit details
    Browse the repository at this point in the history
  3. Merge pull request consuldemocracy#5121 from consul/application_name_…

    …for_deployments
    
    Allow to change the application name for deployments
    Senen authored Jun 12, 2023
    Configuration menu
    Copy the full SHA
    cf8a98f View commit details
    Browse the repository at this point in the history

Commits on Jun 14, 2023

  1. Allow to pass the destination link for the geozone link

    Previous to this commit the geozone link shown in the
    legislation proposal page was pointing to the proposals
    process feature instead to the legislation proposals.
    Senen committed Jun 14, 2023
    Configuration menu
    Copy the full SHA
    a6b1866 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    9003c46 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    1bc2a68 View commit details
    Browse the repository at this point in the history
  4. Add the geozone name to the proposal partial when there are geozones …

    …defined
    
    As we have links pointing to a search by geozone name I
    think we should show somewhere the geozone where the
    proposal belongs.
    Senen committed Jun 14, 2023
    Configuration menu
    Copy the full SHA
    37695cd View commit details
    Browse the repository at this point in the history

Commits on Jun 19, 2023

  1. Configuration menu
    Copy the full SHA
    e4cd02c View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ca12388 View commit details
    Browse the repository at this point in the history

Commits on Jun 23, 2023

  1. Allow administrators to override legislation translations

    Now administrators can override default legislation translations through
    the administration panel.
    Senen committed Jun 23, 2023
    Configuration menu
    Copy the full SHA
    dc9a30a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    27249f6 View commit details
    Browse the repository at this point in the history
  3. Merge pull request consuldemocracy#5137 from consul/legislation_trans…

    …lations
    
    Allow administrators to override legislation and budget translations
    Senen authored Jun 23, 2023
    Configuration menu
    Copy the full SHA
    443c5e0 View commit details
    Browse the repository at this point in the history
  4. Sort languages alphabetically

    So it's easier to know where to add new ones when needed.
    Senen committed Jun 23, 2023
    Configuration menu
    Copy the full SHA
    1d7c821 View commit details
    Browse the repository at this point in the history
  5. Update search dictionaries

    Since the creation of this list 3 years ago we added more languages to the
    application and PostgreSQL added more dictionaries too.
    Senen committed Jun 23, 2023
    Configuration menu
    Copy the full SHA
    3c3ff65 View commit details
    Browse the repository at this point in the history
  6. Merge pull request consuldemocracy#5110 from consul/dependabot/bundle…

    …r/audited-5.3.3
    
    Bump audited from 5.0.2 to 5.3.3
    javierm authored Jun 23, 2023
    Configuration menu
    Copy the full SHA
    8ed898a View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    13bf866 View commit details
    Browse the repository at this point in the history
  8. Merge pull request consuldemocracy#5104 from markusgeert/feature/disa…

    …ble-create-booths-button
    
    Disable the create booths button when the polls function is disabled
    javierm authored Jun 23, 2023
    Configuration menu
    Copy the full SHA
    ec1fe1f View commit details
    Browse the repository at this point in the history

Commits on Jun 26, 2023

  1. Merge pull request consuldemocracy#5122 from consul/strip-metadata

    Remove metadata from images
    taitus authored Jun 26, 2023
    Configuration menu
    Copy the full SHA
    bb8759d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    f497349 View commit details
    Browse the repository at this point in the history
  3. Render budget images with special chars their names

    Images with brackets weren't being rendered properly, so we're now
    enclosing the URL in single quotes. In order to render images with
    single quotes, we're also using the `j` method.
    
    Since the tests were written by a different developer, we're adding them
    in the next commit.
    javierm committed Jun 26, 2023
    Configuration menu
    Copy the full SHA
    5630a24 View commit details
    Browse the repository at this point in the history
  4. Add method to retrieve translations in one database query

    This methods performs much better when we need to load a lot of
    globalized models translations and returns the best fallback translation
    for the current language.
    Senen committed Jun 26, 2023
    Configuration menu
    Copy the full SHA
    2b0a812 View commit details
    Browse the repository at this point in the history
  5. Fix map markers navigation for keyboard users

    By using the bindPopup function instead of the click event
    popups work when using the keyboard.
    
    Note that now we are loading all the map markers in the first
    request in a single query to the database (needed when there
    is a lot or markers to show). Because of that we removed the
    AJAX endpoint.
    Senen committed Jun 26, 2023
    Configuration menu
    Copy the full SHA
    3fa3c90 View commit details
    Browse the repository at this point in the history
  6. Merge pull request consuldemocracy#5134 from consul/pg_search_diction…

    …aries
    
    Update search dictionaries
    Senen authored Jun 26, 2023
    Configuration menu
    Copy the full SHA
    90ddd99 View commit details
    Browse the repository at this point in the history

Commits on Jun 27, 2023

  1. Configuration menu
    Copy the full SHA
    3a623c0 View commit details
    Browse the repository at this point in the history
  2. Remove unused code for legislation proposals votes

    In these commits 38ba5e1 and 8805037 we added the parameter
    "vote_url" in the call to the partial "votes" in collaborative legislation
    proposals.
    
    It seems that this parameter is only used in the proposals module and not in
    collaborative legislation proposals.
    
    While it is true that in the partial "votes" in these commits this parameter
    "vote_url" is referred to, in commit 276baed it seems to be removed.
    
    For this reason, we remove the parameter.
    taitus committed Jun 27, 2023
    Configuration menu
    Copy the full SHA
    ab2c548 View commit details
    Browse the repository at this point in the history
  3. Fix background images with special characters

    Just like we did for budgets, we're doing the same thing in all the
    places where we render background images attached by either regular
    users or administrators.
    
    This way we correctly render background images with characters like
    brackets or quotes.
    javierm committed Jun 27, 2023
    Configuration menu
    Copy the full SHA
    ad26c5c View commit details
    Browse the repository at this point in the history
  4. Merge pull request consuldemocracy#5098 from consul/map_open_popups_w…

    …ith_keyboard
    
    Open marker popups when navigating with the keyboard
    Senen authored Jun 27, 2023
    Configuration menu
    Copy the full SHA
    ab698a7 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    d2b1817 View commit details
    Browse the repository at this point in the history
  6. Merge pull request consuldemocracy#5140 from consul/legislation-propo…

    …sals
    
    Remove unused code from Legislation proposals
    taitus authored Jun 27, 2023
    Configuration menu
    Copy the full SHA
    f001f07 View commit details
    Browse the repository at this point in the history
  7. Fix Serbian locale code

    I accidentally duplicated the locale code within
    commit 3c3ff65.
    Senen committed Jun 27, 2023
    Configuration menu
    Copy the full SHA
    83b5965 View commit details
    Browse the repository at this point in the history

Commits on Jun 28, 2023

  1. Merge pull request consuldemocracy#5141 from consul/search_dictionary…

    …_selector
    
    Fix Serbian locale code
    Senen authored Jun 28, 2023
    Configuration menu
    Copy the full SHA
    93d33b6 View commit details
    Browse the repository at this point in the history

Commits on Jun 29, 2023

  1. Configuration menu
    Copy the full SHA
    15e9c59 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5143 from consul/bump_parser

    Bump parser from 3.1.0.3 to 3.2.2.3
    Senen authored Jun 29, 2023
    Configuration menu
    Copy the full SHA
    59d260c View commit details
    Browse the repository at this point in the history
  3. Restart DelayedJob workers after they crash

    DelayedJob offers the `--monitor` (aliased as `-m`) option to create a
    process that monitors the workers and restarts them when they crash.
    
    This change implies that, in order to stop the delayed job workers, we
    now need to pass the `-n` option when running `bin/delayed_job stop`:
    `RAILS_ENV=production bin/delayed_job -n 2 stop`.
    javierm committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    ee9cd88 View commit details
    Browse the repository at this point in the history
  4. Enable mousewheel when focusing on the map

    Zooming with the mousewheel is useful when you want to use it, but
    annoying when you don't want to.
    
    Here we're taking an intermediary approach: by default, the mousewheel
    isn't active, but it will be active after focusing on the map, so it can
    be used both to scroll and to zoom.
    
    This behavior presents usability issues, though, since we aren't making
    users aware of the way the mousewheel works, and even if they were
    aware, it could be confusing anyway. However, I currently think it's
    better than always enabling or always disabling the mousewheel (might
    change my mind, though).
    
    Note that the "focus" event is only used on the map, so if we click on a
    marker or navigate to a marker with the keyboard without focusing on the
    map first, the mousewheel isn't enabled. The same would happen if we
    used the "click" event.
    
    We might use the Leaflet.GestureHandling plugin in the future to deal
    with this issue and the scroll on touch screens.
    javierm committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    970a64e View commit details
    Browse the repository at this point in the history
  5. Fix text selection in budget heading

    The `inverted-selection` rules defined in the `%brand-background`
    selector weren't being applied because we were using this selector in
    `::before` and `::after` pseudoelements. Not sure about the reason, but
    it looks like the saturation of `::after::selection` pseudoelements
    resulted in invalid selectors and so the inverted selection rules were
    ignored for every selection using `%brand-background`, like
    `%budget-header`.
    
    Using `@include brand-background` instead of `@extend %brand-background`
    in pseudoelements solves the issue. The inverted selection might not
    work in these pseudoelements, but we don't need it there since these
    pseudoelements don't have content.
    javierm committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    6892740 View commit details
    Browse the repository at this point in the history
  6. Bump selenium-webdriver from 3.142 to 4.0.0

    And also `capybara-webmock' to the latest as the previous
    one is not supported by selenium-webdriver.
    
    The change in the rails_helper.rb file fixes a deprecation warning
    related to desired capabilities after this upgrade.
    Senen committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    41a84d6 View commit details
    Browse the repository at this point in the history
  7. Merge pull request consuldemocracy#5147 from consul/bump_capybara-web…

    …mock
    
    Bump selenium-webdriver from 3.142 to 4.0.0
    Senen authored Jun 29, 2023
    Configuration menu
    Copy the full SHA
    b4f2e66 View commit details
    Browse the repository at this point in the history
  8. Render markdown tables in legislation draft

    * Add Tables option to Redcarpet in Legislation draft
    
    * Allow table tags in Admin Legislation Sanitizer
    
    * Add Test to render markdown tables in Legislation drafts
    
    * Add Test for Admin Legislation Sanitizer
    
    We include test for image, table and h1 to h6 tags and additional tests to strengthen the allowed and disallowed parameters
    
    * Add Table from markdown test in System and Factories
    
    * Add test to render  tables for admin user
    
    * Remove comment line about Redcarpet options
    
    * Edit custom css for legislation draft table to make it responsive
    karim-semmoud committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    3faaa85 View commit details
    Browse the repository at this point in the history
  9. Use the same extensions in all markdown renderers

    We were using two different sets of extensions but, since the markdown
    code is always written by administrators, IMHO it makes sense to be
    consistent and always render markdown code the same way.
    javierm authored and karim-semmoud committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    7912020 View commit details
    Browse the repository at this point in the history
  10. Extract markdown helper logic to a class

    This way it'll be easier for other Consul installations to overwrite
    parts of the code, like the default options.
    javierm authored and karim-semmoud committed Jun 29, 2023
    Configuration menu
    Copy the full SHA
    af618ea View commit details
    Browse the repository at this point in the history
  11. Merge pull request consuldemocracy#5136 from Meet-Democracy/Legislati…

    …on-draft-render-markdown-tables
    
    Render markdown tables in legislation draft
    javierm authored Jun 29, 2023
    Configuration menu
    Copy the full SHA
    a668ecd View commit details
    Browse the repository at this point in the history

Commits on Jun 30, 2023

  1. Merge pull request consuldemocracy#5145 from consul/map_wheel_on_focus

    Enable mousewheel when focusing on the map
    javierm authored Jun 30, 2023
    Configuration menu
    Copy the full SHA
    865fe70 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5106 from consul/fix_budget_backgr…

    …ound_image
    
    Render background images with brackets in their names
    javierm authored Jun 30, 2023
    Configuration menu
    Copy the full SHA
    286a128 View commit details
    Browse the repository at this point in the history
  3. Merge pull request consuldemocracy#5129 from consul/geozones

    Do not show geozones when there are no geozones defined
    Senen authored Jun 30, 2023
    Configuration menu
    Copy the full SHA
    37417e5 View commit details
    Browse the repository at this point in the history
  4. Merge pull request consuldemocracy#5146 from consul/delayed_job_monitor

    Restart DelayedJob workers after they crash
    javierm authored Jun 30, 2023
    Configuration menu
    Copy the full SHA
    db4db07 View commit details
    Browse the repository at this point in the history

Commits on Jul 3, 2023

  1. Reduce log size in development/test environments

    Code based on the logger Rails uses by default; as mentioned in the
    Rails configuration guide:
    
    > [the logger] defaults to an instance of ActiveSupport::TaggedLogging
    > that wraps an instance of ActiveSupport::Logger which outputs a log to
    > the log/ directory. You can supply a custom logger, to get full
    > compatibility you must follow these guidelines:
    >
    > * To support a formatter, you must manually assign a formatter from
    >   the config.log_formatter value to the logger.
    > * To support tagged logs, the log instance must be wrapped with
    >   ActiveSupport::TaggedLogging.
    > * To support silencing, the logger must include
    >   ActiveSupport::LoggerSilence module. The ActiveSupport::Logger class
    >   already includes these modules.
    
    Just like the documentation mentions, we're enabling log rotation using
    "1" as the number of old files to keep and then the maximum size of the
    log file.
    javierm committed Jul 3, 2023
    Configuration menu
    Copy the full SHA
    e0a94f6 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5142 from consul/local_logs

    Reduce log size in development/test environments
    javierm authored Jul 3, 2023
    Configuration menu
    Copy the full SHA
    29a3fe4 View commit details
    Browse the repository at this point in the history
  3. Merge pull request consuldemocracy#5144 from consul/fix_invert_selection

    Fix text selection in budget header
    javierm authored Jul 3, 2023
    Configuration menu
    Copy the full SHA
    2766d8f View commit details
    Browse the repository at this point in the history

Commits on Jul 7, 2023

  1. Configuration menu
    Copy the full SHA
    ce7b37f View commit details
    Browse the repository at this point in the history

Commits on Jul 10, 2023

  1. Fix URL to our kanban project

    We were referencing an old URL that has been obsolete for years.
    javierm committed Jul 10, 2023
    Configuration menu
    Copy the full SHA
    832a6dd View commit details
    Browse the repository at this point in the history

Commits on Jul 12, 2023

  1. Configuration menu
    Copy the full SHA
    629756d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    054aef3 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    3d9a23b View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    7dfbf77 View commit details
    Browse the repository at this point in the history
  5. Change the logo to include the new name

    Co-Authored-By: Javi Martín <[email protected]>
    decabeza and javierm committed Jul 12, 2023
    Configuration menu
    Copy the full SHA
    0a47a00 View commit details
    Browse the repository at this point in the history
  6. Remove old comment referencing the project name

    It was obvious which project the comment was about. Also, no point
    having a TODO referencing what to do after upgrading to Rails 5.1, since
    we did it years ago.
    javierm committed Jul 12, 2023
    Configuration menu
    Copy the full SHA
    175c1a7 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    3a72776 View commit details
    Browse the repository at this point in the history

Commits on Jul 13, 2023

  1. Fix English typos

    Senen committed Jul 13, 2023
    Configuration menu
    Copy the full SHA
    53046a5 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5150 from consuldemocracy/typos

    Fix source string typo
    Senen authored Jul 13, 2023
    Configuration menu
    Copy the full SHA
    c4cf747 View commit details
    Browse the repository at this point in the history
  3. Fix release version number in rake tasks

    When we added the tasks, we thought the new version was going to be
    version 1.6.0, but in the end we're renaming it to version 2.0.0.
    javierm committed Jul 13, 2023
    Configuration menu
    Copy the full SHA
    d137df6 View commit details
    Browse the repository at this point in the history
  4. Release version 2.0.0

    javierm committed Jul 13, 2023
    Configuration menu
    Copy the full SHA
    a5d9945 View commit details
    Browse the repository at this point in the history

Commits on Jul 17, 2023

  1. Update translations from Crowdin

    ConsulBot authored and Senen committed Jul 17, 2023
    Configuration menu
    Copy the full SHA
    82f5d69 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7afd921 View commit details
    Browse the repository at this point in the history
  3. Merge pull request consuldemocracy#5126 from consuldemocracy/i18n_cro…

    …wdin
    
    Update translations from Crowdin
    javierm authored Jul 17, 2023
    Configuration menu
    Copy the full SHA
    e2f31b7 View commit details
    Browse the repository at this point in the history
  4. Merge pull request consuldemocracy#5033 from consuldemocracy/release_…

    …2.0.0
    
    Release version 2.0.0
    javierm authored Jul 17, 2023
    Configuration menu
    Copy the full SHA
    28a9bd5 View commit details
    Browse the repository at this point in the history

Commits on Aug 2, 2023

  1. Bump selenium-webdriver from 4.0.0 to 4.11.0

    Webdrivers doesn't seem to be working with GitHub Actions since Chrome
    changed the way to download ChromeDriver [1].
    
    Luckily, webdrivers functionality has recently been added directly to
    selenium-webdriver, and version 4.11.0 is compatible with the new way to
    download ChromeDriver.
    
    So we're updating selenium-webdriver and removing webdrivers.
    
    Note we now have to use the `Options` class instead of the
    `Capabilities`. We're updating Capybara since its changelog mentions its
    latest version also adapts these changes in Selenium.
    
    [1] https://groups.google.com/g/chromedriver-users/c/qVPTFXnedw0
    javierm committed Aug 2, 2023
    Configuration menu
    Copy the full SHA
    5b0fb32 View commit details
    Browse the repository at this point in the history

Commits on Aug 4, 2023

  1. Merge pull request consuldemocracy#5162 from consuldemocracy/bump_sel…

    …enium_webdriver_to_4.11
    
    Bump selenium-webdriver from 4.0.0 to 4.11.0
    javierm authored Aug 4, 2023
    Configuration menu
    Copy the full SHA
    b986dbb View commit details
    Browse the repository at this point in the history

Commits on Aug 5, 2023

  1. Use custom translations in components

    In the `i18n_translation` initializer, we're overwriting the `t` helper
    so calling it uses custom translations if they're available.
    
    However, ViewComponent doesn't use the `t` helper but implements its own
    `t` method. So, when calling the `t` method in a component, we weren't
    using our implementation of the `t` helper, and so we weren't loading
    custom translations.
    
    Using the `t` helper in components solves the issue.
    
    There was a test where we were directly testing a method in a component,
    and that method uses the `t` helper. This caused an error when running
    the test:
    
    ViewComponent::Base::ViewContextCalledBeforeRenderError:
    `#helpers` can't be used during initialization, as it depends on the
    view context that only exists once a ViewComponent is passed to the
    Rails render pipeline.
    
    Using `render_inline` in the test and testing the generated HTML, as
    recommended in the ViewComponent documentation, solves the issue.
    javierm committed Aug 5, 2023
    Configuration menu
    Copy the full SHA
    dc3a286 View commit details
    Browse the repository at this point in the history

Commits on Aug 7, 2023

  1. Fix syntax in robots.txt

    We added the `user_id` rule in commit edaf420. To be honest, I'm not
    sure what we meant, since I haven't found URLs containing the user id.
    
    So we're treating it as if it was a typo and we wanted to do the same
    thing we did with other parameters.
    javierm committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    1bb8c71 View commit details
    Browse the repository at this point in the history
  2. Allow current way to write respond_to blocks

    Not sure exactly since when, but we've started to get rubocop failures
    when using the pattern:
    
    respond_to do |format|
      format.js
    end
    
    We've been using this pattern for ages, so maybe a recent version of
    Rubocop introduced a change that made it report it.
    
    In any case, this is easier to read than respond_to(&:js), so we're
    allowing it.
    javierm committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    7996925 View commit details
    Browse the repository at this point in the history

Commits on Aug 9, 2023

  1. Merge pull request consuldemocracy#5169 from consuldemocracy/fix_robots

    Fix syntax in robots.txt
    javierm authored Aug 9, 2023
    Configuration menu
    Copy the full SHA
    f77c414 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5165 from consuldemocracy/custom_t…

    …ranslations_in_components
    
    Use custom translations in components
    javierm authored Aug 9, 2023
    Configuration menu
    Copy the full SHA
    89d0dc0 View commit details
    Browse the repository at this point in the history
  3. Merge pull request consuldemocracy#5156 from consuldemocracy/fix_rubocop

    Fix Rubocop convention offenses
    javierm authored Aug 9, 2023
    Configuration menu
    Copy the full SHA
    74b07de View commit details
    Browse the repository at this point in the history

Commits on Aug 17, 2023

  1. Update translations from Crowdin

    ConsulBot authored and Senen committed Aug 17, 2023
    Configuration menu
    Copy the full SHA
    582f850 View commit details
    Browse the repository at this point in the history
  2. Release version 2.0.1

    javierm committed Aug 17, 2023
    Configuration menu
    Copy the full SHA
    20e577d View commit details
    Browse the repository at this point in the history

Commits on Aug 18, 2023

  1. Merge pull request consuldemocracy#5176 from consuldemocracy/i18n_cro…

    …wdin
    
    Update translations from Crowdin
    Senen authored Aug 18, 2023
    Configuration menu
    Copy the full SHA
    e064475 View commit details
    Browse the repository at this point in the history
  2. Merge pull request consuldemocracy#5177 from consuldemocracy/release_…

    …2.0.1
    
    Release version 2.0.1
    javierm authored Aug 18, 2023
    Configuration menu
    Copy the full SHA
    fd71ae5 View commit details
    Browse the repository at this point in the history

Commits on Aug 22, 2023

  1. Configuration menu
    Copy the full SHA
    580c3ab View commit details
    Browse the repository at this point in the history

Commits on Aug 23, 2023

  1. Add custom logo header

    decabeza committed Aug 23, 2023
    Configuration menu
    Copy the full SHA
    769da07 View commit details
    Browse the repository at this point in the history
  2. Fix budget header styles

    decabeza committed Aug 23, 2023
    Configuration menu
    Copy the full SHA
    e6b9c0c View commit details
    Browse the repository at this point in the history
  3. Add gradient on process feed

    decabeza committed Aug 23, 2023
    Configuration menu
    Copy the full SHA
    07c9bee View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    a67c2a4 View commit details
    Browse the repository at this point in the history
  5. Add avatar on login items

    decabeza committed Aug 23, 2023
    Configuration menu
    Copy the full SHA
    600bc35 View commit details
    Browse the repository at this point in the history
  6. Remove unused i18n keys

    decabeza committed Aug 23, 2023
    Configuration menu
    Copy the full SHA
    429655c View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    cf611e8 View commit details
    Browse the repository at this point in the history
  8. Update monit.rb

    decabeza committed Aug 23, 2023
    Configuration menu
    Copy the full SHA
    56610e6 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    d3350e9 View commit details
    Browse the repository at this point in the history

Commits on Aug 24, 2023

  1. Fix rubocop offenses

    microweb10 committed Aug 24, 2023
    Configuration menu
    Copy the full SHA
    e76b7c0 View commit details
    Browse the repository at this point in the history

Commits on Aug 25, 2023

  1. Configuration menu
    Copy the full SHA
    f3d5e0f View commit details
    Browse the repository at this point in the history
  2. Add polls custom user message

    decabeza authored and microweb10 committed Aug 25, 2023
    Configuration menu
    Copy the full SHA
    769b9a1 View commit details
    Browse the repository at this point in the history

Commits on Aug 27, 2023

  1. Configuration menu
    Copy the full SHA
    2b6db77 View commit details
    Browse the repository at this point in the history

Commits on Sep 4, 2023

  1. Configuration menu
    Copy the full SHA
    14a1a0e View commit details
    Browse the repository at this point in the history

Commits on Sep 5, 2023

  1. Merge pull request #146 from democrateam/refactor_specs

    Move custom specs to a custom folder
    microweb10 authored Sep 5, 2023
    Configuration menu
    Copy the full SHA
    5e2240a View commit details
    Browse the repository at this point in the history