Skip to content

Commit 3384b46

Browse files
Merge branch 'develop' into feature/3526953-ckeditor-figure
2 parents b092c50 + aa33803 commit 3384b46

File tree

41 files changed

+566
-65
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+566
-65
lines changed

composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
"php": ">=8.2",
77
"composer/installers": "^2.1",
88
"cweagans/composer-patches": "^1.7",
9+
"drupal/admin_toolbar": "^3.6",
910
"drupal/components": "^3.1",
1011
"drupal/core-composer-scaffold": "^11",
1112
"drupal/core-project-message": "^11",

composer.lock

Lines changed: 90 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"dependencies": {
3-
"@civictheme/uikit": "github:civictheme/uikit#057a2d3e24a0fd7918e00db8bfed326e7f5f00b9"
3+
"@civictheme/uikit": "github:civictheme/uikit#fd4cbae4cf41ed780011c7e4f2366a3685561071"
44
},
55
"scripts": {
66
"uikit-change": "node scripts/civictheme-uikit-version-manager/index.mjs"

scripts/civictheme-uikit-version-manager/package-lock.json

Lines changed: 4 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

scripts/custom/provision-30-enable-modules.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ if [ "${DRUPAL_PROFILE:-}" = "govcms" ]; then
2121
else
2222
echo " > Enable Admin module."
2323
drush pm-enable civictheme_admin
24+
drush pm-enable admin_toolbar admin_toolbar_search
2425
fi
2526

2627
echo " > Enable development module."
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
@p0 @civictheme @civictheme_message
2+
Feature: Message fields
3+
4+
@api
5+
Scenario: Fields appear as expected
6+
Given I am logged in as a user with the "Site Administrator" role
7+
When I visit "node/add/civictheme_page"
8+
And I fill in "Title" with "[TEST] Page fields"
9+
When I press "Add Message"
10+
11+
Then should see an "[name='field_c_n_components[0][subform][field_c_p_title][0][value]']" element
12+
And should not see an "[name='field_c_n_components[0][subform][field_c_p_title][0][value]'].required" element
13+
And should not see an "[name='field_c_n_components[0][subform][field_c_p_title][0][value]'][disabled]" element
14+
15+
And should see an "[name='field_c_n_components[0][subform][field_c_p_content][0][value]']" element
16+
And should not see an "[name='field_c_n_components[0][subform][field_c_p_content][0][value]'].required" element
17+
And should not see an "[name='field_c_n_components[0][subform][field_c_p_content][0][value]'][disabled]" element
18+
19+
And should see an "[name='field_c_n_components[0][subform][field_c_p_message_type]']" element
20+
And should see an "[name='field_c_n_components[0][subform][field_c_p_message_type]'].required" element
21+
And should not see an "[name='field_c_n_components[0][subform][field_c_p_message_type]'][disabled]" element
22+
23+
And should see an "[name='field_c_n_components[0][subform][field_c_p_theme]']" element
24+
25+
And should see an "[name='field_c_n_components[0][subform][field_c_p_background][value]']" element
26+
27+
And should see an "[name='field_c_n_components[0][subform][field_c_p_vertical_spacing]']" element
28+
And should see an "[name='field_c_n_components[0][subform][field_c_p_vertical_spacing]'].required" element
29+
And should not see an "[name='field_c_n_components[0][subform][field_c_p_vertical_spacing]'][disabled]" element
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
@p1 @civictheme @civictheme_message
2+
Feature: Message render
3+
4+
Background:
5+
Given "civictheme_page" content:
6+
| title | status |
7+
| [TEST] Page message test | 1 |
8+
9+
@api
10+
Scenario: CivicTheme page content type page can be viewed by anonymous with message light
11+
Given I am an anonymous user
12+
And "field_c_n_components" in "civictheme_page" "node" with "title" of "[TEST] Page message test" has "civictheme_message" paragraph:
13+
| field_c_p_title | [TEST] message title |
14+
| field_c_p_theme | light |
15+
| field_c_p_content:value | Content text |
16+
| field_c_p_content:format | civictheme_rich_text |
17+
| field_c_p_message_type | information |
18+
| field_c_p_background | 1 |
19+
20+
When I visit "civictheme_page" "[TEST] Page message test"
21+
Then I should see an ".ct-message" element
22+
And I should see an ".ct-message.ct-theme-light" element
23+
And I should not see an ".ct-message.ct-theme-dark" element
24+
And I should see an ".ct-message__title" element
25+
And I should see an ".ct-message__content" element
26+
And I should see the text "[TEST] message title"
27+
And I should see the text "Content text"
28+
And save screenshot
29+
30+
@api
31+
Scenario: CivicTheme page content type page can be viewed by anonymous with message dark
32+
Given I am an anonymous user
33+
And "field_c_n_components" in "civictheme_page" "node" with "title" of "[TEST] Page message test" has "civictheme_message" paragraph:
34+
| field_c_p_title | [TEST] message title |
35+
| field_c_p_theme | dark |
36+
| field_c_p_content | Content text |
37+
| field_c_p_message_type | warning |
38+
| field_c_p_background | 0 |
39+
40+
When I visit "civictheme_page" "[TEST] Page message test"
41+
Then I should see an ".ct-message" element
42+
And I should see an ".ct-message.ct-theme-dark" element
43+
And I should not see an ".ct-message.ct-theme-light" element
44+
And I should see an ".ct-message__title" element
45+
And I should see an ".ct-message__content" element
46+
And I should see the text "[TEST] message title"
47+
And I should see the text "Content text"
48+
And save screenshot

web/themes/contrib/civictheme/civictheme.info.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,7 @@ config_devel:
156156
- core.entity_form_display.paragraph.civictheme_iframe.default
157157
- core.entity_form_display.paragraph.civictheme_manual_list.default
158158
- core.entity_form_display.paragraph.civictheme_map.default
159+
- core.entity_form_display.paragraph.civictheme_message.default
159160
- core.entity_form_display.paragraph.civictheme_navigation_card.default
160161
- core.entity_form_display.paragraph.civictheme_navigation_card_ref.default
161162
- core.entity_form_display.paragraph.civictheme_next_step.default
@@ -217,6 +218,7 @@ config_devel:
217218
- core.entity_view_display.paragraph.civictheme_iframe.default
218219
- core.entity_view_display.paragraph.civictheme_manual_list.default
219220
- core.entity_view_display.paragraph.civictheme_map.default
221+
- core.entity_view_display.paragraph.civictheme_message.default
220222
- core.entity_view_display.paragraph.civictheme_navigation_card.default
221223
- core.entity_view_display.paragraph.civictheme_navigation_card_ref.default
222224
- core.entity_view_display.paragraph.civictheme_next_step.default
@@ -394,6 +396,12 @@ config_devel:
394396
- field.field.paragraph.civictheme_map.field_c_p_theme
395397
- field.field.paragraph.civictheme_map.field_c_p_vertical_spacing
396398
- field.field.paragraph.civictheme_map.field_c_p_view_link
399+
- field.field.paragraph.civictheme_message.field_c_p_background
400+
- field.field.paragraph.civictheme_message.field_c_p_content
401+
- field.field.paragraph.civictheme_message.field_c_p_message_type
402+
- field.field.paragraph.civictheme_message.field_c_p_theme
403+
- field.field.paragraph.civictheme_message.field_c_p_title
404+
- field.field.paragraph.civictheme_message.field_c_p_vertical_spacing
397405
- field.field.paragraph.civictheme_navigation_card.field_c_p_image
398406
- field.field.paragraph.civictheme_navigation_card.field_c_p_link
399407
- field.field.paragraph.civictheme_navigation_card.field_c_p_show_image_as_icon
@@ -552,6 +560,7 @@ config_devel:
552560
- field.storage.paragraph.field_c_p_list_topics
553561
- field.storage.paragraph.field_c_p_list_type
554562
- field.storage.paragraph.field_c_p_location
563+
- field.storage.paragraph.field_c_p_message_type
555564
- field.storage.paragraph.field_c_p_panels
556565
- field.storage.paragraph.field_c_p_reference
557566
- field.storage.paragraph.field_c_p_show_image_as_icon
@@ -597,6 +606,7 @@ config_devel:
597606
- paragraphs.paragraphs_type.civictheme_iframe
598607
- paragraphs.paragraphs_type.civictheme_manual_list
599608
- paragraphs.paragraphs_type.civictheme_map
609+
- paragraphs.paragraphs_type.civictheme_message
600610
- paragraphs.paragraphs_type.civictheme_navigation_card
601611
- paragraphs.paragraphs_type.civictheme_navigation_card_ref
602612
- paragraphs.paragraphs_type.civictheme_next_step

web/themes/contrib/civictheme/civictheme.theme

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ require_once __DIR__ . '/includes/libraries.inc';
3434
require_once __DIR__ . '/includes/map.inc';
3535
require_once __DIR__ . '/includes/media.inc';
3636
require_once __DIR__ . '/includes/menu.inc';
37+
require_once __DIR__ . '/includes/message.inc';
3738
require_once __DIR__ . '/includes/mobile_navigation.inc';
3839
require_once __DIR__ . '/includes/next_step.inc';
3940
require_once __DIR__ . '/includes/node.inc';

0 commit comments

Comments
 (0)