[Experimental] Fix: add an unique id to each list item to prevent diffing issue (#45304)
* fix: add an unique id to each list item to prevent diffing issue * chore: changelog
This commit is contained in:
parent
e2ed2a9fdb
commit
2cfd120f15
|
@ -0,0 +1,5 @@
|
||||||
|
Significance: patch
|
||||||
|
Type: fix
|
||||||
|
Comment: [Experimental] Fix: add an unique id to each list item to prevent diffing issue
|
||||||
|
|
||||||
|
|
|
@ -43,7 +43,7 @@ class CheckboxList {
|
||||||
// translators: %s: checkbox label.
|
// translators: %s: checkbox label.
|
||||||
$i18n_label = sprintf( __( 'Checkbox: %s', 'woocommerce' ), $item['aria_label'] ?? '' );
|
$i18n_label = sprintf( __( 'Checkbox: %s', 'woocommerce' ), $item['aria_label'] ?? '' );
|
||||||
?>
|
?>
|
||||||
<li>
|
<li data-wc-key="<?php echo esc_attr( $item['id'] ); ?>">
|
||||||
<div class="wc-block-components-checkbox">
|
<div class="wc-block-components-checkbox">
|
||||||
<label for="<?php echo esc_attr( $item['id'] ); ?>">
|
<label for="<?php echo esc_attr( $item['id'] ); ?>">
|
||||||
<input
|
<input
|
||||||
|
|
Loading…
Reference in New Issue