Commit Graph

91 Commits

Author SHA1 Message Date
Kevin Ansfield
091ae194bf 🐛 Fixed duplicate email open rate column when filtering members by open rate
no issue

- email open rate is shown by default so we don't need to add the column a second time when the list is filtered by that data
- added `email_open_rate` to the default columns list so it's ignored when adding any filtered-by columns
2022-03-17 09:29:15 +00:00
Kevin Ansfield
ab67df76f8 Added tests for filtered columns showing in members table
refs https://github.com/TryGhost/Team/issues/1388
refs https://github.com/TryGhost/Team/issues/1337

- when filtering the members table, extra columns are shown to make any filtered data visible but we didn't have any tests for the functionality
- updated the `filterColumnLabels` getter to return an object with the original filter type name and the display label so it's easier to use test selectors
2022-02-22 16:10:16 +00:00
Kevin Ansfield
c72b31f504 Fixed test-selector typo for members table
refs 995673ad3c (commitcomment-66689174)

- fixed typo
- added check to base state test to confirm
2022-02-15 15:01:36 +00:00
Kevin Ansfield
995673ad3c Added acceptance test for members search
refs https://github.com/TryGhost/Team/issues/1336
refs bf9bbc3aa6

- adds basic search param handling to `GET /members` API mock
- adds acceptance tests for basic search behaviour
- contains regression check for search input not being visible when no members match
2022-02-14 16:23:57 +00:00
Djordje Vlaisavljevic
aed5da5d7a Added static HTML design for showing status/tier in members table
refs https://github.com/TryGhost/Team/issues/1035
2022-02-14 12:58:05 +01:00
Sanne de Vries
7e2230d952 Updated Members screen when subscription access is off 2022-02-11 19:06:48 +01:00
Peter Zimon
278b70d668 Updated members list help vertical alignment 2022-02-11 12:13:34 +01:00
Kevin Ansfield
f1c8af662f Refactored modal for bulk unsubscribing members
refs https://github.com/TryGhost/Team/issues/559

Members controller was becoming bloated and difficult to follow due to catering for many different concerns.

- converted old modal to newer promise-modal style
- pulled full bulk unsubscribing logic out of the members controller and into the modal so logic is contained in one place
2022-02-09 22:04:02 +00:00
Kevin Ansfield
8052166cbe Refactored modal for bulk deleting members
refs https://github.com/TryGhost/Team/issues/559

Members controller was becoming bloated and difficult to follow due to catering for many different concerns.

- converted old modal to newer promise-modal style
- pulled full label-removing logic out of the members controller and into the modal so logic is contained in one place
2022-02-09 22:04:02 +00:00
Kevin Ansfield
efb7bc4c3b Refactored modal for bulk removing a label to members
refs https://github.com/TryGhost/Team/issues/559

Members controller was becoming bloated and difficult to follow due to catering for many different concerns.

- converted old modal to newer promise-modal style
- pulled full label-removing logic out of the members controller and into the modal so logic is contained in one place
2022-02-09 21:58:59 +00:00
Kevin Ansfield
24b222e927 Refactored modal for bulk adding a label to members
refs https://github.com/TryGhost/Team/issues/559

Members controller was becoming bloated and difficult to follow due to catering for many different concerns.

- converted old modal to newer promise-modal style
- pulled full label-adding logic out of the members controller and into the modal so logic is contained in one place
- added `{{members-count-fetcher}}` resource that allows for member counts to be fetched directly from templates avoiding duplicated code
2022-02-09 21:58:59 +00:00
Sanne de Vries
7061b3416f Updated copy on empty members screen 2022-02-09 09:24:11 +01:00
Kevin Ansfield
b80ce527e5 Moved members screen filter components into components/members
no issue

- currently the components are screen-specific rather than generalised so shouldn't have the `gh-` prefix
- fixed linter error for confusing `{{#unless}}...{{else}}` usage
2022-02-08 15:11:01 +00:00
Kevin Ansfield
8e5cbf4e0f Cleaned up members filter labs components
no issue

- the members filtering is out of labs, we don't need to keep the labs component naming around
- renamed `-labs` components/classes to non-labs naming, replacing old and unused non-labs components where necessary
2022-02-08 11:48:55 +00:00
Kevin Ansfield
bf9bbc3aa6 Fixed members search input losing focus whilst typing
closes https://github.com/TryGhost/Team/issues/1318

The `{{if this.members.length "" "hidden"}}` class meant that whenever loading occurred the search input was briefly changed to `display: none` which caused focus to be lost making searching rather painful. It also meant the search input disappeared completely when no members matched a search.

- switched to a standard `<input>` element to get better event handling ergonomics
- added `searchIsFocused` tracked property that is set to `true` any time the search input has focus - works around an unexpected re-render when clearing the search input whilst it has focus
- switched the "hide" conditional to a getter that takes members length, search param text, and search input focus into account so there are no unexpected hides of the search bar
2022-02-08 11:44:08 +00:00
Kevin Ansfield
f111a23031 🐛 Fixed "Show all members" button not clearing search field when no results match
no issue

