Card Article

No notes defined.

<div class="sds-cardArticle sds-box sds-shadowInteraction">

    <div class="sds-cardArticle__header text-center">
        <img src="https://sds.apart.lu/media/illustrations/svg750x560/hero/sdsillu-unlockofflinecedies.svg" alt="" class="img-fluid" />

        <span class="sds-btn -iconBtn -btnSecondary -btnInverse sds-cardArticle__btn" aria-hidden="true">

            <span aria-hidden="true" class="sds-icon sds-icon-play"></span>

        </span>

    </div>

    <div class="sds-cardArticle__body sds-staticStackXs">
        <a href="#!" class="sds-cardArticle__link stretched-link">
            <h3 class="h4 sds-textSemiBold">Heading</h3>
        </a>

        <p class="sds-textHelper sds-metaColor">Lorem ipsum dolor sit amet</p>

    </div>
</div>
<div
	class="{{ namespace }}cardArticle {{ namespace }}box {{ namespace }}shadowInteraction{% for mod in modifiers %} {{ mod }}{% endfor %}{% for mod in classes %} {{ mod }}{% endfor %}">
	{% if img %}
	<div class="{{ namespace }}cardArticle__header text-center">
		<img src="{{ img }}" alt="" class="img-fluid" />
		{% if fakeBtn %}
			{% render "@icon-btn-secondary-inverse", {
				eltType: "span",
				icon: "icon-play",
				classes: [namespace+"cardArticle__btn"],
				attrs: {
					"aria-hidden": "true"
				}
			}, true %}
		{% endif %}
	</div>
	{% endif %}
	<div class="{{ namespace }}cardArticle__body {{ namespace }}staticStackXs">
		<a href="#!" class="{{ namespace }}cardArticle__link stretched-link">
			<h3 class="h4 {{ namespace }}textSemiBold">{{ title }}</h3>
		</a>
		{% if text %}
		<p class="{{ namespace }}textHelper {{ namespace }}metaColor">{{ text }}</p>
		{% endif %}
	</div>
</div>
  • Content:
    /* variables specific to current element */
    
    $element-specific-variables: "";
    
    .#{$namespace}cardArticle {
    
    	/* Save root element context for easy access if nesting is needed */
    
    	$self: &;
    
    
    	/* properties of current element  + media queries */
    
    	&:has(#{$self}__link:focus-visible) {
    		outline: $border-width*2 solid;
    	}
    
    
    	/* 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 */
    
    	// cardArticle__header
    	&__header {
    		position: relative;
    		aspect-ratio: 4/3;
    		border-top-left-radius: inherit;
    		border-top-right-radius: inherit;
    		overflow: hidden;
    
    		IMG {
    			object-fit: cover;
    			width: 100%;
    			height: 100%;
    		}
    	}
    
    	// cardArticle__btn
    	&__btn {
    		position: absolute;
    		bottom: var(--comp-card-article-body-inset-v);
    		right: var(--comp-card-article-body-inset-h);
    	}
    
    	// cardArticle__body
    	&__body {
    		padding-inline: var(--comp-box-medium-inset-h);
    		padding-block: var(--comp-box-medium-inset-v);
    	}
    
    	// cardArticle__link
    	&__link {
    		&:focus-visible {
    			outline: 0 none;
    		}
    	}
    
    
    	/* modifiers */
    
    	// cardArticle -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/card-article/card-article.scss
  • Filesystem Path: components/token-based/surfaces/card/card-article/card-article.scss
  • Size: 1.5 KB