microsoft / microsoft/vscode-custom-data

Restrict property definitions to specific tags

Open
#38 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
240
Forks
95
PR merge metrics
No merged PRs in 30d

Description

I've looked through the information here and several other sites and JSON documents, and the one thing I cannot find an answer to, is how to define a property for only certain tags. For example, NativeScript supports a placeholder-color property on the TextField tag, but VSCode does not recognize it. I've added it as a property to a CSS custom data file as described, but that makes the property available to ALL tags -- not just the TextField tag. If this is indeed new functionality, then I suggest that the property object contain a tags property which would be an array of strings.

{
  "version": 1.1,
  "properties": [
    {
      "name": "placeholder-color",
      "description": "Color of the placeholder text.",
      "tags": ["TextField", "Button"]
    }
  ]
}

On the other hand, if this is already supported in some way, could you please make it more clear in your documents?

Thanks!
Eric

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the custom data format documentation and the property-definition behavior described in this issue. Verify whether tag-scoped properties are already supported; done means documenting the existing syntax or agreeing on and implementing the proposed tags restriction.

Written by the indexing model from the issue text.

Assessment

Tech stack
vscode
Domain
tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.