Skip to content

Conversation

michalkleiner
Copy link
Contributor

@michalkleiner michalkleiner commented Oct 15, 2023

Description:

Follow up PR for #21401

  • Add content and preview images for premium plugins
  • Align widget names and image names with plugin names (with two exceptions for heatmaps and session recordings)
  • Add template for plugin promo widget
  • Extend ContentBlock component to allow for image with a 50/50 grid (this is needed so that the whole card can use the grid and the image is aligned at the top with the heading)
  • Integrate 'Learn more' link opening a modal with plugin details
  • Integrate 'Start free trial' CTA opening a new tab with plugin info from the marketplace
  • Add UI tests

Review

@michalkleiner michalkleiner added not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org. Needs Review PRs that need a code review labels Oct 15, 2023
@michalkleiner michalkleiner added this to the 5.0.0 milestone Oct 15, 2023
@michalkleiner michalkleiner force-pushed the dev-17228-premium-plugins-promos-5x branch from a095432 to a007cc5 Compare October 16, 2023 02:24
@michalkleiner michalkleiner requested a review from a team October 16, 2023 02:48
@michalkleiner
Copy link
Contributor Author

Also there might be some potential to abstract some parts of the widget configure and render methods into a base promo widget class of sorts. I looked into that and the complicating factor is that the configure method is static and render is instance, so if we e.g. wanted to provide new methods for the promoted plugin name or its display name etc, it would again be a mix of static and instance methods that can't be called from a parent class. Perhaps I didn't see the right way through it but it felt it was becoming too convoluted for little benefit.

Base automatically changed from dev-17228-add-menu-item-for-premium-plugins-5 to 5.x-dev October 16, 2023 05:27
@michalkleiner michalkleiner force-pushed the dev-17228-premium-plugins-promos-5x branch from 9f9e01a to 6149202 Compare October 16, 2023 06:10
@michalkleiner
Copy link
Contributor Author

michalkleiner commented Oct 16, 2023

@bx80 or @mneudert do you have any high level remarks/comments on this piece? Keen to get this in. Ta!

Ben and others added 5 commits October 25, 2023 14:01
… as needed

This is needed as config override from UI tests has lower priority than ui-test.php file overrides.
It seems the DI config isn't passed to the class properly during the UI tests
so using its static method using config provided by the DI works better.
@michalkleiner
Copy link
Contributor Author

Already including latest 5.x-dev with the fix from #21435 to make it easier for the merge when #21435 is merged first.

@michalkleiner michalkleiner force-pushed the dev-17228-premium-plugins-promos-5x branch from aad8c6f to 9aab746 Compare October 25, 2023 12:58
@michalkleiner michalkleiner force-pushed the dev-17228-premium-plugins-promos-5x branch from 3fd873e to 4847dca Compare October 25, 2023 20:09
@michalkleiner michalkleiner force-pushed the dev-17228-premium-plugins-promos-5x branch from ac6bb13 to bb7592e Compare October 26, 2023 00:50
@michalkleiner michalkleiner requested review from bx80 and a team October 26, 2023 01:56
@michalkleiner
Copy link
Contributor Author

@matomo-org/core-reviewers this is finally good for another review.

@michalkleiner michalkleiner merged commit 523fc32 into 5.x-dev Oct 27, 2023
@michalkleiner michalkleiner deleted the dev-17228-premium-plugins-promos-5x branch October 27, 2023 01:35
caddoo pushed a commit that referenced this pull request Nov 5, 2023
* Add initial template for plugin promos

* Move image to Card so grid can be used at card level

* Add plugin promo screenshots

* Adjust content

* Use widget template instead of controller view

* Populate plugin promo content

* Remove enable/disable variable override

* Remove legal info markup as not yet designed

* Unify image alt text and remove help url property

* Prepare promo widgets for refactoring for reusability

* Integrate CTA links

* Rename A/B Testing image to match plugin name

* Use marketplace plugin info where possible

* Update Start free trial CTA to open marketplace in new tab

* Move promo features text to lang file

* Add UI tests

* Update UI test screenshots from CI

* Simplify UI test selector

* Update UI tests

* Use full plugin names in category ids

* Disable Professional Services ads for UI tests apart from the plugin itself

* Fix typo in test method name

* Add new widget categories to widgets test

* Add integration test without professional services widgets/categories

* Update expected list of report pages returned by the API in a system test

* Added missing externalLink method reference to the vue global properties

