Skip to content

Commit

Permalink
Boost: make the setting modules work more consistently (#40224)
Browse files Browse the repository at this point in the history
* Update minification modules, clean up

* changelog

* Remove the InputLabel, not used any more

* Reset the text input value if closed (and opened)

* Add Tracks events to minification modules

* Add events in comments and minify toggle will say "panel"

* Don't show "Hide" to hide minify modules. Others don't

There's an Up chevron for that.

* Remove "closeEditText" from imageCDN quality meta.

* Update CSS to fix concatenate panels

* Update so it works with other modules.

* Allow it to use Chevrons as well as pencil
* External state for enclosing module to track expanded status.
* Set a Tracks event when it's toggled open/closed.

* Use CollapsibleMeta component to display meta information

* Saving forms will close form so add Tracks event there.
* Pass the same event to component to do the same

* Quality settings don't use chevrons for toggle

* Move collapsible meta features/ui/ and adjusted paths to load it

* Use the state to record the toggle Tracks event

* Moving Page Cache to CollapsibleMeta

* Add colouring of the chevron, using that instead of pencil

* Update so it handles modules more consistently.

* Add extraButtons prop for the Clear Cache button.
* Replaced Header for most modules with headerText and summary
* Renamed editText to toggleText
* Added onToggleHandler, a callback called when the section is toggled
  up/down.

* Renamed editText to toggleText, remove useChevron prop

* The Quality module uses the up/down chevrons now

* * Use callback instead of state to update minify exceptions

* Add wrapper div, like Page Cache module.

* Style the minify title text correctly

* Remove a bunch of CSS that's not needed here

* Update for changes to CollapsibleModule

* Use extraButtons and headerText instead of Header
* Add Exceptions title back in.
* Don't use external isExpanded state any more.

* Fix up the logging status messages

* Press Return or Enter to submit the concatenate exceptions

* Minor edits to force a failed rebuild

* Break it up, the optimizer is breaking things

* Use this wait function like PageCache uses

* This started to cause a linter error just now.

* Pass the data-testid to the CollapsibleMeta to display

This should fix the concatenate tests that were failing

* Revert this as I figured out where the selector went

* Describe what modules were changed

* Try to fix tests

* Remove this, not needed as it's on the wrapper now

* Remove this wrapper, the div wraps this code.

* Use the original "Exclude" strings that will be translated.

* Update projects/plugins/boost/app/assets/src/js/features/minify-meta/minify-meta.tsx

Add the Number Pad Enter so it can be used to save exceptions.

Co-authored-by: Peter Petrov <peter.petrov89@gmail.com>

* Update projects/plugins/boost/app/assets/src/js/features/page-cache/meta/meta.tsx

Align closing bracket with opening one.

Co-authored-by: Peter Petrov <peter.petrov89@gmail.com>

* Remove most of this, it's not good

* Remove, it's not used anywhere

* Replace useEffect with a single function, props @dilirity

* Add default values and handle extraButtons better

* Update the CollapsibleMeta Storybook

* The title points at Features/UI now

* Only style the up/down chevrons green

* Trying this because linter is showing an odd error.

Error:   58:46  error  Replace `⏎↹↹↹` with `·`  prettier/prettier

* Add default value for onToggleHandler

* Change this so svg files in icons are coloured green

* This style isn't used any more, remove it

---------

Co-authored-by: Peter Petrov <peter.petrov89@gmail.com>

Committed via a GitHub action: https://github.com/Automattic/jetpack/actions/runs/12179992040

Upstream-Ref: Automattic/jetpack@5c12e7a
  • Loading branch information
donnchawp authored and matticbot committed Dec 5, 2024
1 parent a4abe47 commit c3ae4cb
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 17 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ This is an alpha version! The changes listed here are not final.

### Changed
- Resolved an issue where revoked licenses were incorrectly treated as unattached. This caused users to be redirected to the license activation page after site connection, even when unattached licenses were not valid for activation.
- Settings Page: Give Page Cache, Concatenate JS/CSS and Image CDN - Image Quality modules a more unifed look.
- Updated package dependencies.

## [3.6.1] - 2024-11-28
Expand Down
2 changes: 1 addition & 1 deletion app/assets/dist/jetpack-boost.asset.php
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?php return array('dependencies' => array('react', 'react-dom', 'react-jsx-runtime', 'wp-components', 'wp-compose', 'wp-date', 'wp-element', 'wp-i18n', 'wp-polyfill', 'wp-primitives'), 'version' => 'e5a5ff859bb143a809c1');
<?php return array('dependencies' => array('react', 'react-dom', 'react-jsx-runtime', 'wp-components', 'wp-compose', 'wp-date', 'wp-element', 'wp-i18n', 'wp-polyfill', 'wp-primitives'), 'version' => 'ad0b472f5e61544c95e7');
2 changes: 1 addition & 1 deletion app/assets/dist/jetpack-boost.css

Large diffs are not rendered by default.

28 changes: 14 additions & 14 deletions app/assets/dist/jetpack-boost.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion app/assets/dist/jetpack-boost.rtl.css

Large diffs are not rendered by default.

0 comments on commit c3ae4cb

Please sign in to comment.