Selaa lähdekoodia

Update _nav.scss (#2133)

* 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 <[email protected]>
Co-authored-by: Paweł Kuna <[email protected]>
falsulaiman 7 kuukautta sitten
vanhempi
commit
78383ef568
2 muutettua tiedostoa jossa 7 lisäystä ja 2 poistoa
  1. 5 0
      .changeset/red-pens-punch.md
  2. 2 2
      core/scss/ui/_nav.scss

+ 5 - 0
.changeset/red-pens-punch.md

@@ -0,0 +1,5 @@
+---
+"@tabler/core": patch
+---
+
+Fix negative margins in `.navbar-bordered` variant

+ 2 - 2
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;
     }
   }
-}
+}