Commit Graph

245 Commits

Author SHA1 Message Date
Nazar Gargol
670c33f2fe Reenabled members importer tests
refs 2bf69f94e7

- Tests were temporary disabled to unblock the release.
- The solution for failing tests was adding a "waitFor" statement which allowed asyncronous CSV parsing to finish
2020-07-16 23:59:48 +12:00
Nazar Gargol
2bf69f94e7 Removed developerExperiments flag from behind updated members importer
no issue

- Removes redesigned members importer features from behind `enableDeveloperExperiments` flag enabling it by default for everyone
- Had to disable some of the tests for future investigation to unblock the release
2020-07-13 23:55:07 +12:00
Peter Zimon
f74ca902c2 Added sample CSV link to members import
no refs.
- added link to a sample CSV in members import start screen
2020-07-09 17:30:24 +02:00
Peter Zimon
59ed8d718d Members import refinements
no refs.
- updated and removed copy on mapping screen
2020-07-09 14:42:29 +02:00
Peter Zimon
c611f65f53 Refined members import modal
no refs.
- fixed title logic
- fixed stripe validation message
2020-07-09 12:12:53 +02:00
Nazar Gargol
bcfc3792cd Removed invalid and duplicate email validations in members importer 2020-07-09 17:55:40 +12:00
Peter Zimon
36613212bb Fixed test for member import validation
no refs.
- fixed copy for member import validation test
2020-07-08 16:05:44 +02:00
Nazar Gargol
2da05338dd Fixed failure to render gh-members-import-table compontent
refs 4ee30dc5bd

- The tests were failing because there was no protective code to check for empty parameters.
2020-07-08 23:11:07 +12:00
Peter Zimon
6511a47524 Fixed tests
no refs.
2020-07-07 18:18:00 +02:00
Peter Zimon
1dd2a3db07 Updated styles for members import
no refs.
- added spinner to validation state
- applied styles to pre-validation step
- applied styles to import results
2020-07-07 17:53:59 +02:00
Rish
f8b2092f6c 🐛 Fixed nav item not saving updated value on keyboard save
no issue

- Fixes nav item values not saving on keyboard save shortcut
- Nav items value was only being updated in settings on focus out from text field.
- In case of keyboard save, focus out didn't happen so old value got saved and re-populated
- Change fixes to update setting value while typing
2020-07-07 14:47:10 +05:30
Nazar Gargol
39c4fec9ea Improved validation process for members CSV import
no issue

- A new validation stage has been introduced as a second step after CSV file has been dropped. It is meant to catch any obvious validation errors and output detailed statistics about
- These improvements also improve sampling logic which increases sample size to 30 non-empty cells which are used to validate stripe_customer_ids when there's such need.
- New sampling logic also introduces improved automatic field type detection which allows to better map email and stripe_customer_id fields to CSV columns
2020-07-07 00:28:30 +12:00
Nazar Gargol
e36b79c940 Added field mapping column to members importer gird
no issue

- Adds UI to map imported csv fields to ones accepted by Ghost API
- Includes automatic mapping detection for emails and stripe_customer_ids
2020-07-03 16:54:21 +12:00
Kevin Ansfield
8f8fcfc8bb Added UTC offset to scheduled editor status text
refs https://github.com/TryGhost/Ghost/issues/11965

- updated the `{{gh-format-post-time}}` helper that is used in editor status and in post settings menu email sub-menu for displaying email sent time
2020-07-01 20:37:46 +01:00
Kevin Ansfield
6d55e46b73 Fixed gh-format-post-time tests
refs eacf8a72d8

- updated to reflect change of "x hours" display from <15mins to <12hrs
2020-07-01 13:33:25 +01:00
Nazar Gargol
08853fac2d Fixed member import test
refs 09f4a48bc5

- The copy was changed, test needed to be updated as well.
2020-07-01 17:46:50 +12:00
Kevin Ansfield
fcb9b87884 Renamed activeTimezone setting to timezone
refs https://github.com/TryGhost/Ghost/issues/10318

- API has been updated to still work with `active_timezone` for backwards compatibility but it makes sense for the client to match the underlying settings keys
2020-06-24 15:34:59 +01:00
Kevin Ansfield
9348858bbe Added missing renames of settings groups
refs https://github.com/TryGhost/Ghost/issues/10318, 6d83c30f01

- the mocked settings endpoint was not returning any settings created with the old `blog` key which broke tests
2020-06-23 21:05:11 +01:00
Nazar Gargol
6aefc005f8 Removed email validation test from members import validator
refs 2dfff367b9

- The test was removed because feature is no longer needed.
- Qoute from Zimo: " reason: it’s based on a sample so we don’t know for sure how much of the data is actually affected. we might bring it back in the future though"
2020-06-19 14:20:56 +12:00
Nazar Gargol
29c1b2f18c Commented out broken test untill the case clears out
no issue

