Skip to content

Commit

Permalink
Merge pull request #12038 from MozillaFoundation/feature-branch/main-…
Browse files Browse the repository at this point in the history
…nav-dropdown

Main navigation dropdown
  • Loading branch information
jhonatan-lopes authored Apr 29, 2024
2 parents a73956d + a695c57 commit 60d5282
Show file tree
Hide file tree
Showing 100 changed files with 5,320 additions and 156 deletions.
2 changes: 1 addition & 1 deletion maintenance/static/css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -8294,7 +8294,7 @@ a.text-gray-dark:focus, a.text-gray-dark:hover {
padding-bottom: calc( + 22px - 6px / 2); } }
@media (min-width: 768px) {
#primary-nav-container .nav-links a {
padding-bottom: calc( 16px + 9px - 6px / 2); } }
padding-bottom: 1rem; } }
#primary-nav-container .nav-links a:focus, #primary-nav-container .nav-links a:active, #primary-nav-container .nav-links a:hover {
text-decoration: none;
border-bottom-color: #cccccc; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -344,9 +344,7 @@ class Migration(migrations.Migration):
help_text='An id attribute of an element on the current page. For example, "#section-1"',
max_length=300,
required=False,
validators=[
networkapi.wagtailpages.pagemodels.customblocks.common.base_link_block.AnchorLinkValidator()
],
validators=[networkapi.wagtailpages.validators.AnchorLinkValidator()],
),
),
("email", wagtail.blocks.EmailBlock(required=False)),
Expand Down Expand Up @@ -1179,7 +1177,7 @@ class Migration(migrations.Migration):
max_length=300,
required=False,
validators=[
networkapi.wagtailpages.pagemodels.customblocks.common.base_link_block.AnchorLinkValidator()
networkapi.wagtailpages.validators.AnchorLinkValidator()
],
),
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -344,9 +344,7 @@ class Migration(migrations.Migration):
help_text='An id attribute of an element on the current page. For example, "#section-1"',
max_length=300,
required=False,
validators=[
networkapi.wagtailpages.pagemodels.customblocks.common.base_link_block.AnchorLinkValidator()
],
validators=[networkapi.wagtailpages.validators.AnchorLinkValidator()],
),
),
("email", wagtail.blocks.EmailBlock(required=False)),
Expand Down Expand Up @@ -1178,7 +1176,7 @@ class Migration(migrations.Migration):
max_length=300,
required=False,
validators=[
networkapi.wagtailpages.pagemodels.customblocks.common.base_link_block.AnchorLinkValidator()
networkapi.wagtailpages.validators.AnchorLinkValidator()
],
),
),
Expand Down
5 changes: 3 additions & 2 deletions network-api/networkapi/donate_banner/tests.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from django.contrib.auth import get_user_model
from django.test import TestCase
from django.urls import reverse
from wagtail.admin.viewsets import viewsets
from wagtail.admin.viewsets import viewsets as wagtail_admin_viewsets
from wagtail.admin.viewsets.chooser import ChooserViewSet
from wagtail.models import Locale
from wagtail.test.utils import WagtailTestUtils
Expand All @@ -17,7 +17,8 @@ def is_donate_banner_chooser_viewset(self, viewset):
def get_chooser_viewset(self):
# Get the last registered ChooserViewSet for the DonateBanner model.
# Note: There can be multiple ChooserViewSets registered for a model.
model_viewsets = [x for x in viewsets.viewsets if self.is_donate_banner_chooser_viewset(x)]
wagtail_admin_viewsets.populate()
model_viewsets = [x for x in wagtail_admin_viewsets.viewsets if self.is_donate_banner_chooser_viewset(x)]
return model_viewsets[-1]

def setUp(self):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -333,9 +333,7 @@ class Migration(migrations.Migration):
help_text='An id attribute of an element on the current page. For example, "#section-1"',
max_length=300,
required=False,
validators=[
networkapi.wagtailpages.pagemodels.customblocks.common.base_link_block.AnchorLinkValidator()
],
validators=[networkapi.wagtailpages.validators.AnchorLinkValidator()],
),
),
("email", wagtail.blocks.EmailBlock(required=False)),
Expand Down Expand Up @@ -952,7 +950,7 @@ class Migration(migrations.Migration):
max_length=300,
required=False,
validators=[
networkapi.wagtailpages.pagemodels.customblocks.common.base_link_block.AnchorLinkValidator()
networkapi.wagtailpages.validators.AnchorLinkValidator()
],
),
),
Expand Down Expand Up @@ -1676,9 +1674,7 @@ class Migration(migrations.Migration):
help_text='An id attribute of an element on the current page. For example, "#section-1"',
max_length=300,
required=False,
validators=[
networkapi.wagtailpages.pagemodels.customblocks.common.base_link_block.AnchorLinkValidator()
],
validators=[networkapi.wagtailpages.validators.AnchorLinkValidator()],
),
),
("email", wagtail.blocks.EmailBlock(required=False)),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -345,9 +345,7 @@ class Migration(migrations.Migration):
help_text='An id attribute of an element on the current page. For example, "#section-1"',
max_length=300,
required=False,
validators=[
networkapi.wagtailpages.pagemodels.customblocks.common.base_link_block.AnchorLinkValidator()
],
validators=[networkapi.wagtailpages.validators.AnchorLinkValidator()],
),
),
("email", wagtail.blocks.EmailBlock(required=False)),
Expand Down Expand Up @@ -973,7 +971,7 @@ class Migration(migrations.Migration):
max_length=300,
required=False,
validators=[
networkapi.wagtailpages.pagemodels.customblocks.common.base_link_block.AnchorLinkValidator()
networkapi.wagtailpages.validators.AnchorLinkValidator()
],
),
),
Expand Down Expand Up @@ -1696,9 +1694,7 @@ class Migration(migrations.Migration):
help_text='An id attribute of an element on the current page. For example, "#section-1"',
max_length=300,
required=False,
validators=[
networkapi.wagtailpages.pagemodels.customblocks.common.base_link_block.AnchorLinkValidator()
],
validators=[networkapi.wagtailpages.validators.AnchorLinkValidator()],
),
),
("email", wagtail.blocks.EmailBlock(required=False)),
Expand Down
Empty file.
5 changes: 5 additions & 0 deletions network-api/networkapi/nav/apps.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
from django.apps import AppConfig


class NavConfig(AppConfig):
name = "networkapi.nav"
Loading

0 comments on commit 60d5282

Please sign in to comment.