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

EZP-32179: Add footer to platform when user is logged in #1695

Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions src/bundle/Resources/public/img/ibexa-wordmark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
50 changes: 50 additions & 0 deletions src/bundle/Resources/public/scss/_footer.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
.ez-has-full-width-footer {
padding-bottom: calculateRem(65px);
}

.ez-footer {
position: absolute;
bottom: 0;
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
height: calculateRem(50px);
margin-top: calculateRem(24px);
padding: 0 calculateRem(24px);
background-color: $ibexa-white;
font-size: calculateRem(14px);
color: $ibexa-color-font-pale;

&__brand-img {
margin-right: calculateRem(16px);
}

&__link {
display: inline-block;
margin-left: calculateRem(24px);
font-size: calculateRem(14px);
color: $ibexa-color-font-pale;
}
}

.ez-bookmark-list-view,
.ez-drafts-list-view {
.ez-main-row {
.ez-content-container {
.ez-footer {
margin: auto 0 0;
}
}
}
}

.ez-main-row {
.ez-content-container {
.ez-footer {
position: relative;
width: auto;
margin: auto calculateRem(15px) 0;
}
}
}
7 changes: 4 additions & 3 deletions src/bundle/Resources/public/scss/_general.scss
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
html {
height: 100%;
min-height: 100vh;
width: 100%;
font-size: $base-font-size;
}

body {
height: 100%;
position: relative;
min-height: 100vh;
}

a {
Expand Down Expand Up @@ -80,7 +81,7 @@ img {

.ez-login-view {
.ez-main-container {
height: 100%;
height: 100vh;
}
}

Expand Down
2 changes: 2 additions & 0 deletions src/bundle/Resources/public/scss/_main-row.scss
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
}

.ez-content-container {
display: flex;
flex-direction: column;
flex: 1 1 auto;
}
}
1 change: 1 addition & 0 deletions src/bundle/Resources/public/scss/ezplatform.scss
Original file line number Diff line number Diff line change
Expand Up @@ -85,3 +85,4 @@
@import 'trash-search-form';
@import 'inputs';
@import 'links';
@import 'footer';
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.m-sub-items {
margin-top: calculateRem(24px);
margin-bottom: calculateRem(24px);
padding: calculateRem(16px);
background: $ibexa-white;
border-radius: $ibexa-border-radius;
Expand Down
20 changes: 20 additions & 0 deletions src/bundle/Resources/translations/messages.en.xliff
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,26 @@
<target state="new"><![CDATA[Your password has been changed. You can <a href="%login%">log in</a> to eZ Platform.]]></target>
<note>key: ezplatform.reset_user_password.success</note>
</trans-unit>
<trans-unit id="b469507c15ca085ba9753f60ab835f68cda9c725" resname="footer.copyright">
<source><![CDATA[Copyright &copy; %year% Ibexa. All right reserved]]></source>
<target state="new"><![CDATA[Copyright &copy; %year% Ibexa. All right reserved]]></target>
<note>key: footer.copyright</note>
</trans-unit>
<trans-unit id="9108451fc15edd434efe02a84ea849c334073272" resname="footer.ibexa_documentation">
<source>Documentation</source>
<target state="new">Documentation</target>
<note>key: footer.ibexa_documentation</note>
</trans-unit>
<trans-unit id="98ec0f718367b011625843a7ebdd12e8185c53ce" resname="footer.ibexa_dxp">
<source>Ibexa DXP</source>
<target state="new">Ibexa DXP</target>
<note>key: footer.ibexa_dxp</note>
</trans-unit>
<trans-unit id="d62f840248f2507f4299133fe259bc4c091f31a8" resname="footer.ibexa_support">
<source>Support</source>
<target state="new">Support</target>
<note>key: footer.ibexa_support</note>
</trans-unit>
<trans-unit id="5cf420af18fd4a8d856fd30bc13aea5039369f9b" resname="form.cancel">
<source>Cancel</source>
<target state="new">Cancel</target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@
} %}
{% endif %}
</section>
{% include '@ezdesign/ui/footer.html.twig' %}
</div>

