Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dotnet logo #265

Merged
merged 1 commit into from
Dec 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/eight-mangos-complain.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@spotlightjs/overlay': minor
---

dotnet logo
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import { ReactComponent as AstroIcon } from 'platformicons/svg/astro.svg';
import { ReactComponent as DefaultIcon } from 'platformicons/svg/default.svg';
import { ReactComponent as DotNetIcon } from 'platformicons/svg/dotnet.svg';
import { ReactComponent as JavaScriptIcon } from 'platformicons/svg/javascript.svg';
import { ReactComponent as DotNetMauiIcon } from 'platformicons/svg/maui.svg';
import { ReactComponent as NodeIcon } from 'platformicons/svg/nodejs.svg';
import { ReactComponent as PhpIcon } from 'platformicons/svg/php.svg';
import { ReactComponent as PythonIcon } from 'platformicons/svg/python.svg';
Expand All @@ -10,7 +12,7 @@

import { ComponentPropsWithoutRef } from 'react';

type Platform = 'python' | 'javascript' | 'node' | 'ruby' | string;
type Platform = 'python' | 'javascript' | 'node' | 'ruby' | 'csharp' | string;

export default function PlatformIcon({
platform,
Expand All @@ -36,6 +38,11 @@
return <NodeIcon width={size} height={size} {...props} />;
case 'php':
return <PhpIcon width={size} height={size} {...props} />;
case 'dotnet':
case 'csharp': // event.platform is 'csharp'
return <DotNetIcon width={size} height={size} {...props} />;
case 'dotnet.maui':
return <DotNetMauiIcon width={size} height={size} {...props} />;

Check warning on line 45 in packages/overlay/src/integrations/sentry/components/PlatformIcon.tsx

View check run for this annotation

Codecov / codecov/patch

packages/overlay/src/integrations/sentry/components/PlatformIcon.tsx#L41-L45

Added lines #L41 - L45 were not covered by tests
default:
return <DefaultIcon width={size} height={size} {...props} />;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,6 @@
if (name.includes('python')) return 'python';
if (name.includes('php')) return 'php';
if (name.includes('ruby')) return 'ruby';
if (name.includes('dotnet')) return 'dotnet';

Check warning on line 10 in packages/overlay/src/integrations/sentry/utils/sdkToPlatform.ts

View check run for this annotation

Codecov / codecov/patch

packages/overlay/src/integrations/sentry/utils/sdkToPlatform.ts#L10

Added line #L10 was not covered by tests
return 'unknown';
}