@teamturing/react-kit 1.2.2 → 1.2.4
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/dist/index.js +55 -1665
- package/esm/core/Button/index.js +9 -3
- package/esm/core/Chip/index.js +5 -2
- package/esm/core/GradientText/index.js +6 -8
- package/esm/core/Grid/index.js +5 -2
- package/esm/core/IconButton/index.js +5 -2
- package/esm/core/IconToggleButton/index.js +5 -2
- package/esm/core/Space/index.js +5 -6
- package/esm/core/Spinner/index.js +6 -12
- package/esm/core/Stack/index.js +5 -2
- package/esm/core/Text/index.js +5 -2
- package/esm/core/View/index.js +5 -5
- package/esm/core/_UnstyledButton.js +5 -10
- package/package.json +7 -6
- package/esm/node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.esm.js +0 -12
- package/esm/node_modules/@emotion/memoize/dist/emotion-memoize.esm.js +0 -9
- package/esm/node_modules/@emotion/unitless/dist/emotion-unitless.esm.js +0 -51
- package/esm/node_modules/styled-components/dist/styled-components.esm.js +0 -657
- package/esm/node_modules/stylis/src/Enum.js +0 -11
- package/esm/node_modules/stylis/src/Middleware.js +0 -85
- package/esm/node_modules/stylis/src/Parser.js +0 -187
- package/esm/node_modules/stylis/src/Prefixer.js +0 -197
- package/esm/node_modules/stylis/src/Serializer.js +0 -39
- package/esm/node_modules/stylis/src/Tokenizer.js +0 -242
- package/esm/node_modules/stylis/src/Utility.js +0 -128
- package/esm/node_modules/tslib/tslib.es6.js +0 -44
|
@@ -1,242 +0,0 @@
|
|
|
1
|
-
import { assign, append, charat, strlen, trim, from, substr } from './Utility.js';
|
|
2
|
-
|
|
3
|
-
var line = 1;
|
|
4
|
-
var column = 1;
|
|
5
|
-
var length = 0;
|
|
6
|
-
var position = 0;
|
|
7
|
-
var character = 0;
|
|
8
|
-
var characters = '';
|
|
9
|
-
|
|
10
|
-
/**
|
|
11
|
-
* @param {string} value
|
|
12
|
-
* @param {object | null} root
|
|
13
|
-
* @param {object | null} parent
|
|
14
|
-
* @param {string} type
|
|
15
|
-
* @param {string[] | string} props
|
|
16
|
-
* @param {object[] | string} children
|
|
17
|
-
* @param {object[]} siblings
|
|
18
|
-
* @param {number} length
|
|
19
|
-
*/
|
|
20
|
-
function node(value, root, parent, type, props, children, length, siblings) {
|
|
21
|
-
return {
|
|
22
|
-
value: value,
|
|
23
|
-
root: root,
|
|
24
|
-
parent: parent,
|
|
25
|
-
type: type,
|
|
26
|
-
props: props,
|
|
27
|
-
children: children,
|
|
28
|
-
line: line,
|
|
29
|
-
column: column,
|
|
30
|
-
length: length,
|
|
31
|
-
return: '',
|
|
32
|
-
siblings: siblings
|
|
33
|
-
};
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
/**
|
|
37
|
-
* @param {object} root
|
|
38
|
-
* @param {object} props
|
|
39
|
-
* @return {object}
|
|
40
|
-
*/
|
|
41
|
-
function copy(root, props) {
|
|
42
|
-
return assign(node('', null, null, '', null, null, 0, root.siblings), root, {
|
|
43
|
-
length: -root.length
|
|
44
|
-
}, props);
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
/**
|
|
48
|
-
* @param {object} root
|
|
49
|
-
*/
|
|
50
|
-
function lift(root) {
|
|
51
|
-
while (root.root) root = copy(root.root, {
|
|
52
|
-
children: [root]
|
|
53
|
-
});
|
|
54
|
-
append(root, root.siblings);
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
/**
|
|
58
|
-
* @return {number}
|
|
59
|
-
*/
|
|
60
|
-
function char() {
|
|
61
|
-
return character;
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
/**
|
|
65
|
-
* @return {number}
|
|
66
|
-
*/
|
|
67
|
-
function prev() {
|
|
68
|
-
character = position > 0 ? charat(characters, --position) : 0;
|
|
69
|
-
if (column--, character === 10) column = 1, line--;
|
|
70
|
-
return character;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
/**
|
|
74
|
-
* @return {number}
|
|
75
|
-
*/
|
|
76
|
-
function next() {
|
|
77
|
-
character = position < length ? charat(characters, position++) : 0;
|
|
78
|
-
if (column++, character === 10) column = 1, line++;
|
|
79
|
-
return character;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
/**
|
|
83
|
-
* @return {number}
|
|
84
|
-
*/
|
|
85
|
-
function peek() {
|
|
86
|
-
return charat(characters, position);
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
/**
|
|
90
|
-
* @return {number}
|
|
91
|
-
*/
|
|
92
|
-
function caret() {
|
|
93
|
-
return position;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
/**
|
|
97
|
-
* @param {number} begin
|
|
98
|
-
* @param {number} end
|
|
99
|
-
* @return {string}
|
|
100
|
-
*/
|
|
101
|
-
function slice(begin, end) {
|
|
102
|
-
return substr(characters, begin, end);
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
/**
|
|
106
|
-
* @param {number} type
|
|
107
|
-
* @return {number}
|
|
108
|
-
*/
|
|
109
|
-
function token(type) {
|
|
110
|
-
switch (type) {
|
|
111
|
-
// \0 \t \n \r \s whitespace token
|
|
112
|
-
case 0:
|
|
113
|
-
case 9:
|
|
114
|
-
case 10:
|
|
115
|
-
case 13:
|
|
116
|
-
case 32:
|
|
117
|
-
return 5;
|
|
118
|
-
// ! + , / > @ ~ isolate token
|
|
119
|
-
case 33:
|
|
120
|
-
case 43:
|
|
121
|
-
case 44:
|
|
122
|
-
case 47:
|
|
123
|
-
case 62:
|
|
124
|
-
case 64:
|
|
125
|
-
case 126:
|
|
126
|
-
// ; { } breakpoint token
|
|
127
|
-
case 59:
|
|
128
|
-
case 123:
|
|
129
|
-
case 125:
|
|
130
|
-
return 4;
|
|
131
|
-
// : accompanied token
|
|
132
|
-
case 58:
|
|
133
|
-
return 3;
|
|
134
|
-
// " ' ( [ opening delimit token
|
|
135
|
-
case 34:
|
|
136
|
-
case 39:
|
|
137
|
-
case 40:
|
|
138
|
-
case 91:
|
|
139
|
-
return 2;
|
|
140
|
-
// ) ] closing delimit token
|
|
141
|
-
case 41:
|
|
142
|
-
case 93:
|
|
143
|
-
return 1;
|
|
144
|
-
}
|
|
145
|
-
return 0;
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
/**
|
|
149
|
-
* @param {string} value
|
|
150
|
-
* @return {any[]}
|
|
151
|
-
*/
|
|
152
|
-
function alloc(value) {
|
|
153
|
-
return line = column = 1, length = strlen(characters = value), position = 0, [];
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
/**
|
|
157
|
-
* @param {any} value
|
|
158
|
-
* @return {any}
|
|
159
|
-
*/
|
|
160
|
-
function dealloc(value) {
|
|
161
|
-
return characters = '', value;
|
|
162
|
-
}
|
|
163
|
-
|
|
164
|
-
/**
|
|
165
|
-
* @param {number} type
|
|
166
|
-
* @return {string}
|
|
167
|
-
*/
|
|
168
|
-
function delimit(type) {
|
|
169
|
-
return trim(slice(position - 1, delimiter(type === 91 ? type + 2 : type === 40 ? type + 1 : type)));
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
/**
|
|
173
|
-
* @param {number} type
|
|
174
|
-
* @return {string}
|
|
175
|
-
*/
|
|
176
|
-
function whitespace(type) {
|
|
177
|
-
while (character = peek()) if (character < 33) next();else break;
|
|
178
|
-
return token(type) > 2 || token(character) > 3 ? '' : ' ';
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
/**
|
|
182
|
-
* @param {number} index
|
|
183
|
-
* @param {number} count
|
|
184
|
-
* @return {string}
|
|
185
|
-
*/
|
|
186
|
-
function escaping(index, count) {
|
|
187
|
-
while (--count && next())
|
|
188
|
-
// not 0-9 A-F a-f
|
|
189
|
-
if (character < 48 || character > 102 || character > 57 && character < 65 || character > 70 && character < 97) break;
|
|
190
|
-
return slice(index, caret() + (count < 6 && peek() == 32 && next() == 32));
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
/**
|
|
194
|
-
* @param {number} type
|
|
195
|
-
* @return {number}
|
|
196
|
-
*/
|
|
197
|
-
function delimiter(type) {
|
|
198
|
-
while (next()) switch (character) {
|
|
199
|
-
// ] ) " '
|
|
200
|
-
case type:
|
|
201
|
-
return position;
|
|
202
|
-
// " '
|
|
203
|
-
case 34:
|
|
204
|
-
case 39:
|
|
205
|
-
if (type !== 34 && type !== 39) delimiter(character);
|
|
206
|
-
break;
|
|
207
|
-
// (
|
|
208
|
-
case 40:
|
|
209
|
-
if (type === 41) delimiter(type);
|
|
210
|
-
break;
|
|
211
|
-
// \
|
|
212
|
-
case 92:
|
|
213
|
-
next();
|
|
214
|
-
break;
|
|
215
|
-
}
|
|
216
|
-
return position;
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
/**
|
|
220
|
-
* @param {number} type
|
|
221
|
-
* @param {number} index
|
|
222
|
-
* @return {number}
|
|
223
|
-
*/
|
|
224
|
-
function commenter(type, index) {
|
|
225
|
-
while (next())
|
|
226
|
-
// //
|
|
227
|
-
if (type + character === 47 + 10) break;
|
|
228
|
-
// /*
|
|
229
|
-
else if (type + character === 42 + 42 && peek() === 47) break;
|
|
230
|
-
return '/*' + slice(index, position - 1) + '*' + from(type === 47 ? type : next());
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
/**
|
|
234
|
-
* @param {number} index
|
|
235
|
-
* @return {string}
|
|
236
|
-
*/
|
|
237
|
-
function identifier(index) {
|
|
238
|
-
while (!token(peek())) next();
|
|
239
|
-
return slice(index, position);
|
|
240
|
-
}
|
|
241
|
-
|
|
242
|
-
export { alloc, caret, char, character, characters, column, commenter, copy, dealloc, delimit, delimiter, escaping, identifier, length, lift, line, next, node, peek, position, prev, slice, token, whitespace };
|
|
@@ -1,128 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @param {number}
|
|
3
|
-
* @return {number}
|
|
4
|
-
*/
|
|
5
|
-
var abs = Math.abs;
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* @param {number}
|
|
9
|
-
* @return {string}
|
|
10
|
-
*/
|
|
11
|
-
var from = String.fromCharCode;
|
|
12
|
-
|
|
13
|
-
/**
|
|
14
|
-
* @param {object}
|
|
15
|
-
* @return {object}
|
|
16
|
-
*/
|
|
17
|
-
var assign = Object.assign;
|
|
18
|
-
|
|
19
|
-
/**
|
|
20
|
-
* @param {string} value
|
|
21
|
-
* @param {number} length
|
|
22
|
-
* @return {number}
|
|
23
|
-
*/
|
|
24
|
-
function hash(value, length) {
|
|
25
|
-
return charat(value, 0) ^ 45 ? (((length << 2 ^ charat(value, 0)) << 2 ^ charat(value, 1)) << 2 ^ charat(value, 2)) << 2 ^ charat(value, 3) : 0;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
/**
|
|
29
|
-
* @param {string} value
|
|
30
|
-
* @return {string}
|
|
31
|
-
*/
|
|
32
|
-
function trim(value) {
|
|
33
|
-
return value.trim();
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
/**
|
|
37
|
-
* @param {string} value
|
|
38
|
-
* @param {RegExp} pattern
|
|
39
|
-
* @return {string?}
|
|
40
|
-
*/
|
|
41
|
-
function match(value, pattern) {
|
|
42
|
-
return (value = pattern.exec(value)) ? value[0] : value;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
/**
|
|
46
|
-
* @param {string} value
|
|
47
|
-
* @param {(string|RegExp)} pattern
|
|
48
|
-
* @param {string} replacement
|
|
49
|
-
* @return {string}
|
|
50
|
-
*/
|
|
51
|
-
function replace(value, pattern, replacement) {
|
|
52
|
-
return value.replace(pattern, replacement);
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
/**
|
|
56
|
-
* @param {string} value
|
|
57
|
-
* @param {string} search
|
|
58
|
-
* @return {number}
|
|
59
|
-
*/
|
|
60
|
-
function indexof(value, search) {
|
|
61
|
-
return value.indexOf(search);
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
/**
|
|
65
|
-
* @param {string} value
|
|
66
|
-
* @param {number} index
|
|
67
|
-
* @return {number}
|
|
68
|
-
*/
|
|
69
|
-
function charat(value, index) {
|
|
70
|
-
return value.charCodeAt(index) | 0;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
/**
|
|
74
|
-
* @param {string} value
|
|
75
|
-
* @param {number} begin
|
|
76
|
-
* @param {number} end
|
|
77
|
-
* @return {string}
|
|
78
|
-
*/
|
|
79
|
-
function substr(value, begin, end) {
|
|
80
|
-
return value.slice(begin, end);
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
/**
|
|
84
|
-
* @param {string} value
|
|
85
|
-
* @return {number}
|
|
86
|
-
*/
|
|
87
|
-
function strlen(value) {
|
|
88
|
-
return value.length;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
/**
|
|
92
|
-
* @param {any[]} value
|
|
93
|
-
* @return {number}
|
|
94
|
-
*/
|
|
95
|
-
function sizeof(value) {
|
|
96
|
-
return value.length;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
/**
|
|
100
|
-
* @param {any} value
|
|
101
|
-
* @param {any[]} array
|
|
102
|
-
* @return {any}
|
|
103
|
-
*/
|
|
104
|
-
function append(value, array) {
|
|
105
|
-
return array.push(value), value;
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
/**
|
|
109
|
-
* @param {string[]} array
|
|
110
|
-
* @param {function} callback
|
|
111
|
-
* @return {string}
|
|
112
|
-
*/
|
|
113
|
-
function combine(array, callback) {
|
|
114
|
-
return array.map(callback).join('');
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
/**
|
|
118
|
-
* @param {string[]} array
|
|
119
|
-
* @param {RegExp} pattern
|
|
120
|
-
* @return {string[]}
|
|
121
|
-
*/
|
|
122
|
-
function filter(array, pattern) {
|
|
123
|
-
return array.filter(function (value) {
|
|
124
|
-
return !match(value, pattern);
|
|
125
|
-
});
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
export { abs, append, assign, charat, combine, filter, from, hash, indexof, match, replace, sizeof, strlen, substr, trim };
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
/******************************************************************************
|
|
2
|
-
Copyright (c) Microsoft Corporation.
|
|
3
|
-
|
|
4
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
5
|
-
purpose with or without fee is hereby granted.
|
|
6
|
-
|
|
7
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
8
|
-
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
9
|
-
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
10
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
11
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
12
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
13
|
-
PERFORMANCE OF THIS SOFTWARE.
|
|
14
|
-
***************************************************************************** */
|
|
15
|
-
/* global Reflect, Promise, SuppressedError, Symbol */
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
var __assign = function() {
|
|
19
|
-
__assign = Object.assign || function __assign(t) {
|
|
20
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
21
|
-
s = arguments[i];
|
|
22
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
23
|
-
}
|
|
24
|
-
return t;
|
|
25
|
-
};
|
|
26
|
-
return __assign.apply(this, arguments);
|
|
27
|
-
};
|
|
28
|
-
|
|
29
|
-
function __spreadArray(to, from, pack) {
|
|
30
|
-
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
31
|
-
if (ar || !(i in from)) {
|
|
32
|
-
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
|
|
33
|
-
ar[i] = from[i];
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
return to.concat(ar || Array.prototype.slice.call(from));
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
|
|
40
|
-
var e = new Error(message);
|
|
41
|
-
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
42
|
-
};
|
|
43
|
-
|
|
44
|
-
export { __assign, __spreadArray };
|