@edifice.io/react 2.0.1-develop-hotfix.1736779480274 → 2.0.1-develop-hotfix.1736785354321

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.
@@ -16,7 +16,6 @@ export * from './useEdificeIcons';
16
16
  export * from './useHasWorkflow';
17
17
  export * from './useHeader';
18
18
  export * from './useHover';
19
- export * from './useHttpErrorToast';
20
19
  export * from './useImage';
21
20
  export * from './useIsAdml';
22
21
  export * from './useKeyPress';
package/dist/index.js CHANGED
@@ -38,67 +38,66 @@ import { default as default37 } from "./hooks/useDropdown/useDropdown.js";
38
38
  import { default as default38 } from "./hooks/useDropzone/useDropzone.js";
39
39
  import { default as default39 } from "./hooks/useEdificeIcons/useEdificeIcons.js";
40
40
  import { default as default40 } from "./hooks/useHeader/useHeader.js";
41
- import { default as default41 } from "./hooks/useHttpErrorToast/useHttpErrorToast.js";
42
- import { default as default42 } from "./hooks/useImage/useImage.js";
43
- import { default as default43 } from "./hooks/useIsAdml/useIsAdml.js";
44
- import { default as default44 } from "./hooks/useKeyPress/useKeyPress.js";
45
- import { default as default45 } from "./hooks/useLibraryUrl/useLibraryUrl.js";
46
- import { default as default46 } from "./hooks/useScrollToTop/useScrollToTop.js";
47
- import { default as default47 } from "./hooks/useSession/useSession.js";
48
- import { default as default48 } from "./hooks/useTitle/useTitle.js";
49
- import { default as default49 } from "./hooks/useToggle/useToggle.js";
50
- import { default as default50 } from "./hooks/useTrapFocus/useTrapFocus.js";
51
- import { default as default51 } from "./hooks/useTrashedResource/useTrashedResource.js";
52
- import { default as default52 } from "./hooks/useUpload/useUpload.js";
53
- import { default as default53 } from "./hooks/useUploadFiles/useUploadFiles.js";
54
- import { default as default54 } from "./hooks/useWorkspaceFile/useWorkspaceFile.js";
55
- import { default as default55 } from "./hooks/useWorkspaceSearch/useWorkspaceSearch.js";
56
- import { default as default56 } from "./hooks/useXitiTrackPageLoad/useXitiTrackPageLoad.js";
57
- import { default as default57 } from "./hooks/useZendeskGuide/useZendeskGuide.js";
58
- import { default as default58 } from "./components/Alert/Alert.js";
59
- import { default as default59 } from "./components/Avatar/Avatar.js";
60
- import { default as default60 } from "./components/Button/Button.js";
61
- import { default as default61 } from "./components/Checkbox/Checkbox.js";
41
+ import { default as default41 } from "./hooks/useImage/useImage.js";
42
+ import { default as default42 } from "./hooks/useIsAdml/useIsAdml.js";
43
+ import { default as default43 } from "./hooks/useKeyPress/useKeyPress.js";
44
+ import { default as default44 } from "./hooks/useLibraryUrl/useLibraryUrl.js";
45
+ import { default as default45 } from "./hooks/useScrollToTop/useScrollToTop.js";
46
+ import { default as default46 } from "./hooks/useSession/useSession.js";
47
+ import { default as default47 } from "./hooks/useTitle/useTitle.js";
48
+ import { default as default48 } from "./hooks/useToggle/useToggle.js";
49
+ import { default as default49 } from "./hooks/useTrapFocus/useTrapFocus.js";
50
+ import { default as default50 } from "./hooks/useTrashedResource/useTrashedResource.js";
51
+ import { default as default51 } from "./hooks/useUpload/useUpload.js";
52
+ import { default as default52 } from "./hooks/useUploadFiles/useUploadFiles.js";
53
+ import { default as default53 } from "./hooks/useWorkspaceFile/useWorkspaceFile.js";
54
+ import { default as default54 } from "./hooks/useWorkspaceSearch/useWorkspaceSearch.js";
55
+ import { default as default55 } from "./hooks/useXitiTrackPageLoad/useXitiTrackPageLoad.js";
56
+ import { default as default56 } from "./hooks/useZendeskGuide/useZendeskGuide.js";
57
+ import { default as default57 } from "./components/Alert/Alert.js";
58
+ import { default as default58 } from "./components/Avatar/Avatar.js";
59
+ import { default as default59 } from "./components/Button/Button.js";
60
+ import { default as default60 } from "./components/Checkbox/Checkbox.js";
62
61
  import { AccessiblePalette, DefaultPalette } from "./components/ColorPicker/ColorPalette.js";