{{ form_start(form_edit, {
Expand All @@ -117,6 +118,8 @@
</div>
{% endblock %}

{% block footer %}{% endblock %}

{% block react_modules %}
{{ encore_entry_script_tags('ezplatform-admin-ui-content-tree-js', null, 'ezplatform') }}
{% endblock %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
</ul>
{% endblock %}

{% block body_class %}ez-user-settings-list-view{% endblock %}
{% block body_class %}ez-user-settings-list-view ez-has-full-width-footer{% endblock %}

{% block content %}
<section class="container tab-content">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,19 +128,23 @@
} %}
{% endif %}
</div>

{{ form_widget(form_remove.remove, {
'attr': {
'hidden': true
}
}) }}
{{ form_end(form_remove) }}
</div>
{% include '@ezdesign/ui/footer.html.twig' %}
</div>
</div>

{% include '@ezdesign/content/modal/version_conflict.html.twig' %}
{% endblock %}

{% block footer %}{% endblock %}

{% block react_modules %}
{{ encore_entry_script_tags('ezplatform-admin-ui-content-tree-js', null, 'ezplatform') }}
{% endblock %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,8 @@
</div>
{% endblock %}

{% block footer %}{% endblock %}

{% block javascripts %}
{% include '@ezdesign/content/edit/javascripts.html.twig' %}
{% endblock %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,84 +28,86 @@
{{ parent() }}
{% endblock left_sidebar %}

<div class="px-0 pb-4 ez-content-container">
<div class="ez-header">
<div class="container">
{% set items = [] %}
{% for path_location in path_locations %}
{% if not loop.last %}
{% set items = items|merge([{
'value': ez_content_name(path_location.contentInfo),
'url': path('_ez_content_view', {
'contentId': path_location.contentId,
'locationId': path_location.id
})
}]) %}
{% endif %}
{% endfor %}

{% set items = items|merge([{ 'value': ez_content_name(content) }]) %}

{% include '@ezdesign/ui/breadcrumbs.html.twig' with { items: items } %}

{% include '@ezdesign/ui/page_title.html.twig' with {
title: ez_content_name(content),
icon_name: content_type.identifier,
content_type_name: content_type.name
} %}

{% if location.hidden or location.invisible %}
<div class="pb-4">
<div class="ez-alert ez-alert--info">
<svg class="ez-icon ez-icon--small-medium">
<use xlink:href="{{ ez_icon_path('hide') }}"></use>
</svg>
{{ 'content.hidden.message'|trans()|desc('This Content item or its Location is hidden.') }}
</div>
</div>
<div class="px-0 ez-content-container">
<div class="ez-header">
<div class="container">
{% set items = [] %}
{% for path_location in path_locations %}
{% if not loop.last %}
{% set items = items|merge([{
'value': ez_content_name(path_location.contentInfo),
'url': path('_ez_content_view', {
'contentId': path_location.contentId,
'locationId': path_location.id
})
}]) %}
{% endif %}
{{ ez_render_component_group(
'location-view-content-alerts',
{
'versionInfo': content.versionInfo,
'location': location,
}
) }}
</div>
</div>
<div class="panel panel-primary">
<div class="panel-body">
{{ ez_render_component_group('location-view-tab-groups', {
'content': content,
'location': location,
'contentType': content_type,
'draft_pagination_params': draft_pagination_params,
'reverse_relation_pagination_params': reverse_relation_pagination_params,
'custom_urls_pagination_params': custom_urls_pagination_params,
'system_urls_pagination_params': system_urls_pagination_params,
'roles_pagination_params': roles_pagination_params,
'policies_pagination_params': policies_pagination_params,
'is_location_visible': is_location_visible,
}) }}

{% if content_type.isContainer %}
{{ form_start(form_subitems_content_edit, { 'action': path('ezplatform.content.edit'), 'attr': { 'hidden': 'hidden' }}) }}
{{ form_end(form_subitems_content_edit) }}
<div class="container">
{% set udwConfigSingle = ez_udw_config('single_container', {}) %}
<div class="ez-sil"
data-location="{{ location.id }}"
data-mfu-create-permissions-config="{{ subitems_module.content_create_permissions_for_mfu|json_encode() }}"
data-items="{{ subitems_module.items }}"
data-content-types="{{ subitems_module.content_type_info_list }}"
data-udw-config-bulk-move-items="{{ udwConfigSingle }}"
data-udw-config-bulk-add-location="{{ udwConfigSingle }}"
></div>
{% include '@ezdesign/content/modal/location_bulk_action_failed.html.twig' only %}
{% endfor %}

{% set items = items|merge([{ 'value': ez_content_name(content) }]) %}

{% include '@ezdesign/ui/breadcrumbs.html.twig' with { items: items } %}

{% include '@ezdesign/ui/page_title.html.twig' with {
title: ez_content_name(content),
icon_name: content_type.identifier,
content_type_name: content_type.name
} %}

{% if location.hidden or location.invisible %}
<div class="pb-4">
<div class="ez-alert ez-alert--info">
<svg class="ez-icon ez-icon--small-medium">
<use xlink:href="{{ ez_icon_path('hide') }}"></use>
</svg>
{{ 'content.hidden.message'|trans()|desc('This Content item or its Location is hidden.') }}
</div>
</div>
{% endif %}
{% endif %}
{{ ez_render_component_group(
'location-view-content-alerts',
{
'versionInfo': content.versionInfo,
'location': location,
}
) }}
</div>
</div>
<div class="panel panel-primary">
<div class="panel-body">
{{ ez_render_component_group('location-view-tab-groups', {
'content': content,
'location': location,
'contentType': content_type,
'draft_pagination_params': draft_pagination_params,
'reverse_relation_pagination_params': reverse_relation_pagination_params,
'custom_urls_pagination_params': custom_urls_pagination_params,
'system_urls_pagination_params': system_urls_pagination_params,
'roles_pagination_params': roles_pagination_params,
'policies_pagination_params': policies_pagination_params,
'is_location_visible': is_location_visible,
}) }}

{% if content_type.isContainer %}
{{ form_start(form_subitems_content_edit, { 'action': path('ezplatform.content.edit'), 'attr': { 'hidden': 'hidden' }}) }}
{{ form_end(form_subitems_content_edit) }}
<div class="container">
{% set udwConfigSingle = ez_udw_config('single_container', {}) %}
<div class="ez-sil"
data-location="{{ location.id }}"
data-mfu-create-permissions-config="{{ subitems_module.content_create_permissions_for_mfu|json_encode() }}"
data-items="{{ subitems_module.items }}"
data-content-types="{{ subitems_module.content_type_info_list }}"
data-udw-config-bulk-move-items="{{ udwConfigSingle }}"
data-udw-config-bulk-add-location="{{ udwConfigSingle }}"
></div>
{% include '@ezdesign/content/modal/location_bulk_action_failed.html.twig' only %}
</div>
{% endif %}
</div>
</div>

{% include '@ezdesign/ui/footer.html.twig' %}
</div>
<div class="ez-context-menu">
<div class="ez-sticky-container">
Expand Down Expand Up @@ -140,6 +142,8 @@

{% endblock %}

{% block footer %}{% endblock %}

{% block stylesheets %}
{{ encore_entry_link_tags('ezplatform-admin-ui-location-view-css', null, 'ezplatform') }}
{% endblock %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

{% trans_default_domain 'content_type' %}

{% block body_class %}ez-content-type-group-list-view{% endblock %}
{% block body_class %}ez-content-type-group-list-view ez-has-full-width-footer{% endblock %}

{% block breadcrumbs %}
{% include '@ezdesign/ui/breadcrumbs.html.twig' with { items: [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

{% trans_default_domain 'content_type' %}

{% block body_class %}ez-content-type-group-list-view{% endblock %}
{% block body_class %}ez-content-type-group-list-view ez-has-full-width-footer{% endblock %}

{% block breadcrumbs %}
{% include '@ezdesign/ui/breadcrumbs.html.twig' with { items: [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

{% trans_default_domain 'content_type' %}

{% block body_class %}ez-content-type-view{% endblock %}
{% block body_class %}ez-content-type-view ez-has-full-width-footer{% endblock %}

{% set language_code = content_type.mainLanguageCode %}

Expand Down
Loading