@design-system-rte/angular 0.1.1-rc2 → 0.1.1-rc4

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.
Files changed (41) hide show
  1. package/README.md +24 -0
  2. package/ng-package.json +7 -0
  3. package/package.json +7 -50
  4. package/src/{components → lib/components}/button/button.component.stories.ts +1 -2
  5. package/src/public-api.ts +5 -0
  6. package/tsconfig.lib.json +14 -0
  7. package/tsconfig.lib.prod.json +10 -0
  8. package/tsconfig.spec.json +4 -4
  9. package/.editorconfig +0 -15
  10. package/.storybook/main.ts +0 -25
  11. package/.storybook/preview.scss +0 -10
  12. package/.storybook/preview.ts +0 -27
  13. package/.storybook/tsconfig.doc.json +0 -7
  14. package/.storybook/tsconfig.json +0 -11
  15. package/.storybook/typings.d.ts +0 -4
  16. package/.vscode/extensions.json +0 -4
  17. package/.vscode/launch.json +0 -20
  18. package/.vscode/tasks.json +0 -42
  19. package/angular.json +0 -127
  20. package/src/assets/.gitkeep +0 -0
  21. package/tsconfig.app.json +0 -14
  22. package/tsconfig.json +0 -32
  23. /package/src/{components → lib/components}/button/button.component.html +0 -0
  24. /package/src/{components → lib/components}/button/button.component.scss +0 -0
  25. /package/src/{components → lib/components}/button/button.component.spec.ts +0 -0
  26. /package/src/{components → lib/components}/button/button.component.ts +0 -0
  27. /package/src/{components → lib/components}/grid/col/col.directive.ts +0 -0
  28. /package/src/{components → lib/components}/grid/grid.directive.stories.ts +0 -0
  29. /package/src/{components → lib/components}/grid/grid.directive.ts +0 -0
  30. /package/src/{components → lib/components}/link/link.component.html +0 -0
  31. /package/src/{components → lib/components}/link/link.component.scss +0 -0
  32. /package/src/{components → lib/components}/link/link.component.stories.ts +0 -0
  33. /package/src/{components → lib/components}/link/link.component.ts +0 -0
  34. /package/src/{components → lib/components}/radio-button/radio-button.component.html +0 -0
  35. /package/src/{components → lib/components}/radio-button/radio-button.component.scss +0 -0
  36. /package/src/{components → lib/components}/radio-button/radio-button.component.stories.ts +0 -0
  37. /package/src/{components → lib/components}/radio-button/radio-button.component.ts +0 -0
  38. /package/src/{components → lib/components}/radio-button-group/radio-button-group.component.html +0 -0
  39. /package/src/{components → lib/components}/radio-button-group/radio-button-group.component.scss +0 -0
  40. /package/src/{components → lib/components}/radio-button-group/radio-button-group.component.stories.ts +0 -0
  41. /package/src/{components → lib/components}/radio-button-group/radio-button-group.component.ts +0 -0
