From 27d924e336ba15586e75794892158758a2eaa00f Mon Sep 17 00:00:00 2001 From: Oliver-Akins Date: Sun, 19 Jan 2025 16:11:56 -0700 Subject: [PATCH] Add custom data for Foundry / RipCrypt custom elements --- .vscode/foundry.html-data.json | 18 ++++++++++++++++++ .vscode/ripcrypt.html-data.json | 31 +++++++++++++++++++++++++++++++ .vscode/settings.json | 6 +++++- 3 files changed, 54 insertions(+), 1 deletion(-) create mode 100644 .vscode/foundry.html-data.json create mode 100644 .vscode/ripcrypt.html-data.json diff --git a/.vscode/foundry.html-data.json b/.vscode/foundry.html-data.json new file mode 100644 index 0000000..3358d2b --- /dev/null +++ b/.vscode/foundry.html-data.json @@ -0,0 +1,18 @@ +{ + "version": 1.1, + "globalAttributes": [ + { "name": "data-tooltip", "description": "The content for the tooltip to display" }, + { "name": "data-tooltip-direction", "description": "The direction that the tooltip renders in, in relation to the element that has the tooltip", "valueSet": "tooltip-direction" } + ], + "valueSets": [ + { + "name": "tooltip-direction", + "values": [ + { "name": "UP", "description": "Put the tooltip above the element" }, + { "name": "LEFT", "description": "Put the tooltip to the left of the element" }, + { "name": "RIGHT", "description": "Put the tooltip to the right of element" }, + { "name": "DOWN", "description": "Put the tooltip below the element" } + ] + } + ] +} \ No newline at end of file diff --git a/.vscode/ripcrypt.html-data.json b/.vscode/ripcrypt.html-data.json new file mode 100644 index 0000000..0287bb8 --- /dev/null +++ b/.vscode/ripcrypt.html-data.json @@ -0,0 +1,31 @@ +{ + "version": 1.1, + "tags": [ + { + "name": "rc-icon", + "description": "Loads an icon asynchronously, caching the result for future uses", + "attributes": [ + { "name": "name", "description": "The name of the icon, this is relative to the assets folder of the dotdungeon system" }, + { "name": "path", "description": "The full path of the icon, this will only be used if `name` isn't provided or fails to fetch." }, + { "name": "var:size", "description": "The size of the icon, must be a valid CSS unit" }, + { "name": "var:fill", "description": "The fill of the icon, must be a valid CSS colour" }, + { "name": "var:stroke", "description": "The stroke colour of the icon, must be a valid CSS colour" }, + { "name": "var:stroke-width", "description": "The stroke width of the icon, must be a valid CSS unit" }, + { "name": "var:stroke-linejoin", "description": "The stroke linejoin of the icon, must be a valid CSS value" } + ] + }, + { + "name": "rc-svg", + "description": "Loads an icon asynchronously, caching the result for future uses", + "attributes": [ + { "name": "name", "description": "The name of the icon, this is relative to the assets folder of the dotdungeon system" }, + { "name": "path", "description": "The full path of the icon, this will only be used if `name` isn't provided or fails to fetch." }, + { "name": "var:size", "description": "The size of the icon, must be a valid CSS unit" }, + { "name": "var:fill", "description": "The fill of the icon, must be a valid CSS colour" }, + { "name": "var:stroke", "description": "The stroke colour of the icon, must be a valid CSS colour" }, + { "name": "var:stroke-width", "description": "The stroke width of the icon, must be a valid CSS unit" }, + { "name": "var:stroke-linejoin", "description": "The stroke linejoin of the icon, must be a valid CSS value" } + ] + } + ] +} \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json index a72c23c..a52b19b 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -4,5 +4,9 @@ }, "search.exclude": { "foundry.*.link": true - } + }, + "html.customData": [ + "./.vscode/foundry.html-data.json", + "./.vscode/ripcrypt.html-data.json" + ] } \ No newline at end of file