- Need to understand if email validation was removed from the client intentionally.
2020-06-19 00:10:30 +12:00
Nazar Gargol
f62554934d Fixed one of failing member import validation tests 2020-06-18 23:34:49 +12:00
Nazar Gargol
131fd8fe2c Fixed failing test
refs ed98d89771
2020-06-18 18:11:15 +12:00
Nazar Gargol
ed98d89771 Added imported members csv data preview
no issue

- Adds a table representation of data present in a CSV file that is about to be imported. Allows to navigate through data to see how exactly the file would be parsed on server
2020-06-18 17:47:04 +12:00
Kevin Ansfield
7331f8feed Fixed multiple no-shadow linting errors 2020-06-17 09:35:46 +01:00
Daniel Lockyer
282ce16d2c Fixed error message in tests
no issue
2020-06-16 22:06:11 +01:00
Nazar Gargol
fca6d3300d Renamed members import/export endpoints to match API changes
refs 5f00619d1a
2020-06-16 18:13:06 +12:00
Nazar Gargol
095e29d83d Added imported member count to the "Import" button
no issue

- When importing members from CSV file this change shows total amount of members that will attempt to be imported
2020-06-13 00:51:19 +12:00
Nazar Gargol
060b0e759b Fixed isStripeEnabled usage in import validator tests
refs c63a0e6826

- Reason for the fix same as in the referenced commit
2020-06-12 18:28:15 +12:00
Nazar Gargol
c3d141dd03 Added improved validations for 2nd step of members import
no issue

- Adds validations for imported CSV data
- These checks include obvious validation checks for data - like if email addresses are valid, checking if Stripe configured when entries with stripe_customer_id are present and additional server-side validation for entries with stripe_customer_id to check if they appear in connected Stripe account
- The validation set is calculated by naive choosing of first 5, middle 5 and 5 tail records from imported set. This logic comes from observations that errors usually apear withing "test" records in the beggining or the end of the file. These selection rules might change in the future if we find a need for it.
- Adds papaparse CSV parser, which was chosen for it's maturity and relatively small minified size. In the future this library should be lazy-loaded to make the first page load UX nicer
2020-06-12 17:22:36 +12:00
Peter Zimon
8a88f31a91 Fixed test for member import dialog copy changes
no refs.
2020-06-05 15:41:00 +02:00
Nazar Gargol
6bfe8e6490 Added separate stage to members import popup with support of labels
refs 633ba27f0e

