@edifice.io/react 2.5.9-develop-pedago.20260213112355 → 2.5.9-develop-b2school.20260213162502

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.
Files changed (109) hide show
  1. package/dist/components/Badge/Badge.js +10 -1
  2. package/dist/components/MediaViewer/PdfViewer.js +14 -4
  3. package/dist/components/index.d.ts +0 -1
  4. package/dist/hooks/useConf/useConf.d.ts +1 -1
  5. package/dist/hooks/useSession/useSession.d.ts +1 -1
  6. package/dist/icons.js +298 -302
  7. package/dist/index.js +0 -2
  8. package/dist/modules/icons/components/index.d.ts +0 -2
  9. package/dist/modules/modals/ResourceModal/ResourceModal.d.ts +1 -1
  10. package/dist/modules/modals/ResourceModal/hooks/useUpdateMutation.d.ts +1 -1
  11. package/dist/modules/modals/ShareModal/ShareResources.d.ts +1 -1
  12. package/dist/modules/modals/ShareModal/apps/ShareBlog.d.ts +1 -1
  13. package/dist/modules/modals/ShareModal/hooks/useShareMutation.d.ts +1 -1
  14. package/dist/providers/AntThemeProvider/AntProvider.js +5 -5
  15. package/dist/providers/EdificeClientProvider/EdificeClientProvider.context.d.ts +1 -1
  16. package/dist/utilities/react-query/react-query-utils.d.ts +1 -1
  17. package/package.json +6 -6
  18. package/dist/_virtual/common.js +0 -4
  19. package/dist/_virtual/de_DE.js +0 -4
  20. package/dist/_virtual/de_DE2.js +0 -4
  21. package/dist/_virtual/de_DE3.js +0 -4
  22. package/dist/_virtual/de_DE4.js +0 -4
  23. package/dist/_virtual/de_DE5.js +0 -4
  24. package/dist/_virtual/de_DE6.js +0 -4
  25. package/dist/_virtual/defineProperty.js +0 -4
  26. package/dist/_virtual/es_ES.js +0 -4
  27. package/dist/_virtual/es_ES2.js +0 -4
  28. package/dist/_virtual/es_ES3.js +0 -4
  29. package/dist/_virtual/es_ES4.js +0 -4
  30. package/dist/_virtual/es_ES5.js +0 -4
  31. package/dist/_virtual/es_ES6.js +0 -4
  32. package/dist/_virtual/fr_FR.js +0 -4
  33. package/dist/_virtual/fr_FR2.js +0 -4
  34. package/dist/_virtual/fr_FR3.js +0 -4
  35. package/dist/_virtual/fr_FR4.js +0 -4
  36. package/dist/_virtual/fr_FR5.js +0 -4
  37. package/dist/_virtual/fr_FR6.js +0 -4
  38. package/dist/_virtual/interopRequireDefault.js +0 -4
  39. package/dist/_virtual/it_IT.js +0 -4
  40. package/dist/_virtual/it_IT2.js +0 -4
  41. package/dist/_virtual/it_IT3.js +0 -4
  42. package/dist/_virtual/it_IT4.js +0 -4
  43. package/dist/_virtual/it_IT5.js +0 -4
  44. package/dist/_virtual/it_IT6.js +0 -4
  45. package/dist/_virtual/objectSpread2.js +0 -4
  46. package/dist/_virtual/pt_PT.js +0 -4
  47. package/dist/_virtual/pt_PT2.js +0 -4
  48. package/dist/_virtual/pt_PT3.js +0 -4
  49. package/dist/_virtual/pt_PT4.js +0 -4
  50. package/dist/_virtual/pt_PT5.js +0 -4
  51. package/dist/_virtual/pt_PT6.js +0 -4
  52. package/dist/_virtual/toPrimitive.js +0 -4
  53. package/dist/_virtual/toPropertyKey.js +0 -4
  54. package/dist/_virtual/typeof.js +0 -4
  55. package/dist/components/AddAttachments/AddAttachments.d.ts +0 -18
  56. package/dist/components/AddAttachments/AddAttachments.js +0 -87
  57. package/dist/components/AddAttachments/components/AddAttachmentToWorkspaceModal.d.ts +0 -9
  58. package/dist/components/AddAttachments/components/AddAttachmentToWorkspaceModal.js +0 -41
  59. package/dist/components/AddAttachments/components/SingleAttachment.d.ts +0 -13
  60. package/dist/components/AddAttachments/components/SingleAttachment.js +0 -27
  61. package/dist/components/AddAttachments/index.d.ts +0 -2
  62. package/dist/components/AddAttachments/models/attachment.d.ts +0 -9
  63. package/dist/modules/icons/components/IconCollect.d.ts +0 -7
  64. package/dist/modules/icons/components/IconCollect.js +0 -12
  65. package/dist/modules/icons/components/IconSubmission.d.ts +0 -7
  66. package/dist/modules/icons/components/IconSubmission.js +0 -12
  67. package/dist/node_modules/.pnpm/@babel_runtime@7.28.6/node_modules/@babel/runtime/helpers/defineProperty.js +0 -18
  68. package/dist/node_modules/.pnpm/@babel_runtime@7.28.6/node_modules/@babel/runtime/helpers/interopRequireDefault.js +0 -13
  69. package/dist/node_modules/.pnpm/@babel_runtime@7.28.6/node_modules/@babel/runtime/helpers/objectSpread2.js +0 -31
  70. package/dist/node_modules/.pnpm/@babel_runtime@7.28.6/node_modules/@babel/runtime/helpers/toPrimitive.js +0 -20
  71. package/dist/node_modules/.pnpm/@babel_runtime@7.28.6/node_modules/@babel/runtime/helpers/toPropertyKey.js +0 -15
  72. package/dist/node_modules/.pnpm/@babel_runtime@7.28.6/node_modules/@babel/runtime/helpers/typeof.js +0 -16
  73. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/calendar/locale/de_DE.js +0 -11
  74. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/calendar/locale/es_ES.js +0 -11
  75. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/calendar/locale/fr_FR.js +0 -11
  76. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/calendar/locale/it_IT.js +0 -11
  77. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/calendar/locale/pt_PT.js +0 -11
  78. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/date-picker/locale/de_DE.js +0 -22
  79. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/date-picker/locale/es_ES.js +0 -22
  80. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/date-picker/locale/fr_FR.js +0 -27
  81. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/date-picker/locale/it_IT.js +0 -20
  82. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/date-picker/locale/pt_PT.js +0 -45
  83. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/locale/de_DE.js +0 -145
  84. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/locale/es_ES.js +0 -145
  85. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/locale/fr_FR.js +0 -144
  86. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/locale/it_IT.js +0 -156
  87. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/locale/pt_PT.js +0 -158
  88. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/time-picker/locale/de_DE.js +0 -10
  89. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/time-picker/locale/es_ES.js +0 -10
  90. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/time-picker/locale/fr_FR.js +0 -10
  91. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/time-picker/locale/it_IT.js +0 -10
  92. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/lib/time-picker/locale/pt_PT.js +0 -10
  93. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/locale/de_DE.js +0 -8
  94. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/locale/es_ES.js +0 -8
  95. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/locale/fr_FR.js +0 -8
  96. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/locale/it_IT.js +0 -8
  97. package/dist/node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/locale/pt_PT.js +0 -8
  98. package/dist/node_modules/.pnpm/rc-pagination@5.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-pagination/lib/locale/de_DE.js +0 -21
  99. package/dist/node_modules/.pnpm/rc-pagination@5.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-pagination/lib/locale/es_ES.js +0 -21
  100. package/dist/node_modules/.pnpm/rc-pagination@5.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-pagination/lib/locale/fr_FR.js +0 -21
  101. package/dist/node_modules/.pnpm/rc-pagination@5.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-pagination/lib/locale/it_IT.js +0 -21
  102. package/dist/node_modules/.pnpm/rc-pagination@5.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-pagination/lib/locale/pt_PT.js +0 -21
  103. package/dist/node_modules/.pnpm/rc-picker@4.11.3_dayjs@1.11.19_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-picker/lib/locale/common.js +0 -14
  104. package/dist/node_modules/.pnpm/rc-picker@4.11.3_dayjs@1.11.19_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-picker/lib/locale/de_DE.js +0 -37
  105. package/dist/node_modules/.pnpm/rc-picker@4.11.3_dayjs@1.11.19_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-picker/lib/locale/es_ES.js +0 -37
  106. package/dist/node_modules/.pnpm/rc-picker@4.11.3_dayjs@1.11.19_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-picker/lib/locale/fr_FR.js +0 -38
  107. package/dist/node_modules/.pnpm/rc-picker@4.11.3_dayjs@1.11.19_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-picker/lib/locale/it_IT.js +0 -37
  108. package/dist/node_modules/.pnpm/rc-picker@4.11.3_dayjs@1.11.19_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/rc-picker/lib/locale/pt_PT.js +0 -39
  109. package/dist/types/color.d.ts +0 -3
