From 0e086a257f3010f3d4cc931e0ffd83921d17b9f8 Mon Sep 17 00:00:00 2001 From: Jason Smith Date: Wed, 14 Aug 2024 15:03:00 +1000 Subject: [PATCH] refactor(@dpc-sdp/ripple-ui-core): :recycle: rework breadcrumbs for 4+ terms --- .../components/breadcrumbs/RplBreadcrumbs.css | 10 ++- .../components/breadcrumbs/RplBreadcrumbs.vue | 70 ++++++++++++++++--- 2 files changed, 67 insertions(+), 13 deletions(-) diff --git a/packages/ripple-ui-core/src/components/breadcrumbs/RplBreadcrumbs.css b/packages/ripple-ui-core/src/components/breadcrumbs/RplBreadcrumbs.css index fb376e9268..84e9b4e6c9 100644 --- a/packages/ripple-ui-core/src/components/breadcrumbs/RplBreadcrumbs.css +++ b/packages/ripple-ui-core/src/components/breadcrumbs/RplBreadcrumbs.css @@ -10,9 +10,9 @@ display: inline-block; margin-left: var(--local-horizontal-offset); padding-top: calc(var(--rpl-sp-3) - var(--rpl-border-1)); - padding-right: calc(var(--rpl-sp-5) - var(--rpl-border-1)); + padding-right: calc(var(--rpl-sp-4) - var(--rpl-border-1)); padding-bottom: calc(var(--rpl-sp-3) - var(--rpl-border-1)); - padding-left: calc(var(--rpl-sp-5) - var(--rpl-border-1)); + padding-left: calc(var(--rpl-sp-4) - var(--rpl-border-1)); max-width: calc(100% - var(--local-horizontal-offset) * 2); overflow: hidden; text-overflow: ellipsis; @@ -21,6 +21,8 @@ @media (--rpl-bp-m) { --local-horizontal-offset: var(--rpl-sp-4); + padding-right: calc(var(--rpl-sp-5) - var(--rpl-border-1)); + padding-left: calc(var(--rpl-sp-5) - var(--rpl-border-1)); height: auto; overflow: visible; white-space: normal; @@ -84,6 +86,8 @@ &--beside-exit { --local-width-spacer: 124px; - max-width: calc(100% - var(--local-horizontal-offset) * 3 - var(--local-width-spacer)); + max-width: calc( + 100% - var(--local-horizontal-offset) * 3 - var(--local-width-spacer) + ); } } diff --git a/packages/ripple-ui-core/src/components/breadcrumbs/RplBreadcrumbs.vue b/packages/ripple-ui-core/src/components/breadcrumbs/RplBreadcrumbs.vue index c226cbcb0f..a1da641512 100644 --- a/packages/ripple-ui-core/src/components/breadcrumbs/RplBreadcrumbs.vue +++ b/packages/ripple-ui-core/src/components/breadcrumbs/RplBreadcrumbs.vue @@ -1,4 +1,5 @@ -