@egen-civitas/esm-styleguide 2.3.0 → 3.0.0
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/CHANGELOG.md +46 -0
- package/dist/_all.scss +0 -1
- package/dist/_vars.scss +4 -4
- package/dist/assistant/index.d.ts +7 -0
- package/dist/assistant/index.d.ts.map +1 -1
- package/dist/assistant/index.js +5 -0
- package/dist/assistant/live-orb.component.d.ts +6 -0
- package/dist/assistant/live-orb.component.d.ts.map +1 -1
- package/dist/assistant/live-orb.component.js +15 -3
- package/dist/assistant/robot/README.md +47 -0
- package/dist/assistant/robot/Robot.d.ts +16 -0
- package/dist/assistant/robot/Robot.d.ts.map +1 -0
- package/dist/assistant/robot/Robot.js +159 -0
- package/dist/assistant/robot/RobotStage.d.ts +31 -0
- package/dist/assistant/robot/RobotStage.d.ts.map +1 -0
- package/dist/assistant/robot/RobotStage.js +250 -0
- package/dist/assistant/robot/clips.d.ts +62 -0
- package/dist/assistant/robot/clips.d.ts.map +1 -0
- package/dist/assistant/robot/clips.js +179 -0
- package/dist/assistant/robot/controller.d.ts +133 -0
- package/dist/assistant/robot/controller.d.ts.map +1 -0
- package/dist/assistant/robot/controller.js +522 -0
- package/dist/assistant/robot/gestures.d.ts +23 -0
- package/dist/assistant/robot/gestures.d.ts.map +1 -0
- package/dist/assistant/robot/gestures.js +1301 -0
- package/dist/assistant/robot/hands.d.ts +55 -0
- package/dist/assistant/robot/hands.d.ts.map +1 -0
- package/dist/assistant/robot/hands.js +121 -0
- package/dist/assistant/robot/ik.d.ts +34 -0
- package/dist/assistant/robot/ik.d.ts.map +1 -0
- package/dist/assistant/robot/ik.js +57 -0
- package/dist/assistant/robot/index.d.ts +18 -0
- package/dist/assistant/robot/index.d.ts.map +1 -0
- package/dist/assistant/robot/index.js +9 -0
- package/dist/assistant/robot/lazy.d.ts +8 -0
- package/dist/assistant/robot/lazy.d.ts.map +1 -0
- package/dist/assistant/robot/lazy.js +33 -0
- package/dist/assistant/robot/materials.d.ts +46 -0
- package/dist/assistant/robot/materials.d.ts.map +1 -0
- package/dist/assistant/robot/materials.js +101 -0
- package/dist/assistant/robot/parts/Body.d.ts +28 -0
- package/dist/assistant/robot/parts/Body.d.ts.map +1 -0
- package/dist/assistant/robot/parts/Body.js +368 -0
- package/dist/assistant/robot/parts/Head.d.ts +11 -0
- package/dist/assistant/robot/parts/Head.d.ts.map +1 -0
- package/dist/assistant/robot/parts/Head.js +210 -0
- package/dist/assistant/robot/parts/primitives.d.ts +36 -0
- package/dist/assistant/robot/parts/primitives.d.ts.map +1 -0
- package/dist/assistant/robot/parts/primitives.js +127 -0
- package/dist/assistant/robot/skeleton.d.ts +66 -0
- package/dist/assistant/robot/skeleton.d.ts.map +1 -0
- package/dist/assistant/robot/skeleton.js +266 -0
- package/dist/cards/card-header.component.d.ts +1 -1
- package/dist/cards/card-header.component.js +1 -1
- package/dist/cards/card-header.stories.js +1 -1
- package/dist/components/_general.scss +3 -3
- package/dist/config-schema.d.ts +0 -17
- package/dist/config-schema.d.ts.map +1 -1
- package/dist/config-schema.js +0 -25
- package/dist/datepicker/datepicker.stories.js +1 -1
- package/dist/empty-card/empty-card.stories.js +2 -2
- package/dist/error-state/error-state.stories.js +2 -2
- package/dist/icons/icon-registration.d.ts.map +1 -1
- package/dist/icons/icon-registration.js +0 -30
- package/dist/icons/icons.d.ts +4 -32
- package/dist/icons/icons.d.ts.map +1 -1
- package/dist/icons/icons.js +18 -148
- package/dist/index.js +0 -2
- package/dist/internal.d.ts +0 -3
- package/dist/internal.d.ts.map +1 -1
- package/dist/internal.js +0 -3
- package/dist/notifications/actionable-notification.stories.js +5 -5
- package/dist/notifications/notification.stories.js +5 -5
- package/dist/page-header/page-header.component.d.ts +1 -1
- package/dist/page-header/page-header.component.js +1 -1
- package/dist/pagination/pagination.stories.js +2 -2
- package/dist/pictograms/pictogram-registration.d.ts.map +1 -1
- package/dist/pictograms/pictogram-registration.js +2 -36
- package/dist/pictograms/pictograms.d.ts +2 -20
- package/dist/pictograms/pictograms.d.ts.map +1 -1
- package/dist/pictograms/pictograms.js +2 -139
- package/dist/public.d.ts +0 -3
- package/dist/public.d.ts.map +1 -1
- package/dist/public.js +0 -3
- package/dist/responsive-wrapper/responsive-wrapper.stories.js +1 -1
- package/dist/snackbars/snackbar.stories.js +1 -1
- package/dist/toasts/toast.stories.js +1 -1
- package/dist/workbench/splitter.component.d.ts +14 -0
- package/dist/workbench/splitter.component.d.ts.map +1 -1
- package/dist/workbench/splitter.component.js +52 -0
- package/dist/workbench/tool-window-rail.component.d.ts.map +1 -1
- package/dist/workbench/tool-window-rail.component.js +9 -1
- package/dist/workbench/tool-window-zone.component.d.ts.map +1 -1
- package/dist/workbench/tool-window-zone.component.js +9 -1
- package/dist/workbench/workbench.module.scss +64 -1
- package/dist/workbench/workbench.store.d.ts +2 -0
- package/dist/workbench/workbench.store.d.ts.map +1 -1
- package/dist/workbench/workbench.store.js +9 -0
- package/dist/workspaces/container/workspace-container.component.d.ts +8 -8
- package/dist/workspaces/container/workspace-container.component.js +9 -9
- package/dist/workspaces2/workspace2.d.ts +3 -3
- package/dist/workspaces2/workspace2.js +3 -3
- package/mock-jest.tsx +0 -41
- package/mock.tsx +0 -41
- package/package.json +26 -23
- package/src/_vars.scss +4 -4
- package/dist/entity-banner/actions-menu/entity-banner-actions-menu.component.d.ts +0 -19
- package/dist/entity-banner/actions-menu/entity-banner-actions-menu.component.d.ts.map +0 -1
- package/dist/entity-banner/actions-menu/entity-banner-actions-menu.component.js +0 -137
- package/dist/entity-banner/actions-menu/entity-banner-actions-menu.module.scss +0 -23
- package/dist/entity-banner/contact-details/entity-banner-contact-details.component.d.ts +0 -9
- package/dist/entity-banner/contact-details/entity-banner-contact-details.component.d.ts.map +0 -1
- package/dist/entity-banner/contact-details/entity-banner-contact-details.component.js +0 -207
- package/dist/entity-banner/contact-details/entity-banner-contact-details.module.scss +0 -47
- package/dist/entity-banner/contact-details/entity-banner-toggle-contact-details-button.component.d.ts +0 -12
- package/dist/entity-banner/contact-details/entity-banner-toggle-contact-details-button.component.d.ts.map +0 -1
- package/dist/entity-banner/contact-details/entity-banner-toggle-contact-details-button.component.js +0 -15
- package/dist/entity-banner/contact-details/types.d.ts +0 -48
- package/dist/entity-banner/contact-details/types.d.ts.map +0 -1
- package/dist/entity-banner/contact-details/types.js +0 -1
- package/dist/entity-banner/contact-details/useEntityAttributes.d.ts +0 -14
- package/dist/entity-banner/contact-details/useEntityAttributes.d.ts.map +0 -1
- package/dist/entity-banner/contact-details/useEntityAttributes.js +0 -12
- package/dist/entity-banner/contact-details/useEntityGroupsForEntity.d.ts +0 -11
- package/dist/entity-banner/contact-details/useEntityGroupsForEntity.d.ts.map +0 -1
- package/dist/entity-banner/contact-details/useEntityGroupsForEntity.js +0 -9
- package/dist/entity-banner/contact-details/useRelationships.d.ts +0 -35
- package/dist/entity-banner/contact-details/useRelationships.d.ts.map +0 -1
- package/dist/entity-banner/contact-details/useRelationships.js +0 -37
- package/dist/entity-banner/entity-info/entity-banner-entity-identifiers.component.d.ts +0 -9
- package/dist/entity-banner/entity-info/entity-banner-entity-identifiers.component.d.ts.map +0 -1
- package/dist/entity-banner/entity-info/entity-banner-entity-identifiers.component.js +0 -77
- package/dist/entity-banner/entity-info/entity-banner-entity-info.component.d.ts +0 -9
- package/dist/entity-banner/entity-info/entity-banner-entity-info.component.d.ts.map +0 -1
- package/dist/entity-banner/entity-info/entity-banner-entity-info.component.js +0 -72
- package/dist/entity-banner/entity-info/entity-banner-entity-info.module.scss +0 -165
- package/dist/entity-banner/index.d.ts +0 -5
- package/dist/entity-banner/index.d.ts.map +0 -1
- package/dist/entity-banner/index.js +0 -4
- package/dist/entity-photo/entity-photo.component.d.ts +0 -21
- package/dist/entity-photo/entity-photo.component.d.ts.map +0 -1
- package/dist/entity-photo/entity-photo.component.js +0 -111
- package/dist/entity-photo/entity-photo.module.scss +0 -21
- package/dist/entity-photo/index.d.ts +0 -3
- package/dist/entity-photo/index.d.ts.map +0 -1
- package/dist/entity-photo/index.js +0 -2
- package/dist/entity-photo/placeholder-icon.component.d.ts +0 -9
- package/dist/entity-photo/placeholder-icon.component.d.ts.map +0 -1
- package/dist/entity-photo/placeholder-icon.component.js +0 -26
- package/dist/entity-photo/useEntityPhoto.d.ts +0 -29
- package/dist/entity-photo/useEntityPhoto.d.ts.map +0 -1
- package/dist/entity-photo/useEntityPhoto.js +0 -37
- package/dist/icons/svgs/baby.svg +0 -1
- package/dist/icons/svgs/chemistry.svg +0 -1
- package/dist/icons/svgs/drug-order.svg +0 -1
- package/dist/icons/svgs/generic-order-type.svg +0 -1
- package/dist/icons/svgs/hospital-bed.svg +0 -1
- package/dist/icons/svgs/image-medical.svg +0 -1
- package/dist/icons/svgs/lab-order.svg +0 -1
- package/dist/icons/svgs/material-order.svg +0 -1
- package/dist/icons/svgs/medication.svg +0 -1
- package/dist/icons/svgs/microscope.svg +0 -1
- package/dist/icons/svgs/mother.svg +0 -1
- package/dist/icons/svgs/procedure-order.svg +0 -1
- package/dist/icons/svgs/referral-order.svg +0 -1
- package/dist/icons/svgs/syringe.svg +0 -1
- package/dist/logo/_logo.scss +0 -34
- package/dist/logo/egen-logo-full.svg +0 -1
- package/dist/logo/egen-logo-icon.svg +0 -1
- package/dist/logo/egen-logo-partial.svg +0 -1
- package/dist/logo/egen-logo-white.svg +0 -1
- package/dist/logo/index.d.ts +0 -8
- package/dist/logo/index.d.ts.map +0 -1
- package/dist/logo/index.js +0 -22
- package/dist/numeric-datapoint/index.d.ts +0 -4
- package/dist/numeric-datapoint/index.d.ts.map +0 -1
- package/dist/numeric-datapoint/index.js +0 -3
- package/dist/numeric-datapoint/interpretation-utils.d.ts +0 -27
- package/dist/numeric-datapoint/interpretation-utils.d.ts.map +0 -1
- package/dist/numeric-datapoint/interpretation-utils.js +0 -66
- package/dist/numeric-datapoint/numeric-datapoint.component.d.ts +0 -44
- package/dist/numeric-datapoint/numeric-datapoint.component.d.ts.map +0 -1
- package/dist/numeric-datapoint/numeric-datapoint.component.js +0 -110
- package/dist/numeric-datapoint/numeric-datapoint.module.scss +0 -141
- package/dist/numeric-datapoint/use-concept-reference-range.d.ts +0 -13
- package/dist/numeric-datapoint/use-concept-reference-range.d.ts.map +0 -1
- package/dist/numeric-datapoint/use-concept-reference-range.js +0 -31
- package/dist/pictograms/svgs/blood-bank.svg +0 -1
- package/dist/pictograms/svgs/cardiology.svg +0 -1
- package/dist/pictograms/svgs/ct-scan.svg +0 -1
- package/dist/pictograms/svgs/dentistry.svg +0 -1
- package/dist/pictograms/svgs/emergency-department.svg +0 -1
- package/dist/pictograms/svgs/geriatrics.svg +0 -1
- package/dist/pictograms/svgs/gynaecology.svg +0 -1
- package/dist/pictograms/svgs/in-patient.svg +0 -1
- package/dist/pictograms/svgs/labs-2.svg +0 -1
- package/dist/pictograms/svgs/labs.svg +0 -1
- package/dist/pictograms/svgs/obstetrics.svg +0 -1
- package/dist/pictograms/svgs/patient-search.svg +0 -1
- package/dist/pictograms/svgs/patients.svg +0 -1
- package/dist/pictograms/svgs/pharmacy-1.svg +0 -1
- package/dist/pictograms/svgs/pharmacy-2.svg +0 -1
- package/dist/pictograms/svgs/triage.svg +0 -1
- package/dist/pictograms/svgs/x-ray.svg +0 -1
|
@@ -105,10 +105,10 @@ import { showModal } from "../modals/index.js";
|
|
|
105
105
|
* To do so, we need to call `launchChildWorkspace` instead.
|
|
106
106
|
*
|
|
107
107
|
* [^1] Omitting window or group props is useful for workspaces that don't have ties to the window or group "context" (props).
|
|
108
|
-
* For example, in the
|
|
109
|
-
* a "group context" of the current
|
|
108
|
+
* For example, in the entity chart, the notes / business forms / order basket action menu button all share
|
|
109
|
+
* a "group context" of the current session. However, the "entity list" action menu button does not need to share that group
|
|
110
110
|
* context, so opening that workspace should not need to cause other workspaces / windows / groups to potentially close.
|
|
111
|
-
* The "
|
|
111
|
+
* The "entity search" workspace in the queues and unit apps is another example.
|
|
112
112
|
*
|
|
113
113
|
* [^2] 2 sets of props are compatible if either one is nullish, or if they are shallow equal.
|
|
114
114
|
* @experimental
|
package/mock-jest.tsx
CHANGED
|
@@ -6,12 +6,10 @@ import { type Classification } from '@egen-civitas/esm-data-api';
|
|
|
6
6
|
// Icon stubs
|
|
7
7
|
export const ActivityIcon = () => <span>ActivityIcon</span>;
|
|
8
8
|
export const AddIcon = () => <span>AddIcon</span>;
|
|
9
|
-
export const AllergiesIcon = () => <span>AllergiesIcon</span>;
|
|
10
9
|
export const ArrowDownIcon = () => <span>ArrowDownIcon</span>;
|
|
11
10
|
export const ArrowLeftIcon = () => <span>ArrowLeftIcon</span>;
|
|
12
11
|
export const ArrowRightIcon = () => <span>ArrowRightIcon</span>;
|
|
13
12
|
export const ArrowUpIcon = () => <span>ArrowUpIcon</span>;
|
|
14
|
-
export const BabyIcon = () => <span>BabyIcon</span>;
|
|
15
13
|
export const CalendarHeatMapIcon = () => <span>CalendarHeatMapIcon</span>;
|
|
16
14
|
export const CalendarIcon = () => <span>CalendarIcon</span>;
|
|
17
15
|
export const CaretDownIcon = () => <span>CaretDownIcon</span>;
|
|
@@ -22,7 +20,6 @@ export const ChartAverageIcon = () => <span>ChartAverageIcon</span>;
|
|
|
22
20
|
export const ChartLineIcon = () => <span>ChartLineIcon</span>;
|
|
23
21
|
export const CheckmarkFilledIcon = () => <span>CheckmarkFilledIcon</span>;
|
|
24
22
|
export const CheckmarkOutlineIcon = () => <span>CheckmarkOutlineIcon</span>;
|
|
25
|
-
export const ChemistryIcon = () => <span>ChemistryIcon</span>;
|
|
26
23
|
export const ChevronDownIcon = () => <span>ChevronDownIcon</span>;
|
|
27
24
|
export const ChevronLeftIcon = () => <span>ChevronLeftIcon</span>;
|
|
28
25
|
export const ChevronRightIcon = () => <span>ChevronRightIcon</span>;
|
|
@@ -30,11 +27,9 @@ export const ChevronUpIcon = () => <span>ChevronUpIcon</span>;
|
|
|
30
27
|
export const CloseIcon = () => <span>CloseIcon</span>;
|
|
31
28
|
export const CloseFilledIcon = () => <span>CloseFilledIcon</span>;
|
|
32
29
|
export const CloseOutlineIcon = () => <span>CloseOutlineIcon</span>;
|
|
33
|
-
export const ConditionsIcon = () => <span>ConditionsIcon</span>;
|
|
34
30
|
export const DocumentIcon = () => <span>DocumentIcon</span>;
|
|
35
31
|
export const DocumentAttachmentIcon = () => <span>DocumentAttachmentIcon</span>;
|
|
36
32
|
export const DownloadIcon = () => <span>DownloadIcon</span>;
|
|
37
|
-
export const DrugOrderIcon = () => <span>DrugOrderIcon</span>;
|
|
38
33
|
export const EditIcon = () => <span>EditIcon</span>;
|
|
39
34
|
export const EventScheduleIcon = () => <span>EventScheduleIcon</span>;
|
|
40
35
|
export const EventsIcon = () => <span>EventsIcon</span>;
|
|
@@ -42,26 +37,18 @@ export const GenderFemaleIcon = () => <span>GenderFemaleIcon</span>;
|
|
|
42
37
|
export const GenderMaleIcon = () => <span>GenderMaleIcon</span>;
|
|
43
38
|
export const GenderOtherIcon = () => <span>GenderOtherIcon</span>;
|
|
44
39
|
export const GenderUnknownIcon = () => <span>GenderUnknownIcon</span>;
|
|
45
|
-
export const GenericOrderTypeIcon = () => <span>GenericOrderTypeIcon</span>;
|
|
46
40
|
export const GroupIcon = () => <span>GroupIcon</span>;
|
|
47
41
|
export const GroupAccessIcon = () => <span>GroupAccessIcon</span>;
|
|
48
|
-
export const HospitalBedIcon = () => <span>HospitalBedIcon</span>;
|
|
49
42
|
export const Icon = () => <span>Icon</span>;
|
|
50
|
-
export const ImageMedicalIcon = () => <span>ImageMedicalIcon</span>;
|
|
51
43
|
export const InformationFilledIcon = () => <span>InformationFilledIcon</span>;
|
|
52
44
|
export const InformationIcon = () => <span>InformationIcon</span>;
|
|
53
45
|
export const InformationSquareIcon = () => <span>InformationSquareIcon</span>;
|
|
54
46
|
export const InventoryManagementIcon = () => <span>InventoryManagementIcon</span>;
|
|
55
|
-
export const LabOrderIcon = () => <span>LabOrderIcon</span>;
|
|
56
47
|
export const ListCheckedIcon = () => <span>ListCheckedIcon</span>;
|
|
57
48
|
export const LocationIcon = () => <span>LocationIcon</span>;
|
|
58
49
|
export const MaximizeIcon = () => <span>MaximizeIcon</span>;
|
|
59
|
-
export const MedicationIcon = () => <span>MedicationIcon</span>;
|
|
60
|
-
export const MaterialOrderIcon = () => <span>MaterialOrderIcon</span>;
|
|
61
50
|
export const MessageQueueIcon = () => <span>MessageQueueIcon</span>;
|
|
62
|
-
export const MicroscopeIcon = () => <span>MicroscopeIcon</span>;
|
|
63
51
|
export const MoneyIcon = () => <span>MoneyIcon</span>;
|
|
64
|
-
export const MotherIcon = () => <span>MotherIcon</span>;
|
|
65
52
|
export const MovementIcon = () => <span>MovementIcon</span>;
|
|
66
53
|
export const OverflowMenuHorizontalIcon = () => <span>OverflowMenuHorizontalIcon</span>;
|
|
67
54
|
export const OverflowMenuVerticalIcon = () => <span>OverflowMenuVerticalIcon</span>;
|
|
@@ -69,10 +56,8 @@ export const PasswordIcon = () => <span>PasswordIcon</span>;
|
|
|
69
56
|
export const PedestrianFamilyIcon = () => <span>PedestrianFamilyIcon</span>;
|
|
70
57
|
export const PenIcon = () => <span>PenIcon</span>;
|
|
71
58
|
export const PrinterIcon = () => <span>PrinterIcon</span>;
|
|
72
|
-
export const ProcedureOrderIcon = () => <span>ProcedureOrderIcon</span>;
|
|
73
59
|
export const ProgramsIcon = () => <span>ProgramsIcon</span>;
|
|
74
60
|
export const RadiologyIcon = () => <span>RadiologyIcon</span>;
|
|
75
|
-
export const ReferralOrderIcon = () => <span>ReferralOrderIcon</span>;
|
|
76
61
|
export const RenewIcon = () => <span>RenewIcon</span>;
|
|
77
62
|
export const ReportIcon = () => <span>ReportIcon</span>;
|
|
78
63
|
export const ResetIcon = () => <span>ResetIcon</span>;
|
|
@@ -176,7 +161,6 @@ export const ShoppingCartArrowDownIcon = () => <span>ShoppingCartArrowDownIcon</
|
|
|
176
161
|
export const ShoppingCartIcon = () => <span>ShoppingCartIcon</span>;
|
|
177
162
|
export const StickyNoteAddIcon = () => <span>StickyNoteAddIcon</span>;
|
|
178
163
|
export const SwitcherIcon = () => <span>SwitcherIcon</span>;
|
|
179
|
-
export const SyringeIcon = () => <span>SyringeIcon</span>;
|
|
180
164
|
export const TableIcon = () => <span>TableIcon</span>;
|
|
181
165
|
export const TableOfContentsIcon = () => <span>TableOfContentsIcon</span>;
|
|
182
166
|
export const TimeIcon = () => <span>TimeIcon</span>;
|
|
@@ -187,7 +171,6 @@ export const TreeViewAltIcon = () => <span>TreeViewAltIcon</span>;
|
|
|
187
171
|
export const UserAvatarIcon = () => <span>UserAvatarIcon</span>;
|
|
188
172
|
export const UserFollowIcon = () => <span>UserFollowIcon</span>;
|
|
189
173
|
export const UserIcon = () => <span>UserIcon</span>;
|
|
190
|
-
export const UserXrayIcon = () => <span>UserXrayIcon</span>;
|
|
191
174
|
export const ViewIcon = () => <span>ViewIcon</span>;
|
|
192
175
|
export const ViewOffIcon = () => <span>ViewOffIcon</span>;
|
|
193
176
|
export const WarningIcon = () => <span>WarningIcon</span>;
|
|
@@ -197,31 +180,13 @@ export const AppointmentsPictogram = () => <span>AppointmentsPictogram</span>;
|
|
|
197
180
|
export const AppointmentsAltPictogram = () => <span>AppointmentsAltPictogram</span>;
|
|
198
181
|
export const Assessment1Pictogram = () => <span>Assessment1Pictogram</span>;
|
|
199
182
|
export const Assessment2Pictogram = () => <span>Assessment2Pictogram</span>;
|
|
200
|
-
export const BloodBankPictogram = () => <span>BloodBankPictogram</span>;
|
|
201
|
-
export const CardiologyPictogram = () => <span>CardiologyPictogram</span>;
|
|
202
|
-
export const CtScanPictogram = () => <span>CtScanPictogram</span>;
|
|
203
|
-
export const DentistryPictogram = () => <span>DentistryPictogram</span>;
|
|
204
|
-
export const EmergencyDepartmentPictogram = () => <span>EmergencyDepartmentPictogram</span>;
|
|
205
183
|
export const FacilityPictogram = () => <span>FacilityPictogram</span>;
|
|
206
|
-
export const GeriatricsPictogram = () => <span>GeriatricsPictogram</span>;
|
|
207
|
-
export const GynaecologyPictogram = () => <span>GynaecologyPictogram</span>;
|
|
208
184
|
export const HomePictogram = () => <span>HomePictogram</span>;
|
|
209
|
-
export const InPatientPictogram = () => <span>InPatientPictogram</span>;
|
|
210
|
-
export const LaboratoryPictogram = () => <span>LaboratoryPictogram</span>;
|
|
211
|
-
export const Labs2Pictogram = () => <span>Labs2Pictogram</span>;
|
|
212
|
-
export const ObstetricsPictogram = () => <span>ObstetricsPictogram</span>;
|
|
213
|
-
export const PatientListsPictogram = () => <span>PatientListsPictogram</span>;
|
|
214
|
-
export const PatientSearchPictogram = () => <span>PatientSearchPictogram</span>;
|
|
215
|
-
export const PatientsPictogram = () => <span>PatientsPictogram</span>;
|
|
216
185
|
export const PaymentsDeskPictogram = () => <span>PaymentsDeskPictogram</span>;
|
|
217
|
-
export const PharmacyPictogram = () => <span>PharmacyPictogram</span>;
|
|
218
|
-
export const Pharmacy2Pictogram = () => <span>Pharmacy2Pictogram</span>;
|
|
219
186
|
export const RegistrationPictogram = () => <span>RegistrationPictogram</span>;
|
|
220
187
|
export const ServiceQueuesPictogram = () => <span>ServiceQueuesPictogram</span>;
|
|
221
188
|
export const StockManagementPictogram = () => <span>StockManagementPictogram</span>;
|
|
222
189
|
export const TransferPictogram = () => <span>TransferPictogram</span>;
|
|
223
|
-
export const TriagePictogram = () => <span>TriagePictogram</span>;
|
|
224
|
-
export const XrayPictogram = () => <span>XrayPictogram</span>;
|
|
225
190
|
|
|
226
191
|
// Misc stubs
|
|
227
192
|
export const MaybeIcon = ({ icon }) => <span>{icon}</span>;
|
|
@@ -301,12 +266,6 @@ export const Workspace2 = jest.fn(({ title, children }) => (
|
|
|
301
266
|
</div>
|
|
302
267
|
));
|
|
303
268
|
|
|
304
|
-
export const NumericDataPoint = jest.fn(({ value, unit, label }) => (
|
|
305
|
-
<span>
|
|
306
|
-
{label && <span>{label}</span>}
|
|
307
|
-
{value} {unit}
|
|
308
|
-
</span>
|
|
309
|
-
));
|
|
310
269
|
|
|
311
270
|
export const TableBatchActions = jest.fn(({ children }) => <>{children}</>);
|
|
312
271
|
|
package/mock.tsx
CHANGED
|
@@ -7,12 +7,10 @@ import { type Classification } from '@egen-civitas/esm-data-api';
|
|
|
7
7
|
// Icon stubs
|
|
8
8
|
export const ActivityIcon = () => <span>ActivityIcon</span>;
|
|
9
9
|
export const AddIcon = () => <span>AddIcon</span>;
|
|
10
|
-
export const AllergiesIcon = () => <span>AllergiesIcon</span>;
|
|
11
10
|
export const ArrowDownIcon = () => <span>ArrowDownIcon</span>;
|
|
12
11
|
export const ArrowLeftIcon = () => <span>ArrowLeftIcon</span>;
|
|
13
12
|
export const ArrowRightIcon = () => <span>ArrowRightIcon</span>;
|
|
14
13
|
export const ArrowUpIcon = () => <span>ArrowUpIcon</span>;
|
|
15
|
-
export const BabyIcon = () => <span>BabyIcon</span>;
|
|
16
14
|
export const CalendarHeatMapIcon = () => <span>CalendarHeatMapIcon</span>;
|
|
17
15
|
export const CalendarIcon = () => <span>CalendarIcon</span>;
|
|
18
16
|
export const CaretDownIcon = () => <span>CaretDownIcon</span>;
|
|
@@ -23,7 +21,6 @@ export const ChartAverageIcon = () => <span>ChartAverageIcon</span>;
|
|
|
23
21
|
export const ChartLineIcon = () => <span>ChartLineIcon</span>;
|
|
24
22
|
export const CheckmarkFilledIcon = () => <span>CheckmarkFilledIcon</span>;
|
|
25
23
|
export const CheckmarkOutlineIcon = () => <span>CheckmarkOutlineIcon</span>;
|
|
26
|
-
export const ChemistryIcon = () => <span>ChemistryIcon</span>;
|
|
27
24
|
export const ChevronDownIcon = () => <span>ChevronDownIcon</span>;
|
|
28
25
|
export const ChevronLeftIcon = () => <span>ChevronLeftIcon</span>;
|
|
29
26
|
export const ChevronRightIcon = () => <span>ChevronRightIcon</span>;
|
|
@@ -31,11 +28,9 @@ export const ChevronUpIcon = () => <span>ChevronUpIcon</span>;
|
|
|
31
28
|
export const CloseIcon = () => <span>CloseIcon</span>;
|
|
32
29
|
export const CloseFilledIcon = () => <span>CloseFilledIcon</span>;
|
|
33
30
|
export const CloseOutlineIcon = () => <span>CloseOutlineIcon</span>;
|
|
34
|
-
export const ConditionsIcon = () => <span>ConditionsIcon</span>;
|
|
35
31
|
export const DocumentIcon = () => <span>DocumentIcon</span>;
|
|
36
32
|
export const DocumentAttachmentIcon = () => <span>DocumentAttachmentIcon</span>;
|
|
37
33
|
export const DownloadIcon = () => <span>DownloadIcon</span>;
|
|
38
|
-
export const DrugOrderIcon = () => <span>DrugOrderIcon</span>;
|
|
39
34
|
export const EditIcon = () => <span>EditIcon</span>;
|
|
40
35
|
export const EventScheduleIcon = () => <span>EventScheduleIcon</span>;
|
|
41
36
|
export const EventsIcon = () => <span>EventsIcon</span>;
|
|
@@ -43,26 +38,18 @@ export const GenderFemaleIcon = () => <span>GenderFemaleIcon</span>;
|
|
|
43
38
|
export const GenderMaleIcon = () => <span>GenderMaleIcon</span>;
|
|
44
39
|
export const GenderOtherIcon = () => <span>GenderOtherIcon</span>;
|
|
45
40
|
export const GenderUnknownIcon = () => <span>GenderUnknownIcon</span>;
|
|
46
|
-
export const GenericOrderTypeIcon = () => <span>GenericOrderTypeIcon</span>;
|
|
47
41
|
export const GroupIcon = () => <span>GroupIcon</span>;
|
|
48
42
|
export const GroupAccessIcon = () => <span>GroupAccessIcon</span>;
|
|
49
|
-
export const HospitalBedIcon = () => <span>HospitalBedIcon</span>;
|
|
50
43
|
export const Icon = () => <span>Icon</span>;
|
|
51
|
-
export const ImageMedicalIcon = () => <span>ImageMedicalIcon</span>;
|
|
52
44
|
export const InformationFilledIcon = () => <span>InformationFilledIcon</span>;
|
|
53
45
|
export const InformationIcon = () => <span>InformationIcon</span>;
|
|
54
46
|
export const InformationSquareIcon = () => <span>InformationSquareIcon</span>;
|
|
55
47
|
export const InventoryManagementIcon = () => <span>InventoryManagementIcon</span>;
|
|
56
|
-
export const LabOrderIcon = () => <span>LabOrderIcon</span>;
|
|
57
48
|
export const ListCheckedIcon = () => <span>ListCheckedIcon</span>;
|
|
58
49
|
export const LocationIcon = () => <span>LocationIcon</span>;
|
|
59
50
|
export const MaximizeIcon = () => <span>MaximizeIcon</span>;
|
|
60
|
-
export const MedicationIcon = () => <span>MedicationIcon</span>;
|
|
61
|
-
export const MaterialOrderIcon = () => <span>MaterialOrderIcon</span>;
|
|
62
51
|
export const MessageQueueIcon = () => <span>MessageQueueIcon</span>;
|
|
63
|
-
export const MicroscopeIcon = () => <span>MicroscopeIcon</span>;
|
|
64
52
|
export const MoneyIcon = () => <span>MoneyIcon</span>;
|
|
65
|
-
export const MotherIcon = () => <span>MotherIcon</span>;
|
|
66
53
|
export const MovementIcon = () => <span>MovementIcon</span>;
|
|
67
54
|
export const OverflowMenuHorizontalIcon = () => <span>OverflowMenuHorizontalIcon</span>;
|
|
68
55
|
export const OverflowMenuVerticalIcon = () => <span>OverflowMenuVerticalIcon</span>;
|
|
@@ -70,10 +57,8 @@ export const PasswordIcon = () => <span>PasswordIcon</span>;
|
|
|
70
57
|
export const PedestrianFamilyIcon = () => <span>PedestrianFamilyIcon</span>;
|
|
71
58
|
export const PenIcon = () => <span>PenIcon</span>;
|
|
72
59
|
export const PrinterIcon = () => <span>PrinterIcon</span>;
|
|
73
|
-
export const ProcedureOrderIcon = () => <span>ProcedureOrderIcon</span>;
|
|
74
60
|
export const ProgramsIcon = () => <span>ProgramsIcon</span>;
|
|
75
61
|
export const RadiologyIcon = () => <span>RadiologyIcon</span>;
|
|
76
|
-
export const ReferralOrderIcon = () => <span>ReferralOrderIcon</span>;
|
|
77
62
|
export const RenewIcon = () => <span>RenewIcon</span>;
|
|
78
63
|
export const ReportIcon = () => <span>ReportIcon</span>;
|
|
79
64
|
export const ResetIcon = () => <span>ResetIcon</span>;
|
|
@@ -177,7 +162,6 @@ export const ShoppingCartArrowDownIcon = () => <span>ShoppingCartArrowDownIcon</
|
|
|
177
162
|
export const ShoppingCartIcon = () => <span>ShoppingCartIcon</span>;
|
|
178
163
|
export const StickyNoteAddIcon = () => <span>StickyNoteAddIcon</span>;
|
|
179
164
|
export const SwitcherIcon = () => <span>SwitcherIcon</span>;
|
|
180
|
-
export const SyringeIcon = () => <span>SyringeIcon</span>;
|
|
181
165
|
export const TableIcon = () => <span>TableIcon</span>;
|
|
182
166
|
export const TableOfContentsIcon = () => <span>TableOfContentsIcon</span>;
|
|
183
167
|
export const TimeIcon = () => <span>TimeIcon</span>;
|
|
@@ -189,7 +173,6 @@ export const TreeViewAltIcon = () => <span>TreeViewAltIcon</span>;
|
|
|
189
173
|
export const UserAvatarIcon = () => <span>UserAvatarIcon</span>;
|
|
190
174
|
export const UserFollowIcon = () => <span>UserFollowIcon</span>;
|
|
191
175
|
export const UserIcon = () => <span>UserIcon</span>;
|
|
192
|
-
export const UserXrayIcon = () => <span>UserXrayIcon</span>;
|
|
193
176
|
export const ViewIcon = () => <span>ViewIcon</span>;
|
|
194
177
|
export const ViewOffIcon = () => <span>ViewOffIcon</span>;
|
|
195
178
|
export const WarningIcon = () => <span>WarningIcon</span>;
|
|
@@ -199,31 +182,13 @@ export const AppointmentsPictogram = () => <span>AppointmentsPictogram</span>;
|
|
|
199
182
|
export const AppointmentsAltPictogram = () => <span>AppointmentsAltPictogram</span>;
|
|
200
183
|
export const Assessment1Pictogram = () => <span>Assessment1Pictogram</span>;
|
|
201
184
|
export const Assessment2Pictogram = () => <span>Assessment2Pictogram</span>;
|
|
202
|
-
export const BloodBankPictogram = () => <span>BloodBankPictogram</span>;
|
|
203
|
-
export const CardiologyPictogram = () => <span>CardiologyPictogram</span>;
|
|
204
|
-
export const CtScanPictogram = () => <span>CtScanPictogram</span>;
|
|
205
|
-
export const DentistryPictogram = () => <span>DentistryPictogram</span>;
|
|
206
|
-
export const EmergencyDepartmentPictogram = () => <span>EmergencyDepartmentPictogram</span>;
|
|
207
185
|
export const FacilityPictogram = () => <span>FacilityPictogram</span>;
|
|
208
|
-
export const GeriatricsPictogram = () => <span>GeriatricsPictogram</span>;
|
|
209
|
-
export const GynaecologyPictogram = () => <span>GynaecologyPictogram</span>;
|
|
210
186
|
export const HomePictogram = () => <span>HomePictogram</span>;
|
|
211
|
-
export const InPatientPictogram = () => <span>InPatientPictogram</span>;
|
|
212
|
-
export const LaboratoryPictogram = () => <span>LaboratoryPictogram</span>;
|
|
213
|
-
export const Labs2Pictogram = () => <span>Labs2Pictogram</span>;
|
|
214
|
-
export const ObstetricsPictogram = () => <span>ObstetricsPictogram</span>;
|
|
215
|
-
export const PatientListsPictogram = () => <span>PatientListsPictogram</span>;
|
|
216
|
-
export const PatientSearchPictogram = () => <span>PatientSearchPictogram</span>;
|
|
217
|
-
export const PatientsPictogram = () => <span>PatientsPictogram</span>;
|
|
218
187
|
export const PaymentsDeskPictogram = () => <span>PaymentsDeskPictogram</span>;
|
|
219
|
-
export const PharmacyPictogram = () => <span>PharmacyPictogram</span>;
|
|
220
|
-
export const Pharmacy2Pictogram = () => <span>Pharmacy2Pictogram</span>;
|
|
221
188
|
export const RegistrationPictogram = () => <span>RegistrationPictogram</span>;
|
|
222
189
|
export const ServiceQueuesPictogram = () => <span>ServiceQueuesPictogram</span>;
|
|
223
190
|
export const StockManagementPictogram = () => <span>StockManagementPictogram</span>;
|
|
224
191
|
export const TransferPictogram = () => <span>TransferPictogram</span>;
|
|
225
|
-
export const TriagePictogram = () => <span>TriagePictogram</span>;
|
|
226
|
-
export const XrayPictogram = () => <span>XrayPictogram</span>;
|
|
227
192
|
|
|
228
193
|
// Misc stubs
|
|
229
194
|
export const MaybeIcon = ({ icon }) => <span>{icon}</span>;
|
|
@@ -303,12 +268,6 @@ export const Workspace2 = vi.fn(({ title, children }) => (
|
|
|
303
268
|
</div>
|
|
304
269
|
));
|
|
305
270
|
|
|
306
|
-
export const NumericDataPoint = vi.fn(({ value, unit, label }) => (
|
|
307
|
-
<span>
|
|
308
|
-
{label && <span>{label}</span>}
|
|
309
|
-
{value} {unit}
|
|
310
|
-
</span>
|
|
311
|
-
));
|
|
312
271
|
|
|
313
272
|
export const TableBatchActions = vi.fn(({ children }) => <>{children}</>);
|
|
314
273
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@egen-civitas/esm-styleguide",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"license": "MPL-2.0",
|
|
5
5
|
"description": "The styleguide for Egen SPA",
|
|
6
6
|
"main": "dist/internal.js",
|
|
@@ -79,6 +79,7 @@
|
|
|
79
79
|
"@carbon/react": "^1.92.1",
|
|
80
80
|
"@internationalized/date": "^3.8.0",
|
|
81
81
|
"@react-aria/utils": "^3.28.2",
|
|
82
|
+
"@react-three/fiber": "8.17.10",
|
|
82
83
|
"@splinetool/react-spline": "^4.1.0",
|
|
83
84
|
"@splinetool/runtime": "^2.0.58",
|
|
84
85
|
"d3": "^7.8.0",
|
|
@@ -91,21 +92,22 @@
|
|
|
91
92
|
"lodash-es": "^4.17.21",
|
|
92
93
|
"lucide-react": "^0.469.0",
|
|
93
94
|
"react-aria-components": "^1.7.1",
|
|
95
|
+
"three": "0.170.0",
|
|
94
96
|
"uuid": "^14.0.1"
|
|
95
97
|
},
|
|
96
98
|
"peerDependencies": {
|
|
97
|
-
"@egen-civitas/esm-api": "^
|
|
98
|
-
"@egen-civitas/esm-config": "^
|
|
99
|
-
"@egen-civitas/esm-data-api": "^
|
|
100
|
-
"@egen-civitas/esm-error-handling": "^1.0.
|
|
101
|
-
"@egen-civitas/esm-extensions": "^2.
|
|
102
|
-
"@egen-civitas/esm-globals": "^
|
|
99
|
+
"@egen-civitas/esm-api": "^2.0.0",
|
|
100
|
+
"@egen-civitas/esm-config": "^2.0.0",
|
|
101
|
+
"@egen-civitas/esm-data-api": "^2.0.0",
|
|
102
|
+
"@egen-civitas/esm-error-handling": "^1.0.2",
|
|
103
|
+
"@egen-civitas/esm-extensions": "^2.1.0",
|
|
104
|
+
"@egen-civitas/esm-globals": "^2.0.0",
|
|
103
105
|
"@egen-civitas/esm-navigation": "^1.0.2",
|
|
104
|
-
"@egen-civitas/esm-react-utils": "^
|
|
105
|
-
"@egen-civitas/esm-routes": "^1.0
|
|
106
|
-
"@egen-civitas/esm-state": "^1.0.
|
|
107
|
-
"@egen-civitas/esm-translations": "^1.0.
|
|
108
|
-
"@egen-civitas/esm-utils": "^
|
|
106
|
+
"@egen-civitas/esm-react-utils": "^3.0.0",
|
|
107
|
+
"@egen-civitas/esm-routes": "^1.1.0",
|
|
108
|
+
"@egen-civitas/esm-state": "^1.0.3",
|
|
109
|
+
"@egen-civitas/esm-translations": "^1.0.3",
|
|
110
|
+
"@egen-civitas/esm-utils": "^2.0.0",
|
|
109
111
|
"dayjs": "1.x",
|
|
110
112
|
"i18next": "25.x",
|
|
111
113
|
"react": "18.x",
|
|
@@ -116,22 +118,23 @@
|
|
|
116
118
|
"swr": "2.x"
|
|
117
119
|
},
|
|
118
120
|
"devDependencies": {
|
|
119
|
-
"@egen-civitas/esm-api": "^
|
|
120
|
-
"@egen-civitas/esm-config": "^
|
|
121
|
-
"@egen-civitas/esm-data-api": "^
|
|
122
|
-
"@egen-civitas/esm-error-handling": "^1.0.
|
|
121
|
+
"@egen-civitas/esm-api": "^2.0.0",
|
|
122
|
+
"@egen-civitas/esm-config": "^2.0.0",
|
|
123
|
+
"@egen-civitas/esm-data-api": "^2.0.0",
|
|
124
|
+
"@egen-civitas/esm-error-handling": "^1.0.2",
|
|
123
125
|
"@egen-civitas/esm-expression-evaluator": "^1.0.0",
|
|
124
|
-
"@egen-civitas/esm-extensions": "^2.
|
|
125
|
-
"@egen-civitas/esm-globals": "^
|
|
126
|
+
"@egen-civitas/esm-extensions": "^2.1.0",
|
|
127
|
+
"@egen-civitas/esm-globals": "^2.0.0",
|
|
126
128
|
"@egen-civitas/esm-navigation": "^1.0.2",
|
|
127
|
-
"@egen-civitas/esm-react-utils": "^
|
|
128
|
-
"@egen-civitas/esm-routes": "^1.0
|
|
129
|
-
"@egen-civitas/esm-state": "^1.0.
|
|
130
|
-
"@egen-civitas/esm-translations": "^1.0.
|
|
131
|
-
"@egen-civitas/esm-utils": "^
|
|
129
|
+
"@egen-civitas/esm-react-utils": "^3.0.0",
|
|
130
|
+
"@egen-civitas/esm-routes": "^1.1.0",
|
|
131
|
+
"@egen-civitas/esm-state": "^1.0.3",
|
|
132
|
+
"@egen-civitas/esm-translations": "^1.0.3",
|
|
133
|
+
"@egen-civitas/esm-utils": "^2.0.0",
|
|
132
134
|
"@swc/cli": "0.8.1",
|
|
133
135
|
"@swc/core": "1.15.21",
|
|
134
136
|
"@types/geopattern": "^1.2.9",
|
|
137
|
+
"@types/three": "0.170.0",
|
|
135
138
|
"@vitest/coverage-v8": "^4.1.2",
|
|
136
139
|
"concurrently": "^9.2.1",
|
|
137
140
|
"cross-env": "^10.1.0",
|
package/src/_vars.scss
CHANGED
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
// =============================================================================
|
|
4
4
|
// Variables historiques du styleguide — MIGRÉES vers le thème dynamique EGEN
|
|
5
5
|
//
|
|
6
|
-
// Ces ~25 variables SCSS étaient des couleurs Carbon v10 (thème clair
|
|
6
|
+
// Ces ~25 variables SCSS étaient des couleurs Carbon v10 (thème clair historique)
|
|
7
7
|
// figées en hexadécimal, consommées par ~15 fichiers du styleguide
|
|
8
|
-
// (pagination, datepicker, cards,
|
|
8
|
+
// (pagination, datepicker, cards, workspaces,
|
|
9
9
|
// canvas, breadcrumbs, overrides...) ET par des apps entières
|
|
10
10
|
// (esm-implementer-tools-app). Modifier colors.* dans theme.default.json
|
|
11
11
|
// n'avait donc aucun effet sur tout ce qui en dépendait.
|
|
@@ -74,7 +74,7 @@ $brand-primary-100: var(--colors-primary-900, #081a1c);
|
|
|
74
74
|
// =============================================================================
|
|
75
75
|
// --brand-01/02/03 — RECÂBLÉS SUR LE THÈME EGEN (esm-theme)
|
|
76
76
|
//
|
|
77
|
-
// Historiquement ces 3 variables étaient des couleurs
|
|
77
|
+
// Historiquement ces 3 variables étaient des couleurs historiques figées
|
|
78
78
|
// (teal #005d5d/#004144/#007d79), totalement indépendantes du JSON de
|
|
79
79
|
// thème. Une vingtaine de composants (nav latérale, workspaces, boutons
|
|
80
80
|
// d'action, focus rings...) les consomment encore via `@include brand-0X`
|
|
@@ -84,7 +84,7 @@ $brand-primary-100: var(--colors-primary-900, #081a1c);
|
|
|
84
84
|
//
|
|
85
85
|
// Correction : `--brand-01/02/03` pointent maintenant vers l'échelle
|
|
86
86
|
// `--colors-primary-*` injectée dynamiquement par @egen-civitas/esm-theme, avec
|
|
87
|
-
// l'ancienne valeur
|
|
87
|
+
// l'ancienne valeur conservée UNIQUEMENT comme fallback CSS natif
|
|
88
88
|
// (`var(--x, fallback)`) — actif seulement tant que le moteur de thème n'a
|
|
89
89
|
// pas encore injecté ses variables (fenêtre de quelques ms au chargement).
|
|
90
90
|
// Dès que --colors-primary-* existe dans le DOM, tous les composants
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
/** @module @category UI */
|
|
2
|
-
import React from 'react';
|
|
3
|
-
export interface EntityBannerActionsMenuProps {
|
|
4
|
-
entity: fhir.Patient;
|
|
5
|
-
entityUuid: string;
|
|
6
|
-
actionsSlotName: string;
|
|
7
|
-
/**
|
|
8
|
-
* Parts of the actions slot extension state that don't really make sense go in this object,
|
|
9
|
-
* so as to keep the EntityBannerActionsMenu API clean.
|
|
10
|
-
*/
|
|
11
|
-
additionalActionsSlotState?: object;
|
|
12
|
-
}
|
|
13
|
-
/**
|
|
14
|
-
* Overflow menu for the entity banner whose items come from an ExtensionSlot
|
|
15
|
-
* rather than direct React children. Arrow key navigation is handled at the
|
|
16
|
-
* container level via onKeyDown.
|
|
17
|
-
*/
|
|
18
|
-
export declare function EntityBannerActionsMenu({ entity, entityUuid, actionsSlotName, additionalActionsSlotState, }: EntityBannerActionsMenuProps): React.JSX.Element | null;
|
|
19
|
-
//# sourceMappingURL=entity-banner-actions-menu.component.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"entity-banner-actions-menu.component.d.ts","sourceRoot":"","sources":["../../../src/entity-banner/actions-menu/entity-banner-actions-menu.component.tsx"],"names":[],"mappings":"AAAA,2BAA2B;AAC3B,OAAO,KAAmE,MAAM,OAAO,CAAC;AAQxF,MAAM,WAAW,4BAA4B;IAC3C,MAAM,EAAE,IAAI,CAAC,OAAO,CAAC;IACrB,UAAU,EAAE,MAAM,CAAC;IACnB,eAAe,EAAE,MAAM,CAAC;IACxB;;;OAGG;IACH,0BAA0B,CAAC,EAAE,MAAM,CAAC;CACrC;AAED;;;;GAIG;AACH,wBAAgB,uBAAuB,CAAC,EACtC,MAAM,EACN,UAAU,EACV,eAAe,EACf,0BAA0B,GAC3B,EAAE,4BAA4B,4BA0H9B"}
|
|
@@ -1,137 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
/** @module @category UI */ import React, { useCallback, useEffect, useId, useMemo, useRef, useState } from "react";
|
|
3
|
-
import classNames from "classnames";
|
|
4
|
-
import { OverflowMenuVertical } from "@carbon/react/icons";
|
|
5
|
-
import { ExtensionSlot, useExtensionSlot, useLayoutType, useOnClickOutside } from "@egen-civitas/esm-react-utils";
|
|
6
|
-
import { getCoreTranslation } from "@egen-civitas/esm-translations";
|
|
7
|
-
import customOverflowMenuStyles from "../../custom-overflow-menu/custom-overflow-menu.module.scss";
|
|
8
|
-
import styles from "./entity-banner-actions-menu.module.scss";
|
|
9
|
-
/**
|
|
10
|
-
* Overflow menu for the entity banner whose items come from an ExtensionSlot
|
|
11
|
-
* rather than direct React children. Arrow key navigation is handled at the
|
|
12
|
-
* container level via onKeyDown.
|
|
13
|
-
*/ export function EntityBannerActionsMenu({ entity, entityUuid, actionsSlotName, additionalActionsSlotState }) {
|
|
14
|
-
const [menuIsOpen, setMenuIsOpen] = useState(false);
|
|
15
|
-
const { extensions: entityActions } = useExtensionSlot(actionsSlotName);
|
|
16
|
-
const isTablet = useLayoutType() === 'tablet';
|
|
17
|
-
const ref = useOnClickOutside(()=>setMenuIsOpen(false), menuIsOpen);
|
|
18
|
-
const triggerRef = useRef(null);
|
|
19
|
-
const menuRef = useRef(null);
|
|
20
|
-
const uniqueId = useId();
|
|
21
|
-
const triggerId = `entity-actions-menu-trigger-${uniqueId}`;
|
|
22
|
-
const menuId = `entity-actions-menu-${uniqueId}`;
|
|
23
|
-
const toggleShowMenu = useCallback(()=>setMenuIsOpen((state)=>!state), []);
|
|
24
|
-
const closeMenuAndFocusTrigger = useCallback(()=>{
|
|
25
|
-
setMenuIsOpen(false);
|
|
26
|
-
triggerRef.current?.focus();
|
|
27
|
-
}, []);
|
|
28
|
-
const handleMenuKeyDown = useCallback((e)=>{
|
|
29
|
-
if (e.key === 'Escape' && menuIsOpen) {
|
|
30
|
-
e.stopPropagation();
|
|
31
|
-
closeMenuAndFocusTrigger();
|
|
32
|
-
return;
|
|
33
|
-
}
|
|
34
|
-
if ((e.key === 'ArrowDown' || e.key === 'ArrowUp') && menuIsOpen) {
|
|
35
|
-
e.preventDefault();
|
|
36
|
-
const enabledItems = menuRef.current?.querySelectorAll('[role="menuitem"]:not([disabled])');
|
|
37
|
-
if (!enabledItems?.length) {
|
|
38
|
-
return;
|
|
39
|
-
}
|
|
40
|
-
const activeItem = document.activeElement?.closest?.('[role="menuitem"]') ?? document.activeElement;
|
|
41
|
-
const currentPos = Array.from(enabledItems).indexOf(activeItem);
|
|
42
|
-
if (currentPos === -1) {
|
|
43
|
-
enabledItems[e.key === 'ArrowDown' ? 0 : enabledItems.length - 1]?.focus();
|
|
44
|
-
return;
|
|
45
|
-
}
|
|
46
|
-
const direction = e.key === 'ArrowDown' ? 1 : -1;
|
|
47
|
-
const nextPos = currentPos + direction;
|
|
48
|
-
const wrappedPos = nextPos < 0 ? enabledItems.length - 1 : nextPos >= enabledItems.length ? 0 : nextPos;
|
|
49
|
-
enabledItems[wrappedPos]?.focus();
|
|
50
|
-
}
|
|
51
|
-
}, [
|
|
52
|
-
closeMenuAndFocusTrigger,
|
|
53
|
-
menuIsOpen
|
|
54
|
-
]);
|
|
55
|
-
useEffect(()=>{
|
|
56
|
-
if (menuIsOpen && menuRef.current) {
|
|
57
|
-
const firstItem = menuRef.current.querySelector('[role="menuitem"]:not([disabled])');
|
|
58
|
-
firstItem?.focus();
|
|
59
|
-
}
|
|
60
|
-
}, [
|
|
61
|
-
menuIsOpen
|
|
62
|
-
]);
|
|
63
|
-
const entityActionsSlotState = useMemo(()=>({
|
|
64
|
-
entityUuid,
|
|
65
|
-
entity,
|
|
66
|
-
closeMenu: closeMenuAndFocusTrigger,
|
|
67
|
-
...additionalActionsSlotState
|
|
68
|
-
}), [
|
|
69
|
-
entityUuid,
|
|
70
|
-
entity,
|
|
71
|
-
closeMenuAndFocusTrigger,
|
|
72
|
-
additionalActionsSlotState
|
|
73
|
-
]);
|
|
74
|
-
if (entityActions.length === 0) {
|
|
75
|
-
return null;
|
|
76
|
-
}
|
|
77
|
-
return /*#__PURE__*/ _jsx("div", {
|
|
78
|
-
className: styles.overflowMenuContainer,
|
|
79
|
-
children: /*#__PURE__*/ _jsxs("div", {
|
|
80
|
-
"data-overflow-menu": true,
|
|
81
|
-
className: classNames('cds--overflow-menu', customOverflowMenuStyles.container),
|
|
82
|
-
ref: ref,
|
|
83
|
-
children: [
|
|
84
|
-
/*#__PURE__*/ _jsxs("button", {
|
|
85
|
-
className: classNames('cds--btn', 'cds--btn--ghost', 'cds--overflow-menu__trigger', {
|
|
86
|
-
'cds--overflow-menu--open': menuIsOpen
|
|
87
|
-
}, customOverflowMenuStyles.overflowMenuButton),
|
|
88
|
-
"aria-controls": menuId,
|
|
89
|
-
"aria-expanded": menuIsOpen,
|
|
90
|
-
"aria-haspopup": "true",
|
|
91
|
-
id: triggerId,
|
|
92
|
-
onClick: toggleShowMenu,
|
|
93
|
-
onKeyDown: handleMenuKeyDown,
|
|
94
|
-
ref: triggerRef,
|
|
95
|
-
children: [
|
|
96
|
-
/*#__PURE__*/ _jsx("span", {
|
|
97
|
-
className: styles.actionsButtonText,
|
|
98
|
-
children: getCoreTranslation('actions', 'Actions')
|
|
99
|
-
}),
|
|
100
|
-
' ',
|
|
101
|
-
/*#__PURE__*/ _jsx(OverflowMenuVertical, {
|
|
102
|
-
size: 16,
|
|
103
|
-
style: {
|
|
104
|
-
marginLeft: '0.5rem',
|
|
105
|
-
fill: '#78A9FF'
|
|
106
|
-
}
|
|
107
|
-
})
|
|
108
|
-
]
|
|
109
|
-
}),
|
|
110
|
-
/*#__PURE__*/ _jsxs("div", {
|
|
111
|
-
className: classNames('cds--overflow-menu-options', 'cds--overflow-menu--flip', customOverflowMenuStyles.menu, {
|
|
112
|
-
[customOverflowMenuStyles.show]: menuIsOpen
|
|
113
|
-
}),
|
|
114
|
-
"aria-labelledby": triggerId,
|
|
115
|
-
"data-floating-menu-direction": "bottom",
|
|
116
|
-
id: menuId,
|
|
117
|
-
onKeyDown: handleMenuKeyDown,
|
|
118
|
-
ref: menuRef,
|
|
119
|
-
role: "menu",
|
|
120
|
-
tabIndex: -1,
|
|
121
|
-
children: [
|
|
122
|
-
/*#__PURE__*/ _jsx("ul", {
|
|
123
|
-
className: classNames('cds--overflow-menu-options__content', {
|
|
124
|
-
'cds--overflow-menu-options--lg': isTablet
|
|
125
|
-
}),
|
|
126
|
-
children: /*#__PURE__*/ _jsx(ExtensionSlot, {
|
|
127
|
-
name: actionsSlotName,
|
|
128
|
-
state: entityActionsSlotState
|
|
129
|
-
}, actionsSlotName)
|
|
130
|
-
}),
|
|
131
|
-
/*#__PURE__*/ _jsx("span", {})
|
|
132
|
-
]
|
|
133
|
-
})
|
|
134
|
-
]
|
|
135
|
-
})
|
|
136
|
-
});
|
|
137
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
@use '@carbon/colors';
|
|
2
|
-
@use '@carbon/layout';
|
|
3
|
-
@use '@carbon/type';
|
|
4
|
-
@use '../../vars' as *;
|
|
5
|
-
|
|
6
|
-
.actionsButtonText {
|
|
7
|
-
@include type.type-style('body-compact-01');
|
|
8
|
-
color: $interactive-01;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
// Overriding styles for RTL support
|
|
12
|
-
html[dir='rtl'] {
|
|
13
|
-
.overflowMenuContainer {
|
|
14
|
-
& > div {
|
|
15
|
-
margin-left: unset;
|
|
16
|
-
margin-right: -(layout.$spacing-06);
|
|
17
|
-
& > div {
|
|
18
|
-
left: unset;
|
|
19
|
-
right: -6.025rem;
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
/** @module @category UI */
|
|
2
|
-
import React from 'react';
|
|
3
|
-
interface ContactDetailsProps {
|
|
4
|
-
entityId: string;
|
|
5
|
-
inactive: boolean;
|
|
6
|
-
}
|
|
7
|
-
export declare function EntityBannerContactDetails({ entityId, inactive }: ContactDetailsProps): React.JSX.Element;
|
|
8
|
-
export {};
|
|
9
|
-
//# sourceMappingURL=entity-banner-contact-details.component.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"entity-banner-contact-details.component.d.ts","sourceRoot":"","sources":["../../../src/entity-banner/contact-details/entity-banner-contact-details.component.tsx"],"names":[],"mappings":"AAAA,2BAA2B;AAC3B,OAAO,KAAkB,MAAM,OAAO,CAAC;AAWvC,UAAU,mBAAmB;IAC3B,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,OAAO,CAAC;CACnB;AAuKD,wBAAgB,0BAA0B,CAAC,EAAE,QAAQ,EAAE,QAAQ,EAAE,EAAE,mBAAmB,qBAyBrF"}
|