@agnos-ui/react-headless 0.9.2 → 0.9.3

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/config.cjs CHANGED
@@ -5,7 +5,7 @@ const types = require("@agnos-ui/core/types");
5
5
  const config = require("@agnos-ui/core/config");
6
6
  const tansu = require("@amadeus-it-group/tansu");
7
7
  const react = require("react");
8
- const widget = require("./widget-CHGwSEgq.cjs");
8
+ const widget = require("./widget-BkLUvh4T.cjs");
9
9
  const stores = require("./stores-DD819q-h.cjs");
10
10
  const widgetsConfigFactory = (WidgetsConfigContext2 = react.createContext(void 0)) => {
11
11
  const useWidgetContext2 = (widgetName, defaultConfig) => {
package/config.js CHANGED
@@ -4,7 +4,7 @@ import { createWidgetsConfig } from "@agnos-ui/core/config";
4
4
  export * from "@agnos-ui/core/config";
5
5
  import { computed } from "@amadeus-it-group/tansu";
6
6
  import { createContext, useContext, useMemo } from "react";
7
- import { u as useWidgetWithConfig } from "./widget-BiWY_QJE.js";
7
+ import { u as useWidgetWithConfig } from "./widget-DLB7vGCY.js";
8
8
  import { b as usePropsAsStore } from "./stores-DZalyTTa.js";
9
9
  const widgetsConfigFactory = (WidgetsConfigContext2 = createContext(void 0)) => {
10
10
  const useWidgetContext2 = (widgetName, defaultConfig) => {
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const collapse = require("@agnos-ui/core/components/collapse");
4
+ Object.keys(collapse).forEach((k) => {
5
+ if (k !== "default" && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
6
+ enumerable: true,
7
+ get: () => collapse[k]
8
+ });
9
+ });
@@ -0,0 +1 @@
1
+ export * from '@agnos-ui/core/components/collapse';
@@ -0,0 +1 @@
1
+ export * from "@agnos-ui/core/components/collapse";
@@ -28,6 +28,7 @@ export * from './components/progressbar/index';
28
28
  export * from './components/pagination/index';
29
29
  export * from './components/modal/index';
30
30
  export * from './components/carousel/index';
31
+ export * from './components/collapse/index';
31
32
  export * from './components/alert/index';
32
33
  export * from './components/accordion/index';
33
34
  export * from './utils/portal';
@@ -1,4 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const widget = require("../../widget-CHGwSEgq.cjs");
3
+ const widget = require("../../widget-BkLUvh4T.cjs");
4
+ const widget$1 = require("@agnos-ui/core/utils/widget");
4
5
  exports.useWidgetWithConfig = widget.useWidgetWithConfig;
6
+ Object.keys(widget$1).forEach((k) => {
7
+ if (k !== "default" && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
8
+ enumerable: true,
9
+ get: () => widget$1[k]
10
+ });
11
+ });
@@ -1,4 +1,5 @@
1
- import { u } from "../../widget-BiWY_QJE.js";
1
+ import { u } from "../../widget-DLB7vGCY.js";
2
+ export * from "@agnos-ui/core/utils/widget";
2
3
  export {
3
4
  u as useWidgetWithConfig
4
5
  };
package/index.cjs CHANGED
@@ -15,7 +15,8 @@ const cssTransitions = require("@agnos-ui/core/services/transitions/cssTransitio
15
15
  const collapse = require("@agnos-ui/core/services/transitions/collapse");
16
16
  const baseTransitions = require("@agnos-ui/core/services/transitions/baseTransitions");
17
17
  const writables = require("@agnos-ui/core/utils/writables");
18
- const widget = require("./widget-CHGwSEgq.cjs");
18
+ const widget$1 = require("@agnos-ui/core/utils/widget");
19
+ const widget = require("./widget-BkLUvh4T.cjs");
19
20
  const stores$1 = require("@agnos-ui/core/utils/stores");
20
21
  const stores = require("./stores-DD819q-h.cjs");
21
22
  const func = require("@agnos-ui/core/utils/func");
@@ -34,6 +35,7 @@ const progressbar = require("@agnos-ui/core/components/progressbar");
34
35
  const pagination = require("@agnos-ui/core/components/pagination");
35
36
  const modal = require("@agnos-ui/core/components/modal");
36
37
  const carousel = require("@agnos-ui/core/components/carousel");
38
+ const collapse$1 = require("@agnos-ui/core/components/collapse");
37
39
  const alert = require("@agnos-ui/core/components/alert");
38
40
  const accordion = require("@agnos-ui/core/components/accordion");
39
41
  const portal$1 = require("./portal-B0Q5KLrA.cjs");
@@ -146,6 +148,12 @@ Object.keys(writables).forEach((k) => {
146
148
  get: () => writables[k]
147
149
  });
148
150
  });
151
+ Object.keys(widget$1).forEach((k) => {
152
+ if (k !== "default" && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
153
+ enumerable: true,
154
+ get: () => widget$1[k]
155
+ });
156
+ });
149
157
  Object.keys(stores$1).forEach((k) => {
150
158
  if (k !== "default" && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
151
159
  enumerable: true,
@@ -230,6 +238,12 @@ Object.keys(carousel).forEach((k) => {
230
238
  get: () => carousel[k]
231
239
  });
232
240
  });
241
+ Object.keys(collapse$1).forEach((k) => {
242
+ if (k !== "default" && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
243
+ enumerable: true,
244
+ get: () => collapse$1[k]
245
+ });
246
+ });
233
247
  Object.keys(alert).forEach((k) => {
234
248
  if (k !== "default" && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
235
249
  enumerable: true,
package/index.js CHANGED
@@ -13,7 +13,8 @@ export * from "@agnos-ui/core/services/transitions/cssTransitions";
13
13
  export * from "@agnos-ui/core/services/transitions/collapse";
14
14
  export * from "@agnos-ui/core/services/transitions/baseTransitions";
15
15
  export * from "@agnos-ui/core/utils/writables";
16
- import { u } from "./widget-BiWY_QJE.js";
16
+ export * from "@agnos-ui/core/utils/widget";
17
+ import { u } from "./widget-DLB7vGCY.js";
17
18
  export * from "@agnos-ui/core/utils/stores";
18
19
  import { u as u2, a, b } from "./stores-DZalyTTa.js";
19
20
  export * from "@agnos-ui/core/utils/func";
@@ -32,6 +33,7 @@ export * from "@agnos-ui/core/components/progressbar";
32
33
  export * from "@agnos-ui/core/components/pagination";
33
34
  export * from "@agnos-ui/core/components/modal";
34
35
  export * from "@agnos-ui/core/components/carousel";
36
+ export * from "@agnos-ui/core/components/collapse";
35
37
  export * from "@agnos-ui/core/components/alert";
36
38
  export * from "@agnos-ui/core/components/accordion";
37
39
  import { P } from "./portal-CX8X69NK.js";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@agnos-ui/react-headless",
3
3
  "description": "Headless component library for React.",
4
- "version": "0.9.2",
4
+ "version": "0.9.3",
5
5
  "type": "module",
6
6
  "main": "./index.cjs",
7
7
  "module": "./index.js",
@@ -49,7 +49,7 @@
49
49
  }
50
50
  },
51
51
  "dependencies": {
52
- "@agnos-ui/core": "0.9.2"
52
+ "@agnos-ui/core": "0.9.3"
53
53
  },
54
54
  "peerDependencies": {
55
55
  "@amadeus-it-group/tansu": "^2.0.0",
package/utils/widget.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  import type { PropsConfig, Widget, WidgetFactory, WidgetProps, WidgetSlotContext } from '@agnos-ui/core/types';
2
+ export * from '@agnos-ui/core/utils/widget';
2
3
  /**
3
4
  * Create and attach an agnos-ui/core widget to the current react component.
4
5
  *
@@ -2,6 +2,7 @@
2
2
  const stores = require("@agnos-ui/core/utils/stores");
3
3
  const react = require("react");
4
4
  const stores$1 = require("./stores-DD819q-h.cjs");
5
+ require("@agnos-ui/core/utils/widget");
5
6
  function useWidgetWithConfig(factory, props = {}, propsConfig) {
6
7
  const coreWidget = react.useMemo(() => factory({ ...propsConfig, props: { ...propsConfig == null ? void 0 : propsConfig.props, ...props } }), []);
7
8
  const previousProps = react.useRef(props);
@@ -1,6 +1,7 @@
1
1
  import { findChangedProperties } from "@agnos-ui/core/utils/stores";
2
2
  import { useMemo, useRef } from "react";
3
3
  import { a as useObservablesProxy } from "./stores-DZalyTTa.js";
4
+ import "@agnos-ui/core/utils/widget";
4
5
  function useWidgetWithConfig(factory, props = {}, propsConfig) {
5
6
  const coreWidget = useMemo(() => factory({ ...propsConfig, props: { ...propsConfig == null ? void 0 : propsConfig.props, ...props } }), []);
6
7
  const previousProps = useRef(props);