63
- import { default as default62 } from "./components/Combobox/Combobox.js";
62
+ import { default as default61 } from "./components/Combobox/Combobox.js";
64
63
  import { DropzoneContext, useDropzoneContext } from "./components/Dropzone/DropzoneContext.js";
65
- import { default as default63 } from "./components/Form/FormControl.js";
64
+ import { default as default62 } from "./components/Form/FormControl.js";
66
65
  import { Column, Grid } from "./components/Grid/Grid.js";
67
- import { default as default64 } from "./components/Heading/Heading.js";
68
- import { default as default65 } from "./components/Input/Input.js";
69
- import { default as default66 } from "./components/Label/Label.js";
66
+ import { default as default63 } from "./components/Heading/Heading.js";
67
+ import { default as default64 } from "./components/Input/Input.js";
68
+ import { default as default65 } from "./components/Label/Label.js";
70
69
  import { Layout } from "./components/Layout/Layout.js";
71
70
  import { List } from "./components/List/List.js";
72
- import { default as default67 } from "./components/LoadingScreen/LoadingScreen.js";
71
+ import { default as default66 } from "./components/LoadingScreen/LoadingScreen.js";
73
72
  import { Menu } from "./components/Menu/components/Menu.js";
74
- import { default as default68 } from "./components/Modal/Modal.js";
73
+ import { default as default67 } from "./components/Modal/Modal.js";
75
74
  import { Popover, PopoverBody, PopoverFooter, PopoverHeader } from "./components/Popover/Popover.js";
76
- import { default as default69 } from "./components/Radio/Radio.js";
75
+ import { default as default68 } from "./components/Radio/Radio.js";
77
76
  import { Tabs } from "./components/Tabs/components/Tabs.js";
78
- import { default as default70 } from "./components/TextArea/TextArea.js";
77
+ import { default as default69 } from "./components/TextArea/TextArea.js";
79
78
  import { Toolbar } from "./components/Toolbar/Toolbar.js";
80
- import { default as default71 } from "./components/Tooltip/Tooltip.js";
79
+ import { default as default70 } from "./components/Tooltip/Tooltip.js";
81
80
  import { useTreeSortable } from "./components/Tree/hooks/useTreeSortable.js";
82
81
  import { buildTree, determineNewParentId, findItemIndexInTree, flattenNodes, flattenTree, generateUpdateData, getActiveAndOverNodes, getDragDepth, getIndicesToUpdate, getProjection, updateParentIds } from "./components/Tree/utilities/tree-sortable.js";
83
82
  import { useTreeView } from "./components/TreeView/hooks/useTreeView.js";
84
83
  import { TreeNode } from "./components/TreeView/TreeNode.js";
85
84
  import { TreeNodeFolderWrapper, addNode, arrayUnique, deleteNode, findNodeById, findParentNode, findPathById, findTreeNode, getAncestors, hasChildren, modifyNode, moveNode, updateNode, wrapTreeNode } from "./components/TreeView/utilities/treeview.js";
86
- import { default as default72 } from "./components/VisuallyHidden/VisuallyHidden.js";
85
+ import { default as default71 } from "./components/VisuallyHidden/VisuallyHidden.js";
87
86
  import { useCheckable } from "./hooks/useCheckable/useCheckable.js";
