@openmrs/esm-styleguide 8.0.1-pre.3585 → 8.0.1-pre.3600
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/.turbo/turbo-build.log +4 -7
- package/dist/cards/card-header.component.d.ts +11 -0
- package/dist/cards/index.d.ts +1 -0
- package/dist/dashboard-extension/index.d.ts +5 -2
- package/dist/empty-card/empty-card-registration.d.ts +1 -0
- package/dist/empty-card/empty-card.component.d.ts +17 -0
- package/dist/empty-card/index.d.ts +1 -0
- package/dist/error-state/error-state.component.d.ts +4 -0
- package/dist/icons/icons.d.ts +1 -1
- package/dist/internal.d.ts +3 -0
- package/dist/openmrs-esm-styleguide.css +1 -1
- package/dist/openmrs-esm-styleguide.css.map +1 -1
- package/dist/openmrs-esm-styleguide.js +2 -2
- package/dist/openmrs-esm-styleguide.js.map +1 -1
- package/dist/pagination/index.d.ts +1 -0
- package/dist/pagination/pagination.component.d.ts +22 -0
- package/dist/public.d.ts +19 -18
- package/dist/snackbars/index.d.ts +1 -0
- package/dist/toasts/index.d.ts +1 -0
- package/package.json +12 -12
- package/src/cards/card-header.component.tsx +30 -0
- package/src/cards/card-header.module.scss +45 -0
- package/src/cards/index.ts +1 -0
- package/src/dashboard-extension/index.tsx +13 -3
- package/src/declarations.d.ts +14 -2
- package/src/empty-card/empty-card-registration.ts +6 -0
- package/src/empty-card/empty-card.component.tsx +55 -0
- package/src/empty-card/empty-card.module.scss +27 -0
- package/src/empty-card/empty-card.test.tsx +58 -0
- package/src/empty-card/empty-data-illustration.svg +32 -0
- package/src/empty-card/index.ts +1 -0
- package/src/error-state/error-state.component.tsx +7 -6
- package/src/error-state/error-state.module.scss +0 -29
- package/src/error-state/error-state.test.tsx +2 -2
- package/src/icons/icons.tsx +3 -3
- package/src/index.ts +5 -3
- package/src/internal.ts +3 -0
- package/src/pagination/index.ts +1 -0
- package/src/pagination/pagination.component.tsx +77 -0
- package/src/pagination/pagination.module.scss +66 -0
- package/src/pagination/pagination.test.tsx +72 -0
- package/src/public.ts +19 -18
- package/src/snackbars/index.tsx +2 -0
- package/src/toasts/index.tsx +2 -0
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,14 +1,11 @@
|
|
|
1
|
-
[0] Browserslist: browsers data (caniuse-lite) is 7 months old. Please run:
|
|
2
|
-
[0] npx update-browserslist-db@latest
|
|
3
|
-
[0] Why you should do it regularly: https://github.com/browserslist/update-db#readme
|
|
4
1
|
[0] WARNING in ⚠ asset size limit: The following asset(s) exceed the recommended size limit (244.141 KiB). This can impact web performance.
|
|
5
2
|
[0] │ Assets:
|
|
6
|
-
[0] │ openmrs-esm-styleguide.js (
|
|
7
|
-
[0] │ openmrs-esm-styleguide.css (3.
|
|
3
|
+
[0] │ openmrs-esm-styleguide.js (249.622 KiB)
|
|
4
|
+
[0] │ openmrs-esm-styleguide.css (3.264 MiB)
|
|
8
5
|
[0]
|
|
9
6
|
[0] WARNING in ⚠ entrypoint size limit: The following entrypoint(s) combined asset size exceeds the recommended limit (244.141 KiB). This can impact web performance.
|
|
10
7
|
[0] │ Entrypoints:
|
|
11
|
-
[0] │ main (3.
|
|
8
|
+
[0] │ main (3.508 MiB)
|
|
12
9
|
[0] │ openmrs-esm-styleguide.css
|
|
13
10
|
[0] │ openmrs-esm-styleguide.js
|
|
14
11
|
[0]
|
|
@@ -16,6 +13,6 @@
|
|
|
16
13
|
[0] │ You can limit the size of your bundles by using import() to lazy load some parts of your application.
|
|
17
14
|
[0] │ For more info visit https://www.rspack.dev/guide/optimization/code-splitting
|
|
18
15
|
[0]
|
|
19
|
-
[0] Rspack compiled with 3 warnings in
|
|
16
|
+
[0] Rspack compiled with 3 warnings in 9.37 s
|
|
20
17
|
[0] rspack --mode=production exited with code 0
|
|
21
18
|
[1] tsc --project tsconfig.build.json exited with code 0
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface CardHeaderProps {
|
|
3
|
+
/** The title for this card. This must be a pre-translated string. */
|
|
4
|
+
title: string;
|
|
5
|
+
/** The contents of the card header to render if any. */
|
|
6
|
+
children?: React.ReactNode;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* Re-usable header component for O3-style cards, like those found on the patient chart
|
|
10
|
+
*/
|
|
11
|
+
export declare function CardHeader({ title, children }: CardHeaderProps): React.JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { CardHeader, type CardHeaderProps } from './card-header.component';
|
|
@@ -3,7 +3,10 @@ import { type IconId } from '../icons';
|
|
|
3
3
|
export interface DashboardExtensionProps {
|
|
4
4
|
path: string;
|
|
5
5
|
title: string;
|
|
6
|
-
basePath
|
|
7
|
-
icon
|
|
6
|
+
basePath?: string;
|
|
7
|
+
icon?: IconId;
|
|
8
8
|
}
|
|
9
9
|
export declare const DashboardExtension: ({ path, title, basePath, icon }: DashboardExtensionProps) => React.JSX.Element;
|
|
10
|
+
export declare function createDashboard(props: Omit<DashboardExtensionProps, 'basePath'>): ({ basePath }: {
|
|
11
|
+
basePath: string;
|
|
12
|
+
}) => React.JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function setupEmptyCard(): void;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface EmptyCardProps {
|
|
3
|
+
/** The name of the type of item that would be displayed here if not empty. This must be a pre-translated string. */
|
|
4
|
+
displayText: string;
|
|
5
|
+
/** The title to use for this empty component. This must be a pre-translated string. */
|
|
6
|
+
headerTitle: string;
|
|
7
|
+
/** A callback to invoke when the user tries to record a new item. */
|
|
8
|
+
launchForm?(): void;
|
|
9
|
+
}
|
|
10
|
+
export declare const EmptyCardIllustration: ({ width, height }: {
|
|
11
|
+
width?: string | undefined;
|
|
12
|
+
height?: string | undefined;
|
|
13
|
+
}) => React.JSX.Element;
|
|
14
|
+
/**
|
|
15
|
+
* Re-usable card for displaying an empty state
|
|
16
|
+
*/
|
|
17
|
+
export declare const EmptyCard: React.FC<EmptyCardProps>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { EmptyCard, EmptyCardIllustration, type EmptyCardProps } from './empty-card.component';
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
export interface ErrorStateProps {
|
|
3
|
+
/** The error that caused this error card to be rendered. Expected to be a failed fetch result. */
|
|
3
4
|
error: any;
|
|
5
|
+
/** The title to use for this empty component. This must be a pre-translated string. */
|
|
4
6
|
headerTitle: string;
|
|
5
7
|
}
|
|
6
8
|
export declare const ErrorState: React.FC<ErrorStateProps>;
|
|
9
|
+
export declare const ErrorCard: React.FC<ErrorStateProps>;
|
|
10
|
+
export type ErrorCardProps = ErrorStateProps;
|
package/dist/icons/icons.d.ts
CHANGED
|
@@ -316,7 +316,7 @@ export declare const ShoppingCartAddItemIcon: React.MemoExoticComponent<React.Fo
|
|
|
316
316
|
* ```
|
|
317
317
|
*/
|
|
318
318
|
export declare const MaybeIcon: React.MemoExoticComponent<React.ForwardRefExoticComponent<{
|
|
319
|
-
icon: string;
|
|
319
|
+
icon: string | undefined;
|
|
320
320
|
fallback?: React.ReactNode;
|
|
321
321
|
} & IconProps & React.RefAttributes<SVGSVGElement>>>;
|
|
322
322
|
export type SvgIconProps = {
|
package/dist/internal.d.ts
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
export * from './breakpoints';
|
|
2
|
+
export * from './cards';
|
|
2
3
|
export * from './config-schema';
|
|
3
4
|
export * from './custom-overflow-menu';
|
|
4
5
|
export * from './dashboard-extension';
|
|
5
6
|
export * from './datepicker';
|
|
6
7
|
export * from './diagnosis-tags';
|
|
8
|
+
export * from './empty-card';
|
|
7
9
|
export * from './error-state';
|
|
8
10
|
export * from './icons/icons';
|
|
9
11
|
export * from './left-nav';
|
|
@@ -13,6 +15,7 @@ export * from './notifications';
|
|
|
13
15
|
export * from './notifications/actionable-notification.component';
|
|
14
16
|
export * from './notifications/notification.component';
|
|
15
17
|
export * from './page-header';
|
|
18
|
+
export * from './pagination';
|
|
16
19
|
export * from './patient-banner';
|
|
17
20
|
export * from './patient-photo';
|
|
18
21
|
export * from './pictograms/pictograms';
|