Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
769 commits
Select commit Hold shift + click to select a range
75833a3
refactor: pr feedback - name placeholder
jaredrethman Oct 22, 2024
a7be15d
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-audience
jaredrethman Oct 23, 2024
364ac22
refactor: added `newspack` prefix to slug
jaredrethman Oct 23, 2024
c10e4d7
feat: add error message to upsert
jaredrethman Oct 23, 2024
46b0018
fix: force add `slug` to cache
jaredrethman Oct 23, 2024
d95e89d
refactor: pr feedback - use entire `result`
jaredrethman Oct 23, 2024
920a27a
feat: pr feedback - `resetError` on location change
jaredrethman Oct 23, 2024
a9705bc
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-settings-a…
jaredrethman Oct 24, 2024
6cc6041
Fix(epic-ia): hidden menu on php8 (#3493)
ronchambers Oct 24, 2024
da9877c
feat(ia-admin-header-selected): Allow ability to force selected tab (…
ronchambers Oct 24, 2024
a766df8
Merge pull request #3462 from Automattic/feat/ia-settings-additional-…
jaredrethman Oct 24, 2024
6cced4f
refactor: make css class global
jaredrethman Oct 24, 2024
da928a6
feat: add `description` prop to WizardsTab component
jaredrethman Oct 24, 2024
bd85a45
feat: wrap in `WizardsTab` component
jaredrethman Oct 24, 2024
3ff7fa3
refactor: name change `/audience-configuration` to `/audience`
jaredrethman Oct 25, 2024
293620c
fix: only apply merging to plain objects
jaredrethman Oct 25, 2024
84d4d43
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-audience
jaredrethman Oct 25, 2024
d2dc24b
Merge pull request #3503 from Automattic/fix/wizardapifetch-cache-mer…
jaredrethman Oct 28, 2024
fe1d154
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-audience
jaredrethman Oct 28, 2024
035075f
refactor: allow multiple react apps through a single directory
jaredrethman Oct 30, 2024
2de1d80
fix: ci / eslint
jaredrethman Nov 1, 2024
8ad5986
feat(ia): newsletters (#3490)
ronchambers Nov 1, 2024
8ae081d
fix(ia): dashboard newsletters settings link (#3515)
miguelpeixe Nov 1, 2024
359065f
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-audience
jaredrethman Nov 1, 2024
ca7d05b
feat: add reader activation campaign link
jaredrethman Nov 1, 2024
39b46d9
Merge branch 'trunk' into epic/ia
miguelpeixe Nov 4, 2024
7f90d67
feat: wip fixing newsletter enpoint
jaredrethman Nov 5, 2024
a90bfd4
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-audience
jaredrethman Nov 5, 2024
1609d52
fix(dashboard): check theme mod key (#3519)
miguelpeixe Nov 5, 2024
f631e13
feat: update esp href for ras
jaredrethman Nov 5, 2024
5d54aec
feat: update newsletters endpoint
jaredrethman Nov 5, 2024
eb26f31
feat: update recaptcha href
jaredrethman Nov 5, 2024
5781860
feat(ia-listings): IA for Listings Plugin (#3483)
ronchambers Nov 5, 2024
52bb202
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-audience
jaredrethman Nov 5, 2024
7812cc6
feat: text changes
jaredrethman Nov 5, 2024
bd8c799
refactor: final prep for review
jaredrethman Nov 6, 2024
cd5d5f4
fix: style issues on wizards not using `WizardsTab` component
jaredrethman Nov 6, 2024
507c382
fix(ia): core update nag margins
miguelpeixe Nov 7, 2024
a830ac0
refactor: add class `use` imports
jaredrethman Nov 7, 2024
827f70d
feat: add recaptcha scroll-to anchor
jaredrethman Nov 7, 2024
75cb7b9
feat: moved ts types to separate files
jaredrethman Nov 7, 2024
d3d0912
feat: update endpoints to audience configuration
jaredrethman Nov 7, 2024
3320b2d
feat: add `scrollToAnchor` doc comment
jaredrethman Nov 7, 2024
b95be18
fix: remove `wp_enqueue_style`
jaredrethman Nov 7, 2024
76bbc77
Merge pull request #3532 from Automattic/fix/ia-newsletters-css
jaredrethman Nov 7, 2024
d65ce26
Merge branch 'fix/ia-update-nag-margin' into epic/ia
ronchambers Nov 8, 2024
55ee135
fix(ia): adjust notifications margins
ronchambers Nov 8, 2024
f433027
fix: menu order
miguelpeixe Nov 13, 2024
41af659
fix: active menu items
miguelpeixe Nov 14, 2024
f97a88a
Fix/wizard admin menu priority 3 (#3544)
ronchambers Nov 14, 2024
03922a4
Merge branch 'epic/ia' into feat/ia-audience
ronchambers Nov 14, 2024
d87d0ab
feat(ia-audience): after merge, adjust menu ordering
ronchambers Nov 14, 2024
4ea5532
chore: remove ras from engagement wizard
miguelpeixe Nov 14, 2024
2740cf7
chore: remove duplicated components
miguelpeixe Nov 14, 2024
f572a65
fix: `#/complete` link url
miguelpeixe Nov 14, 2024
e2ccdee
fix(ia): deprecate webhooks global endpoint (#3529)
miguelpeixe Nov 19, 2024
d70a121
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-audience
jaredrethman Nov 19, 2024
3ef3e83
feat(connections): jetpack sso settings wizard (#3524)
miguelpeixe Nov 19, 2024
ed1837a
Merge pull request #3500 from Automattic/feat/ia-audience
jaredrethman Nov 20, 2024
c7cca97
feat(ia): audience campaigns (#3549)
miguelpeixe Nov 20, 2024
ca0f3f6
Merge remote-tracking branch 'origin/epic/ia' into epic/ia
jaredrethman Nov 20, 2024
1ca0b41
feat: add `newspack-` prefix to advertising display ads slug
jaredrethman Nov 20, 2024
ad08b10
feat: removed `-admin` suffix from listing slug
jaredrethman Nov 20, 2024
3d1e6b6
fix: re-add `newspack-wizard__content` style definition
jaredrethman Nov 20, 2024
55699a2
revert(ia): webpackChunkName changes
jaredrethman Nov 20, 2024
5785d89
Merge pull request #3561 from Automattic/fix/ia-dashboard-header
jaredrethman Nov 20, 2024
a03c701
refactor(ia): audience development setup and tabs (#3559)
miguelpeixe Nov 21, 2024
d6c79d8
Merge branch 'trunk' into epic/ia
miguelpeixe Nov 21, 2024
ee30891
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-consistent…
jaredrethman Nov 21, 2024
dda3a11
feat(ia): audience checkout/payment and donations wizard
miguelpeixe Nov 21, 2024
832b88d
feat: improve billing fields section integration
miguelpeixe Nov 21, 2024
8419faf
fix: remove "Emails" and start "Revenue " tab
miguelpeixe Nov 21, 2024
4b02093
chore: remove unused import
miguelpeixe Nov 21, 2024
7cdb2ad
feat(ia): pr feedback #issuecomment-2492010662
jaredrethman Nov 21, 2024
3244a02
feat: move "cover fees"
miguelpeixe Nov 21, 2024
bcdb00b
fix: improve NRH settings wizard ui
miguelpeixe Nov 21, 2024
a5dfeac
revert(ia): `admin` suffix removal from listings slug
jaredrethman Nov 21, 2024
c0751d6
chore: move donate block rendering block filter
miguelpeixe Nov 21, 2024
e04818b
chore: remove RR wizard
miguelpeixe Nov 21, 2024
bc8994d
chore: remove RR wizard
miguelpeixe Nov 21, 2024
bdcf4d8
fix(ia): duckduckgo blocking display of advertising menu
jaredrethman Nov 21, 2024
bac1ac8
chore: update and standardize wizard slugs
miguelpeixe Nov 21, 2024
8bd413e
fix: css selector
miguelpeixe Nov 21, 2024
ec20943
feat(ia): audience subscriptions boilerplate
jaredrethman Nov 21, 2024
fbbe54f
Merge pull request #3562 from Automattic/feat/ia-consistent-slugs
jaredrethman Nov 22, 2024
126679d
fix(ia): regression, updated ras endpoint
jaredrethman Nov 22, 2024
92384d8
Merge pull request #3566 from Automattic/fix/ia-dashboard-ras-endpoint
jaredrethman Nov 22, 2024
818c2cf
Merge branch 'epic/ia' into feat/ia-audience-donations-2
miguelpeixe Nov 22, 2024
5455975
fix(ia): if request doesn't return `config` property
jaredrethman Nov 22, 2024
8dd7f2b
revert: file formatting
jaredrethman Nov 22, 2024
e767867
Merge remote-tracking branch 'origin/epic/ia' into fix/ia-dashboard-r…
jaredrethman Nov 22, 2024
c3bd7c6
feat: add request error handling site status
jaredrethman Nov 23, 2024
e9df3a2
feat(ia-setup): initial dev
ronchambers Nov 25, 2024
bd5aff5
refactor: replace `reject` with `resolve`
jaredrethman Nov 25, 2024
1f959a7
fix: ci / wordpress
jaredrethman Nov 25, 2024
10cbc46
fix: translator format specifier
jaredrethman Nov 25, 2024
92d690e
fix: explicit string usage in sprintf
jaredrethman Nov 25, 2024
e5c931a
fix: add translator string
jaredrethman Nov 25, 2024
6c5b7e0
fix: ci / translator
jaredrethman Nov 25, 2024
5749aaa
fix: decouple methods and tweak wizard store
miguelpeixe Nov 25, 2024
620dd67
fix: billing fields api endpoint
miguelpeixe Nov 26, 2024
3509fb7
fix: donations configuration wizard
miguelpeixe Nov 26, 2024
613a2e6
fix: ia: hide notifications (#3563)
ronchambers Nov 26, 2024
e3d1a66
fix: salesforce settings
miguelpeixe Nov 26, 2024
02b79d8
fix: payment gatways endpoints
miguelpeixe Nov 26, 2024
33e6fa8
chore: update constant
miguelpeixe Nov 26, 2024
8a933f1
chore: update donation wizard data type
miguelpeixe Nov 26, 2024
0a88421
feat: revenue tab
miguelpeixe Nov 26, 2024
7d21b9a
test: change wizard to test
miguelpeixe Nov 26, 2024
835e0cc
fix: campaign wizard regressions
miguelpeixe Nov 26, 2024
10a45f4
fix: typo
miguelpeixe Nov 26, 2024
136b27e
fix: handle wizard loading on wizard tab
miguelpeixe Nov 26, 2024
97ac4a6
feat: conditionally load wizards if setup complete
jaredrethman Nov 26, 2024
548596b
Merge branch 'epic/ia' into feat/ia-audience-subscriptions
jaredrethman Nov 26, 2024
c68115d
Merge remote-tracking branch 'origin/feat/ia-audience-donations-2' in…
jaredrethman Nov 26, 2024
6b89046
feat: audience subscriptions revenue, configuration and settings
jaredrethman Nov 27, 2024
9c9c1c8
Merge branch 'epic/ia' into feat/ia-audience-donations-2
miguelpeixe Nov 27, 2024
c1e5ae7
fix: deprecate Salesforce
miguelpeixe Nov 27, 2024
7b3c2d1
Merge remote-tracking branch 'origin/feat/ia-audience-donations-2' in…
jaredrethman Nov 27, 2024
112017c
Merge pull request #3571 from Automattic/feat/ia-dashboard
jaredrethman Nov 27, 2024
93abc96
feat: ia network settings (#3479)
ronchambers Nov 27, 2024
8bf31f0
feat: update ui to use is-narrow card
jaredrethman Nov 28, 2024
f8ca397
feat(ia): audience checkout/payment and donations wizard (#3564)
miguelpeixe Nov 29, 2024
a4b17a6
Merge remote-tracking branch 'origin/trunk' into feat/epic-ia-trunk-r…
jaredrethman Dec 3, 2024
13d6d55
fix: conflicts fixes
jaredrethman Dec 3, 2024
06d15dc
feat: formatted recaptcha
jaredrethman Dec 3, 2024
32b405f
feat: incorporate new `credentials` property
jaredrethman Dec 4, 2024
4b92a82
refactor: move credentials update to function
jaredrethman Dec 4, 2024
e96a94b
fix: ci / eslint
jaredrethman Dec 4, 2024
1c950fa
Merge remote-tracking branch 'origin/trunk' into feat/epic-ia-trunk-r…
jaredrethman Dec 4, 2024
8ebb342
Merge remote-tracking branch 'origin/feat/epic-ia-trunk-rasacc' into …
jaredrethman Dec 5, 2024
69542d8
refactor: remove settings
jaredrethman Dec 5, 2024
ffd6bf8
fix: consistent recaptcha payload
jaredrethman Dec 5, 2024
d2ce4ff
chore: package-lock
jaredrethman Dec 5, 2024
ca290e1
feat: #pullrequestreview-2482526196
jaredrethman Dec 6, 2024
f42af86
fix: ci / eslint
jaredrethman Dec 6, 2024
58020ab
feat: #discussion_r1872015997 add rest and callbacks
jaredrethman Dec 6, 2024
c5f5e61
feat: #discussion_r1872015997 move to component
jaredrethman Dec 6, 2024
3108cde
feat: #discussion_r1872015997 cleanup payment component
jaredrethman Dec 6, 2024
0f6f5ce
refactor: is-fetching styles #discussion_r1872015997
jaredrethman Dec 6, 2024
ef6fde6
fix: ci / eslint
jaredrethman Dec 6, 2024
ff0ffd3
feat: replace `newspack` slug with `newspack-dashboard`
jaredrethman Dec 6, 2024
ac29333
Merge remote-tracking branch 'origin/feat/epic-ia-trunk-rasacc' into …
jaredrethman Dec 6, 2024
d29bd21
refactor: simplify execution
jaredrethman Dec 6, 2024
61c9e15
feat: apply default on missing keys
jaredrethman Dec 6, 2024
b0f697e
Merge remote-tracking branch 'origin/feat/epic-ia-trunk-rasacc' into …
jaredrethman Dec 6, 2024
7161d36
Merge remote-tracking branch 'origin/feat/epic-ia-trunk-rasacc' into …
jaredrethman Dec 6, 2024
1ff052b
Merge remote-tracking branch 'origin/trunk' into feat/epic-ia-trunk-r…
jaredrethman Dec 9, 2024
83f492e
Merge remote-tracking branch 'origin/feat/epic-ia-trunk-rasacc' into …
jaredrethman Dec 11, 2024
32a6b10
Merge remote-tracking branch 'origin/feat/epic-ia-trunk-rasacc' into …
jaredrethman Dec 11, 2024
53b78d2
refactor: `is_setup_complete` method
jaredrethman Dec 12, 2024
858277d
refactor: only setup if `newspack_setup_complete` is not set
jaredrethman Dec 12, 2024
b575236
refactor: change newspack blue
jaredrethman Dec 12, 2024
2bb8133
revert: comments
jaredrethman Dec 12, 2024
dba71e4
revert: accidental scss var overwrite
jaredrethman Dec 12, 2024
18a7628
feat: update audience links
jaredrethman Dec 12, 2024
87ee8d1
refactor: remove "wizard" from slug
jaredrethman Dec 12, 2024
95cd361
feat: cleanup url
jaredrethman Dec 12, 2024
e555c8d
Merge pull request #3592 from Automattic/feat/epic-ia-trunk-rasacc
jaredrethman Dec 12, 2024
b466258
feat: #issuecomment-2539808085
jaredrethman Dec 12, 2024
ea94615
refactor: move wizard class instantiations outside of conditional
jaredrethman Dec 16, 2024
88a93b8
feat(ia): network, disallow menu to appear before setup
jaredrethman Dec 16, 2024
26adf0d
feat(ia): newsletters, disallow menu to appear before setup
jaredrethman Dec 16, 2024
77773e6
refactor: remove unnecessary `admin_menu` hook, use is setup method
jaredrethman Dec 16, 2024
51d770f
feat: wrap `admin_menu` in `is_setup_complete` method
jaredrethman Dec 16, 2024
fe5f058
feat: dashboard, always show menu
jaredrethman Dec 16, 2024
f4acc57
refactor: update audience donations endpoint
jaredrethman Dec 16, 2024
95f62e6
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-setup
jaredrethman Dec 17, 2024
5e15a28
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-audience-s…
jaredrethman Dec 17, 2024
298a33c
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-dashboard-…
jaredrethman Dec 17, 2024
8c4bf1b
feat: update default colors in various scenarios
jaredrethman Dec 17, 2024
cc16cb3
refactor: aligned css var names with `newspack-ui`
jaredrethman Dec 17, 2024
f6d3c7d
feat: add `--newspack-ui-color-primary` to components/src
jaredrethman Dec 17, 2024
c549ed4
refactor: replace all primary color scss vars with css vars
jaredrethman Dec 18, 2024
4b9dd24
revert(ia): `is_setup_complete` conditionals
jaredrethman Dec 18, 2024
1483c09
Merge remote-tracking branch 'origin/trunk' into epic/ia
jaredrethman Dec 18, 2024
b222170
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-dashboard-…
jaredrethman Dec 18, 2024
f463137
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-setup
jaredrethman Dec 18, 2024
bf1011b
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-np-blue-he…
jaredrethman Dec 18, 2024
27398fe
Merge remote-tracking branch 'origin/epic/ia' into feat/ia-audience-s…
jaredrethman Dec 18, 2024
7ba88a2
feat(ia-setup__review): roll back dashboard
ronchambers Dec 18, 2024
3207789
feat(ia-setup__review): roll back setup
ronchambers Dec 18, 2024
87b7a5c
Merge remote-tracking branch 'origin/feat/ia-setup__review' into feat…
jaredrethman Dec 18, 2024
9a7d0c7
Merge pull request #3581 from Automattic/feat/ia-setup
jaredrethman Dec 18, 2024
da7f788
feat: add `/wp-admin/customize.php` as click detination for advanced …
jaredrethman Dec 19, 2024
95eba4a
refactor: replace `--newspack-wizard-color-neutral-70` with `wp-color…
jaredrethman Dec 19, 2024
fefbfba
refactor: #discussion_r1891880020
jaredrethman Dec 19, 2024
60a1787
refactor: #discussion_r1891884248
jaredrethman Dec 19, 2024
e4f67b7
refactor: pr feedback - use `wp-colors.$gray-100` instead of `--newsp…
jaredrethman Dec 20, 2024
2e1b044
revert: replace css vars with scss vars
jaredrethman Dec 20, 2024
5dddc4f
refactor: replace newspack-ui vars with `--wp` variants
jaredrethman Dec 20, 2024
21b930d
refactor: remove newspack-ui import
jaredrethman Dec 20, 2024
dd6ff1b
Merge pull request #3640 from Automattic/fix/ia-display-settings__adv…
jaredrethman Dec 20, 2024
c82f32b
Merge pull request #3621 from Automattic/feat/ia-np-blue-hexcode
jaredrethman Dec 20, 2024
fbaffb8
Merge remote-tracking branch 'origin/trunk' into epic/ia
jaredrethman Jan 5, 2025
ef31013
Merge remote-tracking branch 'origin/trunk' into epic/ia
jaredrethman Jan 11, 2025
5011bfe
feat(ia): cleanup site design (#3668)
jaredrethman Jan 24, 2025
f740314
Merge branch 'epic/ia' into feat/ia-dashboard-links
miguelpeixe Jan 27, 2025
60e8924
Merge branch 'trunk' into epic/ia
miguelpeixe Jan 27, 2025
c1ff671
chore: implement #3665
miguelpeixe Jan 27, 2025
a060c6a
chore: typo
miguelpeixe Jan 27, 2025
5ea2bb7
feat(ia): cleanup settings (#3641)
jaredrethman Jan 28, 2025
60b117b
Merge pull request #3565 from Automattic/feat/ia-audience-subscriptions
dkoo Jan 28, 2025
b551b91
style(tabbed-nav): avoid 1px jank on link hover
dkoo Jan 28, 2025
b6f0324
fix(nav-tabs): do not show native nav tabs in post editor
dkoo Jan 28, 2025
8196be2
Merge pull request #3622 from Automattic/feat/ia-dashboard-links
dkoo Jan 28, 2025
54a04a7
fix(ia): tweak syndication plugin cards behavior
dkoo Jan 28, 2025
05ed793
chore: update docblock
dkoo Jan 28, 2025
c2a1890
chore: update Publish to Apple News title and description
dkoo Jan 28, 2025
e3d793c
chore: update reloadOnStatusChange to reloadOnActivation, for accuracy
dkoo Jan 28, 2025
ca1103b
chore: update reloadOnStatusChange to reloadOnActivation, for accuracy
dkoo Jan 28, 2025
9dc1f09
Merge pull request #3706 from Automattic/fix/tabs-in-post-editor
dkoo Jan 28, 2025
122cecc
fix(ia): dashboard header icon background (#3703)
miguelpeixe Jan 29, 2025
b4b317c
Merge pull request #3704 from Automattic/style/avoid-1px-jank-on-hover
dkoo Jan 29, 2025
0cb39ff
Merge pull request #3707 from Automattic/fix/syndication-plugin-cards
dkoo Jan 29, 2025
644bd97
fix: deactivate plugin if active
dkoo Jan 29, 2025
5df775a
chore(ia): clean up connections (#3708)
miguelpeixe Feb 5, 2025
0bd1b66
fix(ia): cleanup analytics wizard (#3718)
miguelpeixe Feb 5, 2025
79786c8
fix(donation-settings): collect transaction fee settings
dkoo Feb 5, 2025
63c7133
fix(ras): rename Reader Activation to Audience Management throughout …
dkoo Feb 7, 2025
e242248
chore(ia): clean up engagement wizard (#3722)
miguelpeixe Feb 10, 2025
bf756ac
chore(ia): clean up health check wizard (#3721)
miguelpeixe Feb 10, 2025
a227dbe
feat(ras): allow skipping prerequisites; avoid dead end in onboarding
dkoo Feb 10, 2025
dbfa2af
Merge pull request #3730 from Automattic/fix/transaction-fee-settings
dkoo Feb 10, 2025
b10967e
fix: audience management campaign labels
dkoo Feb 10, 2025
a64faa5
fix: audience management campaign API endpoint
dkoo Feb 10, 2025
4940ee5
Update includes/reader-activation/class-reader-activation.php
dkoo Feb 10, 2025
7fb0b65
Merge pull request #3733 from Automattic/fix/ras-to-audience-management
dkoo Feb 10, 2025
13b2241
fix(recaptcha): remove v3 from heading; preserve settings on toggle
dkoo Feb 10, 2025
29dacd5
Merge branch 'epic/ia' into fix/ras-setup-avoid-dead-end
dkoo Feb 10, 2025
26f80b6
fix: class rename
dkoo Feb 10, 2025
17becb8
chore(ia): clean up seo wizard (#3737)
miguelpeixe Feb 11, 2025
626f91a
fix(ia): prevent enqueue of admin css in the frontend (#3742)
miguelpeixe Feb 11, 2025
280e528
Merge branch 'trunk' into epic/ia
miguelpeixe Feb 11, 2025
4df0d73
fix(ia): network content distribution settings (#3709)
miguelpeixe Feb 11, 2025
fae4a6a
fix: update preflight error text (#3744)
chickenn00dle Feb 11, 2025
17a8223
feat: use Modal component instead of browser for confirmation
dkoo Feb 11, 2025
3dbec2d
feat: more flexible confirmation modal in WithWizard HOC
dkoo Feb 12, 2025
4b63f45
Merge branch 'trunk' into epic/ia
miguelpeixe Feb 12, 2025
06ba10b
fix(action-card): remove border between consecutive child sections
dkoo Feb 12, 2025
f89890c
Merge pull request #3738 from Automattic/fix/ras-setup-avoid-dead-end
dkoo Feb 12, 2025
baad1b2
fix(ia): skip cache on google oauth flow (#3743)
miguelpeixe Feb 12, 2025
470f385
Merge pull request #3739 from Automattic/fix/recaptcha-ui
dkoo Feb 12, 2025
283aaa9
feat: update brand colours (#3732)
thomasguillot Feb 13, 2025
3d57bd5
Merge branch 'trunk' into epic/ia
miguelpeixe Feb 13, 2025
4cf3bef
Merge branch 'trunk' into epic/ia
miguelpeixe Feb 14, 2025
e7025a0
fix(ia): newsletters component for the setup wizard (#3749)
miguelpeixe Feb 14, 2025
9459c71
fix(ia): handle trashed donation products and avoid creating dupes (#…
dkoo Feb 18, 2025
318de15
Merge branch 'trunk' into epic/ia
miguelpeixe Feb 19, 2025
9697ccb
feat: add quick actions edit mode
thomasguillot Feb 24, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 3 additions & 0 deletions includes/api/class-plugins-controller.php
Original file line number Diff line number Diff line change
Expand Up @@ -376,6 +376,9 @@ public function configure_item( $request ) {
$managed_plugins = Plugin_Manager::get_managed_plugins();

\Newspack\Configuration_Managers::configure( $slug );

$managed_plugins[ $slug ]['Configured'] = \Newspack\Configuration_Managers::is_configured( $slug );

return rest_ensure_response( $managed_plugins[ $slug ] );
}

Expand Down
4 changes: 2 additions & 2 deletions includes/class-blocks.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,13 +40,13 @@ public static function enqueue_block_editor_assets() {
[
'has_newsletters' => class_exists( 'Newspack_Newsletters_Subscription' ),
'has_reader_activation' => Reader_Activation::is_enabled(),
'newsletters_url' => Wizards::get_wizard( 'engagement' )->newsletters_settings_url(),
'newsletters_url' => Wizards::get_wizard( 'newsletters' )->newsletters_settings_url(),
'has_google_oauth' => Google_OAuth::is_oauth_configured(),
'google_logo_svg' => \Newspack\Newspack_UI_Icons::get_svg( 'google' ),
'reader_activation_terms' => Reader_Activation::get_setting( 'terms_text' ),
'reader_activation_url' => Reader_Activation::get_setting( 'terms_url' ),
'has_recaptcha' => Recaptcha::can_use_captcha(),
'recaptcha_url' => admin_url( 'admin.php?page=newspack-connections-wizard' ),
'recaptcha_url' => admin_url( 'admin.php?page=newspack-settings' ),
]
);
\wp_enqueue_style(
Expand Down
30 changes: 20 additions & 10 deletions includes/class-donations.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,8 @@ public static function init() {
add_filter( 'wcs_place_subscription_order_text', [ __CLASS__, 'order_button_text' ], 9 );
add_filter( 'woocommerce_order_button_text', [ __CLASS__, 'order_button_text' ], 9 );
add_filter( 'option_woocommerce_subscriptions_order_button_text', [ __CLASS__, 'order_button_text' ], 9 );

add_filter( 'render_block', [ __CLASS__, 'prevent_rendering_donate_block' ], 10, 2 );
}

/**
Expand Down Expand Up @@ -454,8 +456,7 @@ public static function get_donation_settings() {
$parsed_settings['amounts'][ $frequency ] = array_map( 'floatval', $amounts );
}

$parsed_settings['platform'] = self::get_platform_slug();
$parsed_settings['billingFields'] = self::get_billing_fields();
$parsed_settings['platform'] = self::get_platform_slug();

// If NYP isn't available, force untiered config.
if ( ! self::can_use_name_your_price() ) {
Expand Down Expand Up @@ -486,13 +487,6 @@ public static function set_donation_settings( $args ) {
if ( isset( $args['saveDonationProduct'] ) && $args['saveDonationProduct'] === true ) {
self::update_donation_product( $configuration );
}

// Update the billing fields.
$billing_fields = isset( $args['billingFields'] ) ? $args['billingFields'] : [];
if ( ! empty( $billing_fields ) ) {
$billing_fields = array_map( 'sanitize_text_field', $billing_fields );
self::update_billing_fields( $billing_fields );
}
}

Logger::log( 'Save donation settings' );
Expand Down Expand Up @@ -644,7 +638,6 @@ public static function get_platform_slug() {
* @param string $platform Platform slug.
*/
public static function set_platform_slug( $platform ) {
delete_option( self::NEWSPACK_READER_REVENUE_PLATFORM );
update_option( self::NEWSPACK_READER_REVENUE_PLATFORM, $platform, true );
}

Expand Down Expand Up @@ -1140,6 +1133,23 @@ public static function disable_coupons( $enabled ) {
return false;
}

/**
* Prevent rendering of Donate block if Reader Revenue platform is set to 'other.
*
* @param string $block_content The block content about to be rendered.
* @param array $block The data of the block about to be rendered.
*/
public static function prevent_rendering_donate_block( $block_content, $block ) {
if (
isset( $block['blockName'] )
&& 'newspack-blocks/donate' === $block['blockName']
&& self::is_platform_other()
) {
return '';
}
return $block_content;
}

/**
* Set the "Place order" button text.
*
Expand Down
4 changes: 2 additions & 2 deletions includes/class-newspack-image-credits.php
Original file line number Diff line number Diff line change
Expand Up @@ -421,8 +421,8 @@ function( $setting ) use ( $key ) {
return $setting['key'] === $key;
}
);
$setting_values = array_values( $setting );
return reset( $setting_values );
$settings_values = array_values( $setting );
return reset( $settings_values );
}

return $default_settings;
Expand Down
96 changes: 57 additions & 39 deletions includes/class-newspack.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,6 @@ public function __construct() {
add_action( 'current_screen', [ $this, 'wizard_redirect' ] );
add_action( 'admin_menu', [ $this, 'handle_resets' ], 1 );
add_action( 'admin_menu', [ $this, 'remove_newspack_suite_plugin_links' ], 1 );
add_action( 'admin_notices', [ $this, 'remove_notifications' ], -9999 );
add_action( 'network_admin_notices', [ $this, 'remove_notifications' ], -9999 );
add_action( 'all_admin_notices', [ $this, 'remove_notifications' ], -9999 );
register_activation_hook( NEWSPACK_PLUGIN_FILE, [ $this, 'activation_hook' ] );
register_deactivation_hook( NEWSPACK_PLUGIN_FILE, [ $this, 'deactivation_hook' ] );
}
Expand All @@ -72,6 +69,7 @@ private function define_constants() {
define( 'NEWSPACK_ACTIVATION_TRANSIENT', '_newspack_activation_redirect' );
define( 'NEWSPACK_NRH_CONFIG', 'newspack_nrh_config' );
define( 'NEWSPACK_CLIENT_ID_COOKIE_NAME', 'newspack-cid' );
define( 'NEWSPACK_SETUP_COMPLETE', 'newspack_setup_complete' );
}

/**
Expand Down Expand Up @@ -117,7 +115,6 @@ private function includes() {
include_once NEWSPACK_ABSPATH . 'includes/oauth/class-google-oauth.php';
include_once NEWSPACK_ABSPATH . 'includes/oauth/class-google-services-connection.php';
include_once NEWSPACK_ABSPATH . 'includes/oauth/class-mailchimp-api.php';
include_once NEWSPACK_ABSPATH . 'includes/oauth/class-fivetran-connection.php';
include_once NEWSPACK_ABSPATH . 'includes/oauth/class-google-login.php';
include_once NEWSPACK_ABSPATH . 'includes/class-blocks.php';
include_once NEWSPACK_ABSPATH . 'includes/tracking/class-pixel.php';
Expand All @@ -126,29 +123,53 @@ private function includes() {
include_once NEWSPACK_ABSPATH . 'includes/revisions-control/class-revisions-control.php';
include_once NEWSPACK_ABSPATH . 'includes/authors/class-authors-custom-fields.php';
include_once NEWSPACK_ABSPATH . 'includes/corrections/class-corrections.php';
include_once NEWSPACK_ABSPATH . 'includes/class-syndication.php';
include_once NEWSPACK_ABSPATH . 'includes/bylines/class-bylines.php';

include_once NEWSPACK_ABSPATH . 'includes/starter_content/class-starter-content-provider.php';
include_once NEWSPACK_ABSPATH . 'includes/starter_content/class-starter-content-generated.php';
include_once NEWSPACK_ABSPATH . 'includes/starter_content/class-starter-content-wordpress.php';

include_once NEWSPACK_ABSPATH . 'includes/wizards/class-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-wizard-section.php';

include_once NEWSPACK_ABSPATH . 'includes/wizards/class-setup-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-dashboard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-components-demo.php';

/* Unified Wizards */
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-settings.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-advertising-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-analytics-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-engagement-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-reader-revenue-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-seo-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-site-design-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-syndication-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-health-check-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-popups-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-connections-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/traits/trait-wizards-admin-header.php';

// Newspack Wizards and Sections.
include_once NEWSPACK_ABSPATH . 'includes/wizards/newspack/class-newspack-dashboard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/newspack/class-newspack-settings.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/newspack/class-custom-events-section.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/newspack/class-syndication-section.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/newspack/class-seo-section.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/newspack/class-pixels-section.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/newspack/class-recirculation-section.php';

include_once NEWSPACK_ABSPATH . 'includes/wizards/class-setup-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-components-demo.php';

// Listings Wizard.
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-listings-wizard.php';

// Advertising Wizard.
include_once NEWSPACK_ABSPATH . 'includes/wizards/advertising/class-advertising-display-ads.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/advertising/class-advertising-sponsors.php';

// Audience Wizard.
include_once NEWSPACK_ABSPATH . 'includes/wizards/audience/class-audience-wizard.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/audience/class-audience-campaigns.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/audience/class-audience-donations.php';
include_once NEWSPACK_ABSPATH . 'includes/wizards/audience/class-audience-subscriptions.php';

// Network Wizard.
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-network-wizard.php';

// Newsletters Wizard.
include_once NEWSPACK_ABSPATH . 'includes/wizards/class-newsletters-wizard.php';

/* Unified Wizards */
include_once NEWSPACK_ABSPATH . 'includes/class-wizards.php';

include_once NEWSPACK_ABSPATH . 'includes/class-handoff-banner.php';
Expand Down Expand Up @@ -179,6 +200,7 @@ private function includes() {
include_once NEWSPACK_ABSPATH . 'includes/plugins/woocommerce-subscriptions/class-woocommerce-subscriptions-gifting.php';
include_once NEWSPACK_ABSPATH . 'includes/plugins/class-teams-for-memberships.php';
include_once NEWSPACK_ABSPATH . 'includes/plugins/class-newspack-elections.php';
include_once NEWSPACK_ABSPATH . 'includes/plugins/class-yoast.php';

include_once NEWSPACK_ABSPATH . 'includes/class-patches.php';
include_once NEWSPACK_ABSPATH . 'includes/polyfills/class-amp-polyfills.php';
Expand Down Expand Up @@ -236,7 +258,7 @@ public function handle_resets() {
if ( ! current_user_can( 'manage_options' ) ) {
return;
}
$redirect_url = admin_url( 'admin.php?page=newspack' );
$redirect_url = admin_url( 'admin.php?page=newspack-dashboard' );
$newspack_reset = filter_input( INPUT_GET, 'newspack_reset', FILTER_SANITIZE_FULL_SPECIAL_CHARS );
if ( 'starter-content' === $newspack_reset ) {
Starter_Content::remove_starter_content();
Expand All @@ -262,19 +284,6 @@ public function handle_resets() {
}
}

/**
* Remove notifications.
*/
public function remove_notifications() {
$screen = get_current_screen();

$is_newspack_screen = ( 'newspack' === $screen->parent_base ) || ( 'admin_page_newspack-' === substr( $screen->base, 0, 20 ) );
if ( ! $screen || ! $is_newspack_screen ) {
return;
}
remove_all_actions( current_action() );
}

/**
* Activation Hook
*/
Expand Down Expand Up @@ -334,15 +343,15 @@ public function wizard_redirect( $current_screen ) {
$post_type_mapping = [
Emails::POST_TYPE => [
'base' => 'edit',
'url' => esc_url( admin_url( 'admin.php?page=newspack' ) ),
'url' => esc_url( admin_url( 'admin.php?page=newspack-dashboard' ) ),
],
];

// Map custom post types to their wizard screen URLs.
if ( class_exists( '\Newspack_Popups' ) ) {
$post_type_mapping[ \Newspack_Popups::NEWSPACK_POPUPS_CPT ] = [
'base' => 'edit',
'url' => esc_url( admin_url( 'admin.php?page=newspack-popups-wizard' ) ),
'url' => esc_url( admin_url( 'admin.php?page=newspack-audience-campaigns' ) ),
];
}

Expand Down Expand Up @@ -379,6 +388,13 @@ public static function is_debug_mode() {
return defined( 'WP_NEWSPACK_DEBUG' ) && WP_NEWSPACK_DEBUG;
}

/**
* Is the Setup completed?
*/
public static function is_setup_complete() {
return '1' === get_option( NEWSPACK_SETUP_COMPLETE, '0' );
}

/**
* Load the common assets.
*/
Expand All @@ -401,12 +417,14 @@ public static function load_common_assets() {
wp_style_add_data( 'newspack-commons', 'rtl', 'replace' );
wp_enqueue_style( 'newspack-commons' );

\wp_enqueue_style(
'newspack-admin',
self::plugin_url() . '/dist/admin.css',
[],
NEWSPACK_PLUGIN_VERSION
);
if ( is_admin() ) {
\wp_enqueue_style(
'newspack-admin',
self::plugin_url() . '/dist/admin.css',
[],
NEWSPACK_PLUGIN_VERSION
);
}
}
}
Newspack::instance();
6 changes: 3 additions & 3 deletions includes/class-plugin-manager.php
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ public static function get_managed_plugins() {
],
'publish-to-apple-news' => [
'Name' => \esc_html__( 'Publish to Apple News', 'newspack-plugin' ),
'Description' => \esc_html__( 'Export and synchronize posts to Apple format', 'newspack-plugin' ),
'Description' => \esc_html__( 'Export and synchronize posts to Apple format.', 'newspack-plugin' ),
'Author' => \esc_html__( 'Alley Interactive', 'newspack-plugin' ),
'AuthorURI' => \esc_url( 'https://www.alleyinteractive.com' ),
'PluginURI' => \esc_url( 'https://github.com/alleyinteractive/apple-news' ),
Expand Down Expand Up @@ -444,7 +444,7 @@ public static function get_managed_plugin_status( $plugin_slug ) {
/**
* Get the list of plugins which are supported, but not managed.
* These plugins will not be added to the WP Admin plugins screen,
* but installing them will not raise any issues in Health Check.
* but installing them shouldn't be an issue.
*/
private static function get_supported_plugins_slugs() {
return [
Expand Down Expand Up @@ -562,7 +562,7 @@ public static function activate( $plugin ) {
}

if ( \is_plugin_active( $installed_plugins[ $plugin_slug ] ) ) {
return new WP_Error( 'newspack_plugin_already_active', __( 'The plugin is already active.', 'newspack-plugin' ) );
return true;
}

$activated = activate_plugin( $installed_plugins[ $plugin_slug ] );
Expand Down
19 changes: 16 additions & 3 deletions includes/class-recaptcha.php
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,16 @@ public static function api_permissions_check() {
public static function get_settings_config() {
return [
'use_captcha' => false,
'credentials' => [],
'credentials' => [
'v3' => [
'site_key' => '',
'site_secret' => '',
],
'v2_invisible' => [
'site_key' => '',
'site_secret' => '',
],
],
'threshold' => 0.5,
'version' => 'v3',
];
Expand Down Expand Up @@ -226,7 +235,11 @@ public static function get_settings() {
$config = self::get_settings_config();
$settings = [];
foreach ( $config as $key => $default_value ) {
$settings[ $key ] = self::get_setting( $key );
if ( 'credentials' === $key ) {
$settings[ $key ] = wp_parse_args( self::get_setting( $key ), $default_value );
} else {
$settings[ $key ] = self::get_setting( $key );
}
}

// Migrate reCAPTCHA settings from separate site_key/site_secret options to credentials array.
Expand Down Expand Up @@ -328,7 +341,7 @@ public static function update_settings( $settings ) {
/**
* Check whether reCaptcha is enabled and that we have all required settings.
*
* @param string $version If specified, chedk whether the given version of reCaptcha is enabled.
* @param string $version If specified, check whether the given version of reCaptcha is enabled.
*
* @return boolean True if we can use reCaptcha to secure checkout requests.
*/
Expand Down
2 changes: 1 addition & 1 deletion includes/class-salesforce.php
Original file line number Diff line number Diff line change
Expand Up @@ -708,7 +708,7 @@ private static function sync_salesforce( $order ) {
* @return string Redirect URL.
*/
public static function get_redirect_url() {
return get_admin_url( null, 'admin.php?page=newspack-reader-revenue-wizard#/salesforce' );
return get_admin_url( null, 'admin.php?page=newspack-audience' );
}

/**
Expand Down
6 changes: 3 additions & 3 deletions includes/class-starter-content.php
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ public static function get_theme() {
*/
public static function upload_logo() {

$attachment_title = esc_attr__( 'Newspack Placeholder Logo', 'newspack' );
$attachment_title = esc_attr__( 'Newspack Placeholder Logomark', 'newspack' );

$args = [
'posts_per_page' => 1,
Expand All @@ -195,9 +195,9 @@ public static function upload_logo() {
}

$file = wp_upload_bits(
'newspack-logo.png',
'newspack-logomark.png',
null,
file_get_contents( NEWSPACK_ABSPATH . 'includes/raw_assets/images/newspack-logo.png' )
file_get_contents( NEWSPACK_ABSPATH . 'includes/raw_assets/images/newspack-logomark.png' )
);

if ( ! $file || empty( $file['file'] ) ) {
Expand Down
Loading