88
- import { default as default73 } from "./hooks/useHasWorkflow/useHasWorkflow.js";
89
- import { default as default74 } from "./hooks/useHover/useHover.js";
90
- import { default as default75 } from "./hooks/useMediaLibrary/useMediaLibrary.js";
87
+ import { default as default72 } from "./hooks/useHasWorkflow/useHasWorkflow.js";
88
+ import { default as default73 } from "./hooks/useHover/useHover.js";
89
+ import { default as default74 } from "./hooks/useMediaLibrary/useMediaLibrary.js";
91
90
  import { useResourceSearch } from "./hooks/useResourceSearch/useResourceSearch.js";
92
- import { default as default76 } from "./hooks/useToast/useToast.js";
93
- import { default as default77 } from "./hooks/useUser/useUser.js";
94
- import { default as default78 } from "./modules/modals/OnboardingModal/OnboardingModal.js";
95
- import { default as default79 } from "./modules/modals/PublishModal/PublishModal.js";
96
- import { default as default80 } from "./modules/modals/ResourceModal/apps/BlogPublic.js";
97
- import { default as default81 } from "./modules/modals/ResourceModal/hooks/useUpdateMutation.js";
91
+ import { default as default75 } from "./hooks/useToast/useToast.js";
92
+ import { default as default76 } from "./hooks/useUser/useUser.js";
93
+ import { default as default77 } from "./modules/modals/OnboardingModal/OnboardingModal.js";
94
+ import { default as default78 } from "./modules/modals/PublishModal/PublishModal.js";
95
+ import { default as default79 } from "./modules/modals/ResourceModal/apps/BlogPublic.js";
96
+ import { default as default80 } from "./modules/modals/ResourceModal/hooks/useUpdateMutation.js";
98
97
  import { ResourceModal } from "./modules/modals/ResourceModal/ResourceModal.js";
99
- import { default as default82 } from "./modules/modals/ShareModal/ShareModal.js";
100
- import { default as default83 } from "./modules/modals/ShareModal/apps/ShareBlog.js";
101
- import { default as default84 } from "./modules/modals/ShareModal/hooks/useShareMutation.js";
98
+ import { default as default81 } from "./modules/modals/ShareModal/ShareModal.js";
99
+ import { default as default82 } from "./modules/modals/ShareModal/apps/ShareBlog.js";
100
+ import { default as default83 } from "./modules/modals/ShareModal/hooks/useShareMutation.js";
102
101
  import { EdificeClientProvider } from "./providers/EdificeClientProvider/EdificeClientProvider.js";
103
102
  import { EdificeClientContext } from "./providers/EdificeClientProvider/EdificeClientProvider.context.js";
104
103
  import { useEdificeClient } from "./providers/EdificeClientProvider/EdificeClientProvider.hook.js";
