@trackunit/css-tailwind-custom-properties-plugin 0.0.10 → 0.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.cjs CHANGED
@@ -12,7 +12,7 @@ var plugin__default = /*#__PURE__*/_interopDefaultLegacy(plugin);
12
12
  * Converts an array of keys to a valid CSS custom property name.
13
13
  *
14
14
  * @param keys An array of strings representing the keys to be converted to a CSS custom property name.
15
- * @returns A string representing the CSS custom property name.
15
+ * @returns { string } A string representing the CSS custom property name.
16
16
  */
17
17
  const keysToCssVariableName = (keys) => `--${keys.join("-")}`.replace(/[^a-zA-Z0-9]/g, "-");
18
18
  /**
@@ -23,7 +23,7 @@ const keysToCssVariableName = (keys) => `--${keys.join("-")}`.replace(/[^a-zA-Z0
23
23
  * @param {object} values - The object containing the nested variables declarations and their values
24
24
  * @param {object} [output] - The flat object to store the generated CSS variable names and values
25
25
  * @param {string[]} [keys] - An array of keys representing the current path of the object being processed
26
- * @returns {object} - The generated flat object containing the CSS variable names and values
26
+ * @returns {VariablesDeclerationObject} - The generated flat object containing the CSS variable names and values
27
27
  */
28
28
  const flattenVariablesDeclerationValues = (values, output = {}, keys = []) => {
29
29
  for (const [key, value] of Object.entries(values)) {
@@ -42,7 +42,7 @@ const flattenVariablesDeclerationValues = (values, output = {}, keys = []) => {
42
42
  * Converts a object containing CSS variables to an array of CSS rules.
43
43
  *
44
44
  * @param variablesDecleration An object containing the CSS variables and their corresponding values.
45
- * @returns An array of CSS rules.
45
+ * @returns {CSSRuleObject[]} An array of CSS rules.
46
46
  */
47
47
  const variablesToCSSRules = (variablesDecleration) => {
48
48
  if (!variablesDecleration) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trackunit/css-tailwind-custom-properties-plugin",
3
- "version": "0.0.10",
3
+ "version": "0.0.12",
4
4
  "main": "./index.cjs",
5
5
  "repository": "https://github.com/Trackunit/manager",
6
6
  "license": "SEE LICENSE IN LICENSE.txt",
@@ -6,7 +6,7 @@ export type VariablesDeclerationObject = {
6
6
  * Converts an array of keys to a valid CSS custom property name.
7
7
  *
8
8
  * @param keys An array of strings representing the keys to be converted to a CSS custom property name.
9
- * @returns A string representing the CSS custom property name.
9
+ * @returns { string } A string representing the CSS custom property name.
10
10
  */
11
11
  export declare const keysToCssVariableName: (keys: string[]) => string;
12
12
  /**
@@ -17,13 +17,13 @@ export declare const keysToCssVariableName: (keys: string[]) => string;
17
17
  * @param {object} values - The object containing the nested variables declarations and their values
18
18
  * @param {object} [output] - The flat object to store the generated CSS variable names and values
19
19
  * @param {string[]} [keys] - An array of keys representing the current path of the object being processed
20
- * @returns {object} - The generated flat object containing the CSS variable names and values
20
+ * @returns {VariablesDeclerationObject} - The generated flat object containing the CSS variable names and values
21
21
  */
22
22
  export declare const flattenVariablesDeclerationValues: (values: object, output?: VariablesDeclerationObject, keys?: string[]) => VariablesDeclerationObject;
23
23
  /**
24
24
  * Converts a object containing CSS variables to an array of CSS rules.
25
25
  *
26
26
  * @param variablesDecleration An object containing the CSS variables and their corresponding values.
27
- * @returns An array of CSS rules.
27
+ * @returns {CSSRuleObject[]} An array of CSS rules.
28
28
  */
29
29
  export declare const variablesToCSSRules: (variablesDecleration: object) => CSSRuleObject[];