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

DataTable sort by function (or other callable) #3090

Merged
merged 13 commits into from
Oct 31, 2023

Commits on Aug 11, 2023

  1. DataTable sort by function (or other callable)

    The `DataTable` widget now takes the `by` argument instead of `columns`, allowing the table to also be sorted using a custom function (or other callable). This is a breaking change since it requires all calls to the `sort` method to include an iterable of key(s) (or a singular function/callable). Covers Textualize#2261 using [suggested function signature](Textualize#2512 (comment)) from @darrenburns on PR Textualize#2512.
    joshbduncan committed Aug 11, 2023
    Configuration menu
    Copy the full SHA
    fcce7e2 View commit details
    Browse the repository at this point in the history

Commits on Aug 28, 2023

  1. argument change and functionaloty update

    Changed back to orinal `columns` argument and added a new `key` argument
    which takes a function (or other callable). This allows the PR to NOT BE
    a breaking change.
    joshbduncan committed Aug 28, 2023
    Configuration menu
    Copy the full SHA
    69730d8 View commit details
    Browse the repository at this point in the history

Commits on Aug 29, 2023

  1. better example for docs

    - Updated the example file for the docs to better show the functionality
    of the change (especially when using `columns` and `key` together).
    - Added one new tests to cover a similar situation to the example
      changes
    joshbduncan committed Aug 29, 2023
    Configuration menu
    Copy the full SHA
    7cd0494 View commit details
    Browse the repository at this point in the history

Commits on Aug 30, 2023

  1. removed unecessary code from example

    - the sort by clicked column function was bloat in my opinion
    joshbduncan committed Aug 30, 2023
    Configuration menu
    Copy the full SHA
    312f9ac View commit details
    Browse the repository at this point in the history

Commits on Sep 21, 2023

  1. requested changes

    joshbduncan committed Sep 21, 2023
    Configuration menu
    Copy the full SHA
    5f71d0f View commit details
    Browse the repository at this point in the history

Commits on Oct 12, 2023

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

Commits on Oct 17, 2023

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

Commits on Oct 24, 2023

  1. Configuration menu
    Copy the full SHA
    948b816 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    9beb7ed View commit details
    Browse the repository at this point in the history

Commits on Oct 27, 2023

  1. Configuration menu
    Copy the full SHA
    6ed8ae3 View commit details
    Browse the repository at this point in the history
  2. Removing some tests from DataTable.sort as duplicates. Ensure there i…

    …s test coverage of the case where a key, but no columns, is passed to DataTable.sort.
    darrenburns committed Oct 27, 2023
    Configuration menu
    Copy the full SHA
    5db5c1a View commit details
    Browse the repository at this point in the history
  3. Remove unused import

    darrenburns committed Oct 27, 2023
    Configuration menu
    Copy the full SHA
    9d17690 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    7541867 View commit details
    Browse the repository at this point in the history