@schemavaults/theme 0.23.1 → 0.24.1
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/README.md
CHANGED
|
@@ -38,27 +38,10 @@ export default config;
|
|
|
38
38
|
|
|
39
39
|
// Import the config factory
|
|
40
40
|
import { SchemaVaultsTailwindConfigFactory } from "@schemavaults/theme";
|
|
41
|
-
|
|
42
|
-
import { lstatSync, existsSync, type Stats } from "fs";
|
|
43
|
-
|
|
44
|
-
function isdir(path: string): boolean {
|
|
45
|
-
if (!existsSync(path)) return false;
|
|
46
|
-
|
|
47
|
-
let lstatResult: Stats;
|
|
48
|
-
try {
|
|
49
|
-
lstatResult = lstatSync(path);
|
|
50
|
-
} catch (e: unknown) {
|
|
51
|
-
throw new Error(
|
|
52
|
-
"Error running lstatSync for tailwind.config.ts isdir() function!",
|
|
53
|
-
);
|
|
54
|
-
}
|
|
55
|
-
return lstatResult.isDirectory();
|
|
56
|
-
}
|
|
41
|
+
|
|
57
42
|
|
|
58
43
|
// Initialize the config factory
|
|
59
44
|
const configFactory = new SchemaVaultsTailwindConfigFactory({
|
|
60
|
-
isdir,
|
|
61
|
-
join,
|
|
62
45
|
scope: 'schemavaults'
|
|
63
46
|
});
|
|
64
47
|
|
|
@@ -67,7 +50,7 @@ const config = configFactory.createConfig({
|
|
|
67
50
|
content: [
|
|
68
51
|
"./src/**/*.tsx|jsx|js|ts",
|
|
69
52
|
"./app/**/*.tsx|jsx|js|ts",
|
|
70
|
-
"@schemavaults/ui", // resolved and converted to an absolute path to the schemavaults package in the node_modules folder
|
|
53
|
+
"@schemavaults/ui", // resolved and converted to an absolute path to the schemavaults package in the node_modules folder. i.e. @schemavaults/ui => .../node_modules/@schemavaults/ui/dist/**/*.tsx|jsx|js|ts
|
|
71
54
|
"@schemavaults/schema-ui",
|
|
72
55
|
],
|
|
73
56
|
});
|
|
@@ -1,14 +1,12 @@
|
|
|
1
1
|
import type { Config as TailwindConfig } from "tailwindcss";
|
|
2
2
|
import { type ScreenBreakpointID } from "./ScreenBreakpoints";
|
|
3
3
|
import type { TailwindTheme } from "./TailwindTheme";
|
|
4
|
-
type OsJoinFn = (path_segment: string, ...remaining_path_segments: string[]) => string;
|
|
5
4
|
export interface ISchemaVaultsTailwindConfigFactoryInitOptions {
|
|
6
5
|
debug?: boolean;
|
|
7
|
-
join?: OsJoinFn;
|
|
8
|
-
isdir?: (path: string) => boolean;
|
|
9
6
|
scope?: string;
|
|
10
7
|
fileExtensions?: readonly string[];
|
|
11
8
|
project_root?: string;
|
|
9
|
+
buildSubdirectories?: readonly string[];
|
|
12
10
|
}
|
|
13
11
|
export interface ISchemaVaultsTailwindConfigCreationOptions {
|
|
14
12
|
content: readonly string[];
|
|
@@ -21,14 +19,16 @@ type ThemeExtension = NonNullable<TailwindConfigTheme["extend"]>;
|
|
|
21
19
|
type ThemeValue = ThemeExtension[string];
|
|
22
20
|
export declare class SchemaVaultsTailwindConfigFactory implements ISchemaVaultsTailwindConfigFactory {
|
|
23
21
|
protected readonly debug: boolean;
|
|
24
|
-
protected readonly join: OsJoinFn;
|
|
25
22
|
protected readonly isdir: (path: string) => boolean;
|
|
23
|
+
protected readonly isfile: (path: string) => boolean;
|
|
26
24
|
protected readonly scope: string;
|
|
27
25
|
protected readonly project_root: string;
|
|
28
|
-
protected static readonly defaultFileExtensionsToSearch: readonly ["js", "jsx", "ts", "tsx"];
|
|
26
|
+
protected static readonly defaultFileExtensionsToSearch: readonly ["js", "jsx", "ts", "tsx", "svelte"];
|
|
27
|
+
protected readonly possibleBuildDirectories: readonly string[];
|
|
29
28
|
protected readonly fileExtensionsToIncludeInTailwindClassNamesSearch: readonly string[];
|
|
30
|
-
private static defaultJoinImplementation;
|
|
31
29
|
private static defaultIsDirImplementation;
|
|
30
|
+
private static defaultIsFileImplementation;
|
|
31
|
+
private static prettyPrintItemList;
|
|
32
32
|
constructor(opts?: ISchemaVaultsTailwindConfigFactoryInitOptions);
|
|
33
33
|
/**
|
|
34
34
|
* @description Load TailwindCSS plugins to use in theme configuration
|
|
@@ -40,8 +40,13 @@ export declare class SchemaVaultsTailwindConfigFactory implements ISchemaVaultsT
|
|
|
40
40
|
protected get brandColors(): ThemeValue;
|
|
41
41
|
protected get screenSizes(): Record<ScreenBreakpointID, `${number}px`>;
|
|
42
42
|
protected get themeExtension(): ThemeExtension;
|
|
43
|
-
|
|
44
|
-
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @param org_scoped_package_identifier A string representing an organization-scoped package identifier. For example: @schemavaults/ui
|
|
46
|
+
* @returns The resolved path for the organization-scoped package. I.e. the path that contains the package.json file
|
|
47
|
+
*/
|
|
48
|
+
protected resolveOrganizationScopedPackagePath(org_scoped_package_identifier: string): string;
|
|
49
|
+
private static defaultPossibleBuildDirectories;
|
|
45
50
|
createConfig(opts?: ISchemaVaultsTailwindConfigCreationOptions): TailwindConfig;
|
|
46
51
|
}
|
|
47
52
|
export default SchemaVaultsTailwindConfigFactory;
|
|
@@ -3,13 +3,14 @@ import { brandColors } from "./brand_colors";
|
|
|
3
3
|
import DefaultOrgScope from "./DefaultOrgScope"; // @schemavaults organization is default
|
|
4
4
|
import { getScreenBreakpoint, listScreenBreakpoints, } from "./ScreenBreakpoints";
|
|
5
5
|
import { existsSync, lstatSync } from "fs";
|
|
6
|
+
import { normalize, join, dirname } from "path";
|
|
6
7
|
// TailwindCSS Plugins:
|
|
7
8
|
import tailwindAnimatePlugin from "./plugins/tailwindcss-animate";
|
|
8
9
|
import * as resolve from "resolve";
|
|
9
10
|
export class SchemaVaultsTailwindConfigFactory {
|
|
10
11
|
debug;
|
|
11
|
-
join;
|
|
12
12
|
isdir;
|
|
13
|
+
isfile;
|
|
13
14
|
scope;
|
|
14
15
|
project_root;
|
|
15
16
|
static defaultFileExtensionsToSearch = [
|
|
@@ -17,42 +18,43 @@ export class SchemaVaultsTailwindConfigFactory {
|
|
|
17
18
|
"jsx",
|
|
18
19
|
"ts",
|
|
19
20
|
"tsx",
|
|
21
|
+
"svelte",
|
|
20
22
|
];
|
|
23
|
+
possibleBuildDirectories;
|
|
21
24
|
fileExtensionsToIncludeInTailwindClassNamesSearch;
|
|
22
|
-
static defaultJoinImplementation(path_segment, ...remaining_path_segments) {
|
|
23
|
-
const path_segments = [
|
|
24
|
-
path_segment,
|
|
25
|
-
...remaining_path_segments,
|
|
26
|
-
];
|
|
27
|
-
return path_segments.join("/");
|
|
28
|
-
}
|
|
29
25
|
static defaultIsDirImplementation(maybeDirPath) {
|
|
30
26
|
if (!existsSync(maybeDirPath)) {
|
|
31
27
|
return false;
|
|
32
28
|
}
|
|
33
29
|
return lstatSync(maybeDirPath).isDirectory();
|
|
34
30
|
}
|
|
31
|
+
static defaultIsFileImplementation(maybeFilePath) {
|
|
32
|
+
if (!existsSync(maybeFilePath)) {
|
|
33
|
+
return false;
|
|
34
|
+
}
|
|
35
|
+
return lstatSync(maybeFilePath).isFile();
|
|
36
|
+
}
|
|
37
|
+
static prettyPrintItemList(items) {
|
|
38
|
+
return `${items.map((d) => `"${d}"`).join(", ")}`;
|
|
39
|
+
}
|
|
35
40
|
constructor(opts) {
|
|
36
41
|
this.debug = opts?.debug ?? false;
|
|
37
42
|
if (this.debug) {
|
|
38
43
|
console.log("[SchemaVaultsTailwindConfigFactory] constructor()");
|
|
39
44
|
}
|
|
40
|
-
this.
|
|
41
|
-
|
|
42
|
-
? opts.join
|
|
43
|
-
: SchemaVaultsTailwindConfigFactory.defaultJoinImplementation;
|
|
44
|
-
this.isdir =
|
|
45
|
-
typeof opts?.isdir === "function"
|
|
46
|
-
? opts.isdir
|
|
47
|
-
: SchemaVaultsTailwindConfigFactory.defaultIsDirImplementation;
|
|
45
|
+
this.isdir = SchemaVaultsTailwindConfigFactory.defaultIsDirImplementation;
|
|
46
|
+
this.isfile = SchemaVaultsTailwindConfigFactory.defaultIsFileImplementation;
|
|
48
47
|
this.scope = opts?.scope ?? DefaultOrgScope;
|
|
49
48
|
if (this.scope.startsWith("@")) {
|
|
50
|
-
throw new
|
|
49
|
+
throw new TypeError("Don't pass the @ in the 'scope', we'll handle adding passing that!");
|
|
51
50
|
}
|
|
52
51
|
this.fileExtensionsToIncludeInTailwindClassNamesSearch = Array.isArray(opts?.fileExtensions)
|
|
53
52
|
? opts.fileExtensions
|
|
54
53
|
: SchemaVaultsTailwindConfigFactory.defaultFileExtensionsToSearch;
|
|
55
54
|
this.project_root = opts?.project_root ?? process.cwd();
|
|
55
|
+
this.possibleBuildDirectories = Array.isArray(opts?.buildSubdirectories)
|
|
56
|
+
? opts.buildSubdirectories
|
|
57
|
+
: SchemaVaultsTailwindConfigFactory.defaultPossibleBuildDirectories;
|
|
56
58
|
if (this.debug) {
|
|
57
59
|
console.log(`[SchemaVaultsTailwindConfigFactory] Initialized '@${this.scope}' config factory`);
|
|
58
60
|
}
|
|
@@ -97,12 +99,17 @@ export class SchemaVaultsTailwindConfigFactory {
|
|
|
97
99
|
};
|
|
98
100
|
return extend;
|
|
99
101
|
}
|
|
100
|
-
|
|
102
|
+
/**
|
|
103
|
+
*
|
|
104
|
+
* @param org_scoped_package_identifier A string representing an organization-scoped package identifier. For example: @schemavaults/ui
|
|
105
|
+
* @returns The resolved path for the organization-scoped package. I.e. the path that contains the package.json file
|
|
106
|
+
*/
|
|
107
|
+
resolveOrganizationScopedPackagePath(org_scoped_package_identifier) {
|
|
101
108
|
const scope = this.scope;
|
|
102
|
-
if (!
|
|
109
|
+
if (!org_scoped_package_identifier.startsWith(`@${scope}/`)) {
|
|
103
110
|
throw new Error(`This method should only be called if content path starts with @${scope}/...`);
|
|
104
111
|
}
|
|
105
|
-
const pkg_blob_parts =
|
|
112
|
+
const pkg_blob_parts = org_scoped_package_identifier.split("/");
|
|
106
113
|
if (pkg_blob_parts.length < 2 ||
|
|
107
114
|
!pkg_blob_parts[1] ||
|
|
108
115
|
typeof pkg_blob_parts[1] !== "string") {
|
|
@@ -118,6 +125,43 @@ export class SchemaVaultsTailwindConfigFactory {
|
|
|
118
125
|
if (typeof package_path !== "string") {
|
|
119
126
|
throw new TypeError("Failed to resolve package path; result not a string!");
|
|
120
127
|
}
|
|
128
|
+
// Helper function that checks if this is the root directory of a package
|
|
129
|
+
const isAPackageRootDir = (current_path) => {
|
|
130
|
+
if (!this.isdir(current_path)) {
|
|
131
|
+
return false;
|
|
132
|
+
}
|
|
133
|
+
else {
|
|
134
|
+
if (join(current_path, "package.json")) {
|
|
135
|
+
return true;
|
|
136
|
+
}
|
|
137
|
+
else {
|
|
138
|
+
return false;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
}; // end fn isAPackageRootDir()
|
|
142
|
+
// Package path should have been loaded-- but 'resolve' likely returns path to:
|
|
143
|
+
// node_modules/@{org}/{pkg}/dist/index.js, not the package root directory
|
|
144
|
+
// We need to traverse upwards until we find the directory containing package.json
|
|
145
|
+
// Or, if we hit node_modules/ and haven't found package.json, throw an error
|
|
146
|
+
let current_path = package_path;
|
|
147
|
+
while (current_path !== "/" && current_path !== "") {
|
|
148
|
+
if (isAPackageRootDir(current_path)) {
|
|
149
|
+
break;
|
|
150
|
+
}
|
|
151
|
+
if (!existsSync(current_path)) {
|
|
152
|
+
throw new Error(`Error resolving package root directory for '@${scope}/${package_name}'`);
|
|
153
|
+
}
|
|
154
|
+
if (this.isdir(current_path)) {
|
|
155
|
+
current_path = normalize(join(current_path, ".."));
|
|
156
|
+
}
|
|
157
|
+
else if (this.isfile(current_path)) {
|
|
158
|
+
current_path = dirname(current_path);
|
|
159
|
+
}
|
|
160
|
+
else {
|
|
161
|
+
throw new Error("Expected current path to be either a directory or a file!");
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
package_path = current_path;
|
|
121
165
|
if (!this.isdir(package_path)) {
|
|
122
166
|
throw new Error(`Expected there to be a directory for package '@${scope}/${package_name}' at path '${package_path}'!`);
|
|
123
167
|
}
|
|
@@ -126,9 +170,12 @@ export class SchemaVaultsTailwindConfigFactory {
|
|
|
126
170
|
console.error(`Failed to resolve path to package '@${scope}/${package_name}':`, e);
|
|
127
171
|
throw new Error(`Failed to resolve path to package: '@${scope}/${package_name}'!`);
|
|
128
172
|
}
|
|
173
|
+
if (this.debug) {
|
|
174
|
+
console.log(`[SchemaVaultsTailwindConfigFactory] Resolved root directory of package '@${scope}/${package_name}' to directory: `, package_path);
|
|
175
|
+
}
|
|
129
176
|
return package_path;
|
|
130
177
|
}
|
|
131
|
-
static
|
|
178
|
+
static defaultPossibleBuildDirectories = [
|
|
132
179
|
"dist",
|
|
133
180
|
"src",
|
|
134
181
|
"build",
|
|
@@ -152,10 +199,13 @@ export class SchemaVaultsTailwindConfigFactory {
|
|
|
152
199
|
const content_length_at_start = content.length;
|
|
153
200
|
if (content_path_input.startsWith(`@${scope}/`)) {
|
|
154
201
|
const package_path = this.resolveOrganizationScopedPackagePath(content_path_input);
|
|
155
|
-
|
|
156
|
-
const buildSubdirPath =
|
|
157
|
-
let hasBuildSubdirectory;
|
|
202
|
+
this.possibleBuildDirectories.forEach((possible_build_dir) => {
|
|
203
|
+
const buildSubdirPath = join(package_path, possible_build_dir);
|
|
204
|
+
let hasBuildSubdirectory = false;
|
|
158
205
|
try {
|
|
206
|
+
if (this.debug) {
|
|
207
|
+
console.log(`[SchemaVaultsTailwindConfigFactory] Checking if build subdirectory exists at path:`, buildSubdirPath);
|
|
208
|
+
}
|
|
159
209
|
hasBuildSubdirectory = this.isdir(buildSubdirPath);
|
|
160
210
|
}
|
|
161
211
|
catch (e) {
|
|
@@ -164,7 +214,12 @@ export class SchemaVaultsTailwindConfigFactory {
|
|
|
164
214
|
throw new Error("Error using isdir() to check if there is a directory at path");
|
|
165
215
|
}
|
|
166
216
|
if (hasBuildSubdirectory) {
|
|
167
|
-
|
|
217
|
+
const tailwindContentSearchPath = `${buildSubdirPath}/**/*.{${this.fileExtensionsToIncludeInTailwindClassNamesSearch.join(",")}}`;
|
|
218
|
+
content.push(tailwindContentSearchPath);
|
|
219
|
+
if (this.debug) {
|
|
220
|
+
console.log(`[SchemaVaultsTailwindConfigFactory] ` +
|
|
221
|
+
`Found build subdirectory. Added TailwindCSS search blob:`, tailwindContentSearchPath);
|
|
222
|
+
}
|
|
168
223
|
}
|
|
169
224
|
});
|
|
170
225
|
}
|
|
@@ -176,9 +231,7 @@ export class SchemaVaultsTailwindConfigFactory {
|
|
|
176
231
|
const content_added_this_iteration = content_length_at_end - content_length_at_start;
|
|
177
232
|
if (content_added_this_iteration < 1 &&
|
|
178
233
|
content_path_input.startsWith(`@${scope}/`)) {
|
|
179
|
-
console.warn(`Did not find any known build
|
|
180
|
-
.map((d) => `"${d}"`)
|
|
181
|
-
.join(", ")})!`);
|
|
234
|
+
console.warn(`Did not find any known build subdirectories (searching subdirectories: ${SchemaVaultsTailwindConfigFactory.prettyPrintItemList(this.possibleBuildDirectories)}) within content path input '${content_path_input}'!`);
|
|
182
235
|
}
|
|
183
236
|
});
|
|
184
237
|
if (content.length === 0) {
|
|
@@ -193,7 +246,9 @@ export class SchemaVaultsTailwindConfigFactory {
|
|
|
193
246
|
darkMode: "class",
|
|
194
247
|
};
|
|
195
248
|
console.assert(config.content.length >= 1, "Failed to load any 'content' search blobs to generate TailwindCSS classes for!");
|
|
196
|
-
|
|
249
|
+
if (!config.content.every((blob) => typeof blob === "string")) {
|
|
250
|
+
throw new TypeError("Received a non-string search blob for the 'content' field of the Tailwind configuration!");
|
|
251
|
+
}
|
|
197
252
|
if (this.debug) {
|
|
198
253
|
console.log("[SchemaVaultsTailwindConfigFactory] Generated TailwindCSS config:\n", config);
|
|
199
254
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TailwindConfigFactory.js","sourceRoot":"","sources":["../src/TailwindConfigFactory.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,eAAe,MAAM,mBAAmB,CAAC,CAAC,wCAAwC;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