package/dist/index.js CHANGED
@@ -1,5 +1,4 @@
1
1
  import { default as default2 } from "./components/ActionBar/ActionBar.js";
2
- import { AddAttachments } from "./components/AddAttachments/AddAttachments.js";
3
2
  import { default as default3 } from "./components/Alert/Alert.js";
4
3
  import { default as default4 } from "./components/AppHeader/AppHeader.js";
5
4
  import { default as default5 } from "./components/AppIcon/AppIcon.js";
@@ -146,7 +145,6 @@ import { useTreeView } from "./components/TreeView/hooks/useTreeView.js";
146
145
  export {
147
146
  AccessiblePalette,
148
147
  default2 as ActionBar,
149
- AddAttachments,
150
148
  default3 as Alert,
151
149
  AntProvider,
152
150
  default4 as AppHeader,
@@ -32,7 +32,6 @@ export { default as IconClock } from './IconClock';
32
32
  export { default as IconCloseFullScreen } from './IconCloseFullScreen';
33
33
  export { default as IconClose } from './IconClose';
34
34
  export { default as IconCode } from './IconCode';
35
- export { default as IconCollect } from './IconCollect';
36
35
  export { default as IconCopy } from './IconCopy';
37
36
  export { default as IconCrop } from './IconCrop';
38
37
  export { default as IconCut } from './IconCut';
@@ -141,7 +140,6 @@ export { default as IconSplitCells } from './IconSplitCells';
141
140
  export { default as IconSquareRoot } from './IconSquareRoot';
142
141
  export { default as IconStarFull } from './IconStarFull';
143
142
  export { default as IconStar } from './IconStar';
144
- export { default as IconSubmission } from './IconSubmission';
145
143
  export { default as IconSubmitToValidate } from './IconSubmitToValidate';
146
144
  export { default as IconSubscript } from './IconSubscript';
147
145
  export { default as IconSuccessFill } from './IconSuccessFill';
@@ -1,6 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { CreateParameters, CreateResult, ID, IFolder, UpdateParameters, UpdateResult } from '@edifice.io/client';
3
- import { UseMutationResult } from '../../../../node_modules/@tanstack/react-query';
3
+ import { UseMutationResult } from '../../../node_modules/@tanstack/react-query';
4
4
  export interface FormInputs {
5
5
  title: string;
6
6
  description: string;
@@ -1,5 +1,5 @@
1
1
  import { UpdateParameters, UpdateResult } from '@edifice.io/client';
2
- import { UseMutationOptions, UseMutationResult } from '../../../../../node_modules/@tanstack/react-query';
2
+ import { UseMutationOptions, UseMutationResult } from '../../../../node_modules/@tanstack/react-query';
3
3
  declare const useUpdateMutation: ({ application, options, }: {
4
4
  application: string;
5
5
  options?: UseMutationOptions<UpdateResult, Error, UpdateParameters>;
@@ -1,5 +1,5 @@
1
1
  import { ID, PutShareResponse, RightStringified, ShareRight, ShareRightAction, ShareRightActionDisplayName, ShareUrls } from '@edifice.io/client';
2
- import { UseMutationResult } from '../../../../node_modules/@tanstack/react-query';
2
+ import { UseMutationResult } from '../../../node_modules/@tanstack/react-query';
3
3
  /**
4
4
  * Configuration options for sharing a resource
5
5
  *
@@ -1,5 +1,5 @@
1
1
  import { ID, UpdateParameters, UpdateResult } from '@edifice.io/client';
2
- import { UseMutationResult } from '../../../../../node_modules/@tanstack/react-query';
2
+ import { UseMutationResult } from '../../../../node_modules/@tanstack/react-query';
3
3
  export type PublicationType = 'RESTRAINT' | 'IMMEDIATE' | undefined;
4
4
  export interface ShareBlogProps {
5
5
  resourceId: ID;
@@ -1,5 +1,5 @@
1
1
  import { PutShareResponse, ShareRight } from '@edifice.io/client';
2
- import { UseMutationOptions, UseMutationResult } from '../../../../../node_modules/@tanstack/react-query';
2
+ import { UseMutationOptions, UseMutationResult } from '../../../../node_modules/@tanstack/react-query';
3
3
  declare const useShareMutation: ({ application, options, }: {
4
4
  application: string;
5
5
  options?: UseMutationOptions<PutShareResponse, Error, {
@@ -3,11 +3,11 @@ import { ConfigProvider } from "antd";
3
3
  import { antTheme } from "./antThemeConfig.js";
4
4
  /* empty css */
5
5
  import { useEdificeClient } from "../EdificeClientProvider/EdificeClientProvider.hook.js";
6
- import frFR from "../../node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/locale/fr_FR.js";
7
- import deDE from "../../node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/locale/de_DE.js";
8
- import esES from "../../node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/locale/es_ES.js";
9
- import itIT from "../../node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/locale/it_IT.js";
10
- import ptPT from "../../node_modules/.pnpm/antd@5.29.3_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/antd/locale/pt_PT.js";
6
+ import frFR from "antd/locale/fr_FR";
7
+ import deDE from "antd/locale/de_DE";
8
+ import esES from "antd/locale/es_ES";
9
+ import itIT from "antd/locale/it_IT";
10
+ import ptPT from "antd/locale/pt_PT";
11
11
  const antdLocaleMap = {
12
12
  fr: frFR,
13
13
  de: deDE,
@@ -1,6 +1,6 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { App, IGetConf, IGetSession, IUserDescription, IUserInfo, IWebApp, UserProfile } from '@edifice.io/client';
3
- import { UseQueryResult } from '../../../node_modules/@tanstack/react-query';
3
+ import { UseQueryResult } from '../../node_modules/@tanstack/react-query';
4
4
  export interface EdificeClientParams {
5
5
  alternativeApp?: boolean;
6
6
  app: App;
@@ -1,4 +1,4 @@
1
- import { InvalidateQueryFilters, QueryClient } from '../../../node_modules/@tanstack/react-query';
1
+ import { InvalidateQueryFilters, QueryClient } from '../../node_modules/@tanstack/react-query';
2
2
  /**
3
3
  * Invalidates queries and resets infinite query data to only contain the first page.
4
4
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@edifice.io/react",
3
- "version": "2.5.9-develop-pedago.20260213112355",
3
+ "version": "2.5.9-develop-b2school.20260213162502",
4
4
  "description": "Edifice React Library",
5
5
  "keywords": [
6
6
  "react",
@@ -135,9 +135,9 @@
135
135
  "swiper": "^10.1.0",
136
136
  "ua-parser-js": "^1.0.36",
137
137
  "react-pdf": "10.2.0",
138
- "@edifice.io/bootstrap": "2.5.9-develop-pedago.20260213112355",
139
- "@edifice.io/utilities": "2.5.9-develop-pedago.20260213112355",
140
- "@edifice.io/tiptap-extensions": "2.5.9-develop-pedago.20260213112355"
138
+ "@edifice.io/tiptap-extensions": "2.5.9-develop-b2school.20260213162502",
139
+ "@edifice.io/utilities": "2.5.9-develop-b2school.20260213162502",
140
+ "@edifice.io/bootstrap": "2.5.9-develop-b2school.20260213162502"
141
141
  },
142
142
  "devDependencies": {
143
143
  "@babel/plugin-transform-react-pure-annotations": "^7.23.3",
@@ -168,8 +168,8 @@
168
168
  "vite": "^5.4.11",
169
169
  "vite-plugin-dts": "^4.1.0",
170
170
  "vite-tsconfig-paths": "^5.0.1",
171
- "@edifice.io/client": "2.5.9-develop-pedago.20260213112355",
172
- "@edifice.io/config": "2.5.9-develop-pedago.20260213112355"
171
+ "@edifice.io/client": "2.5.9-develop-b2school.20260213162502",
172
+ "@edifice.io/config": "2.5.9-develop-b2school.20260213162502"
173
173
  },
174
174
  "peerDependencies": {
175
175
  "@react-spring/web": "^9.7.5",
@@ -1,4 +0,0 @@
1
- var common = {};
2
- export {
3
- common as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var de_DE = {};
2
- export {
3
- de_DE as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var de_DE = {};
2
- export {
3
- de_DE as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var de_DE = {};
2
- export {
3
- de_DE as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var de_DE = {};
2
- export {
3
- de_DE as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var de_DE = {};
2
- export {
3
- de_DE as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var de_DE = {};
2
- export {
3
- de_DE as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var defineProperty = { exports: {} };
2
- export {
3
- defineProperty as __module
4
- };
@@ -1,4 +0,0 @@
1
- var es_ES = {};
2
- export {
3
- es_ES as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var es_ES = {};
2
- export {
3
- es_ES as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var es_ES = {};
2
- export {
3
- es_ES as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var es_ES = {};
2
- export {
3
- es_ES as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var es_ES = {};
2
- export {
3
- es_ES as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var es_ES = {};
2
- export {
3
- es_ES as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var fr_FR = {};
2
- export {
3
- fr_FR as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var fr_FR = {};
2
- export {
3
- fr_FR as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var fr_FR = {};
2
- export {
3
- fr_FR as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var fr_FR = {};
2
- export {
3
- fr_FR as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var fr_FR = {};
2
- export {
3
- fr_FR as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var fr_FR = {};
2
- export {
3
- fr_FR as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var interopRequireDefault = { exports: {} };
2
- export {
3
- interopRequireDefault as __module
4
- };
@@ -1,4 +0,0 @@
1
- var it_IT = {};
2
- export {
3
- it_IT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var it_IT = {};
2
- export {
3
- it_IT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var it_IT = {};
2
- export {
3
- it_IT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var it_IT = {};
2
- export {
3
- it_IT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var it_IT = {};
2
- export {
3
- it_IT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var it_IT = {};
2
- export {
3
- it_IT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var objectSpread2 = { exports: {} };
2
- export {
3
- objectSpread2 as __module
4
- };
@@ -1,4 +0,0 @@
1
- var pt_PT = {};
2
- export {
3
- pt_PT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var pt_PT = {};
2
- export {
3
- pt_PT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var pt_PT = {};
2
- export {
3
- pt_PT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var pt_PT = {};
2
- export {
3
- pt_PT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var pt_PT = {};
2
- export {
3
- pt_PT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var pt_PT = {};
2
- export {
3
- pt_PT as __exports
4
- };
@@ -1,4 +0,0 @@
1
- var toPrimitive = { exports: {} };
2
- export {
3
- toPrimitive as __module
4
- };
@@ -1,4 +0,0 @@
1
- var toPropertyKey = { exports: {} };
2
- export {
3
- toPropertyKey as __module
4
- };
@@ -1,4 +0,0 @@
1
- var _typeof = { exports: {} };
2
- export {
3
- _typeof as __module
4
- };
@@ -1,18 +0,0 @@
1
- import { Attachment } from './models/attachment';
2
- export interface AddAttachmentsProps {
3
- attachments: Attachment[];
4
- onFilesSelected: (files: File[]) => void;
5
- onRemoveAttachment: (attachmentId: string) => void;
6
- editMode?: boolean;
7
- isMutating?: boolean;
8
- onCopyToWorkspace?: (attachments: Attachment[], folderId: string) => Promise<boolean>;
9
- /** Si fourni, chaque pièce jointe affiche un bouton télécharger avec l'URL retournée. */
10
- getDownloadUrl?: (attachmentId: string) => string;
11
- /** Si fourni et qu'il y a plusieurs pièces jointes, affiche un bouton « télécharger tout ». */
12
- downloadAllUrl?: string;
13
- }
14
- export declare const AddAttachments: {
15
- ({ attachments, onFilesSelected, onRemoveAttachment, editMode, isMutating, onCopyToWorkspace, getDownloadUrl, downloadAllUrl, }: AddAttachmentsProps): import("react/jsx-runtime").JSX.Element | null;
16
- displayName: string;
17
- };
18
- export default AddAttachments;
@@ -1,87 +0,0 @@
1
- import { jsxs, Fragment, jsx } from "react/jsx-runtime";
2
- import clsx from "clsx";
3
- import { useRef, useState, useEffect } from "react";
4
- import { useTranslation } from "react-i18next";
5
- import SvgIconDelete from "../../modules/icons/components/IconDelete.js";
6
- import SvgIconDownload from "../../modules/icons/components/IconDownload.js";
7
- import SvgIconFolderAdd from "../../modules/icons/components/IconFolderAdd.js";
8
- import SvgIconPlus from "../../modules/icons/components/IconPlus.js";
9
- import { AddAttachmentToWorkspaceModal } from "./components/AddAttachmentToWorkspaceModal.js";
10
- import { SingleAttachment } from "./components/SingleAttachment.js";
11
- import Flex from "../Flex/Flex.js";
12
- import IconButton from "../Button/IconButton.js";
13
- import Button from "../Button/Button.js";
14
- function fileToAttachment(file) {
15
- return {
16
- id: `${file.name}-${Date.now()}-${Math.random().toString(36).slice(2, 9)}`,
17
- charset: "UTF-8",
18
- contentTransferEncoding: "binary",
19
- contentType: file.type || "application/octet-stream",
20
- filename: file.name,
21
- name: file.name,
22
- size: file.size
23
- };
24
- }
25
- const AddAttachments = ({
26
- attachments,
27
- onFilesSelected,
28
- onRemoveAttachment,
29
- editMode = !1,
30
- isMutating = !1,
31
- onCopyToWorkspace,
32
- getDownloadUrl,
33
- downloadAllUrl
34
- }) => {
35
- const {
36
- t
37
- } = useTranslation(), inputRef = useRef(null), [optimisticAttachments, setOptimisticAttachments] = useState([]), [attachmentsToAddToWorkspace, setAttachmentsToAddToWorkspace] = useState(void 0), prevAttachmentsLengthRef = useRef(attachments.length), displayedAttachments = [...attachments, ...optimisticAttachments];
38
- if (useEffect(() => {
39
- attachments.length > prevAttachmentsLengthRef.current && setOptimisticAttachments([]), prevAttachmentsLengthRef.current = attachments.length;
40
- }, [attachments.length]), !editMode && !displayedAttachments.length) return null;
41
- const resetInputValue = () => {
42
- inputRef.current && (inputRef.current.value = "");
43
- }, handleAttachClick = () => {
44
- var _a;
45
- return (_a = inputRef == null ? void 0 : inputRef.current) == null ? void 0 : _a.click();
46
- }, handleFileChange = (event) => {
47
- const files = Array.from(event.target.files ?? []);
48
- if (files.length > 0) {
49
- onFilesSelected(files);
50
- const newOptimistic = files.map(fileToAttachment);
51
- setOptimisticAttachments((prev) => [...prev, ...newOptimistic]);
52
- }
53
- resetInputValue();
54
- }, handleDetachAllClick = () => {
55
- setOptimisticAttachments([]), attachments.forEach((attachment) => {
56
- onRemoveAttachment(attachment.id);
57
- }), resetInputValue();
58
- }, handleDetachClick = (attachmentId) => {
59
- optimisticAttachments.some((attachment) => attachment.id === attachmentId) ? setOptimisticAttachments((prev) => prev.filter((attachment) => attachment.id !== attachmentId)) : onRemoveAttachment(attachmentId), resetInputValue();
60
- }, handleCopyToWorkspace = (attachments2) => {
61
- setAttachmentsToAddToWorkspace(attachments2);
62
- }, className = clsx("bg-gray-200 rounded px-12 py-8 message-attachments align-self-start gap-8 d-flex flex-column mw-100", {
63
- "border add-attachments-edit mx-16": editMode
64
- });
65
- return /* @__PURE__ */ jsxs("div", { className, "data-drag-handle": !0, children: [
66
- !!displayedAttachments.length && /* @__PURE__ */ jsxs(Fragment, { children: [
67
- /* @__PURE__ */ jsxs(Flex, { direction: "row", align: "center", justify: "between", className: "border-bottom", children: [
68
- /* @__PURE__ */ jsx("span", { className: "caption fw-bold my-8", children: t("attachments") }),
69
- displayedAttachments.length > 1 && /* @__PURE__ */ jsxs("div", { children: [
70
- onCopyToWorkspace && /* @__PURE__ */ jsx(IconButton, { title: t("conversation.copy.all.toworkspace"), color: "tertiary", type: "button", icon: /* @__PURE__ */ jsx(SvgIconFolderAdd, {}), onClick: () => handleCopyToWorkspace(displayedAttachments), variant: "ghost" }),
71
- downloadAllUrl && /* @__PURE__ */ jsx("a", { href: downloadAllUrl, download: !0, children: /* @__PURE__ */ jsx(IconButton, { title: t("download.all.attachment"), color: "tertiary", type: "button", icon: /* @__PURE__ */ jsx(SvgIconDownload, {}), variant: "ghost" }) }),
72
- editMode && /* @__PURE__ */ jsx(IconButton, { title: t("remove.all.attachment"), color: "danger", type: "button", icon: /* @__PURE__ */ jsx(SvgIconDelete, {}), variant: "ghost", onClick: handleDetachAllClick, disabled: isMutating })
73
- ] })
74
- ] }),
75
- /* @__PURE__ */ jsx("ul", { className: "d-flex gap-8 flex-column list-unstyled m-0", children: displayedAttachments.map((attachment) => /* @__PURE__ */ jsx("li", { className: "mw-100", children: /* @__PURE__ */ jsx(SingleAttachment, { attachment, editMode, onDelete: handleDetachClick, onCopyToWorkspace: onCopyToWorkspace ? (attachment2) => handleCopyToWorkspace([attachment2]) : void 0, getDownloadUrl, disabled: isMutating }) }, attachment.id)) })
76
- ] }),
77
- editMode && /* @__PURE__ */ jsxs(Fragment, { children: [
78
- /* @__PURE__ */ jsx(Button, { color: "secondary", variant: "ghost", isLoading: isMutating, onClick: handleAttachClick, disabled: isMutating, className: "align-self-start", leftIcon: /* @__PURE__ */ jsx(SvgIconPlus, {}), children: t("add.attachment") }),
79
- /* @__PURE__ */ jsx("input", { ref: inputRef, multiple: !0, type: "file", name: "attachment-input", id: "attachment-input", onChange: handleFileChange, hidden: !0 })
80
- ] }),
81
- onCopyToWorkspace && !!attachmentsToAddToWorkspace && /* @__PURE__ */ jsx(AddAttachmentToWorkspaceModal, { isOpen: !0, onModalClose: () => setAttachmentsToAddToWorkspace(void 0), attachments: attachmentsToAddToWorkspace, onCopyToWorkspace })
82
- ] });
83
- };
84
- export {
85
- AddAttachments,
86
- AddAttachments as default
87
- };
@@ -1,9 +0,0 @@
1
- import { Attachment } from '../models/attachment';
2
- interface AddAttachmentToWorkspaceModalProps {
3
- attachments: Attachment[];
4
- onModalClose: () => void;
5
- isOpen?: boolean;
6
- onCopyToWorkspace: (attachments: Attachment[], folderId: string) => Promise<boolean>;
7
- }
8
- export declare function AddAttachmentToWorkspaceModal({ attachments, isOpen, onModalClose, onCopyToWorkspace, }: AddAttachmentToWorkspaceModalProps): import('react').ReactPortal;
9
- export {};
@@ -1,41 +0,0 @@
1
- import { jsxs, jsx } from "react/jsx-runtime";
2
- import { useState, useEffect } from "react";
3
- import { createPortal } from "react-dom";
4
- import { toast } from "react-hot-toast";
5
- import { useTranslation } from "react-i18next";
6
- import Modal from "../../Modal/Modal.js";
7
- import WorkspaceFolders from "../../../modules/multimedia/WorkspaceFolders/WorkspaceFolders.js";
8
- import Button from "../../Button/Button.js";
9
- function AddAttachmentToWorkspaceModal({
10
- attachments,
11
- isOpen = !1,
12
- onModalClose,
13
- onCopyToWorkspace
14
- }) {
15
- const {
16
- t
17
- } = useTranslation(), [selectedFolderIdToCopyFile, setSelectedFolderIdToCopyFile] = useState(void 0), [isLoading, setIsLoading] = useState(!1), [disabled, setDisabled] = useState(!1), handleFolderSelected = (folderId, canCopyFileInto) => {
18
- setSelectedFolderIdToCopyFile(canCopyFileInto ? folderId : void 0);
19
- }, handleAddAttachmentToWorkspace = async () => {
20
- if (selectedFolderIdToCopyFile === void 0) return;
21
- setIsLoading(!0), await onCopyToWorkspace(attachments, selectedFolderIdToCopyFile) ? onModalClose() : toast.error(t("attachments.add.to.folder.modal.error")), setIsLoading(!1);
22
- };
23
- return useEffect(() => {
24
- setDisabled(selectedFolderIdToCopyFile === void 0);
25
- }, [selectedFolderIdToCopyFile]), /* @__PURE__ */ createPortal(/* @__PURE__ */ jsxs(Modal, { isOpen, onModalClose, id: "add-attachment-to-workspace-modal", size: "md", children: [
26
- /* @__PURE__ */ jsx(Modal.Header, { onModalClose, children: t("attachments.add.to.folder.modal.title") }),
27
- /* @__PURE__ */ jsx(Modal.Body, { children: /* @__PURE__ */ jsxs("div", { className: "d-flex flex-column gap-12", children: [
28
- /* @__PURE__ */ jsx("p", { children: t("attachments.add.to.folder.modal.description", {
29
- count: attachments.length
30
- }) }),
31
- /* @__PURE__ */ jsx(WorkspaceFolders, { onFolderSelected: handleFolderSelected })
32
- ] }) }),
33
- /* @__PURE__ */ jsxs(Modal.Footer, { children: [
34
- /* @__PURE__ */ jsx(Button, { type: "button", color: "tertiary", variant: "ghost", onClick: onModalClose, children: t("attachments.add.to.folder.modal.cancel") }),
35
- /* @__PURE__ */ jsx(Button, { color: "primary", variant: "filled", onClick: handleAddAttachmentToWorkspace, disabled: isLoading || disabled, isLoading, children: t("attachments.add.to.folder.modal.add") })
36
- ] })
37
- ] }), document.getElementById("portal"));
38
- }
39
- export {
40
- AddAttachmentToWorkspaceModal
41
- };
@@ -1,13 +0,0 @@
1
- import { Attachment } from '../models/attachment';
2
- export interface SingleAttachmentProps {
3
- attachment: Attachment;
4
- onDelete: (attachmentId: string) => void;
5
- editMode?: boolean;
6
- /** Si fourni, affiche le bouton « copier vers l'espace » et appelle ce callback au clic. */
7
- onCopyToWorkspace?: (attachment: Attachment) => void;
8
- /** Si fourni, affiche le bouton télécharger avec l'URL retournée. */
9
- getDownloadUrl?: (attachmentId: string) => string;
10
- /** Désactive les boutons d'action (ex. pendant une suppression). */
11
- disabled?: boolean;
12
- }
13
- export declare function SingleAttachment({ attachment, onDelete, editMode, onCopyToWorkspace, getDownloadUrl, disabled, }: SingleAttachmentProps): import("react/jsx-runtime").JSX.Element;
@@ -1,27 +0,0 @@
1
- import { jsx, jsxs, Fragment } from "react/jsx-runtime";
2
- import SvgIconDelete from "../../../modules/icons/components/IconDelete.js";
3
- import SvgIconDownload from "../../../modules/icons/components/IconDownload.js";
4
- import SvgIconFolderAdd from "../../../modules/icons/components/IconFolderAdd.js";
5
- import { useTranslation } from "react-i18next";
6
- import Attachment from "../../Attachment/Attachment.js";
7
- import IconButton from "../../Button/IconButton.js";
8
- function SingleAttachment({
9
- attachment,
10
- onDelete,
11
- editMode = !1,
12
- onCopyToWorkspace,
13
- getDownloadUrl,
14
- disabled = !1
15
- }) {
16
- const {
17
- t
18
- } = useTranslation(), downloadUrl = getDownloadUrl == null ? void 0 : getDownloadUrl(attachment.id);
19
- return /* @__PURE__ */ jsx(Attachment, { name: attachment.filename, options: /* @__PURE__ */ jsxs(Fragment, { children: [
20
- onCopyToWorkspace && /* @__PURE__ */ jsx(IconButton, { title: t("conversation.copy.toworkspace"), color: "tertiary", type: "button", icon: /* @__PURE__ */ jsx(SvgIconFolderAdd, {}), variant: "ghost", onClick: () => onCopyToWorkspace(attachment), disabled }),
21
- downloadUrl !== void 0 && /* @__PURE__ */ jsx("a", { href: downloadUrl, download: !0, children: /* @__PURE__ */ jsx(IconButton, { title: t("download.attachment"), color: "tertiary", type: "button", icon: /* @__PURE__ */ jsx(SvgIconDownload, {}), variant: "ghost", disabled }) }),
22
- editMode && /* @__PURE__ */ jsx(IconButton, { title: t("remove.attachment"), color: "danger", type: "button", icon: /* @__PURE__ */ jsx(SvgIconDelete, {}), variant: "ghost", onClick: () => onDelete(attachment.id), disabled })
23
- ] }) });
24
- }
25
- export {
26
- SingleAttachment
27
- };
@@ -1,2 +0,0 @@
1
- export { default as AddAttachments } from './AddAttachments';
2
- export * from './AddAttachments';
@@ -1,9 +0,0 @@
1
- export type Attachment = {
2
- id: string;
3
- charset: string;
4
- contentTransferEncoding: string;
5
- contentType: string;
6
- filename: string;
7
- name: string;
8
- size: number;
9
- };
@@ -1,7 +0,0 @@
1
- import { SVGProps } from 'react';
2
- interface SVGRProps {
3
- title?: string;
4
- titleId?: string;
5
- }
6
- declare const SvgIconCollect: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & SVGRProps) => import("react/jsx-runtime").JSX.Element;
7
- export default SvgIconCollect;
@@ -1,12 +0,0 @@
1
- import { jsxs, jsx } from "react/jsx-runtime";
2
- const SvgIconCollect = ({
3
- title,
4
- titleId,
5
- ...props
6
- }) => /* @__PURE__ */ jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", width: "24", height: "24", fill: "none", viewBox: "0 0 20 20", "aria-hidden": "true", "aria-labelledby": titleId, ...props, children: [
7
- title ? /* @__PURE__ */ jsx("title", { id: titleId, children: title }) : null,
8
- /* @__PURE__ */ jsx("path", { fill: "currentColor", d: "M14.988 1.667c.852 0 1.619.519 1.935 1.31l1.352 3.38q.008.02.013.04.006.015.01.03l.012.043.015.08.005.039.003.06.001.018v9.382a2.26 2.26 0 0 1-.693 1.625c-.44.425-1.03.659-1.64.659h-12c-.61 0-1.2-.234-1.64-.66a2.26 2.26 0 0 1-.693-1.624v-9.4l.003-.06.005-.04.015-.08.008-.03.006-.02a1 1 0 0 1 .028-.077L3.08 2.977a2.08 2.08 0 0 1 1.934-1.31zM3.334 16.049c0 .154.063.31.186.428.123.119.296.19.481.19h12a.7.7 0 0 0 .481-.19.6.6 0 0 0 .186-.428V7.5H3.334zm8.334-6.882a.833.833 0 0 1 0 1.666H8.334a.833.833 0 0 1 0-1.666zM5.014 3.333a.42.42 0 0 0-.386.263l-.896 2.237h12.539l-.896-2.237a.42.42 0 0 0-.387-.263z" })
9
- ] });
10
- export {
11
- SvgIconCollect as default
12
- };
@@ -1,7 +0,0 @@
1
- import { SVGProps } from 'react';
2
- interface SVGRProps {
3
- title?: string;
4
- titleId?: string;
5
- }
6
- declare const SvgIconSubmission: ({ title, titleId, ...props }: SVGProps<SVGSVGElement> & SVGRProps) => import("react/jsx-runtime").JSX.Element;
7
- export default SvgIconSubmission;