Skip to content

Commit 18aa2d9

Browse files
committed
Merge branch 'TMS-1223' into stage
2 parents 1e69e6a + 0a09232 commit 18aa2d9

22 files changed

+121
-115
lines changed

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1-
Severa-ID: 2108
2-
Severa-kuvaus:
1+
Project: Tampereen kaupunki, konsernihallinto / Tietohallintoyksikkö:
2+
Project task:
3+
34
Task: https://hiondigital.atlassian.net/browse/TMS-
5+
Task title:
46

57
<!--- Provide a general summary of your changes in the Title above -->
68

CHANGELOG.MD

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
88
## [Unreleased]
99

1010
- TMS-1062: Increase menu-dropdown button size
11+
- TMS-1223: Fix double quote problem from components bg-color field
12+
13+
## [1.13.0] - 2025-10-01
14+
1115
- TMS-1201: Add iframe-field for video fields
1216
- TMS-1164: Remove color changing for button hover-styles
1317

lib/ACF/AlterCallToActionLayout.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,14 @@ class AlterCallToActionLayout {
1616
* Constructor
1717
*/
1818
public function __construct() {
19-
add_filter(
19+
\add_filter(
2020
'tms/acf/layout/_call_to_action/fields',
2121
[ $this, 'alter_fields' ],
2222
10,
2323
2
2424
);
2525

26-
add_filter(
26+
\add_filter(
2727
'tms/acf/layout/call_to_action/data',
2828
[ $this, 'alter_format' ],
2929
20
@@ -38,7 +38,7 @@ public function __construct() {
3838
*
3939
* @return array
4040
*/
41-
public function alter_fields( array $fields, string $key ) : array {
41+
public function alter_fields( array $fields, string $key ): array {
4242
$strings = [
4343
'round_image' => [
4444
'label' => 'Pyöreä kuva',
@@ -52,14 +52,14 @@ public function alter_fields( array $fields, string $key ) : array {
5252

5353
try {
5454
$round_image_field = ( new Field\TrueFalse( $strings['round_image']['label'] ) )
55-
->set_key( "${key}_round_image" )
55+
->set_key( "{$key}_round_image" )
5656
->set_name( 'round_image' )
5757
->use_ui()
5858
->set_wrapper_width( 50 )
5959
->set_instructions( $strings['round_image']['instructions'] );
6060

6161
$aspect_ratio_field = ( new Field\TrueFalse( $strings['wide_img']['label'] ) )
62-
->set_key( "${key}_wide_img" )
62+
->set_key( "{$key}_wide_img" )
6363
->set_name( 'wide_img' )
6464
->use_ui()
6565
->set_wrapper_width( 33 )
@@ -86,7 +86,7 @@ public function alter_fields( array $fields, string $key ) : array {
8686
*
8787
* @return array
8888
*/
89-
public function alter_format( array $layout ) : array {
89+
public function alter_format( array $layout ): array {
9090

9191
if ( empty( $layout['rows'] ) ) {
9292
return $layout;

lib/ACF/AlterFrontPageGroup.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ class AlterPageFrontPageGroup {
1717
* PageGroup constructor.
1818
*/
1919
public function __construct() {
20-
add_filter( 'tms/acf/field/fg_front_page_components_components/layouts',
20+
\add_filter( 'tms/acf/field/fg_front_page_components_components/layouts',
2121
[ $this, 'replace_base_theme_hero' ],
2222
10,
2323
1

lib/ACF/AlterGridFieldsData.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,24 +14,24 @@ class AlterGridFields {
1414
* Constructor
1515
*/
1616
public function __construct() {
17-
add_filter(
17+
\add_filter(
1818
'tms/block/grid/fields',
1919
[ $this, 'alter_fields' ],
2020
10,
2121
2
2222
);
23-
add_filter(
23+
\add_filter(
2424
'tms/acf/layout/_grid/fields',
2525
[ $this, 'alter_fields' ],
2626
10,
2727
2
2828
);
29-
add_filter(
29+
\add_filter(
3030
'tms/acf/block/grid/data',
3131
[ $this, 'alter_format' ],
3232
20
3333
);
34-
add_filter(
34+
\add_filter(
3535
'tms/acf/layout/grid/data',
3636
[ $this, 'alter_format' ],
3737
20
@@ -45,7 +45,7 @@ public function __construct() {
4545
*
4646
* @return array
4747
*/
48-
public function alter_fields( array $fields ) : array {
48+
public function alter_fields( array $fields ): array {
4949
try {
5050
$fields['repeater']->sub_fields['grid_item_custom']->sub_fields['description']->set_maxlength( 300 );
5151
$fields['repeater']->sub_fields['grid_item_custom']->sub_fields['description']->set_new_lines( 'br' );
@@ -64,7 +64,7 @@ public function alter_fields( array $fields ) : array {
6464
*
6565
* @return array
6666
*/
67-
public function alter_format( array $layout ) : array {
67+
public function alter_format( array $layout ): array {
6868
foreach ( $layout['repeater'] as $key => $item ) {
6969
$layout['repeater'][ $key ]['classes'] = str_replace( [ 'has-colors-primary'], [ 'has-colors-secondary' ], $layout['repeater'][ $key ]['classes'] ); // phpcs:ignore
7070
$layout['repeater'][ $key ]['button'] = 'is-primary has-text-weight-semibold';

lib/ACF/AlterImageBannerFields.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ class AlterImageBannerFields {
1414
* Constructor
1515
*/
1616
public function __construct() {
17-
add_filter(
17+
\add_filter(
1818
'tms/acf/layout/_image_banner/fields',
1919
[ $this, 'alter_fields' ],
2020
10,
@@ -29,7 +29,7 @@ public function __construct() {
2929
*
3030
* @return array
3131
*/
32-
public function alter_fields( array $fields ) : array {
32+
public function alter_fields( array $fields ): array {
3333
try {
3434
$fields['align']
3535
->set_choices( [

lib/ACF/AlterKeyFiguresFields.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ class AlterKeyFiguresFields {
1111
* Constructor
1212
*/
1313
public function __construct() {
14-
add_filter(
14+
\add_filter(
1515
'tms/block/key_figures/fields',
1616
[ $this, 'alter_fields' ],
1717
10,
@@ -26,7 +26,7 @@ public function __construct() {
2626
*
2727
* @return array
2828
*/
29-
public function alter_fields( array $fields ) : array {
29+
public function alter_fields( array $fields ): array {
3030
try {
3131
$fields['rows']->sub_fields['numbers']->sub_fields['background_color']
3232
->set_choices( [

lib/ACF/AlterQuoteData.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ class AlterQuoteData {
1717
* Constructor
1818
*/
1919
public function __construct() {
20-
add_filter(
20+
\add_filter(
2121
'tms/acf/block/quote/data',
2222
[ $this, 'alter_data' ],
2323
20,
@@ -32,7 +32,7 @@ public function __construct() {
3232
*
3333
* @return array
3434
*/
35-
public function alter_data( array $data ) : array {
35+
public function alter_data( array $data ): array {
3636
try {
3737
$data['classes']['quote'] = [
3838
is_singular( [

lib/ACF/AlterSettingsGroup.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@ class AlterSettingsGroup {
1616
* Constructor
1717
*/
1818
public function __construct() {
19-
add_filter(
19+
\add_filter(
2020
'tms/acf/group/fg_site_settings/fields',
2121
[ $this, 'remove_theme_color_setting' ],
2222
100
2323
);
2424

25-
add_filter(
25+
\add_filter(
2626
'tms/acf/group/fg_site_settings/fields',
2727
Closure::fromCallable( [ $this, 'register_theme_tabs' ] ),
2828
10,
@@ -55,7 +55,7 @@ public function remove_theme_color_setting( $fields ) {
5555
*
5656
* @return array
5757
*/
58-
protected function register_theme_tabs( array $fields, string $key ) : array {
58+
protected function register_theme_tabs( array $fields, string $key ): array {
5959
try {
6060
$fields[] = new Fields\Settings\ArtworkSettingsTab( '', $key );
6161
$fields[] = new Fields\Settings\ArtistSettingsTab( '', $key );

lib/ACF/AlterSubpagesFields.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,14 @@ class AlterSubpagesFields {
1414
* Constructor
1515
*/
1616
public function __construct() {
17-
add_filter(
17+
\add_filter(
1818
'tms/block/subpages/fields',
1919
[ $this, 'alter_fields' ],
2020
10,
2121
2
2222
);
2323

24-
add_filter(
24+
\add_filter(
2525
'tms/acf/layout/_subpages/fields',
2626
[ $this, 'alter_fields' ],
2727
10,
@@ -36,7 +36,7 @@ public function __construct() {
3636
*
3737
* @return array
3838
*/
39-
public function alter_fields( array $fields ) : array {
39+
public function alter_fields( array $fields ): array {
4040
try {
4141
$fields['background_color']
4242
->set_choices( [

0 commit comments

Comments
 (0)