/**
 * ldesign v0.3.13
 * (c) 2023 ldesign
 * @license MIT
 */

'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

var tinyColor = require('tinycolor2');

function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }

var tinyColor__default = /*#__PURE__*/_interopDefaultLegacy(tinyColor);

function generateColors(primaryColor) {
  var primary = tinyColor__default["default"](primaryColor);
  var warning = tinyColor__default["default"].mix(primary.clone().setAlpha(1), tinyColor__default["default"]({
    r: 113,
    g: 51,
    b: 0
  }), 70);
  var success = primary.clone().setAlpha(1).desaturate(10).lighten(10);
  var danger = primary.clone().setAlpha(1).saturate(25).darken(15);
  var primaryShades = [];
  for (var i = 10; i >= 1; i--) {
    primaryShades.push(primary.clone().darken(i * 5).toHexString());
  }
  var warningShades = [];
  for (var _i = 10; _i >= 1; _i--) {
    warningShades.push(tinyColor__default["default"].mix(warning.clone().setAlpha(1), primary.clone().lighten(_i * 2), 50).toHexString());
  }
  var successShades = [];
  for (var _i2 = 10; _i2 >= 1; _i2--) {
    successShades.push(success.clone().darken(_i2 * 5).toHexString());
  }
  var dangerShades = [];
  for (var _i3 = 10; _i3 >= 1; _i3--) {
    dangerShades.push(tinyColor__default["default"].mix(danger.clone().setAlpha(1), primary.clone().lighten(_i3 * 2), 50).toHexString());
  }
  return {
    primaryShades: primaryShades,
    warningShades: warningShades,
    successShades: successShades,
    dangerShades: dangerShades
  };
}

exports.generateColors = generateColors;
//# sourceMappingURL=index.js.map
