@o3r/design 10.0.0-alpha.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/LICENSE +26 -0
- package/README.md +51 -0
- package/builders/generate-css/index.d.ts +8 -0
- package/builders/generate-css/index.d.ts.map +1 -0
- package/builders/generate-css/index.js +116 -0
- package/builders/generate-css/schema.d.ts +32 -0
- package/builders/generate-css/schema.d.ts.map +1 -0
- package/builders/generate-css/schema.js +3 -0
- package/builders/generate-css/schema.json +68 -0
- package/builders/package.json +3 -0
- package/builders.json +10 -0
- package/cli/generate-css-from-design-token.cli.cjs +33 -0
- package/cli/generate-css-from-design-token.cli.cjs.map +1 -0
- package/cli/generate-css-from-design-token.cli.d.cts +3 -0
- package/cli/generate-css-from-design-token.cli.d.cts.map +1 -0
- package/collection.json +24 -0
- package/migration.json +5 -0
- package/package.json +206 -0
- package/schematics/ extract-token/index.d.ts +8 -0
- package/schematics/ extract-token/index.d.ts.map +1 -0
- package/schematics/ extract-token/index.js +90 -0
- package/schematics/ extract-token/schema.d.ts +14 -0
- package/schematics/ extract-token/schema.d.ts.map +1 -0
- package/schematics/ extract-token/schema.js +3 -0
- package/schematics/ extract-token/schema.json +43 -0
- package/schematics/generate-css/index.d.ts +8 -0
- package/schematics/generate-css/index.d.ts.map +1 -0
- package/schematics/generate-css/index.js +48 -0
- package/schematics/generate-css/schema.d.ts +17 -0
- package/schematics/generate-css/schema.d.ts.map +1 -0
- package/schematics/generate-css/schema.js +3 -0
- package/schematics/generate-css/schema.json +43 -0
- package/schematics/ng-add/index.d.ts +7 -0
- package/schematics/ng-add/index.d.ts.map +1 -0
- package/schematics/ng-add/index.js +19 -0
- package/schematics/ng-add/register-generate-css/index.d.ts +2 -0
- package/schematics/ng-add/register-generate-css/index.d.ts.map +1 -0
- package/schematics/ng-add/register-generate-css/index.js +5 -0
- package/schematics/ng-add/register-generate-css/register-task.d.ts +8 -0
- package/schematics/ng-add/register-generate-css/register-task.d.ts.map +1 -0
- package/schematics/ng-add/register-generate-css/register-task.js +60 -0
- package/schematics/ng-add/register-generate-css/templates/design-token.custom.json.template +3 -0
- package/schematics/ng-add/register-generate-css/templates/theme.scss.template +6 -0
- package/schematics/ng-add/schema.d.ts +6 -0
- package/schematics/ng-add/schema.d.ts.map +1 -0
- package/schematics/ng-add/schema.js +3 -0
- package/schematics/ng-add/schema.json +18 -0
- package/src/core/design-token/design-token-specification.interface.d.ts +195 -0
- package/src/core/design-token/design-token-specification.interface.d.ts.map +1 -0
- package/src/core/design-token/design-token-specification.interface.js +39 -0
- package/src/core/design-token/design-token-specification.interface.js.map +1 -0
- package/src/core/design-token/index.d.ts +4 -0
- package/src/core/design-token/index.d.ts.map +1 -0
- package/src/core/design-token/index.js +7 -0
- package/src/core/design-token/index.js.map +1 -0
- package/src/core/design-token/parsers/design-token-parser.interface.d.ts +70 -0
- package/src/core/design-token/parsers/design-token-parser.interface.d.ts.map +1 -0
- package/src/core/design-token/parsers/design-token-parser.interface.js +3 -0
- package/src/core/design-token/parsers/design-token-parser.interface.js.map +1 -0
- package/src/core/design-token/parsers/design-token.parser.d.ts +25 -0
- package/src/core/design-token/parsers/design-token.parser.d.ts.map +1 -0
- package/src/core/design-token/parsers/design-token.parser.js +142 -0
- package/src/core/design-token/parsers/design-token.parser.js.map +1 -0
- package/src/core/design-token/parsers/index.d.ts +3 -0
- package/src/core/design-token/parsers/index.d.ts.map +1 -0
- package/src/core/design-token/parsers/index.js +6 -0
- package/src/core/design-token/parsers/index.js.map +1 -0
- package/src/core/design-token/renderers/css/design-token-definition.renderers.d.ts +47 -0
- package/src/core/design-token/renderers/css/design-token-definition.renderers.d.ts.map +1 -0
- package/src/core/design-token/renderers/css/design-token-definition.renderers.js +53 -0
- package/src/core/design-token/renderers/css/design-token-definition.renderers.js.map +1 -0
- package/src/core/design-token/renderers/css/design-token-updater.renderers.d.ts +24 -0
- package/src/core/design-token/renderers/css/design-token-updater.renderers.d.ts.map +1 -0
- package/src/core/design-token/renderers/css/design-token-updater.renderers.js +29 -0
- package/src/core/design-token/renderers/css/design-token-updater.renderers.js.map +1 -0
- package/src/core/design-token/renderers/css/design-token-value.renderers.d.ts +19 -0
- package/src/core/design-token/renderers/css/design-token-value.renderers.d.ts.map +1 -0
- package/src/core/design-token/renderers/css/design-token-value.renderers.js +29 -0
- package/src/core/design-token/renderers/css/design-token-value.renderers.js.map +1 -0
- package/src/core/design-token/renderers/css/index.d.ts +4 -0
- package/src/core/design-token/renderers/css/index.d.ts.map +1 -0
- package/src/core/design-token/renderers/css/index.js +7 -0
- package/src/core/design-token/renderers/css/index.js.map +1 -0
- package/src/core/design-token/renderers/design-token-style.renderer.d.ts +25 -0
- package/src/core/design-token/renderers/design-token-style.renderer.d.ts.map +1 -0
- package/src/core/design-token/renderers/design-token-style.renderer.js +58 -0
- package/src/core/design-token/renderers/design-token-style.renderer.js.map +1 -0
- package/src/core/design-token/renderers/design-token.renderer.helpers.d.ts +8 -0
- package/src/core/design-token/renderers/design-token.renderer.helpers.d.ts.map +1 -0
- package/src/core/design-token/renderers/design-token.renderer.helpers.js +11 -0
- package/src/core/design-token/renderers/design-token.renderer.helpers.js.map +1 -0
- package/src/core/design-token/renderers/design-token.renderer.interface.d.ts +56 -0
- package/src/core/design-token/renderers/design-token.renderer.interface.d.ts.map +1 -0
- package/src/core/design-token/renderers/design-token.renderer.interface.js +3 -0
- package/src/core/design-token/renderers/design-token.renderer.interface.js.map +1 -0
- package/src/core/design-token/renderers/index.d.ts +7 -0
- package/src/core/design-token/renderers/index.d.ts.map +1 -0
- package/src/core/design-token/renderers/index.js +10 -0
- package/src/core/design-token/renderers/index.js.map +1 -0
- package/src/core/design-token/renderers/metadata/design-token-definition.renderers.d.ts +39 -0
- package/src/core/design-token/renderers/metadata/design-token-definition.renderers.d.ts.map +1 -0
- package/src/core/design-token/renderers/metadata/design-token-definition.renderers.js +41 -0
- package/src/core/design-token/renderers/metadata/design-token-definition.renderers.js.map +1 -0
- package/src/core/design-token/renderers/metadata/design-token-updater.renderers.d.ts +6 -0
- package/src/core/design-token/renderers/metadata/design-token-updater.renderers.d.ts.map +1 -0
- package/src/core/design-token/renderers/metadata/design-token-updater.renderers.js +13 -0
- package/src/core/design-token/renderers/metadata/design-token-updater.renderers.js.map +1 -0
- package/src/core/design-token/renderers/metadata/design-token-value.renderers.d.ts +18 -0
- package/src/core/design-token/renderers/metadata/design-token-value.renderers.d.ts.map +1 -0
- package/src/core/design-token/renderers/metadata/design-token-value.renderers.js +27 -0
- package/src/core/design-token/renderers/metadata/design-token-value.renderers.js.map +1 -0
- package/src/core/design-token/renderers/metadata/index.d.ts +4 -0
- package/src/core/design-token/renderers/metadata/index.d.ts.map +1 -0
- package/src/core/design-token/renderers/metadata/index.js +7 -0
- package/src/core/design-token/renderers/metadata/index.js.map +1 -0
- package/src/core/design-token/renderers/sass/design-token-definition.renderers.d.ts +22 -0
- package/src/core/design-token/renderers/sass/design-token-definition.renderers.d.ts.map +1 -0
- package/src/core/design-token/renderers/sass/design-token-definition.renderers.js +27 -0
- package/src/core/design-token/renderers/sass/design-token-definition.renderers.js.map +1 -0
- package/src/core/design-token/renderers/sass/index.d.ts +2 -0
- package/src/core/design-token/renderers/sass/index.d.ts.map +1 -0
- package/src/core/design-token/renderers/sass/index.js +5 -0
- package/src/core/design-token/renderers/sass/index.js.map +1 -0
- package/src/core/index.d.ts +2 -0
- package/src/core/index.d.ts.map +1 -0
- package/src/core/index.js +5 -0
- package/src/core/index.js.map +1 -0
- package/src/public_api.d.ts +2 -0
- package/src/public_api.d.ts.map +1 -0
- package/src/public_api.js +5 -0
- package/src/public_api.js.map +1 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
Copyright Amadeus SAS
|
|
2
|
+
|
|
3
|
+
Redistribution and use in source and binary forms, with or without modification,
|
|
4
|
+
are permitted provided that the following conditions are met:
|
|
5
|
+
|
|
6
|
+
1. Redistributions of source code must retain the above copyright notice, this
|
|
7
|
+
list of conditions and the following disclaimer.
|
|
8
|
+
|
|
9
|
+
2. Redistributions in binary form must reproduce the above copyright notice,
|
|
10
|
+
this list of conditions and the following disclaimer in the documentation and/or
|
|
11
|
+
other materials provided with the distribution.
|
|
12
|
+
|
|
13
|
+
3. Neither the name of the copyright holder nor the names of its contributors
|
|
14
|
+
may be used to endorse or promote products derived from this software without
|
|
15
|
+
specific prior written permission.
|
|
16
|
+
|
|
17
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
|
|
18
|
+
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
|
19
|
+
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
20
|
+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
|
|
21
|
+
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
|
22
|
+
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
|
|
23
|
+
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
|
24
|
+
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
25
|
+
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
|
26
|
+
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
package/README.md
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
<h1 align="center">Otter Design</h1>
|
|
2
|
+
<p align="center">
|
|
3
|
+
<img src="https://raw.githubusercontent.com/AmadeusITGroup/otter/main/assets/logo/otter.png" alt="Super cute Otter!" width="40%"/>
|
|
4
|
+
</p>
|
|
5
|
+
|
|
6
|
+
This package is an [Otter Framework Module](https://github.com/AmadeusITGroup/otter/tree/main/docs/core/MODULE.md).
|
|
7
|
+
<br />
|
|
8
|
+
<br />
|
|
9
|
+
|
|
10
|
+
## Description
|
|
11
|
+
|
|
12
|
+
Set of tools to generate CSS themes and [Metadata](https://github.com/AmadeusITGroup/otter/tree/main/docs/cms-adapters/CMS_ADAPTERS.md) based on the [Design Token Specifications](https://design-tokens.github.io/community-group/format/).
|
|
13
|
+
|
|
14
|
+
## How to install
|
|
15
|
+
|
|
16
|
+
```shell
|
|
17
|
+
ng add @o3r/design
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## Generators
|
|
21
|
+
|
|
22
|
+
Otter Design module provides a set of code generators based on [angular schematics](https://angular.io/guide/schematics).
|
|
23
|
+
|
|
24
|
+
| Schematics | Description | How to use |
|
|
25
|
+
| ------------ | ------------------------------------------------------- | -------------------- |
|
|
26
|
+
| add | Include Otter design module in a library / application. | `ng add @o3r/design` |
|
|
27
|
+
| generate-css | Generate CSS Theme based on Design Token Files | `ng g generate-css` |
|
|
28
|
+
|
|
29
|
+
## Builders
|
|
30
|
+
|
|
31
|
+
Otter Design module provides a set of builders based on [angular builders](https://angular.io/guide/cli-builder).
|
|
32
|
+
|
|
33
|
+
### generate-css
|
|
34
|
+
|
|
35
|
+
The `generate-css` builder can generate CSS and CMS Metadata based on given Design Token Json files.
|
|
36
|
+
The following configurations are available:
|
|
37
|
+
|
|
38
|
+
| Options | Default Value | Description |
|
|
39
|
+
| --------------------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
|
|
40
|
+
| **designTokenFilePatterns** | [] *Require* | Path patterns to the Design Token JSON files. <br /> Files in dependencies are supported and resolved with Node Resolver. |
|
|
41
|
+
| **output** | *null* | Output file where the CSS will be generated. <br /> The path specified in `o3rTargetFile` will be ignore if this option is specified |
|
|
42
|
+
| **defaultStyleFile** | src/theme.scss | File path to generate the variable if not determined by the specifications |
|
|
43
|
+
| **metadataOutput** | *null* | Path to generate the metadata for the CMS. <br /> The metadata will be generated only if the file path is specified. |
|
|
44
|
+
| **rootPath** | *null* | Root path of files where the CSS will be generated. |
|
|
45
|
+
| **failOnDuplicate** | false | Determine if the process should stop in case of Token duplication. |
|
|
46
|
+
| **prefix** | *null* | Prefix to append to generated variables. |
|
|
47
|
+
| **watch** | false | Enable Watch mode. |
|
|
48
|
+
|
|
49
|
+
## Technical documentation
|
|
50
|
+
|
|
51
|
+
Documentation providing explanations on the use and customization of the `Design Token` parser and renderers is available in the [technical documentation](https://github.com/AmadeusITGroup/otter/blob/main/docs/design/TECHNICAL_DOCUMENTATION.md).
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { GenerateCssSchematicsSchema } from './schema';
|
|
2
|
+
/**
|
|
3
|
+
* Generate CSS from Design Token files
|
|
4
|
+
* @param options
|
|
5
|
+
*/
|
|
6
|
+
declare const _default: import("@angular-devkit/architect/src/internal").Builder<GenerateCssSchematicsSchema & import("@angular-devkit/core").JsonObject>;
|
|
7
|
+
export default _default;
|
|
8
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/generate-css/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,UAAU,CAAC;AAe5D;;;GAGG;;AACH,wBA4GG"}
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const architect_1 = require("@angular-devkit/architect");
|
|
4
|
+
const public_api_1 = require("../../src/public_api");
|
|
5
|
+
const node_path_1 = require("node:path");
|
|
6
|
+
const globby = require("globby");
|
|
7
|
+
/**
|
|
8
|
+
* Generate CSS from Design Token files
|
|
9
|
+
* @param options
|
|
10
|
+
*/
|
|
11
|
+
exports.default = (0, architect_1.createBuilder)(async (options, context) => {
|
|
12
|
+
const designTokenFilePatterns = Array.isArray(options.designTokenFilePatterns) ? options.designTokenFilePatterns : [options.designTokenFilePatterns];
|
|
13
|
+
const determineCssFileToUpdate = options.output ? () => (0, node_path_1.resolve)(context.workspaceRoot, options.output) :
|
|
14
|
+
(token) => {
|
|
15
|
+
if (token.extensions.o3rTargetFile) {
|
|
16
|
+
return token.context?.basePath && !options.rootPath ?
|
|
17
|
+
(0, node_path_1.resolve)(token.context.basePath, token.extensions.o3rTargetFile) :
|
|
18
|
+
(0, node_path_1.resolve)(context.workspaceRoot, options.rootPath || '', token.extensions.o3rTargetFile);
|
|
19
|
+
}
|
|
20
|
+
return (0, node_path_1.resolve)(context.workspaceRoot, options.defaultStyleFile);
|
|
21
|
+
};
|
|
22
|
+
const tokenVariableNameRenderer = options.prefix ? (variable) => options.prefix + variable.getKey() : undefined;
|
|
23
|
+
const sassRenderer = (0, public_api_1.getSassTokenDefinitionRenderer)({ tokenVariableNameRenderer: (v) => (options?.prefixPrivate || '') + (0, public_api_1.tokenVariableNameSassRenderer)(v) });
|
|
24
|
+
const renderDesignTokenOptionsCss = {
|
|
25
|
+
determineFileToUpdate: determineCssFileToUpdate,
|
|
26
|
+
tokenDefinitionRenderer: (0, public_api_1.getCssTokenDefinitionRenderer)({
|
|
27
|
+
tokenVariableNameRenderer: options.prefix ? (variable) => options.prefix + variable.getKey() : undefined,
|
|
28
|
+
privateDefinitionRenderer: options.renderPrivateVariableTo === 'sass' ? sassRenderer : undefined
|
|
29
|
+
}),
|
|
30
|
+
logger: context.logger
|
|
31
|
+
};
|
|
32
|
+
const renderDesignTokenOptionsMetadata = {
|
|
33
|
+
determineFileToUpdate: () => (0, node_path_1.resolve)(context.workspaceRoot, options.metadataOutput),
|
|
34
|
+
styleContentUpdater: (0, public_api_1.getMetadataStyleContentUpdater)(),
|
|
35
|
+
tokenDefinitionRenderer: (0, public_api_1.getMetadataTokenDefinitionRenderer)({ tokenVariableNameRenderer }),
|
|
36
|
+
logger: context.logger
|
|
37
|
+
};
|
|
38
|
+
const execute = async (renderDesignTokenOptions) => {
|
|
39
|
+
const files = (await globby(designTokenFilePatterns, { cwd: context.workspaceRoot, absolute: true }));
|
|
40
|
+
const inDependencies = designTokenFilePatterns
|
|
41
|
+
.filter((pathName) => !pathName.startsWith('.') && !pathName.startsWith('*') && !pathName.startsWith('/'))
|
|
42
|
+
.map((pathName) => {
|
|
43
|
+
try {
|
|
44
|
+
return require.resolve(pathName);
|
|
45
|
+
}
|
|
46
|
+
catch {
|
|
47
|
+
return undefined;
|
|
48
|
+
}
|
|
49
|
+
})
|
|
50
|
+
.filter((pathName) => !!pathName);
|
|
51
|
+
files.push(...inDependencies);
|
|
52
|
+
try {
|
|
53
|
+
const duplicatedToken = [];
|
|
54
|
+
const tokens = (await Promise.all(files.map(async (file) => ({ file, parsed: await (0, public_api_1.parseDesignTokenFile)(file) }))))
|
|
55
|
+
.reduce((acc, { file, parsed }) => {
|
|
56
|
+
parsed.forEach((variable, key) => {
|
|
57
|
+
if (acc.has(key)) {
|
|
58
|
+
context.logger[options.failOnDuplicate ? 'error' : 'warn'](`A duplication of the variable ${key} is found in ${file}`);
|
|
59
|
+
duplicatedToken.push(variable);
|
|
60
|
+
}
|
|
61
|
+
acc.set(key, variable);
|
|
62
|
+
});
|
|
63
|
+
return acc;
|
|
64
|
+
}, new Map());
|
|
65
|
+
if (options.failOnDuplicate && duplicatedToken.length > 0) {
|
|
66
|
+
throw new Error(`Found ${duplicatedToken.length} duplicated Design Token keys`);
|
|
67
|
+
}
|
|
68
|
+
await (0, public_api_1.renderDesignTokens)(tokens, renderDesignTokenOptions);
|
|
69
|
+
return { success: true };
|
|
70
|
+
}
|
|
71
|
+
catch (err) {
|
|
72
|
+
return { success: false, error: `${err}` };
|
|
73
|
+
}
|
|
74
|
+
};
|
|
75
|
+
const executeMultiRenderer = async () => {
|
|
76
|
+
return (await Promise.allSettled([
|
|
77
|
+
execute(renderDesignTokenOptionsCss),
|
|
78
|
+
...(options.metadataOutput ? [execute(renderDesignTokenOptionsMetadata)] : [])
|
|
79
|
+
])).reduce((acc, res) => {
|
|
80
|
+
if (res.status === 'fulfilled') {
|
|
81
|
+
acc.success &&= res.value.success;
|
|
82
|
+
if (!res.value.error) {
|
|
83
|
+
acc.error ||= '';
|
|
84
|
+
acc.error += '\n' + res.value.error;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
else {
|
|
88
|
+
acc.success = false;
|
|
89
|
+
if (res.reason) {
|
|
90
|
+
acc.error ||= '';
|
|
91
|
+
acc.error += '\n' + res.reason;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
return acc;
|
|
95
|
+
}, { success: true });
|
|
96
|
+
};
|
|
97
|
+
if (!options.watch) {
|
|
98
|
+
return await executeMultiRenderer();
|
|
99
|
+
}
|
|
100
|
+
else {
|
|
101
|
+
try {
|
|
102
|
+
await Promise.resolve().then(() => require('chokidar')).then((chokidar) => chokidar.watch(designTokenFilePatterns.map((p) => (0, node_path_1.resolve)(context.workspaceRoot, p))))
|
|
103
|
+
.then((watcher) => watcher.on('all', async () => {
|
|
104
|
+
const res = await executeMultiRenderer();
|
|
105
|
+
if (res.error) {
|
|
106
|
+
context.logger.error(res.error);
|
|
107
|
+
}
|
|
108
|
+
}));
|
|
109
|
+
return { success: true };
|
|
110
|
+
}
|
|
111
|
+
catch (err) {
|
|
112
|
+
return { success: false, error: `${err}` };
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
});
|
|
116
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import type { SchematicOptionObject } from '@o3r/schematics';
|
|
2
|
+
export interface GenerateCssSchematicsSchema extends SchematicOptionObject {
|
|
3
|
+
/** Path patterns to the Design Token JSON files */
|
|
4
|
+
designTokenFilePatterns: string | string[];
|
|
5
|
+
/**
|
|
6
|
+
* Path to generate the metadata for CMS
|
|
7
|
+
* The Metadata will be generated only if the file path is specified
|
|
8
|
+
*/
|
|
9
|
+
metadataOutput?: string;
|
|
10
|
+
/**
|
|
11
|
+
* Output file where generate the CSS
|
|
12
|
+
*
|
|
13
|
+
* If specified, all the generated CSS variable will be generated in the given file.
|
|
14
|
+
* Otherwise, the output file will be determined based on the Variable parameters
|
|
15
|
+
*/
|
|
16
|
+
output?: string;
|
|
17
|
+
/** File path to generate the variable if not determined by the specification */
|
|
18
|
+
defaultStyleFile: string;
|
|
19
|
+
/** Enable Watch mode */
|
|
20
|
+
watch?: boolean;
|
|
21
|
+
/** Root path of files where the CSS will be generated */
|
|
22
|
+
rootPath?: string;
|
|
23
|
+
/** Determine if the process should stop in case of Token duplication */
|
|
24
|
+
failOnDuplicate?: boolean;
|
|
25
|
+
/** Prefix to happen to generated variables */
|
|
26
|
+
prefix?: string;
|
|
27
|
+
/** Generate the Private Variable to the given language */
|
|
28
|
+
renderPrivateVariableTo?: 'sass';
|
|
29
|
+
/** Prefix to happen to generated Sass variables if generated */
|
|
30
|
+
prefixPrivate?: string;
|
|
31
|
+
}
|
|
32
|
+
//# sourceMappingURL=schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../builders/generate-css/schema.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAC;AAE7D,MAAM,WAAW,2BAA4B,SAAQ,qBAAqB;IACxE,mDAAmD;IACnD,uBAAuB,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAE3C;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;;;;OAKG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,gFAAgF;IAChF,gBAAgB,EAAE,MAAM,CAAC;IAEzB,wBAAwB;IACxB,KAAK,CAAC,EAAE,OAAO,CAAC;IAEhB,yDAAyD;IACzD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,wEAAwE;IACxE,eAAe,CAAC,EAAE,OAAO,CAAC;IAE1B,8CAA8C;IAC9C,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,0DAA0D;IAC1D,uBAAuB,CAAC,EAAE,MAAM,CAAC;IAEjC,gEAAgE;IAChE,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB"}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema",
|
|
3
|
+
"$id": "ngAddSchematicsSchema",
|
|
4
|
+
"title": "Add Otter Design",
|
|
5
|
+
"description": "ngAdd Otter Design",
|
|
6
|
+
"properties": {
|
|
7
|
+
"designTokenFilePatterns": {
|
|
8
|
+
"description": "Path patterns to the Design Token JSON files (it supports Node dependency paths).",
|
|
9
|
+
"oneOf": [
|
|
10
|
+
{
|
|
11
|
+
"type": "string"
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"type": "array",
|
|
15
|
+
"items": {
|
|
16
|
+
"type": "string"
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
]
|
|
20
|
+
},
|
|
21
|
+
"output": {
|
|
22
|
+
"type": "string",
|
|
23
|
+
"description": "Path to generate the metadata for CMS. The Metadata will be generated only if the file path is specified"
|
|
24
|
+
},
|
|
25
|
+
"defaultStyleFile": {
|
|
26
|
+
"type": "string",
|
|
27
|
+
"default": "src/theme.scss",
|
|
28
|
+
"description": "File path to generate the variable if not determined by the specification"
|
|
29
|
+
},
|
|
30
|
+
"metadataOutput": {
|
|
31
|
+
"type": "string",
|
|
32
|
+
"description": "If specified, all the generated CSS variable will be generated in the given file. Otherwise, the output file will be determined based on the Variable parameters."
|
|
33
|
+
},
|
|
34
|
+
"rootPath": {
|
|
35
|
+
"type": "string",
|
|
36
|
+
"description": "Root path used to determine the CSS file to edit if specified by the o3rTargetFile token extension. It will default to the Design Token file folder."
|
|
37
|
+
},
|
|
38
|
+
"watch": {
|
|
39
|
+
"type": "boolean",
|
|
40
|
+
"default": false,
|
|
41
|
+
"description": "Enable Watch mode"
|
|
42
|
+
},
|
|
43
|
+
"failOnDuplicate": {
|
|
44
|
+
"type": "boolean",
|
|
45
|
+
"default": false,
|
|
46
|
+
"description": "Determine if the process should stop in case of Token duplication"
|
|
47
|
+
},
|
|
48
|
+
"prefix": {
|
|
49
|
+
"type": "string",
|
|
50
|
+
"description": "Prefix to happen to generated variables"
|
|
51
|
+
},
|
|
52
|
+
"prefixPrivate": {
|
|
53
|
+
"type": "string",
|
|
54
|
+
"description": "Prefix to happen to generated Sass variables if generated"
|
|
55
|
+
},
|
|
56
|
+
"renderPrivateVariableTo": {
|
|
57
|
+
"type": "string",
|
|
58
|
+
"enum": [
|
|
59
|
+
"sass"
|
|
60
|
+
],
|
|
61
|
+
"description": "Generate the Private Variable to the given language (the variable is not generated if not specified)"
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
"additionalProperties": true,
|
|
65
|
+
"required": [
|
|
66
|
+
"designTokenFilePatterns"
|
|
67
|
+
]
|
|
68
|
+
}
|
package/builders.json
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/angular/angular-cli/master/packages/angular_devkit/architect/src/builders-schema.json",
|
|
3
|
+
"builders": {
|
|
4
|
+
"generate-css": {
|
|
5
|
+
"implementation": "./builders/generate-css/",
|
|
6
|
+
"schema": "./builders/generate-css/schema.json",
|
|
7
|
+
"description": "Generate CSS from Design Token files"
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
const node_path_1 = require("node:path");
|
|
5
|
+
const node_fs_1 = require("node:fs");
|
|
6
|
+
const design_1 = require("@o3r/design");
|
|
7
|
+
const minimist = require("minimist");
|
|
8
|
+
const args = minimist(process.argv.splice(2));
|
|
9
|
+
void (async () => {
|
|
10
|
+
const renderDesignTokenOptions = {};
|
|
11
|
+
const output = args.o || args.output;
|
|
12
|
+
if (output) {
|
|
13
|
+
renderDesignTokenOptions.determineFileToUpdate = () => (0, node_path_1.resolve)(process.cwd(), output);
|
|
14
|
+
}
|
|
15
|
+
const tokens = (await Promise.all(args._
|
|
16
|
+
.map((file) => (0, node_path_1.isAbsolute)(file) ? (0, node_path_1.normalize)(file) : (0, node_path_1.resolve)(process.cwd(), file))
|
|
17
|
+
.filter((file) => {
|
|
18
|
+
const res = (0, node_fs_1.existsSync)(file);
|
|
19
|
+
if (!res) {
|
|
20
|
+
throw new Error(`The file ${file} does not exist, the process will stop`);
|
|
21
|
+
}
|
|
22
|
+
return res;
|
|
23
|
+
})
|
|
24
|
+
.map(async (file) => ({ file, parsed: await (0, design_1.parseDesignTokenFile)(file) })))).reduce((acc, { file, parsed }) => {
|
|
25
|
+
parsed.forEach((variable, key) => {
|
|
26
|
+
acc.set(key, variable);
|
|
27
|
+
console.warn(`A duplication of the variable ${key} is found in ${file}`);
|
|
28
|
+
});
|
|
29
|
+
return acc;
|
|
30
|
+
}, new Map());
|
|
31
|
+
await (0, design_1.renderDesignTokens)(tokens, renderDesignTokenOptions);
|
|
32
|
+
})();
|
|
33
|
+
//# sourceMappingURL=generate-css-from-design-token.cli.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"generate-css-from-design-token.cli.cjs","sourceRoot":"","sources":["../../cli/generate-css-from-design-token.cli.cts"],"names":[],"mappings":";;;AAEA,yCAA2D;AAC3D,qCAAqC;AACrC,wCAAuE;AAEvE,qCAAqC;AAErC,MAAM,IAAI,GAAG,QAAQ,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;AAE9C,KAAK,CAAC,KAAK,IAAI,EAAE;IACf,MAAM,wBAAwB,GAA+B,EAAE,CAAC;IAEhE,MAAM,MAAM,GAAG,IAAI,CAAC,CAAC,IAAI,IAAI,CAAC,MAAM,CAAC;IACrC,IAAI,MAAM,EAAE;QACV,wBAAwB,CAAC,qBAAqB,GAAG,GAAG,EAAE,CAAC,IAAA,mBAAO,EAAC,OAAO,CAAC,GAAG,EAAE,EAAE,MAAM,CAAC,CAAC;KACvF;IAED,MAAM,MAAM,GAAG,CAAC,MAAM,OAAO,CAAC,GAAG,CAC/B,IAAI,CAAC,CAAC;SACH,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAA,sBAAU,EAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAA,qBAAS,EAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAA,mBAAO,EAAC,OAAO,CAAC,GAAG,EAAE,EAAE,IAAI,CAAC,CAAC;SAChF,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE;QACf,MAAM,GAAG,GAAG,IAAA,oBAAU,EAAC,IAAI,CAAC,CAAC;QAC7B,IAAI,CAAC,GAAG,EAAE;YACR,MAAM,IAAI,KAAK,CAAC,YAAY,IAAI,wCAAwC,CAAC,CAAC;SAC3E;QACD,OAAO,GAAG,CAAC;IACb,CAAC,CAAC;SACD,GAAG,CAAC,KAAK,EAAE,IAAI,EAAE,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,IAAA,6BAAoB,EAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAC7E,CAAC,CAAC,MAAM,CAAyB,CAAC,GAAG,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE;QAC1D,MAAM,CAAC,OAAO,CAAC,CAAC,QAAQ,EAAE,GAAG,EAAE,EAAE;YAC/B,GAAG,CAAC,GAAG,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;YACvB,OAAO,CAAC,IAAI,CAAC,iCAAiC,GAAG,gBAAgB,IAAI,EAAE,CAAC,CAAC;QAC3E,CAAC,CAAC,CAAC;QACH,OAAO,GAAG,CAAC;IACb,CAAC,EAAE,IAAI,GAAG,EAAE,CAAC,CAAC;IAEd,MAAM,IAAA,2BAAkB,EAAC,MAAM,EAAE,wBAAwB,CAAC,CAAC;AAC7D,CAAC,CAAC,EAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"generate-css-from-design-token.cli.d.cts","sourceRoot":"","sources":["../../cli/generate-css-from-design-token.cli.cts"],"names":[],"mappings":""}
|
package/collection.json
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/angular/angular-cli/master/packages/angular_devkit/schematics/collection-schema.json",
|
|
3
|
+
"schematics": {
|
|
4
|
+
"ng-add": {
|
|
5
|
+
"description": "Add Otter Design to the project.",
|
|
6
|
+
"factory": "./schematics/ng-add/index#ngAdd",
|
|
7
|
+
"schema": "./schematics/ng-add/schema.json",
|
|
8
|
+
"aliases": [
|
|
9
|
+
"install",
|
|
10
|
+
"i"
|
|
11
|
+
]
|
|
12
|
+
},
|
|
13
|
+
"generate-css": {
|
|
14
|
+
"description": "Generate CSS from Design Token files",
|
|
15
|
+
"factory": "./schematics/generate-css/index#generateCss",
|
|
16
|
+
"schema": "./schematics/generate-css/schema.json"
|
|
17
|
+
},
|
|
18
|
+
"extract-token": {
|
|
19
|
+
"description": "Extract the Design Token specification from SCSS",
|
|
20
|
+
"factory": "./schematics/extract-token/index#extractToken",
|
|
21
|
+
"schema": "./schematics/extract-token/schema.json"
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
package/migration.json
ADDED
package/package.json
ADDED
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@o3r/design",
|
|
3
|
+
"version": "10.0.0-alpha.1",
|
|
4
|
+
"description": "A design framework to generate theme on an Otter application based on Design Tokens.",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"design",
|
|
7
|
+
"otter",
|
|
8
|
+
"otter-module"
|
|
9
|
+
],
|
|
10
|
+
"scripts": {
|
|
11
|
+
"nx": "nx",
|
|
12
|
+
"ng": "yarn nx",
|
|
13
|
+
"test": "yarn nx test styling",
|
|
14
|
+
"copy:templates": "yarn cpy 'schematics/**/templates/**/*' dist/schematics",
|
|
15
|
+
"copy:schemas": "yarn cpy 'schemas/**/*' dist/schemas",
|
|
16
|
+
"prepare:build:builders": "yarn cpy 'builders/**/*.json' dist/builders && yarn cpy '{builders,collection,migration}.json' dist && yarn cpy 'schematics/**/*.json' dist/schematics && yarn copy:templates",
|
|
17
|
+
"prepare:publish": "prepare-publish ./dist",
|
|
18
|
+
"build:source": "tsc -b tsconfig.build.json && yarn cpy package.json dist/",
|
|
19
|
+
"build:builders": "tsc -b tsconfig.builders.json --pretty && yarn copy:templates && generate-cjs-manifest",
|
|
20
|
+
"build": "yarn nx build styling",
|
|
21
|
+
"postbuild": "yarn copy:schemas && patch-package-json-main"
|
|
22
|
+
},
|
|
23
|
+
"exports": {
|
|
24
|
+
"./package.json": {
|
|
25
|
+
"default": "./package.json"
|
|
26
|
+
},
|
|
27
|
+
"./schemas/*.json": {
|
|
28
|
+
"default": "./schemas/*.json"
|
|
29
|
+
},
|
|
30
|
+
".": {
|
|
31
|
+
"es2020": "./src/public_api.js",
|
|
32
|
+
"default": "./src/public_api.js",
|
|
33
|
+
"typings": "./src/public_api.d.ts",
|
|
34
|
+
"node": "./src/public_api.js",
|
|
35
|
+
"require": "./src/public_api.js"
|
|
36
|
+
},
|
|
37
|
+
"./cli/*": {
|
|
38
|
+
"default": "./cli/*"
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
"bin": {
|
|
42
|
+
"o3r-css-from-design-token": "cli/generate-css-from-design-token.cli.cjs"
|
|
43
|
+
},
|
|
44
|
+
"dependencies": {
|
|
45
|
+
"minimist": "^1.2.6",
|
|
46
|
+
"tslib": "^2.5.3"
|
|
47
|
+
},
|
|
48
|
+
"peerDependencies": {
|
|
49
|
+
"@o3r/core": "^10.0.0-alpha.1",
|
|
50
|
+
"@o3r/schematics": "^10.0.0-alpha.1",
|
|
51
|
+
"@o3r/styling": "^10.0.0-alpha.1",
|
|
52
|
+
"chokidar": "^3.5.2",
|
|
53
|
+
"globby": "^11.1.0",
|
|
54
|
+
"minimatch": "~9.0.3",
|
|
55
|
+
"sass": "~1.69.0"
|
|
56
|
+
},
|
|
57
|
+
"peerDependenciesMeta": {
|
|
58
|
+
"@o3r/core": {
|
|
59
|
+
"optional": true
|
|
60
|
+
},
|
|
61
|
+
"@o3r/schematics": {
|
|
62
|
+
"optional": true
|
|
63
|
+
},
|
|
64
|
+
"@o3r/styling": {
|
|
65
|
+
"optional": true
|
|
66
|
+
},
|
|
67
|
+
"chokidar": {
|
|
68
|
+
"optional": true
|
|
69
|
+
},
|
|
70
|
+
"globby": {
|
|
71
|
+
"optional": true
|
|
72
|
+
},
|
|
73
|
+
"sass": {
|
|
74
|
+
"optional": true
|
|
75
|
+
}
|
|
76
|
+
},
|
|
77
|
+
"devDependencies": {
|
|
78
|
+
"@angular-devkit/architect": "~0.1700.3",
|
|
79
|
+
"@angular-devkit/build-angular": "~17.0.3",
|
|
80
|
+
"@angular-devkit/core": "~17.0.3",
|
|
81
|
+
"@angular-devkit/schematics": "~17.0.3",
|
|
82
|
+
"@angular-eslint/eslint-plugin": "~17.1.0",
|
|
83
|
+
"@angular/cli": "~17.0.3",
|
|
84
|
+
"@angular/common": "~17.0.4",
|
|
85
|
+
"@angular/compiler": "~17.0.4",
|
|
86
|
+
"@angular/compiler-cli": "~17.0.4",
|
|
87
|
+
"@angular/core": "~17.0.4",
|
|
88
|
+
"@angular/platform-browser": "~17.0.4",
|
|
89
|
+
"@angular/platform-browser-dynamic": "~17.0.4",
|
|
90
|
+
"@babel/core": "~7.23.0",
|
|
91
|
+
"@babel/preset-typescript": "~7.23.0",
|
|
92
|
+
"@compodoc/compodoc": "^1.1.19",
|
|
93
|
+
"@nx/eslint": "~17.1.1",
|
|
94
|
+
"@nx/eslint-plugin": "~17.1.1",
|
|
95
|
+
"@nx/jest": "~17.1.1",
|
|
96
|
+
"@nx/js": "~17.1.1",
|
|
97
|
+
"@o3r/build-helpers": "^10.0.0-alpha.1",
|
|
98
|
+
"@o3r/core": "^10.0.0-alpha.1",
|
|
99
|
+
"@o3r/eslint-plugin": "^10.0.0-alpha.1",
|
|
100
|
+
"@o3r/schematics": "^10.0.0-alpha.1",
|
|
101
|
+
"@o3r/styling": "^10.0.0-alpha.1",
|
|
102
|
+
"@o3r/test-helpers": "^10.0.0-alpha.1",
|
|
103
|
+
"@schematics/angular": "~17.0.3",
|
|
104
|
+
"@types/jest": "~29.5.2",
|
|
105
|
+
"@types/minimist": "^1.2.2",
|
|
106
|
+
"@types/node": "^20.0.0",
|
|
107
|
+
"@types/semver": "^7.3.13",
|
|
108
|
+
"@typescript-eslint/eslint-plugin": "6.11.0",
|
|
109
|
+
"@typescript-eslint/parser": "^6.11.0",
|
|
110
|
+
"chokidar": "^3.5.2",
|
|
111
|
+
"cpy-cli": "^5.0.0",
|
|
112
|
+
"eslint": "^8.42.0",
|
|
113
|
+
"eslint-import-resolver-node": "^0.3.4",
|
|
114
|
+
"eslint-plugin-jest": "~27.6.0",
|
|
115
|
+
"eslint-plugin-jsdoc": "~48.0.0",
|
|
116
|
+
"eslint-plugin-prefer-arrow": "~1.2.3",
|
|
117
|
+
"eslint-plugin-unicorn": "^50.0.0",
|
|
118
|
+
"globby": "^11.1.0",
|
|
119
|
+
"jest": "~29.7.0",
|
|
120
|
+
"jest-junit": "~16.0.0",
|
|
121
|
+
"jsonc-eslint-parser": "~2.4.0",
|
|
122
|
+
"jsonschema": "~1.4.1",
|
|
123
|
+
"minimatch": "~9.0.3",
|
|
124
|
+
"nx": "~17.1.1",
|
|
125
|
+
"rxjs": "^7.8.1",
|
|
126
|
+
"sass": "~1.69.5",
|
|
127
|
+
"ts-jest": "~29.1.1",
|
|
128
|
+
"ts-node": "~10.9.1",
|
|
129
|
+
"type-fest": "^4.3.1",
|
|
130
|
+
"typescript": "~5.2.2",
|
|
131
|
+
"zone.js": "~0.14.2"
|
|
132
|
+
},
|
|
133
|
+
"engines": {
|
|
134
|
+
"node": ">=18.0.0"
|
|
135
|
+
},
|
|
136
|
+
"builders": "./builders.json",
|
|
137
|
+
"schematics": "./collection.json",
|
|
138
|
+
"ng-update": {
|
|
139
|
+
"migrations": "./migration.json"
|
|
140
|
+
},
|
|
141
|
+
"contributors": [
|
|
142
|
+
{
|
|
143
|
+
"name": "Yannick Adam",
|
|
144
|
+
"url": "https://github.com/yannickadam",
|
|
145
|
+
"email": "yannickadam@users.noreply.github.com"
|
|
146
|
+
},
|
|
147
|
+
{
|
|
148
|
+
"name": "Kilian Panot",
|
|
149
|
+
"url": "https://github.com/kpanot",
|
|
150
|
+
"email": "kpanot@users.noreply.github.com"
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
"name": "Jeremy Bourgeois",
|
|
154
|
+
"url": "https://github.com/jbourgeois-1A",
|
|
155
|
+
"email": "jbourgeois-1A@users.noreply.github.com"
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
"name": "Pierre Henri Ginoux",
|
|
159
|
+
"url": "https://github.com/pginoux-1A",
|
|
160
|
+
"email": "pginoux-1A@users.noreply.github.com"
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
"name": "Mircea Vasile Rednic",
|
|
164
|
+
"url": "https://github.com/mrednic-1A",
|
|
165
|
+
"email": "mrednic-1A@users.noreply.github.com"
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
"name": "Stephane Dalle",
|
|
169
|
+
"email": "sdalle-1A@users.noreply.github.com"
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
"name": "Nicolas Hoffmann",
|
|
173
|
+
"url": "https://github.com/nhoffmann-1A",
|
|
174
|
+
"email": "nhoffmann-1A@users.noreply.github.com"
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
"name": "Victor Scaiceanu",
|
|
178
|
+
"url": "https://github.com/vscaiceanu-1a",
|
|
179
|
+
"email": "vscaiceanu-1A@users.noreply.github.com"
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
"name": "Florian Paul",
|
|
183
|
+
"url": "https://github.com/fpaul-1A",
|
|
184
|
+
"email": "fpaul-1A@users.noreply.github.com"
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
"name": "Corinne Paulve",
|
|
188
|
+
"url": "https://github.com/cpaulve-1A",
|
|
189
|
+
"email": "cpaulve-1A@users.noreply.github.com"
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
"name": "Matthieu Crouzet",
|
|
193
|
+
"url": "https://github.com/matthieu-crouzet",
|
|
194
|
+
"email": "matthieu-crouzet@users.noreply.github.com"
|
|
195
|
+
},
|
|
196
|
+
{
|
|
197
|
+
"name": "Salome Do",
|
|
198
|
+
"url": "https://github.com/sdo-1A",
|
|
199
|
+
"email": "sdo-1A@users.noreply.github.com"
|
|
200
|
+
}
|
|
201
|
+
],
|
|
202
|
+
"bugs": "https://github.com/AmadeusITGroup/otter/issues",
|
|
203
|
+
"repository": "https://github.com/AmadeusITGroup/otter",
|
|
204
|
+
"license": "BSD-3-Clause",
|
|
205
|
+
"homepage": "https://amadeusitgroup.github.io/otter/"
|
|
206
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { Rule } from '@angular-devkit/schematics';
|
|
2
|
+
import type { ExtractTokenSchematicsSchema } from './schema';
|
|
3
|
+
/**
|
|
4
|
+
* Extract the token from o3r mixin sass file
|
|
5
|
+
* @param options
|
|
6
|
+
*/
|
|
7
|
+
export declare function extractToken(options: ExtractTokenSchematicsSchema): Rule;
|
|
8
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../schematics/ extract-token/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,4BAA4B,CAAC;AACvD,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,UAAU,CAAC;AAM7D;;;GAGG;AACH,wBAAgB,YAAY,CAAC,OAAO,EAAE,4BAA4B,GAAG,IAAI,CA0FxE"}
|