@apexcura/ui-components 0.0.14-Beta107 → 0.0.14-Beta109

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.css CHANGED
@@ -341,12 +341,29 @@ video {
341
341
  .m-\[10px\] {
342
342
  margin: 10px;
343
343
  }
344
+ .mr-3 {
345
+ margin-right: 0.75rem;
346
+ }
344
347
  .flex {
345
348
  display: flex;
346
349
  }
347
350
  .table {
348
351
  display: table;
349
352
  }
353
+ .h-5 {
354
+ height: 1.25rem;
355
+ }
356
+ .w-5 {
357
+ width: 1.25rem;
358
+ }
359
+ @keyframes spin {
360
+ to {
361
+ transform: rotate(360deg);
362
+ }
363
+ }
364
+ .animate-spin {
365
+ animation: spin 1s linear infinite;
366
+ }
350
367
  .rounded-\[8px\] {
351
368
  border-radius: 8px;
352
369
  }
@@ -385,6 +402,16 @@ video {
385
402
  --tw-text-opacity: 1;
386
403
  color: rgb(0 0 0 / var(--tw-text-opacity));
387
404
  }
405
+ .text-white {
406
+ --tw-text-opacity: 1;
407
+ color: rgb(255 255 255 / var(--tw-text-opacity));
408
+ }
409
+ .opacity-25 {
410
+ opacity: 0.25;
411
+ }
412
+ .opacity-75 {
413
+ opacity: 0.75;
414
+ }
388
415
  .shadow-\[0px_0px_1px_1px_\#919191\] {
389
416
  --tw-shadow: 0px 0px 1px 1px #919191;
390
417
  --tw-shadow-colored: 0px 0px 1px 1px var(--tw-shadow-color);
package/dist/index.js CHANGED
@@ -439,15 +439,45 @@ var ButtonElement = (props) => {
439
439
  onClick: props.onClick,
440
440
  className: `${props.className ? props.className : ""}`,
441
441
  onMouseEnter: handleMouseEnter,
442
- onMouseLeave: handleMouseLeave
442
+ onMouseLeave: handleMouseLeave,
443
+ disabled: props.loading,
444
+ style: {
445
+ cursor: props.loading ? "no-drop" : "pointer"
446
+ }
443
447
  },
444
- props.isSVGStylesOverride === false ? props.icon && /* @__PURE__ */ import_react11.default.createElement("img", { className: props.iconsClassName, src: props.icon, alt: props.label }) : svgContent && /* @__PURE__ */ import_react11.default.createElement(
448
+ props.isLoading ? /* @__PURE__ */ import_react11.default.createElement(import_react11.default.Fragment, null, /* @__PURE__ */ import_react11.default.createElement(
449
+ "svg",
450
+ {
451
+ className: "animate-spin h-5 w-5 mr-3 text-white",
452
+ xmlns: "http://www.w3.org/2000/svg",
453
+ fill: "none",
454
+ viewBox: "0 0 24 24"
455
+ },
456
+ /* @__PURE__ */ import_react11.default.createElement(
457
+ "circle",
458
+ {
459
+ className: "opacity-25",
460
+ cx: "12",
461
+ cy: "12",
462
+ r: "10",
463
+ stroke: "currentColor",
464
+ strokeWidth: "4"
465
+ }
466
+ ),
467
+ /* @__PURE__ */ import_react11.default.createElement(
468
+ "path",
469
+ {
470
+ className: "opacity-75",
471
+ fill: "currentColor",
472
+ d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"
473
+ }
474
+ )
475
+ ), props.label) : /* @__PURE__ */ import_react11.default.createElement(import_react11.default.Fragment, null, props.isSVGStylesOverride === false ? props.icon && /* @__PURE__ */ import_react11.default.createElement("img", { className: props.iconsClassName, src: props.icon, alt: props.label }) : svgContent && /* @__PURE__ */ import_react11.default.createElement(
445
476
  "span",
446
477
  {
447
478
  dangerouslySetInnerHTML: { __html: svgContent }
448
479
  }
449
- ),
450
- props.label
480
+ ), props.label)
451
481
  );
452
482
  };
453
483
 
package/dist/index.mjs CHANGED
@@ -378,15 +378,45 @@ var ButtonElement = (props) => {
378
378
  onClick: props.onClick,
379
379
  className: `${props.className ? props.className : ""}`,
380
380
  onMouseEnter: handleMouseEnter,
381
- onMouseLeave: handleMouseLeave
381
+ onMouseLeave: handleMouseLeave,
382
+ disabled: props.loading,
383
+ style: {
384
+ cursor: props.loading ? "no-drop" : "pointer"
385
+ }
382
386
  },
383
- props.isSVGStylesOverride === false ? props.icon && /* @__PURE__ */ React11.createElement("img", { className: props.iconsClassName, src: props.icon, alt: props.label }) : svgContent && /* @__PURE__ */ React11.createElement(
387
+ props.isLoading ? /* @__PURE__ */ React11.createElement(React11.Fragment, null, /* @__PURE__ */ React11.createElement(
388
+ "svg",
389
+ {
390
+ className: "animate-spin h-5 w-5 mr-3 text-white",
391
+ xmlns: "http://www.w3.org/2000/svg",
392
+ fill: "none",
393
+ viewBox: "0 0 24 24"
394
+ },
395
+ /* @__PURE__ */ React11.createElement(
396
+ "circle",
397
+ {
398
+ className: "opacity-25",
399
+ cx: "12",
400
+ cy: "12",
401
+ r: "10",
402
+ stroke: "currentColor",
403
+ strokeWidth: "4"
404
+ }
405
+ ),
406
+ /* @__PURE__ */ React11.createElement(
407
+ "path",
408
+ {
409
+ className: "opacity-75",
410
+ fill: "currentColor",
411
+ d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"
412
+ }
413
+ )
414
+ ), props.label) : /* @__PURE__ */ React11.createElement(React11.Fragment, null, props.isSVGStylesOverride === false ? props.icon && /* @__PURE__ */ React11.createElement("img", { className: props.iconsClassName, src: props.icon, alt: props.label }) : svgContent && /* @__PURE__ */ React11.createElement(
384
415
  "span",
385
416
  {
386
417
  dangerouslySetInnerHTML: { __html: svgContent }
387
418
  }
388
- ),
389
- props.label
419
+ ), props.label)
390
420
  );
391
421
  };
392
422
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@apexcura/ui-components",
3
- "version": "0.0.14-Beta107",
3
+ "version": "0.0.14-Beta109",
4
4
  "description": "Apex cura React components library",
5
5
  "keywords": [
6
6
  "apex cura",