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

DS-893: Long strings in notifications causes some minor layout issues #2582

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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
@@ -0,0 +1,73 @@
{% set icon_announce %}
{% include '@bolt-elements-icon/icon.twig' with {
name: 'pega-announce',
size: 'medium',
} only %}
{% endset %}
{% set header_actions %}
{% include '@bolt-components-notifications/notifications-header-action.twig' with {
icon: icon_check_circle,
label: 'Mark all as read',
attributes: {
type: 'button',
},
} only %}
{% include '@bolt-components-notifications/notifications-header-action.twig' with {
icon: icon_pega_setting,
label: 'Notification settings',
attributes: {
href: '#!',
},
} only %}
{% endset %}
{% set content %}
{% set list_content %}
{% include '@bolt-components-notifications/notifications-list-heading-divider.twig' with {
content: 'Latest',
} only %}
{% include '@bolt-components-notifications/notifications-list-item.twig' with {
signifier: icon_announce,
site_name: 'Community',
timestamp: '5 min ago',
message: {
content: 'This a test how it will behave when we have a very long stringstringstringstringstringstringstringstringstringstring without spaces and for example the URL like this one: <em>http://www.this-is/a/very-long/pega-link/WithoutAnySpacesItsForTestingTheBehaviourOfWrappingVeryLongStrings.com</em>.',
attributes: {
href: '#!',
},
},
} only %}
{% include '@bolt-components-notifications/notifications-list-item.twig' with {
signifier: icon_announce,
site_name: 'Collaboration Center',
timestamp: '10 min ago',
message: {
content: 'This is a <em>read notification</em>.',
attributes: {
href: '#!',
},
},
read: true,
} only %}
{% endset %}

{% include '@bolt-components-notifications/notifications-list.twig' with {
content: list_content,
} only %}
{% endset %}
{% set footer_content %}
{% include '@bolt-elements-text-link/text-link.twig' with {
content: 'View all notifications',
reversed_underline: true,
expand_click_target: true,
attributes: {
href: '#!',
}
} only %}
{% endset %}

{% include '@bolt-components-notifications/notifications.twig' with {
content: content,
footer: {
content: footer_content,
},
} only %}
Expand Up @@ -98,6 +98,7 @@
justify-content: space-between;
gap: var(--bolt-spacing-x-xsmall);
row-gap: var(--bolt-spacing-y-xsmall);
word-break: break-word;

> * {
font-weight: inherit;
Expand Down