Code Monkey home page Code Monkey logo

Comments (3)

yusanshi avatar yusanshi commented on September 24, 2024

Thanks for your idea.

As you know, the code highlighting job in the repo is provided by highlight.js and we're using the theme from it.

https://github.com/yusanshi/embed-like-gist/blob/master/embed.js#L33
image

I just looked into https://highlightjs.org/static/demo/, and I found there is no Arduino Dark theme, but Arduino Light.
image

I checked the https://github.com/konrad91/OneDarkArduino repo you provided, and surely the code in it can't be directly used by this project. The needed style code should be like this:

https://cdn.jsdelivr.net/gh/highlightjs/[email protected]/build/styles/arduino-light.min.css

.hljs{display:block;overflow-x:auto;padding:.5em;background:#FFFFFF}.hljs,.hljs-subst{color:#434f54}.hljs-keyword,.hljs-attribute,.hljs-selector-tag,.hljs-doctag,.hljs-name{color:#00979D}.hljs-built_in,.hljs-literal,.hljs-bullet,.hljs-code,.hljs-addition{color:#D35400}.hljs-regexp,.hljs-symbol,.hljs-variable,.hljs-template-variable,.hljs-link,.hljs-selector-attr,.hljs-selector-pseudo{color:#00979D}.hljs-type,.hljs-string,.hljs-selector-id,.hljs-selector-class,.hljs-quote,.hljs-template-tag,.hljs-deletion{color:#005C5F}.hljs-title,.hljs-section{color:#880000;font-weight:bold}.hljs-comment{color:rgba(149,165,166,0.8)}.hljs-meta-keyword{color:#728E00}.hljs-meta{color:#434f54}.hljs-emphasis{font-style:italic}.hljs-strong{font-weight:bold}.hljs-function{color:#728E00}.hljs-number{color:#8A7B52}

So I think there're 2 options we can choose from:

  1. Write our own CSS code for Arduino Dark.
  2. Request this theme to highlight.js. Since they have provided Arduino Light theme, adding a dark version should not be so hard, I think. :)

from emgithub.

yusanshi avatar yusanshi commented on September 24, 2024

I suggest option 2: request the theme to highlight.js.

Once the work was done, we can upgrade highlight.js in this project to use the newly added theme.

from emgithub.

BelKed avatar BelKed commented on September 24, 2024

As @yusanshi mentioned, there already is theme like that – Atom One Dark.

from emgithub.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.