package/README.md ADDED
@@ -0,0 +1,24 @@
1
+ # Lib
2
+
3
+ This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 17.3.0.
4
+
5
+ ## Code scaffolding
6
+
7
+ Run `ng generate component component-name --project lib` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module --project lib`.
8
+ > Note: Don't forget to add `--project lib` or else it will be added to the default project in your `angular.json` file.
9
+
10
+ ## Build
11
+
12
+ Run `ng build lib` to build the project. The build artifacts will be stored in the `dist/` directory.
13
+
14
+ ## Publishing
15
+
16
+ After building your library with `ng build lib`, go to the dist folder `cd dist/lib` and run `npm publish`.
17
+
18
+ ## Running unit tests
19
+
20
+ Run `ng test lib` to execute the unit tests via [Karma](https://karma-runner.github.io).
21
+
22
+ ## Further help
23
+
24
+ To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.io/cli) page.
@@ -0,0 +1,7 @@
1
+ {
2
+ "$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
3
+ "dest": "../../dist/lib",
4
+ "lib": {
5
+ "entryFile": "src/public-api.ts"
6
+ }
7
+ }
package/package.json CHANGED
@@ -1,55 +1,12 @@
1
1
  {
2
2
  "name": "@design-system-rte/angular",
3
- "version": "0.1.1-rc2",
4
- "scripts": {
5
- "ng": "ng",
6
- "build": "echo \"No build for Angular package\" && exit 0",
7
- "storybook": "ng run angular:storybook --port 7007",
8
- "build-storybook": "ng run angular:build-storybook --output-dir ../design-docs/storybook-static/angular --config-dir .storybook",
9
- "test:ci": "npx playwright install && npx start-server-and-test storybook http://localhost:7007 test",
10
- "test": "test-storybook --url http://localhost:7007"
11
- },
12
- "description": "Angular components for the Design System RTE",
13
- "publishConfig": {
14
- "access": "public"
3
+ "version": "0.1.1-rc4",
4
+ "peerDependencies": {
5
+ "@angular/common": "^17.3.0",
6
+ "@angular/core": "^17.3.0"
15
7
  },
16
8
  "dependencies": {
17
- "@angular/animations": "^17.3.0",
18
- "@angular/common": "^17.3.0",
19
- "@angular/compiler": "^17.3.0",
20
- "@angular/core": "^17.3.0",
21
- "@angular/forms": "^17.3.0",
22
- "@angular/platform-browser": "^17.3.0",
23
- "@angular/platform-browser-dynamic": "^17.3.0",
24
- "@angular/router": "^17.3.0",
25
- "rxjs": "~7.8.0",
26
- "tslib": "^2.3.0",
27
- "zone.js": "~0.14.3",
28
- "@design-system-rte/core": "^0.1.2-rc2"
9
+ "tslib": "^2.3.0"
29
10
  },
30
- "devDependencies": {
31
- "@angular-devkit/build-angular": "^17.3.12",
32
- "@angular/cli": "^17.3.12",
33
- "@angular/compiler-cli": "^17.3.0",
34
- "@chromatic-com/storybook": "^3.2.6",
35
- "@compodoc/compodoc": "^1.1.26",
36
- "@storybook/addon-a11y": "^8.6.6",
37
- "@storybook/addon-docs": "^8.6.6",
38
- "@storybook/addon-essentials": "^8.6.6",
39
- "@storybook/addon-interactions": "^8.6.6",
40
- "@storybook/addon-onboarding": "^8.6.6",
41
- "@storybook/angular": "^8.6.6",
42
- "@storybook/blocks": "^8.6.6",
43
- "@storybook/test": "^8.6.6",
44
- "@storybook/test-runner": "^0.22.0",
45
- "@types/jasmine": "~5.1.0",
46
- "jasmine-core": "~5.1.0",
47
- "karma": "~6.4.0",
48
- "karma-chrome-launcher": "~3.2.0",
49
- "karma-coverage": "~2.2.0",
50
- "karma-jasmine": "~5.1.0",
51
- "karma-jasmine-html-reporter": "~2.1.0",
52
- "storybook": "^8.6.6",
53
- "typescript": "~5.4.2"
54
- }
55
- }
11
+ "sideEffects": false
12
+ }
@@ -1,7 +1,6 @@
1
1
  import type { Meta, StoryObj } from '@storybook/angular';
2
2
  import { fn, userEvent, within, expect } from '@storybook/test';
3
- // TODO: Resolve import from core
4
- // import { ENTER_KEY, SPACE_KEY, TAB_KEY } from '@design-system-rte/core/constants/keyboard.constants';
3
+ import { ENTER_KEY, SPACE_KEY, TAB_KEY } from '@design-system-rte/core/constants/keyboard.constants';
5
4
 
6
5
  import { ButtonComponent } from './button.component';
7
6
 
@@ -0,0 +1,5 @@
1
+ /*
2
+ * Public API Surface of lib
3
+ */
4
+
5
+ export * from './lib/components/button/button.component';
@@ -0,0 +1,14 @@
1
+ /* To learn more about this file see: https://angular.io/config/tsconfig. */
2
+ {
3
+ "extends": "../../tsconfig.json",
4
+ "compilerOptions": {
5
+ "outDir": "../../out-tsc/lib",
6
+ "declaration": true,
7
+ "declarationMap": true,
8
+ "inlineSources": true,
9
+ "types": []
10
+ },
11
+ "exclude": [
12
+ "**/*.spec.ts"
13
+ ]
14
+ }
@@ -0,0 +1,10 @@
1
+ /* To learn more about this file see: https://angular.io/config/tsconfig. */
2
+ {
3
+ "extends": "./tsconfig.lib.json",
4
+ "compilerOptions": {
5
+ "declarationMap": false
6
+ },
7
+ "angularCompilerOptions": {
8
+ "compilationMode": "partial"
9
+ }
10
+ }
@@ -1,14 +1,14 @@
1
1
  /* To learn more about this file see: https://angular.io/config/tsconfig. */
2
2
  {
3
- "extends": "./tsconfig.json",
3
+ "extends": "../../tsconfig.json",
4
4
  "compilerOptions": {
5
- "outDir": "./out-tsc/spec",
5
+ "outDir": "../../out-tsc/spec",
6
6
  "types": [
7
7
  "jasmine"
8
8
  ]
9
9
  },
10
10
  "include": [
11
- "src/**/*.spec.ts",
12
- "src/**/*.d.ts"
11
+ "**/*.spec.ts",
12
+ "**/*.d.ts"
13
13
  ]
14
14
  }
package/.editorconfig DELETED
@@ -1,15 +0,0 @@
1
- root = true
2
-
3
- [*]
4
- charset = utf-8
5
- indent_style = space
6
- indent_size = 2
7
- insert_final_newline = true
8
- trim_trailing_whitespace = true
9
-
10
- [*.ts]
11
- quote_type = single
12
-
13
- [*.md]
14
- max_line_length = off
15
- trim_trailing_whitespace = false
@@ -1,25 +0,0 @@
1
- import type { StorybookConfig } from '@storybook/angular';
2
-
3
- import { join, dirname } from "path"
4
-
5
- function getAbsolutePath(value: string): any {
6
- return dirname(require.resolve(join(value, 'package.json')))
7
- }
8
- const config: StorybookConfig = {
9
- "stories": [
10
- "../src/**/*.mdx",
11
- "../src/**/*.stories.@(js|jsx|mjs|ts|tsx)"
12
- ],
13
- "addons": [
14
- getAbsolutePath('@storybook/addon-essentials'),
15
- getAbsolutePath('@storybook/addon-onboarding'),
16
- getAbsolutePath('@chromatic-com/storybook'),
17
- getAbsolutePath('@storybook/addon-interactions'),
18
- getAbsolutePath("@storybook/addon-a11y")
19
- ],
20
- "framework": {
21
- "name": getAbsolutePath('@storybook/angular'),
22
- "options": {}
23
- }
24
- };
25
- export default config;
@@ -1,10 +0,0 @@
1
- @use "@design-system-rte/core/tokens/_mixins.scss" as *;
2
- @use "@design-system-rte/core/components/grid/grid.stories.scss" as *;
3
- @use "@design-system-rte/core/components/grid/grid.scss" as *;
4
-
5
- @include theme-selector('bleu_iceberg');
6
- @include theme-selector('bleu_iceberg', 'dark');
7
- @include theme-selector('violet');
8
- @include theme-selector('violet', 'dark');
9
- @include theme-selector('vert_foret');
10
- @include theme-selector('vert_foret', 'dark');
@@ -1,27 +0,0 @@
1
- import type { Preview } from '@storybook/angular'
2
- import { setCompodocJson } from "@storybook/addon-docs/angular";
3
- import docJson from "../documentation.json";
4
- setCompodocJson(docJson);
5
-
6
- import { addons } from '@storybook/preview-api';
7
-
8
- const preview: Preview = {
9
- parameters: {
10
- controls: {
11
- matchers: {
12
- color: /(background|color)$/i,
13
- date: /Date$/i,
14
- },
15
- },
16
- },
17
- };
18
-
19
- addons.getChannel().on('THEME_CHANGED', (theme) => {
20
- document.querySelector("html")?.setAttribute("data-mode", theme.theme);
21
- document.querySelector("html")?.setAttribute("data-theme", theme.color);
22
- })
23
-
24
- document.querySelector("html")?.setAttribute("data-theme", "bleu_iceberg");
25
- document.querySelector("html")?.setAttribute("data-mode", "light");
26
-
27
- export default preview;
@@ -1,7 +0,0 @@
1
-
2
- {
3
- "extends": "./tsconfig.json",
4
- "exclude": ["../src/test.ts", "../src/**/*.spec.ts", "../src/**/*.stories.ts"],
5
- "include": ["../src/**/*"],
6
- "files": ["./typings.d.ts"]
7
- }
@@ -1,11 +0,0 @@
1
- {
2
- "extends": "../tsconfig.app.json",
3
- "compilerOptions": {
4
- "types": ["node"],
5
- "allowSyntheticDefaultImports": true,
6
- "resolveJsonModule": true
7
- },
8
- "exclude": ["../src/test.ts", "../src/**/*.spec.ts"],
9
- "include": ["../src/**/*.stories.*", "./preview.ts"],
10
- "files": ["./typings.d.ts"]
11
- }
@@ -1,4 +0,0 @@
1
- declare module '*.md' {
2
- const content: string;
3
- export default content;
4
- }
@@ -1,4 +0,0 @@
1
- {
2
- // For more information, visit: https://go.microsoft.com/fwlink/?linkid=827846
3
- "recommendations": ["angular.ng-template"]
4
- }
@@ -1,20 +0,0 @@
1
- {
2
- // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
3
- "version": "0.2.0",
4
- "configurations": [
5
- {
6
- "name": "ng serve",
7
- "type": "chrome",
8
- "request": "launch",
9
- "preLaunchTask": "npm: start",
10
- "url": "http://localhost:4200/"
11
- },
12
- {
13
- "name": "ng test",
14
- "type": "chrome",
15
- "request": "launch",
16
- "preLaunchTask": "npm: test",
17
- "url": "http://localhost:9876/debug.html"
18
- }
19
- ]
20
- }
@@ -1,42 +0,0 @@
1
- {
2
- // For more information, visit: https://go.microsoft.com/fwlink/?LinkId=733558
3
- "version": "2.0.0",
4
- "tasks": [
5
- {
6
- "type": "npm",
7
- "script": "start",
8
- "isBackground": true,
9
- "problemMatcher": {
10
- "owner": "typescript",
11
- "pattern": "$tsc",
12
- "background": {
13
- "activeOnStart": true,
14
- "beginsPattern": {
15
- "regexp": "(.*?)"
16
- },
17
- "endsPattern": {
18
- "regexp": "bundle generation complete"
19
- }
20
- }
21
- }
22
- },
23
- {
24
- "type": "npm",
25
- "script": "test",
26
- "isBackground": true,
27
- "problemMatcher": {
28
- "owner": "typescript",
29
- "pattern": "$tsc",
30
- "background": {
31
- "activeOnStart": true,
32
- "beginsPattern": {
33
- "regexp": "(.*?)"
34
- },
35
- "endsPattern": {
36
- "regexp": "bundle generation complete"
37
- }
38
- }
39
- }
40
- }
41
- ]
42
- }
package/angular.json DELETED
@@ -1,127 +0,0 @@
1
- {
2
- "$schema": "./node_modules/@angular/cli/lib/config/schema.json",
3
- "version": 1,
4
- "newProjectRoot": "projects",
5
- "projects": {
6
- "angular": {
7
- "projectType": "library",
8
- "schematics": {},
9
- "root": "",
10
- "sourceRoot": "src",
11
- "prefix": "app",
12
- "architect": {
13
- "build": {
14
- "builder": "@angular-devkit/build-angular:application",
15
- "options": {
16
- "outputPath": "dist/angular",
17
- "index": "src/index.html",
18
- "browser": "src/main.ts",
19
- "polyfills": [
20
- "zone.js"
21
- ],
22
- "tsConfig": "tsconfig.app.json",
23
- "assets": [
24
- "src/assets"
25
- ],
26
- "styles": [],
27
- "scripts": [],
28
- "stylePreprocessorOptions": {
29
- "includePaths": ["../"]
30
- }
31
- },
32
- "configurations": {
33
- "production": {
34
- "budgets": [
35
- {
36
- "type": "initial",
37
- "maximumWarning": "500kb",
38
- "maximumError": "1mb"
39
- },
40
- {
41
- "type": "anyComponentStyle",
42
- "maximumWarning": "2kb",
43
- "maximumError": "4kb"
44
- }
45
- ],
46
- "outputHashing": "all"
47
- },
48
- "development": {
49
- "optimization": false,
50
- "extractLicenses": false,
51
- "sourceMap": true
52
- }
53
- },
54
- "defaultConfiguration": "production"
55
- },
56
- "serve": {
57
- "builder": "@angular-devkit/build-angular:dev-server",
58
- "configurations": {
59
- "production": {
60
- "buildTarget": "angular:build:production"
61
- },
62
- "development": {
63
- "buildTarget": "angular:build:development"
64
- }
65
- },
66
- "defaultConfiguration": "development"
67
- },
68
- "extract-i18n": {
69
- "builder": "@angular-devkit/build-angular:extract-i18n",
70
- "options": {
71
- "buildTarget": "angular:build"
72
- }
73
- },
74
- "test": {
75
- "builder": "@angular-devkit/build-angular:karma",
76
- "options": {
77
- "polyfills": [
78
- "zone.js",
79
- "zone.js/testing"
80
- ],
81
- "tsConfig": "tsconfig.spec.json",
82
- "assets": [
83
- "src/assets"
84
- ],
85
- "styles": [],
86
- "scripts": []
87
- }
88
- },
89
- "storybook": {
90
- "builder": "@storybook/angular:start-storybook",
91
- "options": {
92
- "configDir": ".storybook",
93
- "browserTarget": "angular:build",
94
- "compodoc": true,
95
- "compodocArgs": [
96
- "-e",
97
- "json",
98
- "-d",
99
- "."
100
- ],
101
- "styles": ["@design-system-rte/core/tokens/main.scss", ".storybook/preview.scss"],
102
- "port": 6006
103
- }
104
- },
105
- "build-storybook": {
106
- "builder": "@storybook/angular:build-storybook",
107
- "options": {
108
- "configDir": ".storybook",
109
- "browserTarget": "angular:build",
110
- "styles": ["@design-system-rte/core/tokens/main.scss", ".storybook/preview.scss"],
111
- "compodoc": true,
112
- "compodocArgs": [
113
- "-e",
114
- "json",
115
- "-d",
116
- "."
117
- ],
118
- "outputDir": "storybook-static"
119
- }
120
- }
121
- }
122
- }
123
- },
124
- "cli": {
125
- "analytics": "9019dcae-6ff4-41d3-acb7-b8e169519772"
126
- }
127
- }
File without changes
package/tsconfig.app.json DELETED
@@ -1,14 +0,0 @@
1
- /* To learn more about this file see: https://angular.io/config/tsconfig. */
2
- {
3
- "extends": "./tsconfig.json",
4
- "compilerOptions": {
5
- "outDir": "./out-tsc/app",
6
- "types": []
7
- },
8
- "files": [
9
- "src/main.ts"
10
- ],
11
- "include": [
12
- "src/**/*.d.ts"
13
- ]
14
- }
package/tsconfig.json DELETED
@@ -1,32 +0,0 @@
1
- /* To learn more about this file see: https://angular.io/config/tsconfig. */
2
- {
3
- "compileOnSave": false,
4
- "compilerOptions": {
5
- "outDir": "./dist/out-tsc",
6
- "strict": true,
7
- "noImplicitOverride": true,
8
- "noPropertyAccessFromIndexSignature": true,
9
- "noImplicitReturns": true,
10
- "noFallthroughCasesInSwitch": true,
11
- "skipLibCheck": true,
12
- "esModuleInterop": true,
13
- "sourceMap": true,
14
- "declaration": false,
15
- "experimentalDecorators": true,
16
- "moduleResolution": "node",
17
- "importHelpers": true,
18
- "target": "ES2022",
19
- "module": "ES2022",
20
- "useDefineForClassFields": false,
21
- "lib": [
22
- "ES2022",
23
- "dom"
24
- ]
25
- },
26
- "angularCompilerOptions": {
27
- "enableI18nLegacyMessageIdFormat": false,
28
- "strictInjectionParameters": true,
29
- "strictInputAccessModifiers": true,
30
- "strictTemplates": true
31
- }
32
- }