- Import modal is now devided into separate stages with ability to specify labels which will be assigned to every member present in the dataset.
- Also adds explicit "Import" button without automatic import when the CSV file is selected
2020-06-05 22:57:07 +12:00
renovate[bot]
654d373655 Update dependency ember-power-select to v4 (#1528)
* Update dependency ember-power-select to v4
* Fixed trigger component override collision when building

- move the "override" into our own namespace
- update all `<PowerSelect>` usage to explicitly reference our customised trigger component

* Bumped ember-power-datepicker

- bumps `ember-basic-dropdown` sub-dependency
- resolves "Error: Could not find module `ember-compatibility-helpers` imported from `@glimmer/component/index`"
- https://github.com/cibernox/ember-basic-dropdown/issues/551

* Updated trigger to use class syntax

- it's not possible to use `.extend()` on an imported class

* Updated <GhBasicDropdown>

- match updated ember-basic-dropdown code

* Added `autofocus` modifier

- added `ember-modifier` dependency so that we can create our own render modifiers

* Updated <GhSearchInputTrigger> to a glimmer component

* Updated gh-token-input components

* Fixed tests

- wrap `<PowerSelect>` with `<div>` to maintain test selectors
- fixed `<GhBasicDropdown>` not rendering anything due to not having a local template

Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Kevin Ansfield <kevin@lookingsideways.co.uk>
2020-05-17 22:35:53 +01:00
Peter Zimon
4b5f538552 Updated notifications design (#1498)
no issue

- updating toaster design for better discoverability
2020-02-27 09:19:29 +00:00
Kevin Ansfield
1e77a4c915 Removed <GhDownloadCount>
no issue

- the count.ghost.org service is being shut down
- replaced the fetch+poll component with a hardcoded figure
2020-01-27 09:51:45 +00:00
Kevin Ansfield
ba4c53134f Upgraded eslint-plugin-ghost and fixed new linter errors
no issue

- update imports for `@ember-data` package (https://github.com/emberjs/rfcs/blob/master/text/0395-ember-data-packages.md)
- use `computed.reads` where applicable (https://github.com/ember-cli/eslint-plugin-ember/blob/master/docs/rules/require-computed-macros.md)
- fix usage of `scheduleOnce` so that functions are only scheduled once (https://github.com/ember-cli/eslint-plugin-ember/blob/master/docs/rules/no-incorrect-calls-with-inline-anonymous-functions.md)
2020-01-16 17:01:12 +00:00
Kevin Ansfield
2231dd84c2 Migrated to <AngleBracketSyntax /> (#1460)
no issue

Ember is migrating to `<AngleBracketSyntax />` for component invocation, see https://github.com/emberjs/rfcs/blob/master/text/0311-angle-bracket-invocation.md

We were in a half-way situation where some templates used angle bracket syntax in some places, this PR updates templates to use the syntax everywhere.

This simplifies the rules for what template code is referring to...

`<Component>` = a component
`{{helper}}` = a helper (or locally assigned handlebars variable)
`{{this.foo}}` = data on the template backing context (a component/controller)
`{{@foo}}` = a named argument passed into the component that the component backing class has not modified (note: this commit does not introduce any named arguments)

- ran codemod https://github.com/ember-codemods/ember-angle-brackets-codemod on the following directories:
  - `app/templates`
  - `lib/koenig-editor/addon/templates`
- removed positional params from components as angle bracket syntax does not support them
  - `gh-feature-flag`
  - `gh-tour-item`
  - `gh-cm-editor`
  - `gh-fullscreen-modal`
  - `gh-task-button`
- updates some code that was missed in 3c851293c1 to use explicit this
2020-01-16 15:14:03 +00:00
Kevin Ansfield
68c7147887 Fixed linting 2020-01-07 09:11:42 +00:00
Kevin Ansfield
7e0bbbf658 Swapped and updated pretender dependency
no issue

- `ember-cli-pretender` is no longer required when using `ember-auto-import`
- updated `pretender` dependency from 2.1.2 to 3.2.0
- removed upload progress tests (one was already skipped due to random failures) because pretender is not outputting meaningful `event.loaded` and `event.total` values
2020-01-06 17:28:47 +00:00
Kevin Ansfield
159e810d5c Merge branch 'master' into v3 2019-10-08 14:04:38 +01:00
Naz Gargol
98da7e1f26 Content visibility configuration in labs (#1346)
no issue

- Changed members description to less verbose
- Added content visibility radio options to members configuration screen
- Moved setting of default visibility to server-side
- Default visibility setting when PSM is opened before making the first request to the server
2019-10-02 11:13:59 +02:00
Naz Gargol
cdb87e5112 Added PSM visibility input (#1344)
refs 80f7e0b19e

- Added visibility input in PSM to control content access level for members
- Added default post visibility in editor. To be changed (moved to server-side) once `defaultContentVisibility` is available in settings service
- Added `visibility` property to post model & mirage
2019-10-01 15:00:53 +02:00
Rishabh Garg
30b2d3a4b3 Switched Admin API version from canary to v3 (#1317)
no issue

- Switches over to new v3 endpoint from canary
2019-09-03 12:40:27 +05:30
Rishabh Garg
99a4c1c4c2 🎨 Updated tags screen design and usability (#1283)
no issue

Updates design and usability for tags list and details screen
2019-08-27 19:21:31 +05:30
Kevin Ansfield
5225a3d30a Added "What's new" indicator and modal to highlight recent updates (#1292)
no issue

- adds `whats-new` service that fetches the changelog from ghost.org and exposes the latest changelog entries
- trigger a background fetch of the changelog from ghost.org when first loading the admin when logged in, or after signing in
- adds a "What's new" menu item next to the user popup menu
- adds an indicator to the user menu button and what's new menu item if there are unseen changelog entries
- closing the changelog modal will update the "last seen date", clearing both indicators
2019-08-23 10:01:27 +01:00
Kevin Ansfield
d4f2280a68 Switched Admin API version from v2 to canary (#1291)
no issue

- Ghost-Admin is our primary API client, we should keep it in sync with the canary API branch to dog food our API changes
2019-08-12 09:56:21 +01:00
Peter Zimon
c51bce7358 🎨 Updated admin area design and usability (#1232)
refs. https://github.com/TryGhost/Team/issues/205

Major update to Ghost Admin UI including:
- improved general consistency (typography, colors and contrast, UI components, icons)
- new design for post and pages lists, improved discoverability of filters 
- search moved to modal
- account menu is decoupled from ghost logo
- further usability fixes
2019-06-18 11:47:20 +01:00
Kevin Ansfield
d193317bbd Refactored deprecated usage of this.$() in rendering tests
no issue

- https://emberjs.com/deprecations/v3.x#toc_jquery-apis
2019-05-13 15:31:32 +01:00
Kevin Ansfield
1520122483 Refactored deprecated usage of setupTest* methods
no issue

- https://github.com/emberjs/ember-mocha/blob/master/docs/migration.md#upgrading-to-the-new-testing-apis
- deleted tests files which had no specific tests
- migrated unskipped component unit tests to integration tests
2019-05-13 15:31:32 +01:00
Kevin Ansfield
cf4246dd5e Bumped waitFor timeouts in gh-uploader tests
no issue

- Travis was randomly failing here
2019-05-13 09:59:05 +01:00
Kevin Ansfield
5883784268 Fixed random failure of gh-uploader test 2019-05-01 16:09:28 +01:00