@@ -111,21 +110,21 @@ import { mergeRefs, setRef } from "./utilities/refs/ref.js";
111
110
  export {
112
111
  AccessiblePalette,
113
112
  default2 as ActionBar,
114
- default58 as Alert,
113
+ default57 as Alert,
115
114
  default3 as AppHeader,
116
115
  default4 as AppIcon,
117
116
  default5 as Attachment,
118
- default59 as Avatar,
117
+ default58 as Avatar,
119
118
  default6 as Badge,
120
- default80 as BlogPublic,
119
+ default79 as BlogPublic,
121
120
  default7 as Breadcrumb,
122
- default60 as Button,
121
+ default59 as Button,
123
122
  default10 as Card,
124
- default61 as Checkbox,
123
+ default60 as Checkbox,
125
124
  default11 as ColorPicker,
126
125
  default12 as ColorPickerItem,
127
126
  Column,
128
- default62 as Combobox,
127
+ default61 as Combobox,
129
128
  DefaultPalette,
130
129
  DndTree,
131
130
  default13 as Dropdown,
@@ -136,45 +135,45 @@ export {
136
135
  EdificeThemeContext,
137
136
  EdificeThemeProvider,
138
137
  default15 as EmptyScreen,
139
- default63 as FormControl,
138
+ default62 as FormControl,
140
139
  default16 as FormText,
141
140
  Grid,
142
- default64 as Heading,
141
+ default63 as Heading,
143
142
  default8 as IconButton,
144
143
  default17 as Image,
145
- default65 as Input,
146
- default66 as Label,
144
+ default64 as Input,
145
+ default65 as Label,
147
146
  Layout,
148
147
  List,
149
148
  default18 as Loading,
150
- default67 as LoadingScreen,
149
+ default66 as LoadingScreen,
151
150
  default19 as Logo,
152
151
  Menu,
153
- default68 as Modal,
154
- default78 as OnboardingModal,
152
+ default67 as Modal,
153
+ default77 as OnboardingModal,
155
154
  Popover,
156
155
  PopoverBody,
157
156
  PopoverFooter,
158
157
  PopoverHeader,
159
- default79 as PublishModal,
160
- default69 as Radio,
158
+ default78 as PublishModal,
159
+ default68 as Radio,
161
160
  ResourceModal,
162
161
  default20 as SearchBar,
163
162
  default9 as SearchButton,
164
163
  default21 as Select,
165
- default83 as ShareBlog,
166
- default82 as ShareModal,
164
+ default82 as ShareBlog,
165
+ default81 as ShareModal,
167
166
  default23 as SortableTree,
168
167
  default22 as Table,
169
168
  Tabs,
170
- default70 as TextArea,
169
+ default69 as TextArea,
171
170
  Toolbar,
172
- default71 as Tooltip,
171
+ default70 as Tooltip,
173
172
  default24 as Tree,
174
173
  TreeNode,
175
174
  TreeNodeFolderWrapper,
176
175
  default25 as TreeView,
177
- default72 as VisuallyHidden,
176
+ default71 as VisuallyHidden,
178
177
  addNode,
179
178
  arrayUnique,
180
179
  buildTree,
@@ -220,33 +219,32 @@ export {
220
219
  useEdificeClient,
221
220
  default39 as useEdificeIcons,
222
221
  useEdificeTheme,
223
- default73 as useHasWorkflow,
222
+ default72 as useHasWorkflow,
224
223
  default40 as useHeader,
225
- default74 as useHover,
226
- default41 as useHttpErrorToast,
227
- default42 as useImage,
228
- default43 as useIsAdml,
229
- default44 as useKeyPress,
230
- default45 as useLibraryUrl,
231
- default75 as useMediaLibrary,
224
+ default73 as useHover,
225
+ default41 as useImage,
226
+ default42 as useIsAdml,
227
+ default43 as useKeyPress,
228
+ default44 as useLibraryUrl,
229
+ default74 as useMediaLibrary,
232
230
  useResourceSearch,
233
- default46 as useScrollToTop,
234
- default47 as useSession,
235
- default84 as useShareMutation,
236
- default48 as useTitle,
237
- default76 as useToast,
238
- default49 as useToggle,
239
- default50 as useTrapFocus,
240
- default51 as useTrashedResource,
231
+ default45 as useScrollToTop,
232
+ default46 as useSession,
233
+ default83 as useShareMutation,
234
+ default47 as useTitle,
235
+ default75 as useToast,
236
+ default48 as useToggle,
237
+ default49 as useTrapFocus,
238
+ default50 as useTrashedResource,
241
239
  useTreeSortable,
242
240
  useTreeView,
243
- default81 as useUpdateMutation,
244
- default52 as useUpload,
245
- default53 as useUploadFiles,
246
- default77 as useUser,
247
- default54 as useWorkspaceFile,
248
- default55 as useWorkspaceSearch,
249
- default56 as useXitiTrackPageLoad,
250
- default57 as useZendeskGuide,
241
+ default80 as useUpdateMutation,
242
+ default51 as useUpload,
243
+ default52 as useUploadFiles,
244
+ default76 as useUser,
245
+ default53 as useWorkspaceFile,
246
+ default54 as useWorkspaceSearch,
247
+ default55 as useXitiTrackPageLoad,
248
+ default56 as useZendeskGuide,
251
249
  wrapTreeNode
252
250
  };
@@ -11,7 +11,6 @@ import SvgIconRecordVideo from "../../icons/components/IconRecordVideo.js";
11
11
  import SvgIconSmartphone from "../../icons/components/IconSmartphone.js";
12
12
  import { InnerTabs } from "./innertabs/index.js";
13
13
  import { MediaLibraryContext } from "./MediaLibraryContext.js";
14
- import useHttpErrorToast from "../../../hooks/useHttpErrorToast/useHttpErrorToast.js";
15
14
  import useHasWorkflow from "../../../hooks/useHasWorkflow/useHasWorkflow.js";
16
15
  import Modal from "../../../components/Modal/Modal.js";
17
16
  import { Tabs } from "../../../components/Tabs/components/Tabs.js";
@@ -73,10 +72,7 @@ const orderedTabs = [
73
72
  showLink,
74
73
  type,
75
74
  ...refModal.current
76
- })), useHttpErrorToast({
77
- isDismissible: !0,
78
- duration: 1 / 0
79
- });
75
+ }));
80
76
  const {
81
77
  t
82
78
  } = useTranslation(), workspaceCreateWorkflow = useHasWorkflow("org.entcore.workspace.controllers.WorkspaceController|addDocument"), videoCaptureWorkflow = useHasWorkflow("com.opendigitaleducation.video.controllers.VideoController|capture"), [type, setType] = useState(null), availableTabs = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@edifice.io/react",