* built vue files

* Use test.vars. approach to disable professional services for UI tests as needed

This is needed as config override from UI tests has lower priority than ui-test.php file overrides.

* Remove test dependency on Advertising class

It seems the DI config isn't passed to the class properly during the UI tests
so using its static method using config provided by the DI works better.

* Reverse logic so that Professional Services are disabled for UI tests by default and only enabled when required

* Ensure page is reloaded after config change

* Update screenshot from CI run

* Reset UI tests config before each test

Tidying up the config within the test where it's set didn't work.

* Move mouse out of viewport to prevent any unwanted hover effects

* Update tests from CI

* Update language to use visitor instead of user

* Update UI test screenshots after content change

---------

Co-authored-by: Ben <ben.burgess@innocraft.com>
caddoo pushed a commit that referenced this pull request Nov 5, 2023
* Add initial template for plugin promos

* Move image to Card so grid can be used at card level

* Add plugin promo screenshots

* Adjust content

* Use widget template instead of controller view

* Populate plugin promo content

* Remove enable/disable variable override

* Remove legal info markup as not yet designed

* Unify image alt text and remove help url property

* Prepare promo widgets for refactoring for reusability

* Integrate CTA links

* Rename A/B Testing image to match plugin name

* Use marketplace plugin info where possible

* Update Start free trial CTA to open marketplace in new tab

* Move promo features text to lang file

* Add UI tests

* Update UI test screenshots from CI

* Simplify UI test selector

* Update UI tests

* Use full plugin names in category ids

* Disable Professional Services ads for UI tests apart from the plugin itself

* Fix typo in test method name

* Add new widget categories to widgets test

* Add integration test without professional services widgets/categories

* Update expected list of report pages returned by the API in a system test

* Added missing externalLink method reference to the vue global properties

* built vue files

* Use test.vars. approach to disable professional services for UI tests as needed

This is needed as config override from UI tests has lower priority than ui-test.php file overrides.

* Remove test dependency on Advertising class

It seems the DI config isn't passed to the class properly during the UI tests
so using its static method using config provided by the DI works better.

* Reverse logic so that Professional Services are disabled for UI tests by default and only enabled when required

* Ensure page is reloaded after config change

* Update screenshot from CI run

* Reset UI tests config before each test

Tidying up the config within the test where it's set didn't work.

* Move mouse out of viewport to prevent any unwanted hover effects

* Update tests from CI

* Update language to use visitor instead of user

* Update UI test screenshots after content change

---------

Co-authored-by: Ben <ben.burgess@innocraft.com>
caddoo pushed a commit that referenced this pull request Nov 5, 2023
* Add initial template for plugin promos

* Move image to Card so grid can be used at card level

* Add plugin promo screenshots

* Adjust content

* Use widget template instead of controller view

* Populate plugin promo content

* Remove enable/disable variable override

* Remove legal info markup as not yet designed

* Unify image alt text and remove help url property

* Prepare promo widgets for refactoring for reusability

* Integrate CTA links

* Rename A/B Testing image to match plugin name

* Use marketplace plugin info where possible

* Update Start free trial CTA to open marketplace in new tab

* Move promo features text to lang file

* Add UI tests

* Update UI test screenshots from CI

* Simplify UI test selector

* Update UI tests

* Use full plugin names in category ids

* Disable Professional Services ads for UI tests apart from the plugin itself

* Fix typo in test method name

* Add new widget categories to widgets test

* Add integration test without professional services widgets/categories

* Update expected list of report pages returned by the API in a system test

* Added missing externalLink method reference to the vue global properties

* built vue files

* Use test.vars. approach to disable professional services for UI tests as needed

This is needed as config override from UI tests has lower priority than ui-test.php file overrides.

* Remove test dependency on Advertising class

It seems the DI config isn't passed to the class properly during the UI tests
so using its static method using config provided by the DI works better.

* Reverse logic so that Professional Services are disabled for UI tests by default and only enabled when required

* Ensure page is reloaded after config change

* Update screenshot from CI run

* Reset UI tests config before each test

Tidying up the config within the test where it's set didn't work.

* Move mouse out of viewport to prevent any unwanted hover effects

* Update tests from CI

* Update language to use visitor instead of user

* Update UI test screenshots after content change

---------

Co-authored-by: Ben <ben.burgess@innocraft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs Review PRs that need a code review not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org.
Development

Successfully merging this pull request may close these issues.

5 participants