1
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-09-02 01:42:36 +02:00

Add deprecate() mixin (#28092)

This commit is contained in:
Martijn Cuppens
2019-01-22 20:55:23 +01:00
committed by GitHub
parent f7e8445f72
commit 5c56e9adff
5 changed files with 16 additions and 3 deletions

View File

@@ -0,0 +1,10 @@
// Deprecate mixin
//
// This mixin can be used to deprecate mixins or functions.
// `$enable-deprecation-messages` is a global variable, `$ignore-warning` is a variable that can be passed to
// some deprecated mixins to suppress the warning (for example if the mixin is still be used in the current version of Bootstrap)
@mixin deprecate($name, $deprecate-version, $remove-version, $ignore-warning) {
@if ($enable-deprecation-messages != false and $ignore-warning != true) {
@warn "#{$name} has been deprecated as of #{$deprecate-version}. It will be removed entirely in #{$remove-version}.";
}
}