3
- "version": "2.0.1-develop-hotfix.1736779480274",
3
+ "version": "2.0.1-develop-hotfix.1736785354321",
4
4
  "description": "Edifice React Library",
5
5
  "keywords": [
6
6
  "react",
@@ -119,9 +119,9 @@
119
119
  "react-slugify": "^3.0.3",
120
120
  "swiper": "^10.1.0",
121
121
  "ua-parser-js": "^1.0.36",
122
- "@edifice.io/utilities": "2.0.0",
123
- "@edifice.io/bootstrap": "2.0.1-develop-hotfix.1736779480274",
124
- "@edifice.io/tiptap-extensions": "2.0.1-develop-hotfix.1736779480274"
122
+ "@edifice.io/bootstrap": "2.0.1-develop-hotfix.1736785354321",
123
+ "@edifice.io/tiptap-extensions": "2.0.1-develop-hotfix.1736785354321",
124
+ "@edifice.io/utilities": "2.0.0"
125
125
  },
126
126
  "devDependencies": {
127
127
  "@babel/plugin-transform-react-pure-annotations": "^7.23.3",
@@ -147,7 +147,7 @@
147
147
  "typescript-eslint": "^8.8.1",
148
148
  "vite": "catalog:",
149
149
  "vite-plugin-dts": "catalog:",
150
- "@edifice.io/client": "2.0.1-develop-hotfix.1736779480274"
150
+ "@edifice.io/client": "2.0.1-develop-hotfix.1736785354321"
151
151
  },
152
152
  "peerDependencies": {
153
153
  "@react-spring/web": "catalog:",
@@ -1,21 +0,0 @@
1
- import React, { useRef, useEffect } from "react";
2
- import { odeServices, LAYER_NAME } from "@edifice.io/client";
3
- import { useTranslation } from "react-i18next";
4
- import useToast from "../useToast/useToast.js";
5
- const useHttpErrorToast = (options) => {
6
- const message = useRef(), toast = useToast(), {
7
- t
8
- } = useTranslation();
9
- return useEffect(() => {
10
- const subscription = odeServices.notify().events().subscribe(LAYER_NAME.TRANSPORT, (event) => {
11
- var _a, _b;
12
- message.current = t(((_b = (_a = event == null ? void 0 : event.data) == null ? void 0 : _a.payload) == null ? void 0 : _b.error) || event.data.response.statusText), toast.error(/* @__PURE__ */ React.createElement("div", {
13
- children: [message.current]
14
- }), options);
15
- });
16
- return () => subscription.revoke();
17
- }, [t, toast]), message.current;
18
- };
19
- export {
20
- useHttpErrorToast as default
21
- };