@spaziodati/atoka-design-system 2.1.6 → 2.1.7

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.
Files changed (109) hide show
  1. package/AddableItems/index.js +1 -1050
  2. package/Alert/index.js +1 -321
  3. package/Badge/index.js +1 -285
  4. package/Bs4V3Wrapper/index.js +1 -253
  5. package/BubbleChart/index.js +2 -3424
  6. package/BubbleChart/index.js.LICENSE.txt +1 -0
  7. package/Button/index.js +1 -325
  8. package/ButtonDropdown/index.js +1 -601
  9. package/CardsPage/index.js +1 -2505
  10. package/CursorPagination/index.js +1 -948
  11. package/DatePicker/index.js +1 -449
  12. package/DetailPage/index.js +1 -1990
  13. package/Dropdown/index.js +1 -723
  14. package/EditableString/index.js +1 -3238
  15. package/EllipsableContent/index.js +1 -786
  16. package/EmptyState/index.js +1 -280
  17. package/Facet/index.js +1 -919
  18. package/FacetSection/index.js +1 -447
  19. package/FadeAnimation/index.js +1 -1157
  20. package/FeedbackButton/index.js +1 -400
  21. package/Form/index.js +1 -450
  22. package/Funnel/index.js +2 -3624
  23. package/Funnel/index.js.LICENSE.txt +1 -0
  24. package/GridCard/index.js +1 -1626
  25. package/HighlightableText/index.js +1 -625
  26. package/Histogram/index.js +1 -2346
  27. package/InlineStringEditor/index.js +1 -1862
  28. package/InputGroup/index.js +1 -279
  29. package/Jumbotron/index.js +1 -272
  30. package/Map/index.js +2 -5187
  31. package/Map/index.js.LICENSE.txt +10 -0
  32. package/Modal/index.js +1 -745
  33. package/Navbar/index.js +1 -3430
  34. package/Pagination/index.js +1 -990
  35. package/PieChart/index.js +1 -1971
  36. package/PublicFooter/index.js +1 -458
  37. package/PublicNavbar/index.js +1 -257
  38. package/RecordBit/index.js +1 -486
  39. package/ResultItemCard/index.js +1 -1073
  40. package/SelectDropdown/index.js +1 -1506
  41. package/Spinner/index.js +1 -327
  42. package/StatisticsItemCard/index.js +1 -1796
  43. package/StatisticsItemNumeric/index.js +1 -285
  44. package/StatisticsLegend/index.js +1 -1555
  45. package/StatisticsTooltip/index.js +1 -796
  46. package/Suggester/index.js +1 -1126
  47. package/SunBurst/index.js +1 -1166
  48. package/TabSwitcher/index.js +1 -1135
  49. package/Title/index.js +1 -304
  50. package/Toasts/index.js +1 -2285
  51. package/ToggleButtonGroup/index.js +1 -607
  52. package/Tooltip/index.js +1 -291
  53. package/Utils/index.js +2 -3002
  54. package/Utils/index.js.LICENSE.txt +1 -0
  55. package/{atoka-design-system-2.1.6.min.css → atoka-design-system-2.1.7.min.css} +0 -0
  56. package/index.js +2 -16819
  57. package/index.js.LICENSE.txt +10 -0
  58. package/package.json +1 -1
  59. package/AddableItems/index.js.map +0 -1
  60. package/Alert/index.js.map +0 -1
  61. package/Badge/index.js.map +0 -1
  62. package/Bs4V3Wrapper/index.js.map +0 -1
  63. package/BubbleChart/index.js.map +0 -1
  64. package/Button/index.js.map +0 -1
  65. package/ButtonDropdown/index.js.map +0 -1
  66. package/CardsPage/index.js.map +0 -1
  67. package/CursorPagination/index.js.map +0 -1
  68. package/DatePicker/index.js.map +0 -1
  69. package/DetailPage/index.js.map +0 -1
  70. package/Dropdown/index.js.map +0 -1
  71. package/EditableString/index.js.map +0 -1
  72. package/EllipsableContent/index.js.map +0 -1
  73. package/EmptyState/index.js.map +0 -1
  74. package/Facet/index.js.map +0 -1
  75. package/FacetSection/index.js.map +0 -1
  76. package/FadeAnimation/index.js.map +0 -1
  77. package/FeedbackButton/index.js.map +0 -1
  78. package/Form/index.js.map +0 -1
  79. package/Funnel/index.js.map +0 -1
  80. package/GridCard/index.js.map +0 -1
  81. package/HighlightableText/index.js.map +0 -1
  82. package/Histogram/index.js.map +0 -1
  83. package/InlineStringEditor/index.js.map +0 -1
  84. package/InputGroup/index.js.map +0 -1
  85. package/Jumbotron/index.js.map +0 -1
  86. package/Map/index.js.map +0 -1
  87. package/Modal/index.js.map +0 -1
  88. package/Navbar/index.js.map +0 -1
  89. package/Pagination/index.js.map +0 -1
  90. package/PieChart/index.js.map +0 -1
  91. package/PublicFooter/index.js.map +0 -1
  92. package/PublicNavbar/index.js.map +0 -1
  93. package/RecordBit/index.js.map +0 -1
  94. package/ResultItemCard/index.js.map +0 -1
  95. package/SelectDropdown/index.js.map +0 -1
  96. package/Spinner/index.js.map +0 -1
  97. package/StatisticsItemCard/index.js.map +0 -1
  98. package/StatisticsItemNumeric/index.js.map +0 -1
  99. package/StatisticsLegend/index.js.map +0 -1
  100. package/StatisticsTooltip/index.js.map +0 -1
  101. package/Suggester/index.js.map +0 -1
  102. package/SunBurst/index.js.map +0 -1
  103. package/TabSwitcher/index.js.map +0 -1
  104. package/Title/index.js.map +0 -1
  105. package/Toasts/index.js.map +0 -1
  106. package/ToggleButtonGroup/index.js.map +0 -1
  107. package/Tooltip/index.js.map +0 -1
  108. package/Utils/index.js.map +0 -1
  109. package/index.js.map +0 -1
