Divider

If the separation is meaningful for reading → <hr />
If it is purely decorative → <div aria-hidden="true">
<!-- Default -->
<div aria-hidden="true" class="sds-divider"></div>

<!-- Semantic -->
<hr class="sds-divider" />

{% if decorative %}<div aria-hidden="true"{% else %}<hr{% endif %}
	class="{{ namespace }}divider{% for mod in modifiers %} {{ mod }}{% endfor %}{% for mod in classes %} {{ mod }}{% endfor %}"
{% if decorative %}></div>{% else %} />{% endif %}
  • Content:
    /* variables specific to current element */
    
    $element-specific-variables: "";
    
    .#{$namespace}divider {
    
    	/* Save root element context for easy access if nesting is needed */
    
    	$self: &;
    
    
    	/* properties of current element  + media queries */
    
    	@include custom-prop-fallback("height", "comp-divider-height");
    	@include custom-prop-fallback("background-color", "comp-divider-background-color");
    	border: 0 none;
    	margin: 0;
    
    
    	/* Pseudo Elements */
    
    	&::before {
    	}
    
    	&::after {
    	}
    
    	/*
    	Include elements that are linked to the current element but have to reside at the root level of the stylesheet
    	(e.g: keyframes)
    	*/
    	@at-root {
    	}
    
    
    	/* children - write selector in full in comments in order to facilitate search */
    
    	// divider__childElement
    	&__childElement {
    
    		// follows same logic as parent
    
    	}
    
    
    	/* modifiers */
    
    	// divider -altStyle
    	&.-altStyle {
    
    		// follows same logic as base element
    
    	}
    
    	/* random parent element */
    	/*
    	*
    	*   Syntax : .randomParentElt & {}
    	*
    	*/
    
    	/* Pseudo Classes */
    
    	&:hover {
    		@media (hover: hover) {
    
    		}
    	}
    
    	&:focus {
    	}
    
    	&:active {
    	}
    
    	&:focus,
    	&:active {
    	}
    
    }
  • URL: /components/raw/divider/_divider.scss
  • Filesystem Path: components/token-based/content/divider/_divider.scss
  • Size: 1.1 KB