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

Add Catppuccin Colors #688

Merged
merged 7 commits into from
Dec 16, 2024
Merged

Add Catppuccin Colors #688

merged 7 commits into from
Dec 16, 2024

Conversation

Shlok-Bhakta
Copy link
Contributor

What type of PR is this? (check all applicable)

  • ✨ Feature
  • πŸ› Bug Fix
  • πŸ“ Documentation Update
  • 🎨 Style
  • ♻️ Code Refactor
  • πŸ”₯ Performance Improvements
  • βœ… Test
  • πŸ€– Build
  • πŸ” CI
  • πŸ“¦ Chore (Release)
  • ⏩ Revert
  • 🌐 Internationalization / Translation

Description

This adds cappuccin colors to the editor from
https://catppuccin.com/palette

Following the spec as close as I could
https://github.com/catppuccin/catppuccin/blob/main/docs/style-guide.md

Related Tickets & Documents

Implements #686

Mobile & Desktop Screenshots/Recordings

Monaco

Catppuccin Latte
Monaco L

Catppuccin Frappe
Monaco F

Catppuccin Macchiato
Monaco Ma

Catppuccin Mocha
Monaco Mo

Codemirror

Catppuccin Latte
Codemirror L

Catppuccin Frappe
Codemirror F

Catppuccin Macchiato
Codemirror Ma

Catppuccin Mocha
Codemirror Mo

Codejar

Catppuccin Latte
Codejar L

Catppuccin Frappe
Codejar F

Catppuccin Macchiato
Codejar Ma

Catppuccin Mocha
Codejar Mo

Added tests?

  • πŸ‘ yes
  • πŸ™… no, because they aren't needed
  • πŸ™‹ no, because I need help

Added to documentations?

  • πŸ““ docs (./docs)
  • πŸ“• storybook (./storybook)
  • πŸ“œ README.md
  • πŸ™… no documentation needed

[optional] Are there any post-deployment tasks we need to perform?

None

[optional] What gif best describes this PR or how it makes you feel?

cat happy

Copy link

netlify bot commented Dec 16, 2024

βœ… Deploy Preview for livecodes ready!

Name Link
πŸ”¨ Latest commit 1ac1ced
πŸ” Latest deploy log https://app.netlify.com/sites/livecodes/deploys/676015f5cefe2d00080b666e
😎 Deploy Preview https://deploy-preview-688--livecodes.netlify.app
πŸ“± Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@Shlok-Bhakta
Copy link
Contributor Author

how do I not duplicate code when adding a theme? @hatemhosny

Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
5.0% Duplication on New Code (required ≀ 3%)

See analysis details on SonarQube Cloud

@hatemhosny
Copy link
Collaborator

Thank you @Shlok-Bhakta
That's very nice indeed.

I prefer to keep external dependencies (like themes), outside LiveCodes code base.
This way we keep the bundle size smaller and we can lazy-load each theme on demand from a fast CDN (e.g. jsdelivr/unpkg).
This also reduces a lot of the code duplication in this code base.

Previously, I inlined the monochrome themes because they were very simple so that they were not worth the extra URL requests.

I moved the themes you added to another repo (https://github.com/live-codes/browser-compilers) which I use for many of the dependencies like this (including language compilers, etc), and I published it to npm so that we can load these dependencies from CDNs that mirror npm. e.g. https://unpkg.com/browse/@live-codes/browser-compilers@0.18.0/dist/catppuccin/

Please check the deploy preview (https://deploy-preview-688--livecodes.netlify.app/) and if you are happy with it I will merge the PR.
Thanks a lot.

@Shlok-Bhakta
Copy link
Contributor Author

Themes look good to me! Thank you for fixing my issue!

@hatemhosny hatemhosny merged commit 7f9c8ad into live-codes:develop Dec 16, 2024
12 of 13 checks passed
@hatemhosny hatemhosny mentioned this pull request Dec 16, 2024
2 tasks
@hatemhosny
Copy link
Collaborator

Thank you, @Shlok-Bhakta
The PR is merged.
You can test it on the development build on: dev.livecodes.io

This will land in livecodes.io in the next release which is planned by the end of this week.
If you have a twitter account, please send it, so that I can give you credit there when the next version is released.
Thanks a lot and you are very welcome to keep contributing to LiveCodes ❀️

@Shlok-Bhakta
Copy link
Contributor Author

Awesome! my twitter is @shlokbhakta

can't wait to use this theme on my blog!

@hatemhosny
Copy link
Collaborator

Awesome! my twitter is @shlokbhakta

can't wait to use this theme on my blog!

You may also be interested in this new feature coming in this release, which can use the new themes!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants