<commit_before>////
/// Ratio box
/// @group core-structures
/// @author <NAME>
////


// Settings
// --------

/// Controls whether styles in this file (ratiobox) are generated.
/// @type Boolean
$sl-generate-ratiobox: $sl-generate !default;

/// The ratiobox module selector
/// @type String
$sl-ratiobox-selector: sl-module('ratiobox') !default;

/// The ratiobox box module selector
/// @type String
$sl-ratiobox-box-selector: sl-module('box') !default;

/// A list of ratios
/// @type List
$sl-ratiobox-ratios: (1, 1) (5, 4) (4, 3) (3, 2) (16, 10) (5, 3) (16, 9) (1.85, 1) (2, 1) (2.39, 1) !default;

/// Whether or not the inversions of each ratio should be made a parameter
/// @type Boolean
$sl-ratiobox-invert: false !default;


// Asserts
// -------

@include sl-assert($sl-generate-ratiobox, 'bool');
@include sl-assert($sl-ratiobox-selector, 'string');
@include sl-assert($sl-ratiobox-box-selector, 'string');
@include sl-assert($sl-ratiobox-ratios, 'list', 'list', 'number');
@include sl-assert($sl-ratiobox-invert, 'bool');


// Mixins
// ------

///
/// @param {Number} $x [1]
/// @param {Number} $y [1]
/// @output
@mixin sl-ratiobox($x: 1, $y: 1) {

	@each $n in $x, $y {
		@if type-of($n) != 'number' or not unitless($n) or $n <= 0 {
			@error '#{inspect($n)} is not a positive decimal greater than zero';
		}
	}

	display: block;
	position: relative;
	padding: ($y / $x * 100%) 0 0 100%;
}

///
/// @output
@mixin sl-ratiobox-box {
	display: block;
	position: absolute;
	top: 0;
	left: 0;<commit_msg>Added param for ratiobox to work with pseudo elms<commit_after>////
/// Ratio box
/// @group core-structures
/// @author <NAME>
////


// Settings
// --------

/// Controls whether styles in this file (ratiobox) are generated.
/// @type Boolean
$sl-generate-ratiobox: $sl-generate !default;

/// The ratiobox module selector
/// @type String
$sl-ratiobox-selector: sl-module('ratiobox') !default;

/// The ratiobox box module selector
/// @type String
$sl-ratiobox-box-selector: sl-module('box') !default;

/// A list of ratios
/// @type List
$sl-ratiobox-ratios: (1, 1) (5, 4) (4, 3) (3, 2) (16, 10) (5, 3) (16, 9) (1.85, 1) (2, 1) (2.39, 1) !default;

/// Whether or not the inversions of each ratio should be made a parameter
/// @type Boolean
$sl-ratiobox-invert: false !default;


// Asserts
// -------

@include sl-assert($sl-generate-ratiobox, 'bool');
@include sl-assert($sl-ratiobox-selector, 'string');
@include sl-assert($sl-ratiobox-box-selector, 'string');
@include sl-assert($sl-ratiobox-ratios, 'list', 'list', 'number');
@include sl-assert($sl-ratiobox-invert, 'bool');


// Mixins
// ------

///
/// @param {Number} $x [1]
/// @param {Number} $y [1]
/// @param {String | Boolean} $pseudo [before]
/// @output
@mixin sl-ratiobox($x: 1, $y: 1, $pseudo: before) {

	@each $n in $x, $y {
		@if type-of($n) != 'number' or not unitless($n) or $n <= 0 {
			@error '#{inspect($n)} is not a positive decimal greater than zero';
		}
	}

	display: block;
	position: relative;

	@if $pseudo == 'before' or $pseudo == 'after' {
		&:#{unquote($pseudo)} {
			content: '';
			display: block;
			padding: ($y / $x * 100%) 0 0 100%;
		}

	} @else {
		padding: ($y / $x * 100%) 0 0 100%;
	}
}

///
/// @output
@mixin sl-ratiobox-box {
	display: block;
	position: absolute;
	top: 0;
	left: 0;
{'fraction_non_alphanumeric': 0.219770253929867, 'fraction_numerical': 0.02781136638452237, 'mean_word_length': 3.045232273838631, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6522044', 'n_tokens_mistral': 1384, 'n_tokens_neox': 1242, 'n_words': 364}