@@ -1,625 +1 @@
1
- (function webpackUniversalModuleDefinition(root, factory) {
2
- if(typeof exports === 'object' && typeof module === 'object')
3
- module.exports = factory(require("classnames"), require("react"));
4
- else if(typeof define === 'function' && define.amd)
5
- define("atoka-design-system", ["classnames", "react"], factory);
6
- else if(typeof exports === 'object')
7
- exports["atoka-design-system"] = factory(require("classnames"), require("react"));
8
- else
9
- root["atoka-design-system"] = factory(root["classnames"], root["react"]);
10
- })(self, function(__WEBPACK_EXTERNAL_MODULE__8310__, __WEBPACK_EXTERNAL_MODULE__8156__) {
11
- return /******/ (() => { // webpackBootstrap
12
- /******/ "use strict";
13
- /******/ var __webpack_modules__ = ({
14
-
15
- /***/ 6627:
16
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
17
-
18
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
19
- /* harmony export */ "MR": () => (/* binding */ boundMethod)
20
- /* harmony export */ });
21
- /* unused harmony exports boundClass, default */
22
- /* harmony import */ var _babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4329);
23
-
24
-
25
- function _typeof(obj) {
26
- if (typeof Symbol === "function" && (0,_babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .Z)(Symbol.iterator) === "symbol") {
27
- _typeof = function _typeof(obj) {
28
- return (0,_babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .Z)(obj);
29
- };
30
- } else {
31
- _typeof = function _typeof(obj) {
32
- return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : (0,_babel_runtime_helpers_typeof__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .Z)(obj);
33
- };
34
- }
35
-
36
- return _typeof(obj);
37
- }
38
- /**
39
- * Return a descriptor removing the value and returning a getter
40
- * The getter will return a .bind version of the function
41
- * and memoize the result against a symbol on the instance
42
- */
43
-
44
-
45
- function boundMethod(target, key, descriptor) {
46
- var fn = descriptor.value;
47
-
48
- if (typeof fn !== 'function') {
49
- throw new TypeError("@boundMethod decorator can only be applied to methods not: ".concat(_typeof(fn)));
50
- } // In IE11 calling Object.defineProperty has a side-effect of evaluating the
51
- // getter for the property which is being replaced. This causes infinite
52
- // recursion and an "Out of stack space" error.
53
-
54
-
55
- var definingProperty = false;
56
- return {
57
- configurable: true,
58
- get: function get() {
59
- // eslint-disable-next-line no-prototype-builtins
60
- if (definingProperty || this === target.prototype || this.hasOwnProperty(key) || typeof fn !== 'function') {
61
- return fn;
62
- }
63
-
64
- var boundFn = fn.bind(this);
65
- definingProperty = true;
66
- Object.defineProperty(this, key, {
67
- configurable: true,
68
- get: function get() {
69
- return boundFn;
70
- },
71
- set: function set(value) {
72
- fn = value;
73
- delete this[key];
74
- }
75
- });
76
- definingProperty = false;
77
- return boundFn;
78
- },
79
- set: function set(value) {
80
- fn = value;
81
- }
82
- };
83
- }
84
- /**
85
- * Use boundMethod to bind all methods on the target.prototype
86
- */
87
-
88
- function boundClass(target) {
89
- // (Using reflect to get all keys including symbols)
90
- var keys; // Use Reflect if exists
91
-
92
- if (typeof Reflect !== 'undefined' && typeof Reflect.ownKeys === 'function') {
93
- keys = Reflect.ownKeys(target.prototype);
94
- } else {
95
- keys = Object.getOwnPropertyNames(target.prototype); // Use symbols if support is provided
96
-
97
- if (typeof Object.getOwnPropertySymbols === 'function') {
98
- keys = keys.concat(Object.getOwnPropertySymbols(target.prototype));
99
- }
100
- }
101
-
102
- keys.forEach(function (key) {
103
- // Ignore special case target method
104
- if (key === 'constructor') {
105
- return;
106
- }
107
-
108
- var descriptor = Object.getOwnPropertyDescriptor(target.prototype, key); // Only methods need binding
109
-
110
- if (typeof descriptor.value === 'function') {
111
- Object.defineProperty(target.prototype, key, boundMethod(target, key, descriptor));
112
- }
113
- });
114
- return target;
115
- }
116
- function autobind() {
117
- if (arguments.length === 1) {
118
- return boundClass.apply(void 0, arguments);
119
- }
120
-
121
- return boundMethod.apply(void 0, arguments);
122
- }
123
-
124
- /***/ }),
125
-
126
- /***/ 8265:
127
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
128
-
129
- // ESM COMPAT FLAG
130
- __webpack_require__.r(__webpack_exports__);
131
-
132
- // EXPORTS
133
- __webpack_require__.d(__webpack_exports__, {
134
- "HighlightableText": () => (/* reexport */ HighlightableText)
135
- });
136
-
137
- // EXTERNAL MODULE: ./node_modules/autobind-decorator/lib/esm/index.js
138
- var esm = __webpack_require__(6627);
139
- // EXTERNAL MODULE: external "classnames"
140
- var external_classnames_ = __webpack_require__(8310);
141
- var external_classnames_default = /*#__PURE__*/__webpack_require__.n(external_classnames_);
142
- // EXTERNAL MODULE: external "react"
143
- var external_react_ = __webpack_require__(8156);
144
- var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_);
145
- // EXTERNAL MODULE: ./src/components/Utils/Text.ts
146
- var Text = __webpack_require__(2394);
147
- ;// CONCATENATED MODULE: ./src/components/HighlightableText/HighlightableText.tsx
148
- var __extends = (undefined && undefined.__extends) || (function () {
149
- var extendStatics = function (d, b) {
150
- extendStatics = Object.setPrototypeOf ||
151
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
152
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
153
- return extendStatics(d, b);
154
- };
155
- return function (d, b) {
156
- if (typeof b !== "function" && b !== null)
157
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
158
- extendStatics(d, b);
159
- function __() { this.constructor = d; }
160
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
161
- };
162
- })();
163
- var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
164
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
165
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
166
- else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
167
- return c > 3 && r && Object.defineProperty(target, key, r), r;
168
- };
169
- var __metadata = (undefined && undefined.__metadata) || function (k, v) {
170
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
171
- };
172
-
173
-
174
-
175
-
176
-
177
- var HighlightableText = /** @class */ (function (_super) {
178
- __extends(HighlightableText, _super);
179
- function HighlightableText() {
180
- return _super !== null && _super.apply(this, arguments) || this;
181
- }
182
- HighlightableText.prototype.needToHighlight = function () {
183
- return !(0,Text/* isStringEmpty */.Wq)(this.props.highlighted);
184
- };
185
- HighlightableText.prototype.getParts = function () {
186
- if (typeof this.props.children != 'string') {
187
- throw Error('In this component, children have to be a string');
188
- }
189
- return (0,Text/* splitTextInParts */.ho)(this.props.highlighted, this.props.children);
190
- };
191
- HighlightableText.prototype.renderPart = function (text, index) {
192
- var _a;
193
- var isSelected = (0,Text/* isMatching */.OH)(text, this.props.highlighted), classname = external_classnames_default()('atoka-highlightable-text', this.props.size, (_a = {
194
- 'text-muted': this.props.isDisabled === true,
195
- 'bold': this.props.isBold,
196
- 'selected-text': isSelected
197
- },
198
- _a[this.props.highlightColor] = isSelected,
199
- _a)), output = text;
200
- if (isSelected) {
201
- output = external_react_default().createElement("strong", null, text);
202
- }
203
- return (external_react_default().createElement("span", { key: "".concat(text, "-").concat(index), className: classname }, output));
204
- };
205
- HighlightableText.prototype.highlightedText = function () {
206
- var parts = this.getParts();
207
- if (parts == null) {
208
- return null;
209
- }
210
- return external_react_default().createElement("span", { className: this.props.className }, parts.map(this.renderPart));
211
- };
212
- HighlightableText.prototype.render = function () {
213
- var children = this.props.children, classname = external_classnames_default()('atoka-highlightable-text', this.props.highlightColor, this.props.size, this.props.className, {
214
- 'text-muted': this.props.isDisabled === true,
215
- 'bold': this.props.isBold,
216
- });
217
- // We just need the style, which will apply on the <strong> or <b> elements
218
- if (typeof children !== 'string') {
219
- return external_react_default().createElement("span", { className: classname }, children);
220
- }
221
- if (!this.needToHighlight()) {
222
- return external_react_default().createElement("span", { className: classname }, children);
223
- }
224
- return this.highlightedText();
225
- };
226
- var _a;
227
- HighlightableText.displayName = 'HighlightableText';
228
- HighlightableText.defaultProps = {
229
- size: 'md',
230
- highlightColor: 'orange',
231
- };
232
- __decorate([
233
- esm/* boundMethod */.MR,
234
- __metadata("design:type", Function),
235
- __metadata("design:paramtypes", [String, Number]),
236
- __metadata("design:returntype", typeof (_a = typeof (external_react_default()) !== "undefined" && (external_react_default()).ReactNode) === "function" ? _a : Object)
237
- ], HighlightableText.prototype, "renderPart", null);
238
- return HighlightableText;
239
- }((external_react_default()).PureComponent));
240
-
241
-
242
- ;// CONCATENATED MODULE: ./src/components/HighlightableText/index.ts
243
-
244
-
245
-
246
- /***/ }),
247
-
248
- /***/ 2394:
249
- /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
250
-
251
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
252
- /* harmony export */ "Wq": () => (/* binding */ isStringEmpty),
253
- /* harmony export */ "OH": () => (/* binding */ isMatching),
254
- /* harmony export */ "ho": () => (/* binding */ splitTextInParts)
255
- /* harmony export */ });
256
- /* unused harmony exports slugify, estimateWordSize, ellipse, matchAndFormatRangeLabel, formatRange, ellipseAndFormat, escapeRegExp */
257
- var __values = (undefined && undefined.__values) || function(o) {
258
- var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
259
- if (m) return m.call(o);
260
- if (o && typeof o.length === "number") return {
261
- next: function () {
262
- if (o && i >= o.length) o = void 0;
263
- return { value: o && o[i++], done: !o };
264
- }
265
- };
266
- throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
267
- };
268
- var __read = (undefined && undefined.__read) || function (o, n) {
269
- var m = typeof Symbol === "function" && o[Symbol.iterator];
270
- if (!m) return o;
271
- var i = m.call(o), r, ar = [], e;
272
- try {
273
- while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
274
- }
275
- catch (error) { e = { error: error }; }
276
- finally {
277
- try {
278
- if (r && !r.done && (m = i["return"])) m.call(i);
279
- }
280
- finally { if (e) throw e.error; }
281
- }
282
- return ar;
283
- };
284
- var __spreadArray = (undefined && undefined.__spreadArray) || function (to, from, pack) {
285
- if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
286
- if (ar || !(i in from)) {
287
- if (!ar) ar = Array.prototype.slice.call(from, 0, i);
288
- ar[i] = from[i];
289
- }
290
- }
291
- return to.concat(ar || Array.prototype.slice.call(from));
292
- };
293
- function isStringEmpty(s) {
294
- if (s == null) {
295
- return true;
296
- }
297
- return s.match(/^\s*$/) !== null;
298
- }
299
- function slugify(text) {
300
- var a = 'àáâäæãåāăąçćčđďèéêëēėęěğǵḧîïíīįìłḿñńǹňôöòóœøōõőṕŕřßśšşșťțûüùúūǘůűųẃẍÿýžźż·/_,:;', b = 'aaaaaaaaaacccddeeeeeeeegghiiiiiilmnnnnoooooooooprrsssssttuuuuuuuuuwxyyzzz------', p = new RegExp(a.split('').join('|'), 'g');
301
- return text
302
- .toString()
303
- .toLowerCase()
304
- .replace(/\s+/g, '-') // Replace spaces with -
305
- .replace(p, function (c) { return b.charAt(a.indexOf(c)); }) // Replace special characters
306
- .replace(/&/g, '-and-') // Replace & with 'and'
307
- .replace(/[^\w-]+/g, '') // Remove all non-word characters
308
- .replace(/--+/g, '-') // Replace multiple - with single -
309
- .replace(/^-+/, '') // Trim - from start of text
310
- .replace(/-+$/, ''); // Trim - from end of text
311
- }
312
- function estimateWordSize(wordLength, letterPixels, constant) {
313
- return wordLength * letterPixels + constant;
314
- }
315
- function ellipse(input, length) {
316
- if (input == null) {
317
- return '';
318
- }
319
- return input.length > length ? "".concat(input.substr(0, length - 1), "\u2026") : input;
320
- }
321
- function matchAndFormatRangeLabel(formatter) {
322
- return function (label) {
323
- var match = /^([\d*]+)-([\d*]+)$/.exec(label);
324
- if (match == null) {
325
- return label;
326
- }
327
- return formatRange({
328
- from: match[1],
329
- to: match[2],
330
- }, formatter !== null && formatter !== void 0 ? formatter : (function (v) { return v; }));
331
- };
332
- }
333
- function formatRange(item, formatter) {
334
- var _a, _b;
335
- var to = item.to === '*' ? '*' : formatter(parseInt((_a = item.to) !== null && _a !== void 0 ? _a : '0', 10)), from = formatter(parseInt((_b = item.from) !== null && _b !== void 0 ? _b : '0', 10));
336
- if (from === to) {
337
- return "".concat(from);
338
- }
339
- return "".concat(from, " - ").concat(to);
340
- }
341
- function ellipseAndFormat(formatter, maxLabelLength) {
342
- return function (value) {
343
- var strValue = value.toString();
344
- if (formatter == null) {
345
- return ellipse(strValue, maxLabelLength);
346
- }
347
- return ellipse("".concat(formatter(strValue)), maxLabelLength);
348
- };
349
- }
350
- function escapeRegExp(input) {
351
- // eslint-disable-next-line
352
- return input.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, '\\$&');
353
- }
354
- function isMatching(text0, text1) {
355
- var e_1, _a;
356
- if (text0 == null || text1 == null) {
357
- return false;
358
- }
359
- text0 = text0.toLowerCase();
360
- text1 = text1.toLowerCase();
361
- if (text1.match(' ') === null) {
362
- return text0.match(escapeRegExp(text1)) !== null;
363
- }
364
- var splitNeedles = text1
365
- .split(' ')
366
- .filter(function (s) { return !isStringEmpty(s); })
367
- .sort(function (a, b) { return b.length - a.length; });
368
- try {
369
- for (var splitNeedles_1 = __values(splitNeedles), splitNeedles_1_1 = splitNeedles_1.next(); !splitNeedles_1_1.done; splitNeedles_1_1 = splitNeedles_1.next()) {
370
- var needle = splitNeedles_1_1.value;
371
- if (text0 === needle) {
372
- return true;
373
- }
374
- }
375
- }
376
- catch (e_1_1) { e_1 = { error: e_1_1 }; }
377
- finally {
378
- try {
379
- if (splitNeedles_1_1 && !splitNeedles_1_1.done && (_a = splitNeedles_1.return)) _a.call(splitNeedles_1);
380
- }
381
- finally { if (e_1) throw e_1.error; }
382
- }
383
- return false;
384
- }
385
- function splitTextInParts(needles, text) {
386
- var e_2, _a;
387
- if (text == null) {
388
- return [];
389
- }
390
- if (needles.match(' ') === null) {
391
- var re = new RegExp('(' + escapeRegExp(needles) + ')', 'gi');
392
- return text.split(re);
393
- }
394
- var splitNeedles = needles
395
- .split(' ')
396
- .filter(function (s) { return !isStringEmpty(s); })
397
- .sort(function (a, b) { return b.length - a.length; }), ret = [text];
398
- try {
399
- for (var splitNeedles_2 = __values(splitNeedles), splitNeedles_2_1 = splitNeedles_2.next(); !splitNeedles_2_1.done; splitNeedles_2_1 = splitNeedles_2.next()) {
400
- var needle = splitNeedles_2_1.value;
401
- var re = new RegExp('(' + needle + ')', 'gi');
402
- for (var index = 0; index < ret.length; index++) {
403
- var currentText = ret[index];
404
- if (isMatching(currentText, escapeRegExp(needles))) {
405
- continue;
406
- }
407
- var newParts = currentText.split(re).filter(function (s) { return s !== ''; });
408
- ret.splice.apply(ret, __spreadArray([index, 1], __read(newParts), false));
409
- }
410
- }
411
- }
412
- catch (e_2_1) { e_2 = { error: e_2_1 }; }
413
- finally {
414
- try {
415
- if (splitNeedles_2_1 && !splitNeedles_2_1.done && (_a = splitNeedles_2.return)) _a.call(splitNeedles_2);
416
- }
417
- finally { if (e_2) throw e_2.error; }
418
- }
419
- return ret;
420
- }
421
-
422
-
423
- /***/ }),
424
-
425
- /***/ 8310:
426
- /***/ ((module) => {
427
-
428
- module.exports = __WEBPACK_EXTERNAL_MODULE__8310__;
429
-
430
- /***/ }),
431
-
432
- /***/ 8156:
433
- /***/ ((module) => {
434
-
435
- module.exports = __WEBPACK_EXTERNAL_MODULE__8156__;
436
-
437
- /***/ }),
438
-
439
- /***/ 4329:
440
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
441
-
442
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
443
- /* harmony export */ "Z": () => (/* binding */ _typeof)
444
- /* harmony export */ });
445
- function _typeof(obj) {
446
- "@babel/helpers - typeof";
447
-
448
- return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
449
- return typeof obj;
450
- } : function (obj) {
451
- return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
452
- }, _typeof(obj);
453
- }
454
-
455
- /***/ })
456
-
457
- /******/ });
458
- /************************************************************************/
459
- /******/ // The module cache
460
- /******/ var __webpack_module_cache__ = {};
461
- /******/
462
- /******/ // The require function
463
- /******/ function __webpack_require__(moduleId) {
464
- /******/ // Check if module is in cache
465
- /******/ var cachedModule = __webpack_module_cache__[moduleId];
466
- /******/ if (cachedModule !== undefined) {
467
- /******/ return cachedModule.exports;
468
- /******/ }
469
- /******/ // Create a new module (and put it into the cache)
470
- /******/ var module = __webpack_module_cache__[moduleId] = {
471
- /******/ // no module.id needed
472
- /******/ // no module.loaded needed
473
- /******/ exports: {}
474
- /******/ };
475
- /******/
476
- /******/ // Execute the module function
477
- /******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
478
- /******/
479
- /******/ // Return the exports of the module
480
- /******/ return module.exports;
481
- /******/ }
482
- /******/
483
- /******/ // expose the modules object (__webpack_modules__)
484
- /******/ __webpack_require__.m = __webpack_modules__;
485
- /******/
486
- /************************************************************************/
487
- /******/ /* webpack/runtime/chunk loaded */
488
- /******/ (() => {
489
- /******/ var deferred = [];
490
- /******/ __webpack_require__.O = (result, chunkIds, fn, priority) => {
491
- /******/ if(chunkIds) {
492
- /******/ priority = priority || 0;
493
- /******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];
494
- /******/ deferred[i] = [chunkIds, fn, priority];
495
- /******/ return;
496
- /******/ }
497
- /******/ var notFulfilled = Infinity;
498
- /******/ for (var i = 0; i < deferred.length; i++) {
499
- /******/ var [chunkIds, fn, priority] = deferred[i];
500
- /******/ var fulfilled = true;
501
- /******/ for (var j = 0; j < chunkIds.length; j++) {
502
- /******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {
503
- /******/ chunkIds.splice(j--, 1);
504
- /******/ } else {
505
- /******/ fulfilled = false;
506
- /******/ if(priority < notFulfilled) notFulfilled = priority;
507
- /******/ }
508
- /******/ }
509
- /******/ if(fulfilled) {
510
- /******/ deferred.splice(i--, 1)
511
- /******/ var r = fn();
512
- /******/ if (r !== undefined) result = r;
513
- /******/ }
514
- /******/ }
515
- /******/ return result;
516
- /******/ };
517
- /******/ })();
518
- /******/
519
- /******/ /* webpack/runtime/compat get default export */
520
- /******/ (() => {
521
- /******/ // getDefaultExport function for compatibility with non-harmony modules
522
- /******/ __webpack_require__.n = (module) => {
523
- /******/ var getter = module && module.__esModule ?
524
- /******/ () => (module['default']) :
525
- /******/ () => (module);
526
- /******/ __webpack_require__.d(getter, { a: getter });
527
- /******/ return getter;
528
- /******/ };
529
- /******/ })();
530
- /******/
531
- /******/ /* webpack/runtime/define property getters */
532
- /******/ (() => {
533
- /******/ // define getter functions for harmony exports
534
- /******/ __webpack_require__.d = (exports, definition) => {
535
- /******/ for(var key in definition) {
536
- /******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
537
- /******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
538
- /******/ }
539
- /******/ }
540
- /******/ };
541
- /******/ })();
542
- /******/
543
- /******/ /* webpack/runtime/hasOwnProperty shorthand */
544
- /******/ (() => {
545
- /******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
546
- /******/ })();
547
- /******/
548
- /******/ /* webpack/runtime/make namespace object */
549
- /******/ (() => {
550
- /******/ // define __esModule on exports
551
- /******/ __webpack_require__.r = (exports) => {
552
- /******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
553
- /******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
554
- /******/ }
555
- /******/ Object.defineProperty(exports, '__esModule', { value: true });
556
- /******/ };
557
- /******/ })();
558
- /******/
559
- /******/ /* webpack/runtime/jsonp chunk loading */
560
- /******/ (() => {
561
- /******/ // no baseURI
562
- /******/
563
- /******/ // object to store loaded and loading chunks
564
- /******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched
565
- /******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded
566
- /******/ var installedChunks = {
567
- /******/ 4953: 0,
568
- /******/ 5785: 0
569
- /******/ };
570
- /******/
571
- /******/ // no chunk on demand loading
572
- /******/
573
- /******/ // no prefetching
574
- /******/
575
- /******/ // no preloaded
576
- /******/
577
- /******/ // no HMR
578
- /******/
579
- /******/ // no HMR manifest
580
- /******/
581
- /******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);
582
- /******/
583
- /******/ // install a JSONP callback for chunk loading
584
- /******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => {
585
- /******/ var [chunkIds, moreModules, runtime] = data;
586
- /******/ // add "moreModules" to the modules object,
587
- /******/ // then flag all "chunkIds" as loaded and fire callback
588
- /******/ var moduleId, chunkId, i = 0;
589
- /******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) {
590
- /******/ for(moduleId in moreModules) {
591
- /******/ if(__webpack_require__.o(moreModules, moduleId)) {
592
- /******/ __webpack_require__.m[moduleId] = moreModules[moduleId];
593
- /******/ }
594
- /******/ }
595
- /******/ if(runtime) var result = runtime(__webpack_require__);
596
- /******/ }
597
- /******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data);
598
- /******/ for(;i < chunkIds.length; i++) {
599
- /******/ chunkId = chunkIds[i];
600
- /******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {
601
- /******/ installedChunks[chunkId][0]();
602
- /******/ }
603
- /******/ installedChunks[chunkIds[i]] = 0;
604
- /******/ }
605
- /******/ return __webpack_require__.O(result);
606
- /******/ }
607
- /******/
608
- /******/ var chunkLoadingGlobal = self["webpackChunkatoka_design_system"] = self["webpackChunkatoka_design_system"] || [];
609
- /******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));
610
- /******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));
611
- /******/ })();
612
- /******/
613
- /************************************************************************/
614
- /******/
615
- /******/ // startup
616
- /******/ // Load entry module and return exports
617
- /******/ // This entry module depends on other loaded chunks and execution need to be delayed
618
- /******/ var __webpack_exports__ = __webpack_require__.O(undefined, [5785], () => (__webpack_require__(8265)))
619
- /******/ __webpack_exports__ = __webpack_require__.O(__webpack_exports__);
620
- /******/
621
- /******/ return __webpack_exports__;
622
- /******/ })()
623
- ;
624
- });
625
- //# sourceMappingURL=index.js.map
1
+ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("classnames"),require("react")):"function"==typeof define&&define.amd?define("atoka-design-system",["classnames","react"],e):"object"==typeof exports?exports["atoka-design-system"]=e(require("classnames"),require("react")):t["atoka-design-system"]=e(t.classnames,t.react)}(self,(function(t,e){return(()=>{"use strict";var r,n={6627:(t,e,r)=>{r.d(e,{MR:()=>i});var n=r(4329);function o(t){return o="function"==typeof Symbol&&"symbol"===(0,n.Z)(Symbol.iterator)?function(t){return(0,n.Z)(t)}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":(0,n.Z)(t)},o(t)}function i(t,e,r){var n=r.value;if("function"!=typeof n)throw new TypeError("@boundMethod decorator can only be applied to methods not: ".concat(o(n)));var i=!1;return{configurable:!0,get:function(){if(i||this===t.prototype||this.hasOwnProperty(e)||"function"!=typeof n)return n;var r=n.bind(this);return i=!0,Object.defineProperty(this,e,{configurable:!0,get:function(){return r},set:function(t){n=t,delete this[e]}}),i=!1,r},set:function(t){n=t}}}},8265:(t,e,r)=>{r.r(e),r.d(e,{HighlightableText:()=>h});var n,o=r(6627),i=r(8310),l=r.n(i),a=r(8156),s=r.n(a),u=r(2394),c=(n=function(t,e){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])},n(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}),f=function(t,e,r,n){var o,i=arguments.length,l=i<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)l=Reflect.decorate(t,e,r,n);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(l=(i<3?o(l):i>3?o(e,r,l):o(e,r))||l);return i>3&&l&&Object.defineProperty(e,r,l),l},p=function(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)},h=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}var r;return c(e,t),e.prototype.needToHighlight=function(){return!(0,u.Wq)(this.props.highlighted)},e.prototype.getParts=function(){if("string"!=typeof this.props.children)throw Error("In this component, children have to be a string");return(0,u.ho)(this.props.highlighted,this.props.children)},e.prototype.renderPart=function(t,e){var r,n=(0,u.OH)(t,this.props.highlighted),o=l()("atoka-highlightable-text",this.props.size,((r={"text-muted":!0===this.props.isDisabled,bold:this.props.isBold,"selected-text":n})[this.props.highlightColor]=n,r)),i=t;return n&&(i=s().createElement("strong",null,t)),s().createElement("span",{key:"".concat(t,"-").concat(e),className:o},i)},e.prototype.highlightedText=function(){var t=this.getParts();return null==t?null:s().createElement("span",{className:this.props.className},t.map(this.renderPart))},e.prototype.render=function(){var t=this.props.children,e=l()("atoka-highlightable-text",this.props.highlightColor,this.props.size,this.props.className,{"text-muted":!0===this.props.isDisabled,bold:this.props.isBold});return"string"!=typeof t?s().createElement("span",{className:e},t):this.needToHighlight()?this.highlightedText():s().createElement("span",{className:e},t)},e.displayName="HighlightableText",e.defaultProps={size:"md",highlightColor:"orange"},f([o.MR,p("design:type",Function),p("design:paramtypes",[String,Number]),p("design:returntype","function"==typeof(r=void 0!==s()&&s().ReactNode)?r:Object)],e.prototype,"renderPart",null),e}(s().PureComponent)},2394:(t,e,r)=>{r.d(e,{Wq:()=>l,OH:()=>s,ho:()=>u});var n=function(t){var e="function"==typeof Symbol&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},o=function(t,e){var r="function"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var n,o,i=r.call(t),l=[];try{for(;(void 0===e||e-- >0)&&!(n=i.next()).done;)l.push(n.value)}catch(t){o={error:t}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return l},i=function(t,e,r){if(r||2===arguments.length)for(var n,o=0,i=e.length;o<i;o++)!n&&o in e||(n||(n=Array.prototype.slice.call(e,0,o)),n[o]=e[o]);return t.concat(n||Array.prototype.slice.call(e))};function l(t){return null==t||null!==t.match(/^\s*$/)}function a(t){return t.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}function s(t,e){var r,o;if(null==t||null==e)return!1;if(t=t.toLowerCase(),null===(e=e.toLowerCase()).match(" "))return null!==t.match(a(e));var i=e.split(" ").filter((function(t){return!l(t)})).sort((function(t,e){return e.length-t.length}));try{for(var s=n(i),u=s.next();!u.done;u=s.next()){if(t===u.value)return!0}}catch(t){r={error:t}}finally{try{u&&!u.done&&(o=s.return)&&o.call(s)}finally{if(r)throw r.error}}return!1}function u(t,e){var r,u;if(null==e)return[];if(null===t.match(" ")){var c=new RegExp("("+a(t)+")","gi");return e.split(c)}var f=t.split(" ").filter((function(t){return!l(t)})).sort((function(t,e){return e.length-t.length})),p=[e];try{for(var h=n(f),y=h.next();!y.done;y=h.next())for(var d=y.value,g=(c=new RegExp("("+d+")","gi"),0);g<p.length;g++){var m=p[g];if(!s(m,a(t))){var b=m.split(c).filter((function(t){return""!==t}));p.splice.apply(p,i([g,1],o(b),!1))}}}catch(t){r={error:t}}finally{try{y&&!y.done&&(u=h.return)&&u.call(h)}finally{if(r)throw r.error}}return p}},8310:e=>{e.exports=t},8156:t=>{t.exports=e},4329:(t,e,r)=>{function n(t){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n(t)}r.d(e,{Z:()=>n})}},o={};function i(t){var e=o[t];if(void 0!==e)return e.exports;var r=o[t]={exports:{}};return n[t](r,r.exports,i),r.exports}i.m=n,r=[],i.O=(t,e,n,o)=>{if(!e){var l=1/0;for(c=0;c<r.length;c++){for(var[e,n,o]=r[c],a=!0,s=0;s<e.length;s++)(!1&o||l>=o)&&Object.keys(i.O).every((t=>i.O[t](e[s])))?e.splice(s--,1):(a=!1,o<l&&(l=o));if(a){r.splice(c--,1);var u=n();void 0!==u&&(t=u)}}return t}o=o||0;for(var c=r.length;c>0&&r[c-1][2]>o;c--)r[c]=r[c-1];r[c]=[e,n,o]},i.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return i.d(e,{a:e}),e},i.d=(t,e)=>{for(var r in e)i.o(e,r)&&!i.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},i.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),i.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},(()=>{var t={4953:0,8699:0};i.O.j=e=>0===t[e];var e=(e,r)=>{var n,o,[l,a,s]=r,u=0;if(l.some((e=>0!==t[e]))){for(n in a)i.o(a,n)&&(i.m[n]=a[n]);if(s)var c=s(i)}for(e&&e(r);u<l.length;u++)o=l[u],i.o(t,o)&&t[o]&&t[o][0](),t[l[u]]=0;return i.O(c)},r=self.webpackChunkatoka_design_system=self.webpackChunkatoka_design_system||[];r.forEach(e.bind(null,0)),r.push=e.bind(null,r.push.bind(r))})();var l=i.O(void 0,[8699],(()=>i(8265)));return l=i.O(l)})()}));