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

IBX-2232: Header name convention #340

Merged
merged 1 commit into from
Mar 1, 2022
Merged
Show file tree
Hide file tree
Changes from all 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
15 changes: 15 additions & 0 deletions src/bundle/Resources/public/scss/_page-title.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,19 @@
width: calc(100% - #{calculateRem(36px)});
margin-bottom: calculateRem(16px);
}

&__title {
display: flex;
}

.ibexa-tag {
max-height: calculateRem(28px);
margin-left: calculateRem(8px);
padding: calculateRem(2px) calculateRem(12px);

&__content {
font-weight: normal;
font-size: $ibexa-text-font-size-medium;
}
}
}
4 changes: 2 additions & 2 deletions src/bundle/Resources/translations/content_create.en.xliff
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
<note>key: creating</note>
</trans-unit>
<trans-unit id="750bead6705b295c7b7d66c27b2768c1b9329ed5" resname="editing_details">
<source>under %location_name%</source>
<target state="new">under %location_name%</target>
<source>under %location_name% in %language%</source>
<target state="new">under %location_name% in %language%</target>
<note>key: editing_details</note>
</trans-unit>
<trans-unit id="32d50c07b2eacd6fa72742ff1c1f5963c26a251d" resname="new_content_item">
Expand Down
48 changes: 29 additions & 19 deletions src/bundle/Resources/translations/content_type.en.xliff
Original file line number Diff line number Diff line change
Expand Up @@ -381,11 +381,6 @@
<target state="new">Created Content Type group '%name%'.</target>
<note>key: content_type_group.create.success</note>
</trans-unit>
<trans-unit id="59f3d7c7674d76f2854970e9c63a8db856b1229f" resname="content_type_group.creating">
<source>Creating</source>
<target state="new">Creating</target>
<note>key: content_type_group.creating</note>
</trans-unit>
<trans-unit id="eec79e4a9109f28892797768f085eab39eaedc31" resname="content_type_group.delete.submit">
<source>Delete</source>
<target state="new">Delete</target>
Expand All @@ -396,6 +391,16 @@
<target state="new">Deleted Content Type group '%name%'.</target>
<note>key: content_type_group.delete.success</note>
</trans-unit>
<trans-unit id="f9cf70fcb6c6aef73a8a39eb0a9cd4e71c11b5ba" resname="content_type_group.edit.action_name">
<source>Editing Content Type group</source>
<target state="new">Editing Content Type group</target>
<note>key: content_type_group.edit.action_name</note>
</trans-unit>
<trans-unit id="cd6124f27c9a5743763f9a49cfc160d34723d713" resname="content_type_group.new.action_name">
<source>Creating</source>
<target state="new">Creating</target>
<note>key: content_type_group.new.action_name</note>
</trans-unit>
<trans-unit id="4c6dfb0b81f5b9d70fed0dda3840f0677ece9570" resname="content_type_group.update.name">
<source>Name</source>
<target state="new">Name</target>
Expand All @@ -411,16 +416,6 @@
<target state="new">Updated Content Type group '%name%'.</target>
<note>key: content_type_group.update.success</note>
</trans-unit>
<trans-unit id="1bd4c745d76ae79ef7e95baea27281fff04e77f6" resname="content_type_group.view.add.title">
<source>Creating a new Content Type group</source>
<target state="new">Creating a new Content Type group</target>
<note>key: content_type_group.view.add.title</note>
</trans-unit>
<trans-unit id="1b6ebace1ed08d4e8de6a84a5523e19b53dfd443" resname="content_type_group.view.edit.title">
<source>Editing Content Type group '%identifier%'</source>
<target state="new">Editing Content Type group '%identifier%'</target>
<note>key: content_type_group.view.edit.title</note>
</trans-unit>
<trans-unit id="8eb8668549f90436db605805680144f4b87c7fc0" resname="content_type_group.view.list.action.add">
<source>Create</source>
<target state="new">Create</target>
Expand Down Expand Up @@ -451,15 +446,30 @@
<target state="new">Content Type groups</target>
<note>key: content_type_group.view.list.title</note>
</trans-unit>
<trans-unit id="b857ebe01d0a852bd8e10d599e75004fb961f1d5" resname="content_type_group.view.new.title">
<source>New Content Type group</source>
<target state="new">New Content Type group</target>
<note>key: content_type_group.view.new.title</note>
</trans-unit>
<trans-unit id="1769b5258d896d9ccb207c09e04534ce9a01c571" resname="content_type_group.view.view.title">
<source>%identifier%</source>
<target state="new">%identifier%</target>
<note>key: content_type_group.view.view.title</note>
</trans-unit>
<trans-unit id="f34946beab1da2af6535a8e4a88145e9557de0aa" resname="editing">
<source>Editing</source>
<target state="new">Editing</target>
<note>key: editing</note>
<trans-unit id="ad4e9a4e42b99d945f972bab5a2eff694d283793" resname="creating">
<source>Creating</source>
<target state="new">Creating</target>
<note>key: creating</note>
</trans-unit>
<trans-unit id="3e8769270428f8e66f5880d772f45e09d2c88aa0" resname="creating.title">
<source>New Content type</source>
<target state="new">New Content type</target>
<note>key: creating.title</note>
</trans-unit>
<trans-unit id="6b7aac07f7af9bb4762fd3a87ff0a9df02921f7a" resname="editing_content_type">
<source>Editing Content type</source>
<target state="new">Editing Content type</target>
<note>key: editing_content_type</note>
</trans-unit>
<trans-unit id="f99cc628dc4d82c5ee69eae79039a2f449eec064" resname="field_definition.description">
<source>Description</source>
Expand Down
20 changes: 0 additions & 20 deletions src/bundle/Resources/translations/messages.en.xliff
Original file line number Diff line number Diff line change
Expand Up @@ -256,16 +256,6 @@
<target state="new">More</target>
<note>key: content_type_selector.list.show_more</note>
</trans-unit>
<trans-unit id="ad4e9a4e42b99d945f972bab5a2eff694d283793" resname="creating">
<source>Creating Content type</source>
<target state="new">Creating Content type</target>
<note>key: creating</note>
</trans-unit>
<trans-unit id="3e8769270428f8e66f5880d772f45e09d2c88aa0" resname="creating.title">
<source>New Content type</source>
<target state="new">New Content type</target>
<note>key: creating.title</note>
</trans-unit>
<trans-unit id="fe1c876b1a9bcde155f03227bce4ae4fbd54c24f" resname="custom_url_alias_add_form.add">
<source>Create</source>
<target state="new">Create</target>
Expand Down Expand Up @@ -296,16 +286,6 @@
<target state="new">Search...</target>
<note>key: dropdown.search</note>
</trans-unit>
<trans-unit id="f34946beab1da2af6535a8e4a88145e9557de0aa" resname="editing">
<source>Editing</source>
<target state="new">Editing</target>
<note>key: editing</note>
</trans-unit>
<trans-unit id="3103e1aed613987a16236d0f603f22ae48aa417b" resname="editing.title">
<source>Editing Content type %identifier%</source>
<target state="new">Editing Content type %identifier%</target>
<note>key: editing.title</note>
</trans-unit>
<trans-unit id="7cb40cbc703336ab1285e81ebf100b82b05a0e27" resname="error.page.403.actions">
<source><![CDATA[Contact your administrator to request access.<br/>Go back to the <a href="%dashboard%">dashboard</a> or <a href="%search%">search</a> for another item.]]></source>
<target state="new"><![CDATA[Contact your administrator to request access.<br/>Go back to the <a href="%dashboard%">dashboard</a> or <a href="%search%">search</a> for another item.]]></target>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,13 @@

