@homebound/truss 1.110.1 → 1.111.2
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/build/config.d.ts +9 -0
- package/build/config.js +13 -0
- package/build/config.js.map +1 -1
- package/build/index.js +17 -2
- package/build/index.js.map +1 -1
- package/package.json +4 -2
package/build/config.d.ts
CHANGED
|
@@ -63,6 +63,15 @@ export interface Config {
|
|
|
63
63
|
/** Any extra chunks of code you want appended to the end of the file. */
|
|
64
64
|
extras?: Array<string | Code>;
|
|
65
65
|
}
|
|
66
|
+
/**
|
|
67
|
+
* A helper method to define config w/o a trailing cast.
|
|
68
|
+
*
|
|
69
|
+
* Based on `vite.config.ts`'s approach.
|
|
70
|
+
*
|
|
71
|
+
* We could eventually use this as a place to apply defaults, but currently
|
|
72
|
+
* just return the passed in `config` object as-is.
|
|
73
|
+
*/
|
|
74
|
+
export declare function defineConfig(config: Config): Config;
|
|
66
75
|
/**
|
|
67
76
|
* A function takes the project's `Config` and produces a list of utility methods to
|
|
68
77
|
* add to the generated `Css.ts` file.
|
package/build/config.js
CHANGED
|
@@ -1,3 +1,16 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.defineConfig = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* A helper method to define config w/o a trailing cast.
|
|
6
|
+
*
|
|
7
|
+
* Based on `vite.config.ts`'s approach.
|
|
8
|
+
*
|
|
9
|
+
* We could eventually use this as a place to apply defaults, but currently
|
|
10
|
+
* just return the passed in `config` object as-is.
|
|
11
|
+
*/
|
|
12
|
+
function defineConfig(config) {
|
|
13
|
+
return config;
|
|
14
|
+
}
|
|
15
|
+
exports.defineConfig = defineConfig;
|
|
3
16
|
//# sourceMappingURL=config.js.map
|
package/build/config.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":";;;AA8EA;;;;;;;GAOG;AACH,SAAgB,YAAY,CAAC,MAAc;IACzC,OAAO,MAAM,CAAC;AAChB,CAAC;AAFD,oCAEC"}
|
package/build/index.js
CHANGED
|
@@ -15,11 +15,12 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
exports.newSetCssVariablesMethod = exports.newParamMethod = exports.newIncrementMethods = exports.newIncrementDelegateMethods = exports.newMethodsForProp = exports.newMethod = exports.newAliasesMethods = exports.generate = exports.defaultSections = void 0;
|
|
18
|
+
var generate_1 = require("./generate");
|
|
18
19
|
__exportStar(require("./config"), exports);
|
|
19
20
|
var tachyons_1 = require("./sections/tachyons");
|
|
20
21
|
Object.defineProperty(exports, "defaultSections", { enumerable: true, get: function () { return tachyons_1.defaultSections; } });
|
|
21
|
-
var
|
|
22
|
-
Object.defineProperty(exports, "generate", { enumerable: true, get: function () { return
|
|
22
|
+
var generate_2 = require("./generate");
|
|
23
|
+
Object.defineProperty(exports, "generate", { enumerable: true, get: function () { return generate_2.generate; } });
|
|
23
24
|
var methods_1 = require("./methods");
|
|
24
25
|
Object.defineProperty(exports, "newAliasesMethods", { enumerable: true, get: function () { return methods_1.newAliasesMethods; } });
|
|
25
26
|
Object.defineProperty(exports, "newMethod", { enumerable: true, get: function () { return methods_1.newMethod; } });
|
|
@@ -28,4 +29,18 @@ Object.defineProperty(exports, "newIncrementDelegateMethods", { enumerable: true
|
|
|
28
29
|
Object.defineProperty(exports, "newIncrementMethods", { enumerable: true, get: function () { return methods_1.newIncrementMethods; } });
|
|
29
30
|
Object.defineProperty(exports, "newParamMethod", { enumerable: true, get: function () { return methods_1.newParamMethod; } });
|
|
30
31
|
Object.defineProperty(exports, "newSetCssVariablesMethod", { enumerable: true, get: function () { return methods_1.newSetCssVariablesMethod; } });
|
|
32
|
+
if (require.main === module) {
|
|
33
|
+
// Hook up ts-node so we can require a TypeScript file
|
|
34
|
+
require("ts-node/register/transpile-only");
|
|
35
|
+
var path = require("path").join(process.cwd(), "./truss-config.ts");
|
|
36
|
+
var config_1 = require(path).default;
|
|
37
|
+
(0, generate_1.generate)(config_1)
|
|
38
|
+
.then(function (done) {
|
|
39
|
+
console.log("Generated ".concat(config_1.outputPath));
|
|
40
|
+
})
|
|
41
|
+
.catch(function (err) {
|
|
42
|
+
console.error(err);
|
|
43
|
+
process.exit(1);
|
|
44
|
+
});
|
|
45
|
+
}
|
|
31
46
|
//# sourceMappingURL=index.js.map
|
package/build/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,2CAA2B;AAC3B,gDAAwD;AAA/C,2GAAA,eAAe,OAAA;AACxB,uCAAwC;AAA/B,oGAAA,QAAQ,OAAA;AAEjB,qCAQqB;AAPnB,4GAAA,iBAAiB,OAAA;AACjB,oGAAA,SAAS,OAAA;AACT,4GAAA,iBAAiB,OAAA;AACjB,sHAAA,2BAA2B,OAAA;AAC3B,8GAAA,mBAAmB,OAAA;AACnB,yGAAA,cAAc,OAAA;AACd,mHAAA,wBAAwB,OAAA"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,uCAAwC;AAExC,2CAA2B;AAC3B,gDAAwD;AAA/C,2GAAA,eAAe,OAAA;AACxB,uCAAwC;AAA/B,oGAAA,QAAQ,OAAA;AAEjB,qCAQqB;AAPnB,4GAAA,iBAAiB,OAAA;AACjB,oGAAA,SAAS,OAAA;AACT,4GAAA,iBAAiB,OAAA;AACjB,sHAAA,2BAA2B,OAAA;AAC3B,8GAAA,mBAAmB,OAAA;AACnB,yGAAA,cAAc,OAAA;AACd,mHAAA,wBAAwB,OAAA;AAG1B,IAAI,OAAO,CAAC,IAAI,KAAK,MAAM,EAAE;IAC3B,sDAAsD;IACtD,OAAO,CAAC,iCAAiC,CAAC,CAAC;IAC3C,IAAM,IAAI,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,mBAAmB,CAAC,CAAC;IACtE,IAAM,QAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,OAAO,CAAC;IACrC,IAAA,mBAAQ,EAAC,QAAM,CAAC;SACb,IAAI,CAAC,UAAC,IAAI;QACT,OAAO,CAAC,GAAG,CAAC,oBAAa,QAAM,CAAC,UAAU,CAAE,CAAC,CAAC;IAChD,CAAC,CAAC;SACD,KAAK,CAAC,UAAC,GAAG;QACT,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACnB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC,CAAC,CAAC;CACN"}
|
package/package.json
CHANGED
|
@@ -1,19 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@homebound/truss",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.111.2",
|
|
4
4
|
"main": "build/index.js",
|
|
5
|
+
"bin": "build/index.js",
|
|
5
6
|
"scripts": {
|
|
6
7
|
"test": "jest"
|
|
7
8
|
},
|
|
8
9
|
"license": "ISC",
|
|
9
10
|
"dependencies": {
|
|
10
11
|
"csstype": "^2.6.10",
|
|
11
|
-
"
|
|
12
|
+
"ts-node": "^10.7.0",
|
|
12
13
|
"ts-poet": "^3.2.2"
|
|
13
14
|
},
|
|
14
15
|
"devDependencies": {
|
|
15
16
|
"@homebound/tsconfig": "^1.0.3",
|
|
16
17
|
"@types/jest": "^26.0.20",
|
|
18
|
+
"@types/node": "^16.0.3",
|
|
17
19
|
"jest": "^26.6.3",
|
|
18
20
|
"ts-jest": "^26.4.4",
|
|
19
21
|
"typescript": "^4.6.3"
|