Skip to content

Commit

Permalink
(feat) O3-4216 Add the Programs Icon to CarbonMRS icon pack (#1212)
Browse files Browse the repository at this point in the history
  • Loading branch information
Munyua123 authored Nov 27, 2024
1 parent 1d11a98 commit a46c9fa
Show file tree
Hide file tree
Showing 4 changed files with 40 additions and 16 deletions.
1 change: 1 addition & 0 deletions packages/framework/esm-styleguide/mock.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ export const OverflowMenuVerticalIcon = () => <div>OverflowMenuVerticalIcon</div
export const PedestrianFamilyIcon = () => <div>PedestrianFamilyIcon</div>;
export const PenIcon = () => <div>PenIcon</div>;
export const PrinterIcon = () => <div>PrinterIcon</div>;
export const ProgramsIcon = () => <div>ProgramsIcon</div>;
export const RenewIcon = () => <div>RenewIcon</div>;
export const ReportIcon = () => <div>ReportIcon</div>;
export const SyringeIcon = () => <div>SyringeIcon</div>;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ import overflowMenuVertical from './svgs/overflow-menu--vertical.svg';
import pedestrianFamily from './svgs/pedestrian-family.svg';
import pen from './svgs/pen.svg';
import printer from './svgs/printer.svg';
import programs from './svgs/programs.svg';
import renew from './svgs/renew.svg';
import password from './svgs/password.svg';
import report from './svgs/report.svg';
Expand Down Expand Up @@ -139,6 +140,7 @@ export function setupIcons() {
addSvg('omrs-icon-pedestrian-family', pedestrianFamily);
addSvg('omrs-icon-pen', pen);
addSvg('omrs-icon-printer', printer);
addSvg('omrs-icon-programs', programs);
addSvg('omrs-icon-renew', renew);
addSvg('omrs-icon-password', password);
addSvg('omrs-icon-report', report);
Expand Down
40 changes: 24 additions & 16 deletions packages/framework/esm-styleguide/src/icons/icons.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -455,6 +455,14 @@ export const PrinterIcon = memo(
}),
);

/**
*/
export const ProgramsIcon = memo(
forwardRef<SVGSVGElement, IconProps>(function ProgramsIcon(props, ref) {
return <Icon ref={ref} icon="omrs-icon-programs" iconProps={props} />;
}),
);

/**
*/
export const RenewIcon = memo(
Expand All @@ -463,6 +471,14 @@ export const RenewIcon = memo(
}),
);

/**
*/
export const ReportIcon = memo(
forwardRef<SVGSVGElement, IconProps>(function ReportIcon(props, ref) {
return <Icon ref={ref} icon="omrs-icon-report" iconProps={props} />;
}),
);

/**
*/
export const ResetIcon = memo(
Expand Down Expand Up @@ -530,6 +546,14 @@ export const StickyNoteAddIcon = memo(
}),
);

/**
*/
export const SyringeIcon = memo(
forwardRef<SVGSVGElement, IconProps>(function SyringeIcon(props, ref) {
return <Icon ref={ref} icon="omrs-icon-syringe" iconProps={props} />;
}),
);

/**
* Used as a button to add an item to the Order basket from a search
*/
Expand Down Expand Up @@ -643,22 +667,6 @@ export const WarningIcon = memo(
}),
);

/**
*/
export const ReportIcon = memo(
forwardRef<SVGSVGElement, IconProps>(function ReportIcon(props, ref) {
return <Icon ref={ref} icon="omrs-icon-report" iconProps={props} />;
}),
);

/**
*/
export const SyringeIcon = memo(
forwardRef<SVGSVGElement, IconProps>(function SyringeIcon(props, ref) {
return <Icon ref={ref} icon="omrs-icon-syringe" iconProps={props} />;
}),
);

// Icon aliases that are a little more aligned to specific use-cases
// should all resolve to a defined React icon

Expand Down
13 changes: 13 additions & 0 deletions packages/framework/esm-styleguide/src/icons/svgs/programs.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit a46c9fa

Please sign in to comment.