Giter Site home page Giter Site logo

vitaly-z / vscode-fontawesome-auto-complete Goto Github PK

View Code? Open in Web Editor NEW

This project forked from janne252/vscode-fontawesome-auto-complete

0.0 0.0 0.0 9.62 MB

Auto-complete & preview Font Awesome icons in any language.

Home Page: https://marketplace.visualstudio.com/items?itemName=Janne252.fontawesome-autocomplete

License: GNU General Public License v3.0

JavaScript 8.70% PHP 0.51% AutoHotkey 0.78% TypeScript 86.74% HTML 1.79% Batchfile 0.80% Vue 0.69%

vscode-fontawesome-auto-complete's Introduction

Font Awesome Auto-complete & Preview

Font Awesome 6 (free) Font Awesome 5 (free) Font Awesome 4

Auto-complete & preview Font Awesome 6, 5, or 4 icons in any language (see configuration).

Installation

Product / installation type Platform
VS Code Visual Studio Marketplace
VSCodium Open VSX Version
Manual .vsix file

Default usage

Type "fa-" (without quotes) to start auto-completing icons. If the icon preview is not showing up (as shown in the GIFs below), press Ctrl+Space (default hotkey) or press the "Read More..." button to expand the details view.

Additional features

Mouse-over documentation

Configuration

The following options can be set in the settings to configure the behavior of the extension:

{
    // Font Awesome version to use.
    "fontAwesomeAutocomplete.version": "5",
    // List of glob patterns that determine where Font Awesome 5 Autocomplete will provide suggestions.
    "fontAwesomeAutocomplete.patterns": [
        "**/*.html"
    ],
    // A word that triggers the autocompletion of Font Awesome icons. Last character of the trigger word is also the trigger character for autocompletion menu.
    "fontAwesomeAutocomplete.triggerWord": "fa-",
    // A list of glob patterns for which the extension should NOT auto-remove the trigger word when a font class name is inserted from the autocompletion list.
    "fontAwesomeAutocomplete.disableTriggerWordAutoClearPatterns": ["**/*.html"],
    // Background color of a Font Awesome icon preview. Supports any valid CSS color.
    "fontAwesomeAutocomplete.preview.backgroundColor": "#ffffff",
    // Foreground color of a Font Awesome icon preview. Supports any valid CSS color.
    "fontAwesomeAutocomplete.preview.foregroundColor": "#000000",
    // Allows overriding the inserted text per file type when an autocompletion item is selected. 
    // Available template placeholders are {style}, {styleName}, {name}, and {prefix}. 
    // {name} supports the following formatters: camelCase, kebabCase, pascalCase, and snakeCase. Usage: {name:formatter}, e.g. {name:camelCase}
    "fontAwesomeAutocomplete.insertionTemplate": {
        "**/*.html": "{style} {prefix}{name}"
    }
    // Artificially increases the importance of completion items. Enabled by default as FontAwesome Autocomplete extension only provides suggestions based on the triggerWord setting.
    "fontAwesomeAutocomplete.enableElevatedSortPriority": true
}

The extension listens for changes in the settings and auto-reloads itself when necessary.

Troubleshooting / FAQ

I'm not using standard CSS class name icon references

See Insertion templates for 3rd party libraries.

Autocompletion suggestions are not appearing

See the configuration reference. Font Awesome icons only appear in the autocompletion item list if the current word starts with the value of the setting fontAwesomeAutocomplete.triggerWord, e.g. "fa-" (default).

  • The last character of the trigger word (e.g. -, which is the default) also works as the trigger character for the autocompletion menu.

Malformed / incomplete / weird output after choosing an autocompletion item

Try adding the current file extension as a glob pattern (e.g. "**/*.html") to the fontAwesomeAutocomplete.disableTriggerWordAutoClearPatterns setting. If that doesn't help, please open an issue!

Mouse-over documentation does not work with a custom insertion template

If a custom insertion template is configured and the mouse-over documentation does not work, please open an issue. Make sure to provide the custom insertion template for reference and issue reproduction.

Autocompletion suggestions of this extension appear at the end of the list

This is usually caused by another extension having higher priority, especially if the other extension provides snippets.

  • Make sure the setting fontAwesomeAutocomplete.enableElevatedSortPriority is set to true (default)
  • Set the setting editor.snippetSuggestions to "bottom" If you're still having trouble with the sort order of the autocompletion items, please open issue.

Insertion templates for 3rd party libraries

Changelog

See CHANGELOG.md

License

See LICENCE.md

vscode-fontawesome-auto-complete's People

Contributors

janne252 avatar

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.