Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cherry pick commits for WP 6.5 RC 1 #59541

Merged
merged 25 commits into from
Mar 4, 2024
Merged

Commits on Mar 4, 2024

  1. Site Logo: Update capitalization of Use as Site Icon toggle (#59383)

    Co-authored-by: andrewserong <andrewserong@git.wordpress.org>
    Co-authored-by: aaronjorbin <jorbin@git.wordpress.org>
    3 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    2e5c3e3 View commit details
    Browse the repository at this point in the history
  2. Avoid loading theme fonts again and assume they were already resolved…

    … by the font face resolver. (#59421)
    
    * Avoid loading theme fonts again and assume they were already resolved by the font face resolver.
    
    This allows us to remove some related to guess the url of theme fonts.
    
    * fix comment text
    
    Co-authored-by: Peter Wilson <519727+peterwilsoncc@users.noreply.github.com>
    
    ---------
    Co-authored-by: matiasbenedetto <mmaattiiaass@git.wordpress.org>
    Co-authored-by: peterwilsoncc <peterwilsoncc@git.wordpress.org>
    Co-authored-by: youknowriad <youknowriad@git.wordpress.org>
    Co-authored-by: t-hamano <wildworks@git.wordpress.org>
    Co-authored-by: swissspidy <swissspidy@git.wordpress.org>
    7 people committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    30c4f7d View commit details
    Browse the repository at this point in the history
  3. Font library: Update the spacing in the font collection panel heading (

    …#59357)
    
    Co-authored-by: carolinan <poena@git.wordpress.org>
    Co-authored-by: matiasbenedetto <mmaattiiaass@git.wordpress.org>
    3 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    df0c480 View commit details
    Browse the repository at this point in the history
  4. Block Bindings: Don't show protected fields that are bound to blocks (#…

    …59326)
    
    * Check if the meta field is protected
    
    * Check if the meta field is available in the REST API
    
    * Use `get_registered_meta_keys` function
    
    * Return empty string instead of null
    
    * Return null if the bindings config is not correct
    
    * Return `null` when the field is unavailable or protected
    
    * Add tests for protected fields
    
    * Update tests to match current behavior
    
    * Remove unnecessary `show_in_rest` conditional
    
    Co-authored-by: Pascal Birchler <pascalb@google.com>
    
    ---------
    
    Co-authored-by: Pascal Birchler <pascalb@google.com>
    2 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    87a55e2 View commit details
    Browse the repository at this point in the history
  5. Block Hooks: Display toggle for hooked blocks added via filter (#59396)

    Show the Block Hooks toggle for hooked blocks that were added via the `hooked_block_types` filter (rather than at block registration time, i.e. via the `blockHooks` field in `block.json`), by evaluating the anchor block's `ignoredHookedBlocks` metadata attribute. (This attribute is only present if the containing template/part/pattern has user modifications.)
    
    Co-authored-by: ockham <bernhard-reiter@git.wordpress.org>
    Co-authored-by: gziolo <gziolo@git.wordpress.org>
    Co-authored-by: michalczaplinski <czapla@git.wordpress.org>
    Co-authored-by: sirreal <jonsurrell@git.wordpress.org>
    5 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    2bc516a View commit details
    Browse the repository at this point in the history
  6. URLPopover: Fix a problem with the layout of link settings (#58906)

    Co-authored-by: t-hamano <wildworks@git.wordpress.org>
    Co-authored-by: getdave <get_dave@git.wordpress.org>
    3 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    8f8f533 View commit details
    Browse the repository at this point in the history
  7. Block Bindings: do not use useSource hook conditionally (#59403)

    * replace use-binding-attributes with block-binding-support
    
    * minor enhancement
    
    * minor change
    
    * tweak
    
    * do not import use-binding-attributes
    
    * use isItPossibleToBindBlock() helper
    
    * introduce core/entity source handler
    
    * rename folder
    
    * rename source name
    
    * polish post-entity source handler
    
    * make core/post-entity more consistent with core-data
    
    * make entity source hand;ler more generic
    
    * fix entity sour handl;er issues
    
    * remove uneeded useValue () hook (crossfingers)
    
    * minor jsdoc improvement
    
    * clean
    
    * rename with updateValue()
    
    * remove core/entity binding source handler
    
    * move useSource to Connector cmp
    
    * move the whole dryining logic to the Connect component
    
    * improve jsdoc
    
    * rename to blockProps
    
    * minor jsdoc improvements
    
    * use a single effect to update attr and value
    
    * discard useValue. Return value and setValue instead
    
    * check wheter updateValue function is defined
    
    * check prop value is defined when updating attr
    
    * handle `placerholder`
    
    * ensure to put attribute in sync when onmount
    
    * remove // eslint comment
    
    * enable editing for bound with post-meta
    
    * move block bindiung processor to hooks/
    
    * ensure update bound attr once when mounting
    
    * Update packages/block-editor/src/hooks/block-binding-support/index.js
    
    Co-authored-by: Michal <mmczaplinski@gmail.com>
    
    * disable editing block attribute
    
    * move changes to the use-binding-attributes file
    
    * introduce BlockBindingBridge component
    
    * update isItPossibleToBindBlock() import path
    
    * introduce hasPossibleBlockBinding() helper
    
    * use hooks API to extened blocks with bound attts
    
    * fix propagating attr value. jsdoc
    
    * minor changes
    
    * minor code enhancement
    
    * not edit bound prop for now
    
    * jsdoc
    
    * revert using hooks API to extrend block
    
    * jsdoc
    
    * update internal path
    
    * rollback hook utils chnages
    
    * tidy
    
    * wrap Connector instances with a Fragment
    
    * return original Edit instance when no bindings
    
    * check whether useSource is defined
    
    * Use `useSelect` and move it out of the for loop
    
    * check attr value type
    
    * iterare when creating BindingConnector instances
    
    * rename helper functions
    
    * use useSelect to get binding sources
    
    * Update packages/block-editor/src/hooks/use-bindings-attributes.js
    
    Co-authored-by: Michal <mmczaplinski@gmail.com>
    
    * Update packages/block-editor/src/hooks/use-bindings-attributes.js
    
    Co-authored-by: Michal <mmczaplinski@gmail.com>
    
    * pass prev attr value to compare
    
    * improve binding allowed block attributes
    
    * sync derevied updates when updating bound attr
    
    * improve getting attr source
    
    * check properly bindings data
    
    * preserve the RichTextData for block attr
    
    * comment line just for tesrting purposes
    
    * rebasing changes
    
    * rollback change foir testing purposes
    
    * change cmp prop name. improve jsdoc
    
    * simplify checking bindins value
    
    * use attr name as key instance
    
    * store bound attrs values in a local state
    
    * collect and update bound attr in a local state
    
    * Refactor block binding functionality from e55f6bc
    
    * pick block data from straight props
    
    * remove conditional onPropValueChange call
    
    * Update e2e tests
    
    * Use `useLayoutEffect` instead of `useEffect`
    
    ---------
    
    Co-authored-by: Michal <mmczaplinski@gmail.com>
    Co-authored-by: Mario Santos <santosguillamot@gmail.com>
    3 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    e88f867 View commit details
    Browse the repository at this point in the history
  8. Font Library: Hide UI elements when user lacks permissions (#59332)

    Co-authored-by: creativecoder <grantmkin@git.wordpress.org>
    Co-authored-by: matiasbenedetto <mmaattiiaass@git.wordpress.org>
    Co-authored-by: mikachan <mikachan@git.wordpress.org>
    Co-authored-by: peterwilsoncc <peterwilsoncc@git.wordpress.org>
    Co-authored-by: youknowriad <youknowriad@git.wordpress.org>
    Co-authored-by: swissspidy <swissspidy@git.wordpress.org>
    Co-authored-by: getdave <get_dave@git.wordpress.org>
    8 people committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    bd2eeec View commit details
    Browse the repository at this point in the history
  9. Font Library: fix infinite loop when calling wp_get_upload_dir in a f…

    …unction that's used to filter font_dir (#58839)
    
    * fix infinite loop when calling wp_get_upload_dir in a function thats  used to filter font_dir
    
    * remove not needed parameter
    
    * remove filter after use
    
    * removing not needed parameter
    
    * Add a comment explaining the reasons behind the implementation
    
    Co-authored-by: Colin Stewart <79332690+costdev@users.noreply.github.com>
    
    * fix spaces
    
    Co-authored-by: Colin Stewart <79332690+costdev@users.noreply.github.com>
    
    ---------
    
    Co-authored-by: matiasbenedetto <mmaattiiaass@git.wordpress.org>
    Co-authored-by: costdev <costdev@git.wordpress.org>
    Co-authored-by: creativecoder <grantmkin@git.wordpress.org>
    Co-authored-by: youknowriad <youknowriad@git.wordpress.org>
    Co-authored-by: dd32 <dd32@git.wordpress.org>
    Co-authored-by: jazzsequence <jazzs3quence@git.wordpress.org>
    7 people committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    b5f2b33 View commit details
    Browse the repository at this point in the history
  10. Avoid creating font families without font faces. (#59436)

    If we ae trying to create a new font family with font faces but the font family was created in the database but the font faces failed because of the file system permissions, the font family is removed from the database.
    
    ---
    Co-authored-by: matiasbenedetto <mmaattiiaass@git.wordpress.org>
    Co-authored-by: mikachan <mikachan@git.wordpress.org>
    matiasbenedetto authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    6c04972 View commit details
    Browse the repository at this point in the history
  11. Site Editor: Ensure ResizableFrame does not force Cover blocks within…

    … the editor to always display drag handle (#59262)
    
    
    Co-authored-by: andrewserong <andrewserong@git.wordpress.org>
    Co-authored-by: getdave <get_dave@git.wordpress.org>
    3 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    82a4572 View commit details
    Browse the repository at this point in the history
  12. Change default "Connected to a custom field" message in bindings (#59434

    )
    
    * Change default message to read the label or use dynamic data
    
    * Translate "dynamic data" string
    
    * Update message logic to handle translations
    SantosGuillamot authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    b423ff5 View commit details
    Browse the repository at this point in the history
  13. List: copy wrapper when multi selecting items (#59460)

    Co-authored-by: ellatrix <ellatrix@git.wordpress.org>
    Co-authored-by: t-hamano <wildworks@git.wordpress.org>
    Co-authored-by: annezazu <annezazu@git.wordpress.org>
    4 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    13e2c3f View commit details
    Browse the repository at this point in the history
  14. Use block naming for marking blocks as overridable in patterns (#59268)

    Co-authored-by: talldan <talldanwp@git.wordpress.org>
    Co-authored-by: aaronrobertshaw <aaronrobertshaw@git.wordpress.org>
    Co-authored-by: kevin940726 <kevin940726@git.wordpress.org>
    Co-authored-by: michalczaplinski <czapla@git.wordpress.org>
    Co-authored-by: youknowriad <youknowriad@git.wordpress.org>
    Co-authored-by: gziolo <gziolo@git.wordpress.org>
    7 people committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    9332cee View commit details
    Browse the repository at this point in the history
  15. Site Logo: Update url for site icon settings with fallback for WP cor…

    …e versions earlier than 6.5 (#59485)
    
    * Site Logo: Update url for site icon settings with fallback for WP core versions earlier than 6.5
    
    * Move PHP changes to compat.php file
    
    Co-authored-by: andrewserong <andrewserong@git.wordpress.org>
    Co-authored-by: ramonjd <ramonopoly@git.wordpress.org>
    Co-authored-by: tellthemachines <isabel_brison@git.wordpress.org>
    Co-authored-by: t-hamano <wildworks@git.wordpress.org>
    Co-authored-by: Mamaduka <mamaduka@git.wordpress.org>
    Co-authored-by: carolinan <poena@git.wordpress.org>
    Co-authored-by: richtabor <richtabor@git.wordpress.org>
    Co-authored-by: aaronjorbin <jorbin@git.wordpress.org>
    9 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    b60b97c View commit details
    Browse the repository at this point in the history
  16. Rich text: fix typing into empty flex element (#59473)

    Co-authored-by: ellatrix <ellatrix@git.wordpress.org>
    Co-authored-by: fabiankaegy <fabiankaegy@git.wordpress.org>
    Co-authored-by: annezazu <annezazu@git.wordpress.org>
    Co-authored-by: colorful-tones <colorful-tones@git.wordpress.org>
    Co-authored-by: youknowriad <youknowriad@git.wordpress.org>
    Co-authored-by: t-hamano <wildworks@git.wordpress.org>
    Co-authored-by: Mgrmjp <miikkamakela@git.wordpress.org>
    8 people committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    43b12ee View commit details
    Browse the repository at this point in the history
  17. Fix inserting button block when pressing enter in a block with bound …

    …`text` attribute (#59361)
    
    * Add tabindex 0 to all disabled elements in rich text
    
    * Insert block when use enter in disabled rich text
    
    * Take default block into account
    
    * Add e2e tests when pressing enter in bound blocks
    
    * Revert initial implementation
    
    * Use `insertAfterBlock` instead of `insertDefaultBlock`.
    
    * Remove unnecessary `insertDefaultBlock`
    
    * Destructure innerBlocks array in tests
    
    Co-authored-by: Greg Ziółkowski <grzegorz@gziolo.pl>
    
    * Prettify tests
    
    * Remove unnecessary select in tests
    
    * Destructuring blocks in tests
    
    * Revert "Remove unnecessary select in tests"
    
    This reverts commit 63ffff87ca048a218567772710dcc45affcfd2aa.
    
    * Remove unnecessary select in tests
    
    * Adapt tests to latest changes
    
    ---------
    
    Co-authored-by: Greg Ziółkowski <grzegorz@gziolo.pl>
    2 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    77ba590 View commit details
    Browse the repository at this point in the history
  18. Changed installFont to installFonts so that multiple font families ca…

    …n be installed at once (#59451)
    
    * Changed installFont to installFonts so that multiple font families can be installed at once
    
    ---------
    
    Co-authored-by: pbking <pbking@git.wordpress.org>
    Co-authored-by: mikachan <mikachan@git.wordpress.org>
    Co-authored-by: colorful-tones <colorful-tones@git.wordpress.org>
    Co-authored-by: annezazu <annezazu@git.wordpress.org>
    Co-authored-by: provenself <provenself@git.wordpress.org>
    Co-authored-by: matiasbenedetto <mmaattiiaass@git.wordpress.org>
    Co-authored-by: peterwilsoncc <peterwilsoncc@git.wordpress.org>
    8 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    122d14c View commit details
    Browse the repository at this point in the history
  19. Rename data_wp_context_function (#59465)

    Co-authored-by: c4rl0sbr4v0 <cbravobernal@git.wordpress.org>
    Co-authored-by: DAreRodz <darerodz@git.wordpress.org>
    Co-authored-by: swissspidy <swissspidy@git.wordpress.org>
    4 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    c3d8a4b View commit details
    Browse the repository at this point in the history
  20. Add visual indicator if a block is connected to block binding source (#…

    …59185)
    
    * Add BlockControlsFirst slot to block controls groups
    
    * Add connection icon to BlockControls toolbar button
    
    * Add block binding toolbar button if block is connected to a source
    
    * Add i18n support for block toolbar button label
    
    * Add BlockBindingsButton component and remove BlockControlsFirst group
    
    * Refactor BlockBindingsButton to check for block connections
    
    * Change the ToolbarButton label
    
    * Update block-bindings-button import to block-bindings-indicator
    
    * Block Bindings: Add connection icon to list view (#59331)
    
    * Add connection icon to list view
    
    * Remove extraneous string
    
    * Move bindings style to useBlockProps
    
    * Remove extraneous comment
    
    * Move bindings selector logic to toolbar
    
    * Rename indicator file
    
    * Move purple stroke style from SVG markup to CSS
    
    * Check if block can be bound before adding styles
    
    * Simplify the SVG icon:
    - get rid of 2 unnecessary `<path>` elements
    - move the stroke styles to CSS
    - add the `evenodd` rule
    
    * Update the CSS namespacing to include the `__`
    
    * Fix issues with block binding indicator color
    
    ---------
    
    Co-authored-by: michalczaplinski <czapla@git.wordpress.org>
    Co-authored-by: artemiomorales <artemiosans@git.wordpress.org>
    Co-authored-by: Mamaduka <mamaduka@git.wordpress.org>
    Co-authored-by: gziolo <gziolo@git.wordpress.org>
    Co-authored-by: SantosGuillamot <santosguillamot@git.wordpress.org>
    Co-authored-by: jasmussen <joen@git.wordpress.org>
    Co-authored-by: SaxonF <saxonafletcher@git.wordpress.org>
    Co-authored-by: afercia <afercia@git.wordpress.org>
    9 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    af7ee16 View commit details
    Browse the repository at this point in the history
  21. #55091 updated the way templates can be replaced, changing some of th…

    …e HTML structure. (#59259)
    
    Updating performance tests to find new elements.
    
    Co-authored-by: ramonjd <ramonopoly@git.wordpress.org>
    Co-authored-by: andrewserong <andrewserong@git.wordpress.org>
    3 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    0f75d06 View commit details
    Browse the repository at this point in the history
  22. Performance tests: make site editor performance test backwards compat…

    …ible (#59266)
    
    * Update Performance tests base branch after #59259
    This commit makes the test backwards compatible until the performance tests base  commit is updated.
    
    * use locator
    
    Co-authored-by: ramonjd <ramonopoly@git.wordpress.org>
    Co-authored-by: youknowriad <youknowriad@git.wordpress.org>
    Co-authored-by: Mamaduka <mamaduka@git.wordpress.org>
    4 people committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    eef6c06 View commit details
    Browse the repository at this point in the history
  23. DataViews: set color for primary field/a element when focused (#58814)

    Co-authored-by: oandregal <oandregal@git.wordpress.org>
    Co-authored-by: jasmussen <joen@git.wordpress.org>
    Co-authored-by: jameskoster <jameskoster@git.wordpress.org>
    Co-authored-by: t-hamano <wildworks@git.wordpress.org>
    5 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    8334c94 View commit details
    Browse the repository at this point in the history
  24. Data views: Use aria-disabled on disabled checkboxes (#59364)

    Co-authored-by: jameskoster <jameskoster@git.wordpress.org>
    Co-authored-by: Mamaduka <mamaduka@git.wordpress.org>
    Co-authored-by: ramonjd <ramonopoly@git.wordpress.org>
    Co-authored-by: youknowriad <youknowriad@git.wordpress.org>
    Co-authored-by: andrewhayward <andrewhayward@git.wordpress.org>
    Co-authored-by: mirka <0mirka00@git.wordpress.org>
    Co-authored-by: alexstine <alexstine@git.wordpress.org>
    Co-authored-by: scruffian <scruffian@git.wordpress.org>
    9 people committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    89cd003 View commit details
    Browse the repository at this point in the history
  25. InnerBlocks: Support insert before/after the block actions (#59162)

    * Don't call selectors during the render; subscribe to the store instead
    * Get blocks on demand
    * Update 'insertBeforeBlock' and 'insertAfterBlock' actions
    * A handler 'attributesToCopy' definitions
    
    Unlinked contributors: mapk, gwwar.
    
    Co-authored-by: Mamaduka <mamaduka@git.wordpress.org>
    Co-authored-by: noisysocks <noisysocks@git.wordpress.org>
    Co-authored-by: talldan <talldanwp@git.wordpress.org>
    Co-authored-by: ramonjd <ramonopoly@git.wordpress.org>
    Co-authored-by: shaunandrews <shaunandrews@git.wordpress.org>
    Co-authored-by: richtabor <richtabor@git.wordpress.org>
    7 people authored and youknowriad committed Mar 4, 2024
    Configuration menu
    Copy the full SHA
    ebdf83d View commit details
    Browse the repository at this point in the history