{% include '@ibexadesign/ui/edit_header.html.twig' with {
action_name: 'creating'|trans|desc('Creating'),
content_type_name: content_type.name,
title: 'new_content_item'|trans({'%contentType%': content_type.name})|desc('New %contentType%'),
icon_name: content_type.name,
show_autosave_status: true,
subtitle: 'editing_details'|trans({ '%location_name%': parent_location.contentInfo.name })|desc('under %location_name%'),
subtitle: 'editing_details'|trans({
'%location_name%': parent_location.contentInfo.name,
'%language%': language.name
})|desc('under %location_name% in %language%' ),
context_actions: knp_menu_render(content_create_sidebar_right, {'template': '@ibexadesign/ui/menu/context_menu.html.twig'})
} %}
{% endblock %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,15 @@

{% include '@ibexadesign/ui/edit_header.html.twig' with {
action_name: 'editing'|trans|desc('Editing'),
content_type_name: content_type.name,
title: content.name,
icon_name: 'content-type',
show_autosave_status: true,
description: content_type.description,
subtitle: 'editing_details'|trans({ '%location_name%': parent_location.contentInfo.name, '%language%': language.name })|desc('under %location_name% in %language%'),
subtitle: 'editing_details'|trans({
'%location_name%': parent_location.contentInfo.name,
'%language%': language.name
})|desc('under %location_name% in %language%'),
context_actions: knp_menu_render(content_edit_sidebar_right, { 'template': '@ibexadesign/ui/menu/context_menu.html.twig' })
} %}
{% endblock %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
{% set content_type_group_create_sidebar_right = knp_menu_get('ezplatform_admin_ui.menu.content_type_group_create.sidebar_right') %}

{% include '@ibexadesign/ui/edit_header.html.twig' with {
action_name: 'content_type_group.creating'|trans|desc('Creating'),
action_name: 'content_type_group.new.action_name'|trans|desc('Creating'),
icon_name: 'file',
title: 'content_type_group.view.add.title'|trans|desc('Creating a new Content Type group'),
title: 'content_type_group.view.new.title'|trans|desc('New Content Type group'),
context_actions: knp_menu_render(content_type_group_create_sidebar_right, {'template': '@ibexadesign/ui/menu/context_menu.html.twig'})
} %}
{% endblock %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
{% set content_type_group_edit_sidebar_right = knp_menu_get('ezplatform_admin_ui.menu.content_type_group_edit.sidebar_right', [], {'save_id': form.update.vars.id}) %}

{% include '@ibexadesign/ui/edit_header.html.twig' with {
action_name: 'editing'|trans|desc('Editing'),
action_name: 'content_type_group.edit.action_name'|trans|desc('Editing Content Type group'),
icon_name: 'file',
title: 'content_type_group.view.edit.title'|trans({'%identifier%': content_type_group.identifier})|desc('Editing Content Type group \'%identifier%\''),
title: content_type_group.identifier,
show_autosave_status: false,
context_actions: knp_menu_render(content_type_group_edit_sidebar_right, {'template': '@ibexadesign/ui/menu/context_menu.html.twig'})
} %}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{% extends '@ibexadesign/content_type/edit_base.html.twig' %}

{% trans_default_domain 'content_type' %}

{% set language_code = content_type.mainLanguageCode %}

{% block header %}
Expand All @@ -9,7 +11,7 @@
}) %}

