@ilo-org/react 0.24.3 → 0.24.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.
@@ -1,20 +1,22 @@
1
- import { LoadingStatus, LoadingSize } from '../../types';
1
+ import { ThemeTypes } from '../../types';
2
2
 
3
+ export type LoadingStatus = "loading" | "loaded" | "idle";
4
+ export type LoadingSize = "small" | "large";
3
5
  export interface LoadingProps {
4
6
  /**
5
7
  * Specify an optional className to be added to your empty component.
6
8
  */
7
9
  className?: string;
8
- /**
9
- * Specify the loading message
10
- */
11
- message?: string;
12
10
  /**
13
11
  * Specify the loader's size
14
12
  */
15
- size?: Required<LoadingSize>;
13
+ size: LoadingSize;
16
14
  /**
17
15
  * Specify the loading status
18
16
  */
19
- status?: Required<LoadingStatus>;
17
+ status: LoadingStatus;
18
+ /**
19
+ * Specify the theme of the loading component
20
+ */
21
+ theme?: ThemeTypes;
20
22
  }
@@ -17,8 +17,6 @@ export type TooltipThemes = "light" | "dark";
17
17
  export type TooltipIconThemes = "light" | "dark";
18
18
  export type TooltipAlignment = "top" | "right" | "bottom" | "left";
19
19
  export type TooltipPlacement = "negative" | "center" | "positive";
20
- export type LoadingStatus = "idle" | "loading" | "loaded";
21
- export type LoadingSize = "small" | "large";
22
20
  export type NotificationPlacement = "dialog" | "inline";
23
21
  export type NotificationTypes = "error" | "info" | "success" | "warning";
24
22
  export type PositionTypes = "top" | "bottom" | "left" | "right";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ilo-org/react",
3
- "version": "0.24.3",
3
+ "version": "0.24.4",
4
4
  "description": "React components for the ILO's Design System",
5
5
  "keywords": [
6
6
  "ui_patterns",
@@ -72,12 +72,12 @@
72
72
  "use-breakpoint": "^4.0.6",
73
73
  "video.js": "^7.21.2",
74
74
  "videojs-youtube": "^3.0.1",
75
- "@ilo-org/brand-assets": "1.0.0",
76
- "@ilo-org/icons-react": "1.0.3",
77
75
  "@ilo-org/fonts": "1.0.0",
78
- "@ilo-org/styles": "1.8.3",
76
+ "@ilo-org/styles": "1.8.4",
79
77
  "@ilo-org/themes": "0.9.1",
80
- "@ilo-org/utils": "0.1.1"
78
+ "@ilo-org/brand-assets": "1.0.0",
79
+ "@ilo-org/utils": "0.1.1",
80
+ "@ilo-org/icons-react": "1.0.3"
81
81
  },
82
82
  "devDependencies": {
83
83
  "@storybook/addon-actions": "^8.1.9",
@@ -1 +0,0 @@
1
- "use strict";const l=require("react/jsx-runtime"),c=require("./index-chunk-D921N0ug.js"),t=require("./useGlobalSettings-chunk-DEacV16j.js"),d=({className:o,message:n,size:i,status:e})=>{const{prefix:r}=t.useGlobalSettings(),s=`${r}--loading`,a=c.classnames(o,{[s]:!0,[`${s}--${i}`]:i,[`${s}--${e}`]:e});return l.jsx("div",{className:a,role:"alert","aria-live":"assertive",children:e&&n&&e!=="idle"&&l.jsx("p",{className:`${s}--copy`,children:n})})},$=d;exports.Loading=$;
@@ -1,14 +0,0 @@
1
- import { jsx as e } from "react/jsx-runtime";
2
- import { c } from "./index-chunk-CY3PQDr4.js";
3
- import { u as t } from "./useGlobalSettings-chunk-Bu2lRvQa.js";
4
- const d = ({ className: i, message: r, size: s, status: o }) => {
5
- const { prefix: l } = t(), a = `${l}--loading`, n = c(i, {
6
- [a]: !0,
7
- [`${a}--${s}`]: s,
8
- [`${a}--${o}`]: o
9
- });
10
- return /* @__PURE__ */ e("div", { className: n, role: "alert", "aria-live": "assertive", children: o && r && o !== "idle" && /* @__PURE__ */ e("p", { className: `${a}--copy`, children: r }) });
11
- }, f = d;
12
- export {
13
- f as L
14
- };
@@ -1,4 +0,0 @@
1
- import { L as r } from "./Loading-chunk-BycGy-99.js";
2
- export {
3
- r as Loading
4
- };