bpms_site/.svn/pristine/15/15fcac9e2e6514e90fe089a5b4f24f994aec7e87.svn-base
2025-11-02 16:38:49 +03:30

25 lines
680 B
Plaintext

/**
* **PostCSS Plugin Warning**
*
* Loader wrapper for postcss plugin warnings (`root.messages`)
*
* @class Warning
* @extends Error
*
* @param {Object} warning PostCSS Warning
*/ export default class Warning extends Error {
constructor(warning){
super(warning);
const { text, line, column, plugin } = warning;
this.name = "Warning";
this.message = `${this.name}\n\n`;
if (typeof line !== "undefined") {
this.message += `(${line}:${column}) `;
}
this.message += plugin ? `${plugin}: ` : "";
this.message += `${text}`;
this.stack = false;
}
}
//# sourceMappingURL=Warning.js.map