Giter VIP home page Giter VIP logo

vscode-css-comment's Introduction

px-comment README

This extention renders the px values of the rem numbers or rem valurs of px numbers in your vs code file .

image

Configuration

The following properties are configurable:

  // Decoration color for the px comment value
  "remToPxComment.pxCommentColor": "#36C210",

    // Decoration color for the rem comment value
  "remToPxComment.remCommentColor": "#D61355",

  // value to convert px to rem, default is 16px
  "remToPxComment.remConversionValue": 16

  // tells if to convert from rem to px or the other way around
  "remToPxComment.convertToPx": true
  
  // tells if to convert from px to rem or the other way around
  "remToPxComment.convertToRem": true

  // tells if to add increment and decrement key board shortcuts
  "remToPxComment.addKeyBoardShortcuts": false

  // if true the converted line will have a bg color
  "remToPxComment.hasLineBgColor": false

  // bg color of converted line, the color appled will be of low opacity
  "remToPxComment.lineBgColor": "#36C210"

Keyboard shortcuts

By checking the addKeyBoardShortcuts in settings a set of default shortcuts for incrementing and decrementing numbers will be enabled

An example is like the following

Screen.Recording.2023-01-10.at.11.46.06.PM.mov

In the above video pressing cmd+shift+i in mac or ctrl+shift+i in windows will increment the number by 1 based on cursor position

Similarly pressing cmd+shift+d in mac or ctrl+shift+d in windows will decrement the number by 1 based on cursor position

These are all the keyboard shortcuts that will be enabled when checking addKeyBoardShortcuts option in settings

All increments :

  • cmd+shift+i in mac or ctrl+shift+i in windows : increment number by one
  • cmd+shift+h in mac or ctrl+shift+h in windows : increment number by one tenth
  • cmd+shift+t in mac or ctrl+shift+t in windows : increment number ten

All decrements :

  • cmd+shift+d in mac or ctrl+shift+d in windows : decrement number by 1
  • cmd+shift+z in mac or ctrl+shift+z in windows : decrement number by one tenth
  • cmd+shift+v in mac or ctrl+shift+v in windows : decrement number by ten

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.