- the reset button was only clearing the `filter` param rather than resetting all query params
- removed unnecessary `searchText` indirection, the search input can work directly with the query param
2022-02-08 11:36:49 +00:00
Sanne de Vries
9234c8f695 🎨 Improved empty state of the Members screen
No issue

- Added resources to help and inspire people get started with members, which will be hidden after 6+ members are added
2022-02-07 16:11:08 +01:00
Gabriel Csapo
beb5ae1737 [chore] adds ember-template-lint and fixes all fixable issues (#2238)
no issue

- This will help with the octane migration and you can still run the lint rules even when they are todos. (Checkout the docs at 158b119667/docs/todos.md) The good news is any new code will be checked against the recommended config.
- I fixed all the auto fixable things we could get in this PR as well
2022-02-02 16:09:43 +00:00
Sanne de Vries
21b4b15a1c Improved Email newsletter settings page (#2207)
Updated email newsletter settings

- Added toggle to disable email newsletters
- Hides email related UI when email is completely turned off
- Rearranged email newsletter settings
- Added publish-menu preview in 
- Changed default-recipients setting
- Updated publish-menu to show Publish as default action
- Removed the confirmation modal during publishing when no emails are intended to be sent
2022-01-27 12:40:11 +01:00
Fabien O'Carroll
592e3df794 Added Members Filtering feature
no-issue

This adds the ability to apply complex filters to members, as well as to
perform bulk actions on the filtered set, including unsubscribing,
adding & removing labels.
2021-10-01 14:16:28 +02:00
Rishabh
6e3d2bef3a Updated filter UI to show existing filters on page refresh
refs https://github.com/TryGhost/Team/issues/972

If a filter is applied in the new members list then the URL gets updated and the filter dropdown contains the filters that have been created. When refreshing the page while a filter is applied, the URL remains the same, the filter is still applied but the UI in the filter dropdown resets and doesn't show the appropriate filter fields and values.

This change parses the nql filter from URL using `nql-lang` library and rebuilds the filter UI blocks based on current filter in URL. It also ignores any invalid or unexpected filters in the UI.
2021-09-09 15:13:58 +05:30
Rishabh
e70e0e273d Fixed member list not loading on scroll with filtering
closes https://github.com/TryGhost/Team/issues/971
reverts abe5c6d681

We use vertical-collection to allow infinite loading + scrolling for members list instead of loading and rendering all members at once. The behavior was not working correctly with updated list for filtering feature, as we dynamically update columns. This change fixes the scroll behavior and members loading together by updating the containerSelector for vertical collection.
2021-09-07 16:50:43 +05:30
Peter Zimon
5516968936 Added empty result states to new members filtering 2021-09-03 12:18:15 +02:00
Peter Zimon
0f0c44295e Added show-all button to empty members filter list 2021-09-03 11:37:26 +02:00
Rishabh
5594ba7219 Added live filter update to members list
refs https://github.com/TryGhost/Team/issues/963

- adds live update to member list based on applied filters
- cleans up filter behaviour for different scenarios
2021-08-13 23:22:59 +05:30
Rishabh
520252f5aa Added filter count to filter builder UI
no refs
2021-08-13 18:37:19 +05:30
Rishabh
084380d155 Wired reset filters filter button in filter builder
closes https://github.com/TryGhost/Team/issues/964

Wires the "Reset" button in filter builder to clear all filters easily and see the original full list of members.
2021-08-13 18:00:28 +05:30
Peter Zimon
0c3848c23a Refined members action dropdown 2021-08-13 13:55:08 +02:00
Rishabh
38a3962368 Added bulk operations UI for filtered members
refs https://github.com/TryGhost/Team/issues/969

A lot of power of filtering members comes from ability to perform actions on the filtered member list. This change adds bulk operation actions on the the UI to apply on filtered members, but has not wired them up to the API yet.

- adds unsubscribe bulk operation UI
- adds label addition bulk operation UI
- adds label removal bulk operation UI
- adds new single label selection UI for add/remove label to members UI
2021-08-13 17:11:34 +05:30
Rishabh
a895bafb53 Added label editing feature in filtering dropdown
refs https://github.com/TryGhost/Team/issues/966

With introduction of members filtering, the current way of editing member labels needed an upgrade. This change updates the member label input component to include editing option which allows triggering label edit modal directly from the filtering menu when working with labels. The long term idea is to make this a consistent global pattern with labels dropdown, extending to member details screen as well.
2021-08-12 17:51:18 +05:30
Rishabh
247f24394d Added dynamic columns to member list from filter UI
refs https://github.com/TryGhost/Team/issues/943

- adds new columns to member list table based on selected filters in UI
- handles dynamic columns in members list with formatted output like for labels
- works behind the filtering feature flag
2021-08-10 17:41:59 +05:30
Rishabh
30756f8882 Separated alpha members filtering feature into own component
refs https://github.com/TryGhost/Team/issues/943

- separates the new alpha members filtering to its own `-labs` component
- fixes behaviour for existing filtering feature on members list which was overwritten with last change
- updates up action handling to modern glimmer syntax
2021-08-07 09:48:47 +05:30
Rishabh
7a43c53ddb Added basic members list filtering via UI
refs https://github.com/TryGhost/Team/issues/943

- updates the static filtering ui to dynamic (behind alpha flag)
- generates basic nql filter queries for selected filters - `is` , `is not`
- filters members list on applied filters
2021-08-05 19:22:58 +05:30
Rishabh
9ee66f8b85 Added filtering on members list via URL param
refs https://github.com/TryGhost/Team/issues/942

- adds `?filter` param to members list page which allows directly filtering list via NQL filter syntax
2021-08-04 15:53:06 +05:30
Peter Zimon
5255489779 Added static members filtering
- added filter builder dropdown (alpha)
- refactored related CSS
2021-07-23 16:05:22 +02:00
Peter Zimon
d356f5451a Added static result table for members filtering
- Added horizontal scrolling, fullscreen table component.
- Mocked multiple columns in the members result list.

Alpha feature.
2021-07-22 15:47:01 +02:00
Kevin Ansfield
7ab0db9be7 Fixed ember-test-selectors bound attributes deprecations
no issue

- converted publish menu and `gh-tags-list-item` components to glimmer syntax so data attributes can be passed in via `...attributes`
- added explicit `data-test-button` bound attribute to `gh-task-button` component
- moved `modal-theme-warnings` auto-bound data attribute from JS file to explicit html attribute in template
2021-07-08 22:44:52 +01:00
Kevin Ansfield
72590083f3 Added ability to bulk delete members by label or status (#1883)
refs https://github.com/TryGhost/Team/issues/585
requires https://github.com/TryGhost/Ghost/pull/12082

When a label or status filter is selected on the members screen show a "Delete selected" option in the actions dropdown. Bulk deleted members will _not_ have any subscription data modified in Stripe, if a member should be deleted and have their subscription cancelled it's necessary to do that on a per-member basis.

- updated bulk delete handling to match API
- added link to bulk delete confirmation modal in members actions dropdown (only shown when label, status, or search is used)
- updated testing framework for members
  - added label factory for easier test setup
  - updated `GET /members` and `DEL /members` endpoints to work with label filters
  - updated test selectors for easier reference in tests
2021-04-08 12:06:27 +01:00
Peter Zimon
0fbb1adbdb Dashboard mini charts basic styles 2021-02-19 10:39:13 +01:00
Peter Zimon
f7cb949a6e Responsive UI fixes 2021-02-12 14:29:49 +01:00
Rish
6f1ea8b018 Fixed nightshift property not set on Member charts
no issue

Nightshift value was not correctly setup on <GhMembersChart> component, so it was always set to false.
2021-02-11 20:54:34 +05:30
Peter Zimon
6e1b6a2618 Updated custom integration UI 2021-02-08 21:16:41 +01:00
Peter Zimon
879c7866e9 Members screen UI refinements 2021-02-04 16:52:19 +01:00
Peter Zimon
c757ddbef8 UI updates (#1835)
* Admin UI update basics

Added the basics for the Admin UI/style update. Very far from being done...

* Admin style updates

- exploring menu
- enabling full width content (integrations selection bg)
- updated main screens
2021-02-03 20:08:01 +01:00
Sanne de Vries
ffe0f84700 Added open-rate column and ordering to the members list (#1790)
closes https://github.com/TryGhost/Ghost/issues/12421

- added `emailOpenRate` property to member model
- added open-rate column to the members list
  - hidden when email analytics is disabled
- added `{{feature "flag"}}` helper so feature flags can be checked in templates without injecting the feature service into the backing class
- added `order` query param to the members controller/route and wired it into the data fetching routine
- added order dropdown to the filter bar with "Newest" (default) and "Open rate" as the two options
  - whole dropdown is hidden if email analytics is disabled

Co-authored-by: Kevin Ansfield <kevin@lookingsideways.co.uk>
2020-12-08 19:23:57 +00:00
Fabien 'egg' O'Carroll
6ecb38eaa5 Added support for filtering the exported Members CSV (#1716)
no-issue

Co-authored-by: Peter Zimon <zimo@ghost.org>
2020-09-23 14:29:47 +01:00
Kevin Ansfield
3b78973a21 Removed bulk member edit dev experiment
no issue

- we're moving forward with a simplified bulk delete and the UI would conflict if both approaches are behind the dev experiments flag
2020-07-23 15:03:18 +01:00
Kevin Ansfield
eee84ab5f7 Added first pass bulk members delete confirmation and results display
no issue

- display a confirmation modal when bulk deleting members
- hit the `DELETE /members/?all=true` endpoint when confirming
- show counts of members deleted/skipped
- fix selection reset when leaving edit mode
2020-06-19 18:14:41 +01:00
Kevin Ansfield
d8270a110c Moved members bulk delete confirmation into a modal 2020-06-19 14:14:39 +01:00
Kevin Ansfield
34c28dcc0e Added rough "edit mode" for members table behind dev flag
no issue

- initial UI for bulk-selection, focusing for now on first stage which is limited to select-all and delete actions
- adds "Edit" button to the members table that shows the "selection" toolbar in place of the table header and shows a checkbox next to each member
2020-06-18 11:08:53 +01:00