opus-toolkit-components 0.1.6 → 0.1.8

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.
@@ -1,689 +0,0 @@
1
- (function webpackUniversalModuleDefinition(root, factory) {
2
- if(typeof exports === 'object' && typeof module === 'object')
3
- module.exports = factory(require("react"));
4
- else if(typeof define === 'function' && define.amd)
5
- define("opus-components", ["react"], factory);
6
- else if(typeof exports === 'object')
7
- exports["opus-components"] = factory(require("react"));
8
- else
9
- root["opus-components"] = factory(root["react"]);
10
- })(self, (__WEBPACK_EXTERNAL_MODULE__155__) => {
11
- return /******/ (() => { // webpackBootstrap
12
- /******/ "use strict";
13
- /******/ var __webpack_modules__ = ({
14
-
15
- /***/ 250:
16
- /***/ ((module, __webpack_exports__, __webpack_require__) => {
17
-
18
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
19
- /* harmony export */ A: () => (__WEBPACK_DEFAULT_EXPORT__)
20
- /* harmony export */ });
21
- /* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(354);
22
- /* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
23
- /* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(314);
24
- /* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
25
- // Imports
26
-
27
-
28
- var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
29
- // Module
30
- ___CSS_LOADER_EXPORT___.push([module.id, `.primary-btn{background:#e23193;color:#fff}.primary-btn:hover{background:#005de5}.secondary-btn{background:#005de5;color:#fff}.secondary-btn:hover{background:#e23193}.outline-btn{background:none;border:2px solid #fff;color:#fff}.outline-btn:hover{background:#e23193;border-color:#e23193}`, "",{"version":3,"sources":["webpack://./src/components/Buttons/_button.scss","webpack://./node_modules/opus-toolkit-styles/fragments/_colours.scss"],"names":[],"mappings":"AAoBA,aACI,kBCEO,CDDP,UAhBS,CAKX,mBACE,kBCSO,CDMX,eACI,kBCPO,CDQP,UAvBS,CAKX,qBACE,kBCWO,CDWX,aACI,eAAA,CACA,qBAAA,CACA,UA/BS,CAKX,mBACE,kBCWO,CDTL,oBCSK","sourcesContent":["@import 'opus-toolkit-styles/fragments/colours';\r\n// Define color variables\r\n$primary-color: $c247Pink;\r\n$primary-hover-color: $c247Blue;\r\n$secondary-color: $c247Blue;\r\n$hover-color: $c247Pink;\r\n$text-color: white;\r\n$outline-border-color: white;\r\n\r\n// Create a mixin for hover effects to avoid repetition\r\n@mixin hover-effect($hover-bg, $hover-border: null) {\r\n &:hover {\r\n background: $hover-bg;\r\n @if $hover-border {\r\n border-color: $hover-border;\r\n }\r\n }\r\n}\r\n\r\n// Primary button styles\r\n.primary-btn {\r\n background: $primary-color;\r\n color: $text-color;\r\n @include hover-effect($primary-hover-color);\r\n}\r\n\r\n// Secondary button styles\r\n.secondary-btn {\r\n background: $secondary-color;\r\n color: $text-color;\r\n @include hover-effect($hover-color);\r\n}\r\n\r\n// Outline button styles\r\n.outline-btn {\r\n background: none;\r\n border: 2px solid $outline-border-color;\r\n color: $text-color;\r\n @include hover-effect($hover-color, $hover-color);\r\n}","// Foundation Brand colors\r\n$opusDeepBlue: #0c022f;\r\n$opusNavy: #24135f;\r\n$opusRichBlue: #003494;\r\n\r\n// Grey/Blue Scale\r\n$opusDarkest: #07011c;\r\n$opusGrey800: #1b1f51;\r\n$opusGrey700: #444877;\r\n$opusGrey600: #8b8fac;\r\n$opusGrey400: #e3e4eb;\r\n$opusGrey200: #f8f8fb;\r\n$opusWhite: #ffffff;\r\n\r\n// Brand Colours\r\n$opusLightBlue: #005de5;\r\n$opusBrandBlue: #0176d9;\r\n$opusPurple: #451f88;\r\n$opusPink: #e05db4;\r\n\r\n// C247 Colours\r\n$c247Blue: #005de5;\r\n$c247Purple: #ad43c4;\r\n$c247Pink: #e23193;\r\n\r\n// Utility Colours\r\n$danger: #bb0808;\r\n$success: #27be36;"],"sourceRoot":""}]);
31
- // Exports
32
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
33
-
34
-
35
- /***/ }),
36
-
37
- /***/ 865:
38
- /***/ ((module, __webpack_exports__, __webpack_require__) => {
39
-
40
- /* harmony export */ __webpack_require__.d(__webpack_exports__, {
41
- /* harmony export */ A: () => (__WEBPACK_DEFAULT_EXPORT__)
42
- /* harmony export */ });
43
- /* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(354);
44
- /* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
45
- /* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(314);
46
- /* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
47
- // Imports
48
-
49
-
50
- var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
51
- // Module
52
- ___CSS_LOADER_EXPORT___.push([module.id, `.dark-card{background-color:#24135f;color:#fff}.light-card{background-color:#fff;color:#0c022f}`, "",{"version":3,"sources":["webpack://./src/components/Cards/card.scss"],"names":[],"mappings":"AAGA,WACI,wBAHO,CAIP,UAAA,CAEJ,YACI,qBAAA,CACA,aATW","sourcesContent":["$opusDeepBlue: #0c022f;\r\n$opusNavy: #24135f;\r\n\r\n.dark-card {\r\n background-color: $opusNavy;\r\n color: white;\r\n}\r\n.light-card {\r\n background-color: white;\r\n color: $opusDeepBlue;\r\n}"],"sourceRoot":""}]);
53
- // Exports
54
- /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
55
-
56
-
57
- /***/ }),
58
-
59
- /***/ 314:
60
- /***/ ((module) => {
61
-
62
-
63
-
64
- /*
65
- MIT License http://www.opensource.org/licenses/mit-license.php
66
- Author Tobias Koppers @sokra
67
- */
68
- module.exports = function (cssWithMappingToString) {
69
- var list = [];
70
-
71
- // return the list of modules as css string
72
- list.toString = function toString() {
73
- return this.map(function (item) {
74
- var content = "";
75
- var needLayer = typeof item[5] !== "undefined";
76
- if (item[4]) {
77
- content += "@supports (".concat(item[4], ") {");
78
- }
79
- if (item[2]) {
80
- content += "@media ".concat(item[2], " {");
81
- }
82
- if (needLayer) {
83
- content += "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {");
84
- }
85
- content += cssWithMappingToString(item);
86
- if (needLayer) {
87
- content += "}";
88
- }
89
- if (item[2]) {
90
- content += "}";
91
- }
92
- if (item[4]) {
93
- content += "}";
94
- }
95
- return content;
96
- }).join("");
97
- };
98
-
99
- // import a list of modules into the list
100
- list.i = function i(modules, media, dedupe, supports, layer) {
101
- if (typeof modules === "string") {
102
- modules = [[null, modules, undefined]];
103
- }
104
- var alreadyImportedModules = {};
105
- if (dedupe) {
106
- for (var k = 0; k < this.length; k++) {
107
- var id = this[k][0];
108
- if (id != null) {
109
- alreadyImportedModules[id] = true;
110
- }
111
- }
112
- }
113
- for (var _k = 0; _k < modules.length; _k++) {
114
- var item = [].concat(modules[_k]);
115
- if (dedupe && alreadyImportedModules[item[0]]) {
116
- continue;
117
- }
118
- if (typeof layer !== "undefined") {
119
- if (typeof item[5] === "undefined") {
120
- item[5] = layer;
121
- } else {
122
- item[1] = "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {").concat(item[1], "}");
123
- item[5] = layer;
124
- }
125
- }
126
- if (media) {
127
- if (!item[2]) {
128
- item[2] = media;
129
- } else {
130
- item[1] = "@media ".concat(item[2], " {").concat(item[1], "}");
131
- item[2] = media;
132
- }
133
- }
134
- if (supports) {
135
- if (!item[4]) {
136
- item[4] = "".concat(supports);
137
- } else {
138
- item[1] = "@supports (".concat(item[4], ") {").concat(item[1], "}");
139
- item[4] = supports;
140
- }
141
- }
142
- list.push(item);
143
- }
144
- };
145
- return list;
146
- };
147
-
148
- /***/ }),
149
-
150
- /***/ 354:
151
- /***/ ((module) => {
152
-
153
-
154
-
155
- module.exports = function (item) {
156
- var content = item[1];
157
- var cssMapping = item[3];
158
- if (!cssMapping) {
159
- return content;
160
- }
161
- if (typeof btoa === "function") {
162
- var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(cssMapping))));
163
- var data = "sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(base64);
164
- var sourceMapping = "/*# ".concat(data, " */");
165
- return [content].concat([sourceMapping]).join("\n");
166
- }
167
- return [content].join("\n");
168
- };
169
-
170
- /***/ }),
171
-
172
- /***/ 72:
173
- /***/ ((module) => {
174
-
175
-
176
-
177
- var stylesInDOM = [];
178
- function getIndexByIdentifier(identifier) {
179
- var result = -1;
180
- for (var i = 0; i < stylesInDOM.length; i++) {
181
- if (stylesInDOM[i].identifier === identifier) {
182
- result = i;
183
- break;
184
- }
185
- }
186
- return result;
187
- }
188
- function modulesToDom(list, options) {
189
- var idCountMap = {};
190
- var identifiers = [];
191
- for (var i = 0; i < list.length; i++) {
192
- var item = list[i];
193
- var id = options.base ? item[0] + options.base : item[0];
194
- var count = idCountMap[id] || 0;
195
- var identifier = "".concat(id, " ").concat(count);
196
- idCountMap[id] = count + 1;
197
- var indexByIdentifier = getIndexByIdentifier(identifier);
198
- var obj = {
199
- css: item[1],
200
- media: item[2],
201
- sourceMap: item[3],
202
- supports: item[4],
203
- layer: item[5]
204
- };
205
- if (indexByIdentifier !== -1) {
206
- stylesInDOM[indexByIdentifier].references++;
207
- stylesInDOM[indexByIdentifier].updater(obj);
208
- } else {
209
- var updater = addElementStyle(obj, options);
210
- options.byIndex = i;
211
- stylesInDOM.splice(i, 0, {
212
- identifier: identifier,
213
- updater: updater,
214
- references: 1
215
- });
216
- }
217
- identifiers.push(identifier);
218
- }
219
- return identifiers;
220
- }
221
- function addElementStyle(obj, options) {
222
- var api = options.domAPI(options);
223
- api.update(obj);
224
- var updater = function updater(newObj) {
225
- if (newObj) {
226
- if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap && newObj.supports === obj.supports && newObj.layer === obj.layer) {
227
- return;
228
- }
229
- api.update(obj = newObj);
230
- } else {
231
- api.remove();
232
- }
233
- };
234
- return updater;
235
- }
236
- module.exports = function (list, options) {
237
- options = options || {};
238
- list = list || [];
239
- var lastIdentifiers = modulesToDom(list, options);
240
- return function update(newList) {
241
- newList = newList || [];
242
- for (var i = 0; i < lastIdentifiers.length; i++) {
243
- var identifier = lastIdentifiers[i];
244
- var index = getIndexByIdentifier(identifier);
245
- stylesInDOM[index].references--;
246
- }
247
- var newLastIdentifiers = modulesToDom(newList, options);
248
- for (var _i = 0; _i < lastIdentifiers.length; _i++) {
249
- var _identifier = lastIdentifiers[_i];
250
- var _index = getIndexByIdentifier(_identifier);
251
- if (stylesInDOM[_index].references === 0) {
252
- stylesInDOM[_index].updater();
253
- stylesInDOM.splice(_index, 1);
254
- }
255
- }
256
- lastIdentifiers = newLastIdentifiers;
257
- };
258
- };
259
-
260
- /***/ }),
261
-
262
- /***/ 659:
263
- /***/ ((module) => {
264
-
265
-
266
-
267
- var memo = {};
268
-
269
- /* istanbul ignore next */
270
- function getTarget(target) {
271
- if (typeof memo[target] === "undefined") {
272
- var styleTarget = document.querySelector(target);
273
-
274
- // Special case to return head of iframe instead of iframe itself
275
- if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {
276
- try {
277
- // This will throw an exception if access to iframe is blocked
278
- // due to cross-origin restrictions
279
- styleTarget = styleTarget.contentDocument.head;
280
- } catch (e) {
281
- // istanbul ignore next
282
- styleTarget = null;
283
- }
284
- }
285
- memo[target] = styleTarget;
286
- }
287
- return memo[target];
288
- }
289
-
290
- /* istanbul ignore next */
291
- function insertBySelector(insert, style) {
292
- var target = getTarget(insert);
293
- if (!target) {
294
- throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");
295
- }
296
- target.appendChild(style);
297
- }
298
- module.exports = insertBySelector;
299
-
300
- /***/ }),
301
-
302
- /***/ 540:
303
- /***/ ((module) => {
304
-
305
-
306
-
307
- /* istanbul ignore next */
308
- function insertStyleElement(options) {
309
- var element = document.createElement("style");
310
- options.setAttributes(element, options.attributes);
311
- options.insert(element, options.options);
312
- return element;
313
- }
314
- module.exports = insertStyleElement;
315
-
316
- /***/ }),
317
-
318
- /***/ 56:
319
- /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
320
-
321
-
322
-
323
- /* istanbul ignore next */
324
- function setAttributesWithoutAttributes(styleElement) {
325
- var nonce = true ? __webpack_require__.nc : 0;
326
- if (nonce) {
327
- styleElement.setAttribute("nonce", nonce);
328
- }
329
- }
330
- module.exports = setAttributesWithoutAttributes;
331
-
332
- /***/ }),
333
-
334
- /***/ 825:
335
- /***/ ((module) => {
336
-
337
-
338
-
339
- /* istanbul ignore next */
340
- function apply(styleElement, options, obj) {
341
- var css = "";
342
- if (obj.supports) {
343
- css += "@supports (".concat(obj.supports, ") {");
344
- }
345
- if (obj.media) {
346
- css += "@media ".concat(obj.media, " {");
347
- }
348
- var needLayer = typeof obj.layer !== "undefined";
349
- if (needLayer) {
350
- css += "@layer".concat(obj.layer.length > 0 ? " ".concat(obj.layer) : "", " {");
351
- }
352
- css += obj.css;
353
- if (needLayer) {
354
- css += "}";
355
- }
356
- if (obj.media) {
357
- css += "}";
358
- }
359
- if (obj.supports) {
360
- css += "}";
361
- }
362
- var sourceMap = obj.sourceMap;
363
- if (sourceMap && typeof btoa !== "undefined") {
364
- css += "\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), " */");
365
- }
366
-
367
- // For old IE
368
- /* istanbul ignore if */
369
- options.styleTagTransform(css, styleElement, options.options);
370
- }
371
- function removeStyleElement(styleElement) {
372
- // istanbul ignore if
373
- if (styleElement.parentNode === null) {
374
- return false;
375
- }
376
- styleElement.parentNode.removeChild(styleElement);
377
- }
378
-
379
- /* istanbul ignore next */
380
- function domAPI(options) {
381
- if (typeof document === "undefined") {
382
- return {
383
- update: function update() {},
384
- remove: function remove() {}
385
- };
386
- }
387
- var styleElement = options.insertStyleElement(options);
388
- return {
389
- update: function update(obj) {
390
- apply(styleElement, options, obj);
391
- },
392
- remove: function remove() {
393
- removeStyleElement(styleElement);
394
- }
395
- };
396
- }
397
- module.exports = domAPI;
398
-
399
- /***/ }),
400
-
401
- /***/ 113:
402
- /***/ ((module) => {
403
-
404
-
405
-
406
- /* istanbul ignore next */
407
- function styleTagTransform(css, styleElement) {
408
- if (styleElement.styleSheet) {
409
- styleElement.styleSheet.cssText = css;
410
- } else {
411
- while (styleElement.firstChild) {
412
- styleElement.removeChild(styleElement.firstChild);
413
- }
414
- styleElement.appendChild(document.createTextNode(css));
415
- }
416
- }
417
- module.exports = styleTagTransform;
418
-
419
- /***/ }),
420
-
421
- /***/ 155:
422
- /***/ ((module) => {
423
-
424
- module.exports = __WEBPACK_EXTERNAL_MODULE__155__;
425
-
426
- /***/ })
427
-
428
- /******/ });
429
- /************************************************************************/
430
- /******/ // The module cache
431
- /******/ var __webpack_module_cache__ = {};
432
- /******/
433
- /******/ // The require function
434
- /******/ function __webpack_require__(moduleId) {
435
- /******/ // Check if module is in cache
436
- /******/ var cachedModule = __webpack_module_cache__[moduleId];
437
- /******/ if (cachedModule !== undefined) {
438
- /******/ return cachedModule.exports;
439
- /******/ }
440
- /******/ // Create a new module (and put it into the cache)
441
- /******/ var module = __webpack_module_cache__[moduleId] = {
442
- /******/ id: moduleId,
443
- /******/ // no module.loaded needed
444
- /******/ exports: {}
445
- /******/ };
446
- /******/
447
- /******/ // Execute the module function
448
- /******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
449
- /******/
450
- /******/ // Return the exports of the module
451
- /******/ return module.exports;
452
- /******/ }
453
- /******/
454
- /************************************************************************/
455
- /******/ /* webpack/runtime/compat get default export */
456
- /******/ (() => {
457
- /******/ // getDefaultExport function for compatibility with non-harmony modules
458
- /******/ __webpack_require__.n = (module) => {
459
- /******/ var getter = module && module.__esModule ?
460
- /******/ () => (module['default']) :
461
- /******/ () => (module);
462
- /******/ __webpack_require__.d(getter, { a: getter });
463
- /******/ return getter;
464
- /******/ };
465
- /******/ })();
466
- /******/
467
- /******/ /* webpack/runtime/define property getters */
468
- /******/ (() => {
469
- /******/ // define getter functions for harmony exports
470
- /******/ __webpack_require__.d = (exports, definition) => {
471
- /******/ for(var key in definition) {
472
- /******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
473
- /******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
474
- /******/ }
475
- /******/ }
476
- /******/ };
477
- /******/ })();
478
- /******/
479
- /******/ /* webpack/runtime/hasOwnProperty shorthand */
480
- /******/ (() => {
481
- /******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
482
- /******/ })();
483
- /******/
484
- /******/ /* webpack/runtime/make namespace object */
485
- /******/ (() => {
486
- /******/ // define __esModule on exports
487
- /******/ __webpack_require__.r = (exports) => {
488
- /******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
489
- /******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
490
- /******/ }
491
- /******/ Object.defineProperty(exports, '__esModule', { value: true });
492
- /******/ };
493
- /******/ })();
494
- /******/
495
- /******/ /* webpack/runtime/nonce */
496
- /******/ (() => {
497
- /******/ __webpack_require__.nc = undefined;
498
- /******/ })();
499
- /******/
500
- /************************************************************************/
501
- var __webpack_exports__ = {};
502
- // ESM COMPAT FLAG
503
- __webpack_require__.r(__webpack_exports__);
504
-
505
- // EXPORTS
506
- __webpack_require__.d(__webpack_exports__, {
507
- Accordion: () => (/* reexport */ Accordion),
508
- Button: () => (/* reexport */ Button),
509
- Card: () => (/* reexport */ Card),
510
- Input: () => (/* reexport */ Input)
511
- });
512
-
513
- // EXTERNAL MODULE: external "react"
514
- var external_react_ = __webpack_require__(155);
515
- var external_react_default = /*#__PURE__*/__webpack_require__.n(external_react_);
516
- ;// ./src/components/Accordions/Accordion.js
517
-
518
- function Accordion(_ref) {
519
- let {
520
- items = [],
521
- children
522
- } = _ref;
523
- // Default value for items
524
- const [activeIndex, setActiveIndex] = (0,external_react_.useState)(null);
525
- const handleToggle = index => {
526
- setActiveIndex(activeIndex === index ? null : index);
527
- };
528
- return /*#__PURE__*/external_react_default().createElement("div", {
529
- className: "accordion"
530
- }, items.length > 0 ? items.map((item, index) => /*#__PURE__*/external_react_default().createElement("div", {
531
- className: "accordion-item border-2 rounded-lg border-gray-200 mb-2",
532
- key: index
533
- }, /*#__PURE__*/external_react_default().createElement("div", {
534
- className: "accordion-header flex p-4 justify-between",
535
- onClick: () => handleToggle(index),
536
- style: {
537
- cursor: 'pointer'
538
- }
539
- }, /*#__PURE__*/external_react_default().createElement("h3", null, item.title), /*#__PURE__*/external_react_default().createElement("div", null, activeIndex === index ? '-' : '+')), activeIndex === index && /*#__PURE__*/external_react_default().createElement("div", {
540
- className: "accordion-body p-4 border-t"
541
- }, item.content))) : /*#__PURE__*/external_react_default().createElement("div", {
542
- className: "accordion-body p-4 border-t"
543
- }, children));
544
- }
545
- // EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js
546
- var injectStylesIntoStyleTag = __webpack_require__(72);
547
- var injectStylesIntoStyleTag_default = /*#__PURE__*/__webpack_require__.n(injectStylesIntoStyleTag);
548
- // EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/styleDomAPI.js
549
- var styleDomAPI = __webpack_require__(825);
550
- var styleDomAPI_default = /*#__PURE__*/__webpack_require__.n(styleDomAPI);
551
- // EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/insertBySelector.js
552
- var insertBySelector = __webpack_require__(659);
553
- var insertBySelector_default = /*#__PURE__*/__webpack_require__.n(insertBySelector);
554
- // EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js
555
- var setAttributesWithoutAttributes = __webpack_require__(56);
556
- var setAttributesWithoutAttributes_default = /*#__PURE__*/__webpack_require__.n(setAttributesWithoutAttributes);
557
- // EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/insertStyleElement.js
558
- var insertStyleElement = __webpack_require__(540);
559
- var insertStyleElement_default = /*#__PURE__*/__webpack_require__.n(insertStyleElement);
560
- // EXTERNAL MODULE: ./node_modules/style-loader/dist/runtime/styleTagTransform.js
561
- var styleTagTransform = __webpack_require__(113);
562
- var styleTagTransform_default = /*#__PURE__*/__webpack_require__.n(styleTagTransform);
563
- // EXTERNAL MODULE: ./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js!./src/components/Buttons/_button.scss
564
- var _button = __webpack_require__(250);
565
- ;// ./src/components/Buttons/_button.scss
566
-
567
-
568
-
569
-
570
-
571
-
572
-
573
-
574
-
575
-
576
-
577
- var options = {};
578
-
579
- options.styleTagTransform = (styleTagTransform_default());
580
- options.setAttributes = (setAttributesWithoutAttributes_default());
581
- options.insert = insertBySelector_default().bind(null, "head");
582
- options.domAPI = (styleDomAPI_default());
583
- options.insertStyleElement = (insertStyleElement_default());
584
-
585
- var update = injectStylesIntoStyleTag_default()(_button/* default */.A, options);
586
-
587
-
588
-
589
-
590
- /* harmony default export */ const Buttons_button = (_button/* default */.A && _button/* default */.A.locals ? _button/* default */.A.locals : undefined);
591
-
592
- ;// ./src/components/Buttons/Button.js
593
-
594
-
595
- function Button(_ref) {
596
- let {
597
- type = 'button',
598
- rank = 'primary',
599
- text = 'Example Button',
600
- size = 'md',
601
- isFullWidth = false,
602
- // The boolean to toggle 'w-full'
603
- onClick
604
- } = _ref;
605
- // Conditional class based on isFullWidth
606
- const classNames = `transition ease-in-out duration-700 rounded px-6 py-2 text-${size} ${rank}-btn ${isFullWidth ? 'w-full' : ''}`;
607
- return /*#__PURE__*/external_react_default().createElement("button", {
608
- type: type,
609
- className: classNames,
610
- onClick: onClick
611
- }, text);
612
- }
613
- // EXTERNAL MODULE: ./node_modules/css-loader/dist/cjs.js!./node_modules/sass-loader/dist/cjs.js!./src/components/Cards/card.scss
614
- var card = __webpack_require__(865);
615
- ;// ./src/components/Cards/card.scss
616
-
617
-
618
-
619
-
620
-
621
-
622
-
623
-
624
-
625
-
626
-
627
- var card_options = {};
628
-
629
- card_options.styleTagTransform = (styleTagTransform_default());
630
- card_options.setAttributes = (setAttributesWithoutAttributes_default());
631
- card_options.insert = insertBySelector_default().bind(null, "head");
632
- card_options.domAPI = (styleDomAPI_default());
633
- card_options.insertStyleElement = (insertStyleElement_default());
634
-
635
- var card_update = injectStylesIntoStyleTag_default()(card/* default */.A, card_options);
636
-
637
-
638
-
639
-
640
- /* harmony default export */ const Cards_card = (card/* default */.A && card/* default */.A.locals ? card/* default */.A.locals : undefined);
641
-
642
- ;// ./src/components/Cards/Card.js
643
-
644
-
645
- function Card(_ref) {
646
- let {
647
- mode = 'light',
648
- children
649
- } = _ref;
650
- const cardClasses = `p-5 ${mode}-card rounded-lg shadow-lg`;
651
- return /*#__PURE__*/external_react_default().createElement("div", {
652
- className: cardClasses
653
- }, children);
654
- }
655
- ;// ./src/components/Forms/Inputs/Input.js
656
-
657
- function Input(_ref) {
658
- let {
659
- label,
660
- placeholder,
661
- type = 'text',
662
- name,
663
- isValid = true,
664
- errorMessage = `${label} is required`,
665
- onChange
666
- } = _ref;
667
- const inputClasses = `rounded-md bg-white border px-4 py-3 text-md font-normal text-gray-900 ${isValid ? 'border-slate-500' : 'border-rose-500'}`;
668
- return /*#__PURE__*/external_react_default().createElement("div", {
669
- className: "flex flex-col mb-4"
670
- }, /*#__PURE__*/external_react_default().createElement("label", null, label), /*#__PURE__*/external_react_default().createElement("input", {
671
- className: inputClasses,
672
- type: type,
673
- name: name,
674
- placeholder: placeholder,
675
- onChange: onChange
676
- }), !isValid && /*#__PURE__*/external_react_default().createElement("span", {
677
- className: "text-rose-500 text-sm"
678
- }, errorMessage));
679
- }
680
- ;// ./src/index.js
681
-
682
-
683
-
684
-
685
- /******/ return __webpack_exports__;
686
- /******/ })()
687
- ;
688
- });
689
- //# sourceMappingURL=opus-toolkit-components.js.map