{% include '@ibexadesign/ui/edit_header.html.twig' with {
action_name: 'creating'|trans|desc('Creating Content type'),
action_name: 'creating'|trans|desc('Creating'),
icon_name: 'file',
title: 'creating.title'|trans|desc('New Content type'),
show_autosave_status: false,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{% extends "@ibexadesign/content_type/edit_base.html.twig" %}

{% trans_default_domain 'content_type' %}

{% set language_code = language_code|default(content_type.mainLanguageCode) %}

{% block header %}
Expand All @@ -9,9 +11,9 @@
}) %}

{% include '@ibexadesign/ui/edit_header.html.twig' with {
action_name: 'editing'|trans|desc('Editing'),
action_name: 'editing_content_type'|trans|desc('Editing Content type'),
icon_name: 'file',
title: 'editing.title'|trans({ '%identifier%': content_type.name })|desc('Editing Content type %identifier%'),
title: content_type.name,
show_autosave_status: false,
context_actions: knp_menu_render(content_type_edit_sidebar_right, {'template': '@ibexadesign/ui/menu/context_menu.html.twig'})
} %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
<div class="ibexa-page-title__top">
<h1 class="ibexa-page-title__title">
{{ title }}
{% if tag is defined %}
<div class="ibexa-tag">
<div class="ibexa-tag__content">{{ tag }}</div>
</div>
{% endif %}
</h1>
{% block top_side %}{% endblock %}
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,12 @@

{% block header %}
{% set user_content_edit_menu = knp_menu_get('ezplatform_admin_ui.menu.user_create.sidebar_right', [], {
'parent_group': parent_group,
'parent_group': parent_group,
'content_type': content_type
}) %}

{% include '@ibexadesign/ui/edit_header.html.twig' with {
action_name: 'Create'|trans|desc('Creating'),
content_type_name: content_type.name,
icon_name: content_type.name,
show_autosave_status: false,
title: 'new_content_item'|trans({'%contentType%': content_type.name})|desc('New %contentType%'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
content_type_name: content_type.name,
icon_name: content_type.name,
show_autosave_status: false,
title: content_type.name,
title: "%s %s"|format(user.getFieldValue('first_name'), user.getFieldValue('last_name')),
subtitle: 'editing_details'|trans({ '%location_name%': parent_location.contentInfo.name })|desc('under %location_name%'),
context_actions: knp_menu_render(user_content_edit_menu, {'template': '@ibexadesign/ui/menu/context_menu.html.twig'})
} %}
Expand Down