summaryrefslogtreecommitdiff
path: root/dev/generate-css-json.js
diff options
context:
space:
mode:
authorCashew <52880648+Scrub1492@users.noreply.github.com>2023-12-19 12:44:40 +0900
committerGitHub <noreply@github.com>2023-12-19 03:44:40 +0000
commitc661eafa7d57c32e33e51dd6eb787b97832e97f0 (patch)
tree1a68a563f9f1960d528595d6b33f74cb506bd77e /dev/generate-css-json.js
parenteb7bf9542c92ea7937d4b4a699ae2d47270da96b (diff)
Add some JSDoc annotations to describe code functionality. (#355)
* lesen-tan initial commit * update README.md * tidy up code * opt for Map<K, V> instead of Object * Document dev/* * add docs for deinflector.js * update deinflector example * Annotate * Revert "Merge branch 'development' of https://github.com/Scrub1492/lesen-tan into development" This reverts commit b92348f702bc031b36f24462adfa940d17f9ecdd, reversing changes made to 3255e6d963281af3533dcf1e893df39032d29fec. * Lint error fix * Lint error fix
Diffstat (limited to 'dev/generate-css-json.js')
-rw-r--r--dev/generate-css-json.js9
1 files changed, 5 insertions, 4 deletions
diff --git a/dev/generate-css-json.js b/dev/generate-css-json.js
index e5d4d7f0..a0035346 100644
--- a/dev/generate-css-json.js
+++ b/dev/generate-css-json.js
@@ -86,11 +86,11 @@ function removeProperty(styles, property, removedProperties) {
}
/**
- * @param {import('css-style-applier').RawStyleData} rules
+ * Manually formats JSON for improved compactness.
+ * @param {import('css-style-applier').RawStyleData} rules CSS ruleset.
* @returns {string}
*/
export function formatRulesJson(rules) {
- // Manually format JSON, for improved compactness
// return JSON.stringify(rules, null, 4);
const indent1 = ' ';
const indent2 = indent1.repeat(2);
@@ -123,8 +123,9 @@ export function formatRulesJson(rules) {
}
/**
- * @param {string} cssFile
- * @param {string} overridesCssFile
+ * Generates a CSS ruleset.
+ * @param {string} cssFile Path to CSS file.
+ * @param {string} overridesCssFile Path to override CSS file.
* @returns {import('css-style-applier').RawStyleData}
* @throws {Error}
*/