carbon-design-system / carbon

A design system built by IBM
https://www.carbondesignsystem.com
Apache License 2.0
7.79k stars 1.8k forks source link

[AI] Create design spec for AI `Code-snippet` #15301

Open aagonzales opened 10 months ago

aagonzales commented 10 months ago

Create a design spec for an AI flavor of code snippet (inline, single line and multi-line), incorporating the slug and aura gradient where appropriate. Design a solution for both light and dark themes.

Tasks

Features AI Chat needs

See: https://labs-canary.carbondesignsystem.com/?path=/story/components-chat-code--showcase

github-actions[bot] commented 10 months ago

Thank you for submitting a feature request. Your proposal is open and will soon be triaged by the Carbon team.

If your proposal is accepted and the Carbon team has bandwidth they will take on the issue, or else request you or other volunteers from the community to work on this issue.

RichKummer commented 9 months ago

Figma design specs

Image

RichKummer commented 8 months ago

I also looked at how AI generated code could be previewed inside a code editor. Sharing some quick sketches here, along with feedback from Taylor:

Hey! I'll give you my 2c. Feasibility of this will depend on the tech powering the code editor. It is typically possible though to bold, italic, etc within these. vscode does this through themes as part of their support for syntax highlighting. Determining what gets italicized can differ between themes. I'm sure there's a default set of things in vscode, but I'm not sure what they are. Overall I think italicizing as the only marker of AI generated code may not be enough. It would need a background highlight or something like a slug imo. (edited)

Slack message

Image