From 78383ef568a7b8ce923716c5f4e18bdb1eb70437 Mon Sep 17 00:00:00 2001 From: falsulaiman <54753177+FahadAlsulaiman@users.noreply.github.com> Date: Thu, 6 Feb 2025 20:23:13 +0300 Subject: [PATCH] Update _nav.scss (#2133) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Update _nav.scss ### Issue: Dash (`-`) causing W3C validator error and CSS issues **Problem**: The use of a dash (`-`) in certain areas is triggering errors in the W3C validator and affecting the proper functioning of CSS. 1. **HTML Issue**: The dash might be incorrectly placed in attribute names or element IDs, causing validation errors. - Example: `data-name` is fine, but ensure it's used correctly and within the valid context. 2. **CSS Issue**: If the dash is used improperly in class or ID names, it can cause selector issues in CSS. - Example: `.my-class-name` is correct, but make sure that the class is correctly applied to the element and styled properly in CSS. **Proposed Fix**: - Ensure that any attribute or class names are formatted correctly. For example, `data-name` is valid, but check for any spelling mistakes or misplaced dashes. - In CSS, ensure proper selector syntax like: ```css .my-class-name { /* Styles here */ } * Fix margin calculation for nav links in _nav.scss * Create red-pens-punch.md --------- Co-authored-by: codecalm Co-authored-by: Paweł Kuna <1282324+codecalm@users.noreply.github.com> --- .changeset/red-pens-punch.md | 5 +++++ core/scss/ui/_nav.scss | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 .changeset/red-pens-punch.md diff --git a/.changeset/red-pens-punch.md b/.changeset/red-pens-punch.md new file mode 100644 index 000000000..47aa4db78 --- /dev/null +++ b/.changeset/red-pens-punch.md @@ -0,0 +1,5 @@ +--- +"@tabler/core": patch +--- + +Fix negative margins in `.navbar-bordered` variant diff --git a/core/scss/ui/_nav.scss b/core/scss/ui/_nav.scss index 98120fcb0..76421a68b 100644 --- a/core/scss/ui/_nav.scss +++ b/core/scss/ui/_nav.scss @@ -36,7 +36,7 @@ .nav-link { padding-left: 0; padding-right: 0; - margin: 0 0 (- $nav-bordered-border-width); + margin: 0 0 calc(-1 * #{$nav-bordered-border-width}); border: 0; border-bottom: $nav-bordered-link-active-border-width var(--#{$prefix}border-style) transparent; } @@ -88,4 +88,4 @@ justify-content: center; } } -} \ No newline at end of file +}