gant-core 0.1.40 → 0.1.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cli/index.js +1 -1
- package/lib/index.d.ts +2 -0
- package/lib/index.js +416 -3
- package/lib/index.js.map +1 -1
- package/package.json +1 -1
package/lib/cli/index.js
CHANGED
|
@@ -66794,7 +66794,7 @@ const createCwdConfig = (cwd, name, vue) => {
|
|
|
66794
66794
|
};
|
|
66795
66795
|
|
|
66796
66796
|
var name = "gant-core";
|
|
66797
|
-
var version = "0.1.
|
|
66797
|
+
var version = "0.1.42";
|
|
66798
66798
|
var description = "";
|
|
66799
66799
|
var main = "lib/index.js";
|
|
66800
66800
|
var bin = {
|
package/lib/index.d.ts
CHANGED
|
@@ -7,6 +7,7 @@ export * from 'axios';
|
|
|
7
7
|
import * as mitt from 'mitt';
|
|
8
8
|
import * as i18next from 'i18next';
|
|
9
9
|
import { InitOptions, Callback } from 'i18next';
|
|
10
|
+
export * from '@ctrl/tinycolor';
|
|
10
11
|
|
|
11
12
|
declare const PresetColors: readonly ["blue", "purple", "cyan", "green", "magenta", "pink", "red", "orange", "yellow", "volcano", "geekblue", "lime", "gold"];
|
|
12
13
|
type PresetColorKey = (typeof PresetColors)[number];
|
|
@@ -1989,6 +1990,7 @@ interface GlobalOptions {
|
|
|
1989
1990
|
menuData?: ServerMenuData | ((res: UserAggregateInfo) => ServerMenuData);
|
|
1990
1991
|
loginSuccessCallback?: () => void;
|
|
1991
1992
|
ssoCallback?: () => boolean;
|
|
1993
|
+
websocket?: boolean;
|
|
1992
1994
|
}
|
|
1993
1995
|
|
|
1994
1996
|
declare const MENU_HISTORY_UPDATE = "MENU_HISTORY_UPDATE";
|
package/lib/index.js
CHANGED
|
@@ -1193,7 +1193,7 @@ class GlobalStoreClass {
|
|
|
1193
1193
|
this.menuStore.init(isEmpty(localeMenus) ? startMenus : localeMenus, currentUser.id);
|
|
1194
1194
|
};
|
|
1195
1195
|
init = async (options) => {
|
|
1196
|
-
const { base = "/", menuData, loginSuccessCallback, ssoCallback } = options;
|
|
1196
|
+
const { base = "/", menuData, loginSuccessCallback, ssoCallback, websocket: _startwebsocket = true } = options;
|
|
1197
1197
|
this.loginStore.init(options?.loginConfig, base, ssoCallback);
|
|
1198
1198
|
try {
|
|
1199
1199
|
//检查token
|
|
@@ -1205,7 +1205,8 @@ class GlobalStoreClass {
|
|
|
1205
1205
|
await codeListStoreInstance.findAllCodeList();
|
|
1206
1206
|
await parameterStoreInstance.findAllParameters();
|
|
1207
1207
|
//websocket注册
|
|
1208
|
-
|
|
1208
|
+
if (_startwebsocket)
|
|
1209
|
+
websocket.init(this.userStore.currentUser.userLoginName);
|
|
1209
1210
|
await loginSuccessCallback?.();
|
|
1210
1211
|
return true;
|
|
1211
1212
|
}
|
|
@@ -3979,6 +3980,19 @@ function rgbaToHex(r, g, b, a, allow4Char) {
|
|
|
3979
3980
|
}
|
|
3980
3981
|
return hex.join('');
|
|
3981
3982
|
}
|
|
3983
|
+
/**
|
|
3984
|
+
* Converts an RGBA color to an ARGB Hex8 string
|
|
3985
|
+
* Rarely used, but required for "toFilter()"
|
|
3986
|
+
*/
|
|
3987
|
+
function rgbaToArgbHex(r, g, b, a) {
|
|
3988
|
+
var hex = [
|
|
3989
|
+
pad2(convertDecimalToHex(a)),
|
|
3990
|
+
pad2(Math.round(r).toString(16)),
|
|
3991
|
+
pad2(Math.round(g).toString(16)),
|
|
3992
|
+
pad2(Math.round(b).toString(16)),
|
|
3993
|
+
];
|
|
3994
|
+
return hex.join('');
|
|
3995
|
+
}
|
|
3982
3996
|
/** Converts a decimal to a hex value */
|
|
3983
3997
|
function convertDecimalToHex(d) {
|
|
3984
3998
|
return Math.round(parseFloat(d) * 255).toString(16);
|
|
@@ -4832,6 +4846,405 @@ var TinyColor = /** @class */ (function () {
|
|
|
4832
4846
|
};
|
|
4833
4847
|
return TinyColor;
|
|
4834
4848
|
}());
|
|
4849
|
+
// kept for backwards compatability with v1
|
|
4850
|
+
function tinycolor(color, opts) {
|
|
4851
|
+
if (color === void 0) { color = ''; }
|
|
4852
|
+
if (opts === void 0) { opts = {}; }
|
|
4853
|
+
return new TinyColor(color, opts);
|
|
4854
|
+
}
|
|
4855
|
+
|
|
4856
|
+
// Readability Functions
|
|
4857
|
+
// ---------------------
|
|
4858
|
+
// <http://www.w3.org/TR/2008/REC-WCAG20-20081211/#contrast-ratiodef (WCAG Version 2)
|
|
4859
|
+
/**
|
|
4860
|
+
* AKA `contrast`
|
|
4861
|
+
*
|
|
4862
|
+
* Analyze the 2 colors and returns the color contrast defined by (WCAG Version 2)
|
|
4863
|
+
*/
|
|
4864
|
+
function readability(color1, color2) {
|
|
4865
|
+
var c1 = new TinyColor(color1);
|
|
4866
|
+
var c2 = new TinyColor(color2);
|
|
4867
|
+
return ((Math.max(c1.getLuminance(), c2.getLuminance()) + 0.05) /
|
|
4868
|
+
(Math.min(c1.getLuminance(), c2.getLuminance()) + 0.05));
|
|
4869
|
+
}
|
|
4870
|
+
/**
|
|
4871
|
+
* Ensure that foreground and background color combinations meet WCAG2 guidelines.
|
|
4872
|
+
* The third argument is an object.
|
|
4873
|
+
* the 'level' property states 'AA' or 'AAA' - if missing or invalid, it defaults to 'AA';
|
|
4874
|
+
* the 'size' property states 'large' or 'small' - if missing or invalid, it defaults to 'small'.
|
|
4875
|
+
* If the entire object is absent, isReadable defaults to {level:"AA",size:"small"}.
|
|
4876
|
+
*
|
|
4877
|
+
* Example
|
|
4878
|
+
* ```ts
|
|
4879
|
+
* new TinyColor().isReadable('#000', '#111') => false
|
|
4880
|
+
* new TinyColor().isReadable('#000', '#111', { level: 'AA', size: 'large' }) => false
|
|
4881
|
+
* ```
|
|
4882
|
+
*/
|
|
4883
|
+
function isReadable(color1, color2, wcag2) {
|
|
4884
|
+
var _a, _b;
|
|
4885
|
+
if (wcag2 === void 0) { wcag2 = { level: 'AA', size: 'small' }; }
|
|
4886
|
+
var readabilityLevel = readability(color1, color2);
|
|
4887
|
+
switch (((_a = wcag2.level) !== null && _a !== void 0 ? _a : 'AA') + ((_b = wcag2.size) !== null && _b !== void 0 ? _b : 'small')) {
|
|
4888
|
+
case 'AAsmall':
|
|
4889
|
+
case 'AAAlarge':
|
|
4890
|
+
return readabilityLevel >= 4.5;
|
|
4891
|
+
case 'AAlarge':
|
|
4892
|
+
return readabilityLevel >= 3;
|
|
4893
|
+
case 'AAAsmall':
|
|
4894
|
+
return readabilityLevel >= 7;
|
|
4895
|
+
default:
|
|
4896
|
+
return false;
|
|
4897
|
+
}
|
|
4898
|
+
}
|
|
4899
|
+
/**
|
|
4900
|
+
* Given a base color and a list of possible foreground or background
|
|
4901
|
+
* colors for that base, returns the most readable color.
|
|
4902
|
+
* Optionally returns Black or White if the most readable color is unreadable.
|
|
4903
|
+
*
|
|
4904
|
+
* @param baseColor - the base color.
|
|
4905
|
+
* @param colorList - array of colors to pick the most readable one from.
|
|
4906
|
+
* @param args - and object with extra arguments
|
|
4907
|
+
*
|
|
4908
|
+
* Example
|
|
4909
|
+
* ```ts
|
|
4910
|
+
* new TinyColor().mostReadable('#123', ['#124", "#125'], { includeFallbackColors: false }).toHexString(); // "#112255"
|
|
4911
|
+
* new TinyColor().mostReadable('#123', ['#124", "#125'],{ includeFallbackColors: true }).toHexString(); // "#ffffff"
|
|
4912
|
+
* new TinyColor().mostReadable('#a8015a', ["#faf3f3"], { includeFallbackColors:true, level: 'AAA', size: 'large' }).toHexString(); // "#faf3f3"
|
|
4913
|
+
* new TinyColor().mostReadable('#a8015a', ["#faf3f3"], { includeFallbackColors:true, level: 'AAA', size: 'small' }).toHexString(); // "#ffffff"
|
|
4914
|
+
* ```
|
|
4915
|
+
*/
|
|
4916
|
+
function mostReadable(baseColor, colorList, args) {
|
|
4917
|
+
if (args === void 0) { args = { includeFallbackColors: false, level: 'AA', size: 'small' }; }
|
|
4918
|
+
var bestColor = null;
|
|
4919
|
+
var bestScore = 0;
|
|
4920
|
+
var includeFallbackColors = args.includeFallbackColors, level = args.level, size = args.size;
|
|
4921
|
+
for (var _i = 0, colorList_1 = colorList; _i < colorList_1.length; _i++) {
|
|
4922
|
+
var color = colorList_1[_i];
|
|
4923
|
+
var score = readability(baseColor, color);
|
|
4924
|
+
if (score > bestScore) {
|
|
4925
|
+
bestScore = score;
|
|
4926
|
+
bestColor = new TinyColor(color);
|
|
4927
|
+
}
|
|
4928
|
+
}
|
|
4929
|
+
if (isReadable(baseColor, bestColor, { level: level, size: size }) || !includeFallbackColors) {
|
|
4930
|
+
return bestColor;
|
|
4931
|
+
}
|
|
4932
|
+
args.includeFallbackColors = false;
|
|
4933
|
+
return mostReadable(baseColor, ['#fff', '#000'], args);
|
|
4934
|
+
}
|
|
4935
|
+
|
|
4936
|
+
/**
|
|
4937
|
+
* Returns the color represented as a Microsoft filter for use in old versions of IE.
|
|
4938
|
+
*/
|
|
4939
|
+
function toMsFilter(firstColor, secondColor) {
|
|
4940
|
+
var color = new TinyColor(firstColor);
|
|
4941
|
+
var hex8String = '#' + rgbaToArgbHex(color.r, color.g, color.b, color.a);
|
|
4942
|
+
var secondHex8String = hex8String;
|
|
4943
|
+
var gradientType = color.gradientType ? 'GradientType = 1, ' : '';
|
|
4944
|
+
if (secondColor) {
|
|
4945
|
+
var s = new TinyColor(secondColor);
|
|
4946
|
+
secondHex8String = '#' + rgbaToArgbHex(s.r, s.g, s.b, s.a);
|
|
4947
|
+
}
|
|
4948
|
+
return "progid:DXImageTransform.Microsoft.gradient(".concat(gradientType, "startColorstr=").concat(hex8String, ",endColorstr=").concat(secondHex8String, ")");
|
|
4949
|
+
}
|
|
4950
|
+
|
|
4951
|
+
/**
|
|
4952
|
+
* If input is an object, force 1 into "1.0" to handle ratios properly
|
|
4953
|
+
* String input requires "1.0" as input, so 1 will be treated as 1
|
|
4954
|
+
*/
|
|
4955
|
+
function fromRatio(ratio, opts) {
|
|
4956
|
+
var newColor = {
|
|
4957
|
+
r: convertToPercentage(ratio.r),
|
|
4958
|
+
g: convertToPercentage(ratio.g),
|
|
4959
|
+
b: convertToPercentage(ratio.b),
|
|
4960
|
+
};
|
|
4961
|
+
if (ratio.a !== undefined) {
|
|
4962
|
+
newColor.a = Number(ratio.a);
|
|
4963
|
+
}
|
|
4964
|
+
return new TinyColor(newColor, opts);
|
|
4965
|
+
}
|
|
4966
|
+
/** old random function */
|
|
4967
|
+
function legacyRandom() {
|
|
4968
|
+
return new TinyColor({
|
|
4969
|
+
r: Math.random(),
|
|
4970
|
+
g: Math.random(),
|
|
4971
|
+
b: Math.random(),
|
|
4972
|
+
});
|
|
4973
|
+
}
|
|
4974
|
+
|
|
4975
|
+
/* eslint-disable @typescript-eslint/no-redundant-type-constituents */
|
|
4976
|
+
// randomColor by David Merfield under the CC0 license
|
|
4977
|
+
// https://github.com/davidmerfield/randomColor/
|
|
4978
|
+
function random(options) {
|
|
4979
|
+
if (options === void 0) { options = {}; }
|
|
4980
|
+
// Check if we need to generate multiple colors
|
|
4981
|
+
if (options.count !== undefined &&
|
|
4982
|
+
options.count !== null) {
|
|
4983
|
+
var totalColors = options.count;
|
|
4984
|
+
var colors = [];
|
|
4985
|
+
options.count = undefined;
|
|
4986
|
+
while (totalColors > colors.length) {
|
|
4987
|
+
// Since we're generating multiple colors,
|
|
4988
|
+
// incremement the seed. Otherwise we'd just
|
|
4989
|
+
// generate the same color each time...
|
|
4990
|
+
options.count = null;
|
|
4991
|
+
if (options.seed) {
|
|
4992
|
+
options.seed += 1;
|
|
4993
|
+
}
|
|
4994
|
+
colors.push(random(options));
|
|
4995
|
+
}
|
|
4996
|
+
options.count = totalColors;
|
|
4997
|
+
return colors;
|
|
4998
|
+
}
|
|
4999
|
+
// First we pick a hue (H)
|
|
5000
|
+
var h = pickHue(options.hue, options.seed);
|
|
5001
|
+
// Then use H to determine saturation (S)
|
|
5002
|
+
var s = pickSaturation(h, options);
|
|
5003
|
+
// Then use S and H to determine brightness (B).
|
|
5004
|
+
var v = pickBrightness(h, s, options);
|
|
5005
|
+
var res = { h: h, s: s, v: v };
|
|
5006
|
+
if (options.alpha !== undefined) {
|
|
5007
|
+
res.a = options.alpha;
|
|
5008
|
+
}
|
|
5009
|
+
// Then we return the HSB color in the desired format
|
|
5010
|
+
return new TinyColor(res);
|
|
5011
|
+
}
|
|
5012
|
+
function pickHue(hue, seed) {
|
|
5013
|
+
var hueRange = getHueRange(hue);
|
|
5014
|
+
var res = randomWithin(hueRange, seed);
|
|
5015
|
+
// Instead of storing red as two seperate ranges,
|
|
5016
|
+
// we group them, using negative numbers
|
|
5017
|
+
if (res < 0) {
|
|
5018
|
+
res = 360 + res;
|
|
5019
|
+
}
|
|
5020
|
+
return res;
|
|
5021
|
+
}
|
|
5022
|
+
function pickSaturation(hue, options) {
|
|
5023
|
+
if (options.hue === 'monochrome') {
|
|
5024
|
+
return 0;
|
|
5025
|
+
}
|
|
5026
|
+
if (options.luminosity === 'random') {
|
|
5027
|
+
return randomWithin([0, 100], options.seed);
|
|
5028
|
+
}
|
|
5029
|
+
var saturationRange = getColorInfo(hue).saturationRange;
|
|
5030
|
+
var sMin = saturationRange[0];
|
|
5031
|
+
var sMax = saturationRange[1];
|
|
5032
|
+
switch (options.luminosity) {
|
|
5033
|
+
case 'bright':
|
|
5034
|
+
sMin = 55;
|
|
5035
|
+
break;
|
|
5036
|
+
case 'dark':
|
|
5037
|
+
sMin = sMax - 10;
|
|
5038
|
+
break;
|
|
5039
|
+
case 'light':
|
|
5040
|
+
sMax = 55;
|
|
5041
|
+
break;
|
|
5042
|
+
}
|
|
5043
|
+
return randomWithin([sMin, sMax], options.seed);
|
|
5044
|
+
}
|
|
5045
|
+
function pickBrightness(H, S, options) {
|
|
5046
|
+
var bMin = getMinimumBrightness(H, S);
|
|
5047
|
+
var bMax = 100;
|
|
5048
|
+
switch (options.luminosity) {
|
|
5049
|
+
case 'dark':
|
|
5050
|
+
bMax = bMin + 20;
|
|
5051
|
+
break;
|
|
5052
|
+
case 'light':
|
|
5053
|
+
bMin = (bMax + bMin) / 2;
|
|
5054
|
+
break;
|
|
5055
|
+
case 'random':
|
|
5056
|
+
bMin = 0;
|
|
5057
|
+
bMax = 100;
|
|
5058
|
+
break;
|
|
5059
|
+
}
|
|
5060
|
+
return randomWithin([bMin, bMax], options.seed);
|
|
5061
|
+
}
|
|
5062
|
+
function getMinimumBrightness(H, S) {
|
|
5063
|
+
var lowerBounds = getColorInfo(H).lowerBounds;
|
|
5064
|
+
for (var i = 0; i < lowerBounds.length - 1; i++) {
|
|
5065
|
+
var s1 = lowerBounds[i][0];
|
|
5066
|
+
var v1 = lowerBounds[i][1];
|
|
5067
|
+
var s2 = lowerBounds[i + 1][0];
|
|
5068
|
+
var v2 = lowerBounds[i + 1][1];
|
|
5069
|
+
if (S >= s1 && S <= s2) {
|
|
5070
|
+
var m = (v2 - v1) / (s2 - s1);
|
|
5071
|
+
var b = v1 - m * s1;
|
|
5072
|
+
return m * S + b;
|
|
5073
|
+
}
|
|
5074
|
+
}
|
|
5075
|
+
return 0;
|
|
5076
|
+
}
|
|
5077
|
+
function getHueRange(colorInput) {
|
|
5078
|
+
var num = parseInt(colorInput, 10);
|
|
5079
|
+
if (!Number.isNaN(num) && num < 360 && num > 0) {
|
|
5080
|
+
return [num, num];
|
|
5081
|
+
}
|
|
5082
|
+
if (typeof colorInput === 'string') {
|
|
5083
|
+
var namedColor = bounds.find(function (n) { return n.name === colorInput; });
|
|
5084
|
+
if (namedColor) {
|
|
5085
|
+
var color = defineColor(namedColor);
|
|
5086
|
+
if (color.hueRange) {
|
|
5087
|
+
return color.hueRange;
|
|
5088
|
+
}
|
|
5089
|
+
}
|
|
5090
|
+
var parsed = new TinyColor(colorInput);
|
|
5091
|
+
if (parsed.isValid) {
|
|
5092
|
+
var hue = parsed.toHsv().h;
|
|
5093
|
+
return [hue, hue];
|
|
5094
|
+
}
|
|
5095
|
+
}
|
|
5096
|
+
return [0, 360];
|
|
5097
|
+
}
|
|
5098
|
+
function getColorInfo(hue) {
|
|
5099
|
+
// Maps red colors to make picking hue easier
|
|
5100
|
+
if (hue >= 334 && hue <= 360) {
|
|
5101
|
+
hue -= 360;
|
|
5102
|
+
}
|
|
5103
|
+
for (var _i = 0, bounds_1 = bounds; _i < bounds_1.length; _i++) {
|
|
5104
|
+
var bound = bounds_1[_i];
|
|
5105
|
+
var color = defineColor(bound);
|
|
5106
|
+
if (color.hueRange && hue >= color.hueRange[0] && hue <= color.hueRange[1]) {
|
|
5107
|
+
return color;
|
|
5108
|
+
}
|
|
5109
|
+
}
|
|
5110
|
+
throw Error('Color not found');
|
|
5111
|
+
}
|
|
5112
|
+
function randomWithin(range, seed) {
|
|
5113
|
+
if (seed === undefined) {
|
|
5114
|
+
return Math.floor(range[0] + Math.random() * (range[1] + 1 - range[0]));
|
|
5115
|
+
}
|
|
5116
|
+
// Seeded random algorithm from http://indiegamr.com/generate-repeatable-random-numbers-in-js/
|
|
5117
|
+
var max = range[1] || 1;
|
|
5118
|
+
var min = range[0] || 0;
|
|
5119
|
+
seed = (seed * 9301 + 49297) % 233280;
|
|
5120
|
+
var rnd = seed / 233280.0;
|
|
5121
|
+
return Math.floor(min + rnd * (max - min));
|
|
5122
|
+
}
|
|
5123
|
+
function defineColor(bound) {
|
|
5124
|
+
var sMin = bound.lowerBounds[0][0];
|
|
5125
|
+
var sMax = bound.lowerBounds[bound.lowerBounds.length - 1][0];
|
|
5126
|
+
var bMin = bound.lowerBounds[bound.lowerBounds.length - 1][1];
|
|
5127
|
+
var bMax = bound.lowerBounds[0][1];
|
|
5128
|
+
return {
|
|
5129
|
+
name: bound.name,
|
|
5130
|
+
hueRange: bound.hueRange,
|
|
5131
|
+
lowerBounds: bound.lowerBounds,
|
|
5132
|
+
saturationRange: [sMin, sMax],
|
|
5133
|
+
brightnessRange: [bMin, bMax],
|
|
5134
|
+
};
|
|
5135
|
+
}
|
|
5136
|
+
/**
|
|
5137
|
+
* @hidden
|
|
5138
|
+
*/
|
|
5139
|
+
var bounds = [
|
|
5140
|
+
{
|
|
5141
|
+
name: 'monochrome',
|
|
5142
|
+
hueRange: null,
|
|
5143
|
+
lowerBounds: [
|
|
5144
|
+
[0, 0],
|
|
5145
|
+
[100, 0],
|
|
5146
|
+
],
|
|
5147
|
+
},
|
|
5148
|
+
{
|
|
5149
|
+
name: 'red',
|
|
5150
|
+
hueRange: [-26, 18],
|
|
5151
|
+
lowerBounds: [
|
|
5152
|
+
[20, 100],
|
|
5153
|
+
[30, 92],
|
|
5154
|
+
[40, 89],
|
|
5155
|
+
[50, 85],
|
|
5156
|
+
[60, 78],
|
|
5157
|
+
[70, 70],
|
|
5158
|
+
[80, 60],
|
|
5159
|
+
[90, 55],
|
|
5160
|
+
[100, 50],
|
|
5161
|
+
],
|
|
5162
|
+
},
|
|
5163
|
+
{
|
|
5164
|
+
name: 'orange',
|
|
5165
|
+
hueRange: [19, 46],
|
|
5166
|
+
lowerBounds: [
|
|
5167
|
+
[20, 100],
|
|
5168
|
+
[30, 93],
|
|
5169
|
+
[40, 88],
|
|
5170
|
+
[50, 86],
|
|
5171
|
+
[60, 85],
|
|
5172
|
+
[70, 70],
|
|
5173
|
+
[100, 70],
|
|
5174
|
+
],
|
|
5175
|
+
},
|
|
5176
|
+
{
|
|
5177
|
+
name: 'yellow',
|
|
5178
|
+
hueRange: [47, 62],
|
|
5179
|
+
lowerBounds: [
|
|
5180
|
+
[25, 100],
|
|
5181
|
+
[40, 94],
|
|
5182
|
+
[50, 89],
|
|
5183
|
+
[60, 86],
|
|
5184
|
+
[70, 84],
|
|
5185
|
+
[80, 82],
|
|
5186
|
+
[90, 80],
|
|
5187
|
+
[100, 75],
|
|
5188
|
+
],
|
|
5189
|
+
},
|
|
5190
|
+
{
|
|
5191
|
+
name: 'green',
|
|
5192
|
+
hueRange: [63, 178],
|
|
5193
|
+
lowerBounds: [
|
|
5194
|
+
[30, 100],
|
|
5195
|
+
[40, 90],
|
|
5196
|
+
[50, 85],
|
|
5197
|
+
[60, 81],
|
|
5198
|
+
[70, 74],
|
|
5199
|
+
[80, 64],
|
|
5200
|
+
[90, 50],
|
|
5201
|
+
[100, 40],
|
|
5202
|
+
],
|
|
5203
|
+
},
|
|
5204
|
+
{
|
|
5205
|
+
name: 'blue',
|
|
5206
|
+
hueRange: [179, 257],
|
|
5207
|
+
lowerBounds: [
|
|
5208
|
+
[20, 100],
|
|
5209
|
+
[30, 86],
|
|
5210
|
+
[40, 80],
|
|
5211
|
+
[50, 74],
|
|
5212
|
+
[60, 60],
|
|
5213
|
+
[70, 52],
|
|
5214
|
+
[80, 44],
|
|
5215
|
+
[90, 39],
|
|
5216
|
+
[100, 35],
|
|
5217
|
+
],
|
|
5218
|
+
},
|
|
5219
|
+
{
|
|
5220
|
+
name: 'purple',
|
|
5221
|
+
hueRange: [258, 282],
|
|
5222
|
+
lowerBounds: [
|
|
5223
|
+
[20, 100],
|
|
5224
|
+
[30, 87],
|
|
5225
|
+
[40, 79],
|
|
5226
|
+
[50, 70],
|
|
5227
|
+
[60, 65],
|
|
5228
|
+
[70, 59],
|
|
5229
|
+
[80, 52],
|
|
5230
|
+
[90, 45],
|
|
5231
|
+
[100, 42],
|
|
5232
|
+
],
|
|
5233
|
+
},
|
|
5234
|
+
{
|
|
5235
|
+
name: 'pink',
|
|
5236
|
+
hueRange: [283, 334],
|
|
5237
|
+
lowerBounds: [
|
|
5238
|
+
[20, 100],
|
|
5239
|
+
[30, 90],
|
|
5240
|
+
[40, 86],
|
|
5241
|
+
[60, 84],
|
|
5242
|
+
[80, 80],
|
|
5243
|
+
[90, 75],
|
|
5244
|
+
[100, 73],
|
|
5245
|
+
],
|
|
5246
|
+
},
|
|
5247
|
+
];
|
|
4835
5248
|
|
|
4836
5249
|
var hueStep = 2; // 色相阶梯
|
|
4837
5250
|
var saturationStep = 0.16; // 饱和度阶梯,浅色部分
|
|
@@ -5961,5 +6374,5 @@ var main = async ({ microServiceMap, dynamicLangCallback, ...globalOptions }) =>
|
|
|
5961
6374
|
return res;
|
|
5962
6375
|
};
|
|
5963
6376
|
|
|
5964
|
-
export { MENU_BREADCRUMBS_UPDATE, MENU_HISTORY_UPDATE, PROGRESS_UPDEDATE, PresetColors, WS_CONTENT_CLOSE, WS_CONTENT_ERROR, WS_CONTENT_SUCCESS, codeListStore, derivative$1 as compactAlgorithm, index as companydataStore, derivative$2 as darkAlgorithm, derivative$3 as defaultAlgorithm, emitter, expireCache, formatToken as formatAliasToken, getAliasToken, getAlphaColor$1 as getAlphaColor, getAntdLocaleKey, getBackgroundColor, getDarkenSolidColor, getLightenSolidColor, getLocaleKey, getRoutes, getTokenCssVar, getTraceId, globalStore, main as init, initDynamicLang, lighten, loginStore, menuStore, parameterStore, Progress as progress, request, requestInstance, seedToken as seed, setLocaleKey, storage as storageStore, token, tr, useRequestHeader, useRequestMicroSevices, userStore, websocket };
|
|
6377
|
+
export { MENU_BREADCRUMBS_UPDATE, MENU_HISTORY_UPDATE, PROGRESS_UPDEDATE, PresetColors, TinyColor, WS_CONTENT_CLOSE, WS_CONTENT_ERROR, WS_CONTENT_SUCCESS, bounds, codeListStore, derivative$1 as compactAlgorithm, index as companydataStore, convertDecimalToHex, convertHexToDecimal, derivative$2 as darkAlgorithm, derivative$3 as defaultAlgorithm, emitter, expireCache, formatToken as formatAliasToken, fromRatio, getAliasToken, getAlphaColor$1 as getAlphaColor, getAntdLocaleKey, getBackgroundColor, getDarkenSolidColor, getLightenSolidColor, getLocaleKey, getRoutes, getTokenCssVar, getTraceId, globalStore, hslToRgb, hsvToRgb, main as init, initDynamicLang, inputToRGB, isReadable, isValidCSSUnit, legacyRandom, lighten, loginStore, menuStore, mostReadable, names, numberInputToObject, parameterStore, parseIntFromHex, Progress as progress, random, readability, request, requestInstance, rgbToHex, rgbToHsl, rgbToHsv, rgbToRgb, rgbaToArgbHex, rgbaToHex, seedToken as seed, setLocaleKey, storage as storageStore, stringInputToObject, tinycolor, toMsFilter, token, tr, useRequestHeader, useRequestMicroSevices, userStore, websocket };
|
|
5965
6378
|
//# sourceMappingURL=index.js.map
|