@rxap/environment 21.0.1 → 22.0.0-dev.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.
Files changed (87) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/compodoc/architecture.html +222 -0
  3. package/compodoc/changelog.html +57 -5
  4. package/compodoc/components/EnvironmentComponent.html +87 -22
  5. package/compodoc/dependencies.html +84 -15
  6. package/compodoc/index.html +46 -5
  7. package/compodoc/interfaces/Environment.html +860 -671
  8. package/compodoc/js/architecture-graph.js +288 -0
  9. package/compodoc/js/libs/bootstrap-native.js +4 -2
  10. package/compodoc/js/libs/jszip.min.js +13 -0
  11. package/compodoc/js/libs/svg-pan-zoom.min.js +3 -3
  12. package/compodoc/js/libs/tablesort.min.js +3 -3
  13. package/compodoc/js/libs/tablesort.number.min.js +3 -3
  14. package/compodoc/js/libs/vis-network.min.js +78 -0
  15. package/compodoc/js/menu-wc.js +25 -12
  16. package/compodoc/js/menu.js +10 -11
  17. package/compodoc/js/routes/routes_index.js +1 -0
  18. package/compodoc/js/routes.js +142 -34
  19. package/compodoc/js/search/search-lunr.js +6 -8
  20. package/compodoc/js/search/search.js +118 -66
  21. package/compodoc/js/search/search_index.js +2 -2
  22. package/compodoc/js/tabs.js +98 -15
  23. package/compodoc/js/tree.js +44 -7
  24. package/compodoc/license.html +48 -6
  25. package/compodoc/llms.txt +66 -0
  26. package/compodoc/miscellaneous/functions.html +63 -16
  27. package/compodoc/miscellaneous/typealiases.html +47 -5
  28. package/compodoc/miscellaneous/variables.html +58 -5
  29. package/compodoc/modules.html +44 -3
  30. package/compodoc/overview.html +54 -3
  31. package/compodoc/properties.html +45 -4
  32. package/compodoc/routes.html +227 -0
  33. package/compodoc/styles/compodoc.css +365 -44
  34. package/compodoc/styles/dark.css +16 -0
  35. package/compodoc/template-playground/default-templates.json +192 -0
  36. package/compodoc/template-playground/hbs-render.service.ts +217 -0
  37. package/compodoc/template-playground/main.ts +9 -0
  38. package/compodoc/template-playground/template-editor.service.ts +173 -0
  39. package/compodoc/template-playground/template-playground.component.ts +614 -0
  40. package/compodoc/template-playground/template-playground.module.ts +29 -0
  41. package/compodoc/template-playground/zip-export.service.ts +86 -0
  42. package/compodoc/template-playground-app/app.js +1389 -0
  43. package/compodoc/template-playground-app/index.html +462 -0
  44. package/docs/documentation.json +306 -343
  45. package/docs/html/assets/highlight.css +1 -1
  46. package/docs/html/assets/icons.js +1 -1
  47. package/docs/html/assets/icons.svg +1 -1
  48. package/docs/html/assets/main.js +5 -5
  49. package/docs/html/assets/search.js +1 -1
  50. package/docs/html/assets/style.css +265 -228
  51. package/docs/html/classes/EnvironmentComponent.html +70 -3
  52. package/docs/html/functions/DetermineProductionEnvironmentName.html +42 -1
  53. package/docs/html/functions/DetermineReleaseName.html +43 -1
  54. package/docs/html/functions/IsNotReleaseVersion.html +42 -1
  55. package/docs/html/functions/ProvideEnvironment.html +42 -1
  56. package/docs/html/functions/UpdateEnvironment.html +45 -2
  57. package/docs/html/hierarchy.html +29 -0
  58. package/docs/html/index.html +40 -4
  59. package/docs/html/interfaces/Environment.html +188 -27
  60. package/docs/html/modules.html +52 -1
  61. package/docs/html/types/AnySchema.html +55 -1
  62. package/docs/html/variables/RXAP_ENVIRONMENT.html +33 -1
  63. package/docs/markdown/README.md +1 -1
  64. package/docs/markdown/classes/EnvironmentComponent.md +6 -6
  65. package/docs/markdown/functions/DetermineProductionEnvironmentName.md +4 -4
  66. package/docs/markdown/functions/DetermineReleaseName.md +4 -4
  67. package/docs/markdown/functions/IsNotReleaseVersion.md +2 -2
  68. package/docs/markdown/functions/ProvideEnvironment.md +2 -2
  69. package/docs/markdown/functions/UpdateEnvironment.md +4 -4
  70. package/docs/markdown/globals.md +2 -2
  71. package/docs/markdown/interfaces/Environment.md +63 -59
  72. package/docs/markdown/type-aliases/AnySchema.md +7 -5
  73. package/docs/markdown/variables/RXAP_ENVIRONMENT.md +2 -2
  74. package/docs/wiki/Class.EnvironmentComponent.md +5 -5
  75. package/docs/wiki/Function.DetermineProductionEnvironmentName.md +3 -3
  76. package/docs/wiki/Function.DetermineReleaseName.md +3 -3
  77. package/docs/wiki/Function.IsNotReleaseVersion.md +1 -1
  78. package/docs/wiki/Function.ProvideEnvironment.md +1 -1
  79. package/docs/wiki/Function.UpdateEnvironment.md +3 -3
  80. package/docs/wiki/Interface.Environment.md +62 -58
  81. package/docs/wiki/TypeAlias.AnySchema.md +6 -4
  82. package/docs/wiki/Variable.RXAP_ENVIRONMENT.md +1 -1
  83. package/docs/wiki/globals.md +1 -1
  84. package/fesm2022/rxap-environment.mjs +68 -51
  85. package/fesm2022/rxap-environment.mjs.map +1 -1
  86. package/package.json +7 -7
  87. package/types/rxap-environment.d.ts +92 -100
@@ -2,11 +2,11 @@
2
2
 
3
3
  # Interface: Environment
4
4
 
5
- Defined in: [environment.ts:3](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L3)
5
+ Defined in: [environment.ts:3](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L3)
6
6
 
7
7
  ## Indexable
8
8
 
9
- \[`key`: `string`\]: `any`
9
+ > \[`key`: `string`\]: `any`
10
10
 
11
11
  ## Properties
12
12
 
@@ -14,7 +14,7 @@ Defined in: [environment.ts:3](https://gitlab.com/rxap/packages/-/blob/61502283d
14
14
 
15
15
  > **app**: `string`
16
16
 
17
- Defined in: [environment.ts:7](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L7)
17
+ Defined in: [environment.ts:7](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L7)
18
18
 
19
19
  The name of the app
20
20
 
@@ -22,9 +22,9 @@ The name of the app
22
22
 
23
23
  ### branch?
24
24
 
25
- > `optional` **branch**: `null` \| `string`
25
+ > `optional` **branch?**: `string` \| `null`
26
26
 
27
- Defined in: [environment.ts:35](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L35)
27
+ Defined in: [environment.ts:35](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L35)
28
28
 
29
29
  The current branch
30
30
 
@@ -32,9 +32,9 @@ The current branch
32
32
 
33
33
  ### commit?
34
34
 
35
- > `optional` **commit**: `null` \| `string`
35
+ > `optional` **commit?**: `string` \| `null`
36
36
 
37
- Defined in: [environment.ts:27](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L27)
37
+ Defined in: [environment.ts:27](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L27)
38
38
 
39
39
  The current commit
40
40
 
@@ -42,61 +42,65 @@ The current commit
42
42
 
43
43
  ### config?
44
44
 
45
- > `optional` **config**: `string` \| \{ `fromLocalStorage`: `boolean`; `fromUrlParam`: `string` \| `boolean`; `schema`: [`AnySchema`](../wiki/TypeAlias.AnySchema); `static`: `Record`\<`string`, `any`\>; `strategy`: `string`; `url`: `string` \| `string`[] \| (`environment`) => `string` \| `string`[]; \}
45
+ > `optional` **config?**: `string` \| \{ `fromLocalStorage?`: `boolean`; `fromUrlParam?`: `string` \| `boolean`; `schema?`: [`AnySchema`](../wiki/TypeAlias.AnySchema); `static?`: `Record`\<`string`, `any`\>; `strategy?`: `string`; `url?`: `string` \| `string`[] \| ((`environment`) => `string` \| `string`[]); \}
46
46
 
47
- Defined in: [environment.ts:66](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L66)
47
+ Defined in: [environment.ts:66](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L66)
48
48
 
49
- #### Type declaration
49
+ #### Union Members
50
50
 
51
51
  `string`
52
52
 
53
- \{ `fromLocalStorage`: `boolean`; `fromUrlParam`: `string` \| `boolean`; `schema`: [`AnySchema`](../wiki/TypeAlias.AnySchema); `static`: `Record`\<`string`, `any`\>; `strategy`: `string`; `url`: `string` \| `string`[] \| (`environment`) => `string` \| `string`[]; \}
53
+ ***
54
+
55
+ ##### Type Literal
56
+
57
+ \{ `fromLocalStorage?`: `boolean`; `fromUrlParam?`: `string` \| `boolean`; `schema?`: [`AnySchema`](../wiki/TypeAlias.AnySchema); `static?`: `Record`\<`string`, `any`\>; `strategy?`: `string`; `url?`: `string` \| `string`[] \| ((`environment`) => `string` \| `string`[]); \}
54
58
 
55
- #### fromLocalStorage?
59
+ ##### fromLocalStorage?
56
60
 
57
- > `optional` **fromLocalStorage**: `boolean`
61
+ > `optional` **fromLocalStorage?**: `boolean`
58
62
 
59
- #### fromUrlParam?
63
+ ##### fromUrlParam?
60
64
 
61
- > `optional` **fromUrlParam**: `string` \| `boolean`
65
+ > `optional` **fromUrlParam?**: `string` \| `boolean`
62
66
 
63
- #### schema?
67
+ ##### schema?
64
68
 
65
- > `optional` **schema**: [`AnySchema`](../wiki/TypeAlias.AnySchema)
69
+ > `optional` **schema?**: [`AnySchema`](../wiki/TypeAlias.AnySchema)
66
70
 
67
- #### static?
71
+ ##### static?
68
72
 
69
- > `optional` **static**: `Record`\<`string`, `any`\>
73
+ > `optional` **static?**: `Record`\<`string`, `any`\>
70
74
 
71
75
  static config values
72
76
 
73
- #### strategy?
77
+ ##### strategy?
74
78
 
75
- > `optional` **strategy**: `string`
79
+ > `optional` **strategy?**: `string`
76
80
 
77
- #### url?
81
+ ##### url?
78
82
 
79
- > `optional` **url**: `string` \| `string`[] \| (`environment`) => `string` \| `string`[]
83
+ > `optional` **url?**: `string` \| `string`[] \| ((`environment`) => `string` \| `string`[])
80
84
 
81
85
  ***
82
86
 
83
87
  ### moduleFederation?
84
88
 
85
- > `optional` **moduleFederation**: `object`
89
+ > `optional` **moduleFederation?**: `object`
86
90
 
87
- Defined in: [environment.ts:47](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L47)
91
+ Defined in: [environment.ts:47](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L47)
88
92
 
89
93
  #### manifest?
90
94
 
91
- > `optional` **manifest**: `string` \| `Record`\<`string`, `string`\>
95
+ > `optional` **manifest?**: `string` \| `Record`\<`string`, `string`\>
92
96
 
93
97
  ***
94
98
 
95
99
  ### name?
96
100
 
97
- > `optional` **name**: `string`
101
+ > `optional` **name?**: `string`
98
102
 
99
- Defined in: [environment.ts:11](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L11)
103
+ Defined in: [environment.ts:11](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L11)
100
104
 
101
105
  The name of the environment
102
106
 
@@ -104,21 +108,21 @@ The name of the environment
104
108
 
105
109
  ### openApi?
106
110
 
107
- > `optional` **openApi**: `object`
111
+ > `optional` **openApi?**: `object`
108
112
 
109
- Defined in: [environment.ts:80](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L80)
113
+ Defined in: [environment.ts:80](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L80)
110
114
 
111
115
  #### load?
112
116
 
113
- > `optional` **load**: `boolean` \| \{ `openApiUrl`: `string`; \}
117
+ > `optional` **load?**: `boolean` \| \{ `openApiUrl?`: `string`; \}
114
118
 
115
119
  ***
116
120
 
117
121
  ### origin?
118
122
 
119
- > `optional` **origin**: `string`
123
+ > `optional` **origin?**: `string`
120
124
 
121
- Defined in: [environment.ts:78](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L78)
125
+ Defined in: [environment.ts:78](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L78)
122
126
 
123
127
  ***
124
128
 
@@ -126,7 +130,7 @@ Defined in: [environment.ts:78](https://gitlab.com/rxap/packages/-/blob/61502283
126
130
 
127
131
  > **production**: `boolean`
128
132
 
129
- Defined in: [environment.ts:15](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L15)
133
+ Defined in: [environment.ts:15](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L15)
130
134
 
131
135
  The app is compiled from code in the production branch
132
136
 
@@ -134,9 +138,9 @@ The app is compiled from code in the production branch
134
138
 
135
139
  ### release?
136
140
 
137
- > `optional` **release**: `null` \| `string`
141
+ > `optional` **release?**: `string` \| `null`
138
142
 
139
- Defined in: [environment.ts:23](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L23)
143
+ Defined in: [environment.ts:23](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L23)
140
144
 
141
145
  The current app release
142
146
 
@@ -144,53 +148,53 @@ The current app release
144
148
 
145
149
  ### sentry?
146
150
 
147
- > `optional` **sentry**: `object`
151
+ > `optional` **sentry?**: `object`
148
152
 
149
- Defined in: [environment.ts:51](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L51)
153
+ Defined in: [environment.ts:51](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L51)
150
154
 
151
155
  #### debug?
152
156
 
153
- > `optional` **debug**: `boolean`
157
+ > `optional` **debug?**: `boolean`
154
158
 
155
159
  #### dsn?
156
160
 
157
- > `optional` **dsn**: `string`
161
+ > `optional` **dsn?**: `string`
158
162
 
159
163
  #### enabled?
160
164
 
161
- > `optional` **enabled**: `boolean`
165
+ > `optional` **enabled?**: `boolean`
162
166
 
163
167
  #### integrations?
164
168
 
165
- > `optional` **integrations**: `object`
169
+ > `optional` **integrations?**: `object`
166
170
 
167
171
  ##### integrations.BrowserTracing?
168
172
 
169
- > `optional` **BrowserTracing**: `object`
173
+ > `optional` **BrowserTracing?**: `object`
170
174
 
171
175
  ##### integrations.BrowserTracing.tracePropagationTargets?
172
176
 
173
- > `optional` **tracePropagationTargets**: `string`[]
177
+ > `optional` **tracePropagationTargets?**: `string`[]
174
178
 
175
179
  ##### integrations.httpClient?
176
180
 
177
- > `optional` **httpClient**: `object`
181
+ > `optional` **httpClient?**: `object`
178
182
 
179
183
  ##### integrations.httpClient.failedRequestStatusCodes?
180
184
 
181
- > `optional` **failedRequestStatusCodes**: (`number` \| \[`number`, `number`\])[]
185
+ > `optional` **failedRequestStatusCodes?**: (`number` \| \[`number`, `number`\])[]
182
186
 
183
187
  ##### integrations.httpClient.failedRequestTargets?
184
188
 
185
- > `optional` **failedRequestTargets**: (`string` \| `RegExp`)[]
189
+ > `optional` **failedRequestTargets?**: (`string` \| `RegExp`)[]
186
190
 
187
191
  ***
188
192
 
189
193
  ### serviceWorker?
190
194
 
191
- > `optional` **serviceWorker**: `boolean`
195
+ > `optional` **serviceWorker?**: `boolean`
192
196
 
193
- Defined in: [environment.ts:19](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L19)
197
+ Defined in: [environment.ts:19](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L19)
194
198
 
195
199
  Where the service worker is active or not
196
200
 
@@ -198,21 +202,21 @@ Where the service worker is active or not
198
202
 
199
203
  ### slug?
200
204
 
201
- > `optional` **slug**: `object`
205
+ > `optional` **slug?**: `object`
202
206
 
203
- Defined in: [environment.ts:43](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L43)
207
+ Defined in: [environment.ts:43](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L43)
204
208
 
205
209
  #### name?
206
210
 
207
- > `optional` **name**: `string`
211
+ > `optional` **name?**: `string`
208
212
 
209
213
  ***
210
214
 
211
215
  ### tag?
212
216
 
213
- > `optional` **tag**: `null` \| `string`
217
+ > `optional` **tag?**: `string` \| `null`
214
218
 
215
- Defined in: [environment.ts:39](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L39)
219
+ Defined in: [environment.ts:39](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L39)
216
220
 
217
221
  The current tag
218
222
 
@@ -220,16 +224,16 @@ The current tag
220
224
 
221
225
  ### tier?
222
226
 
223
- > `optional` **tier**: `string`
227
+ > `optional` **tier?**: `string`
224
228
 
225
- Defined in: [environment.ts:41](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L41)
229
+ Defined in: [environment.ts:41](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L41)
226
230
 
227
231
  ***
228
232
 
229
233
  ### timestamp?
230
234
 
231
- > `optional` **timestamp**: `null` \| `string` \| `number`
235
+ > `optional` **timestamp?**: `string` \| `number` \| `null`
232
236
 
233
- Defined in: [environment.ts:31](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L31)
237
+ Defined in: [environment.ts:31](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L31)
234
238
 
235
239
  The build timestamp
@@ -2,16 +2,18 @@
2
2
 
3
3
  # Type Alias: AnySchema
4
4
 
5
- > **AnySchema**: `object`
5
+ > **AnySchema** = `object`
6
6
 
7
- Defined in: [environment.ts:1](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment.ts#L1)
7
+ Defined in: [environment.ts:1](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L1)
8
8
 
9
- ## Type declaration
9
+ ## Properties
10
10
 
11
- ### validateAsync()
11
+ ### validateAsync
12
12
 
13
13
  > **validateAsync**: (...`args`) => `any`
14
14
 
15
+ Defined in: [environment.ts:1](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment.ts#L1)
16
+
15
17
  #### Parameters
16
18
 
17
19
  ##### args
@@ -4,4 +4,4 @@
4
4
 
5
5
  > `const` **RXAP\_ENVIRONMENT**: `InjectionToken`\<[`Environment`](../wiki/Interface.Environment)\>
6
6
 
7
- Defined in: [environment/tokens.ts:4](https://gitlab.com/rxap/packages/-/blob/61502283d3119c1cda051f50c92b1b3e3860adb4/packages/angular/environment/src/lib/environment/tokens.ts#L4)
7
+ Defined in: [environment/tokens.ts:4](https://gitlab.com/rxap/packages/-/blob/947fa470d880611063dad4f2b0b1c759b5b07f1b/packages/angular/environment/src/lib/environment/tokens.ts#L4)
@@ -1,4 +1,4 @@
1
- # @rxap/environment v21.0.1
1
+ # @rxap/environment v22.0.0-dev.1
2
2
 
3
3
  ## Classes
4
4
 
@@ -1,85 +1,102 @@
1
- import { __decorate } from 'tslib';
2
- import { DatePipe } from '@angular/common';
3
- import * as i0 from '@angular/core';
4
- import { InjectionToken, inject, ChangeDetectionStrategy, Component } from '@angular/core';
5
- const RXAP_ENVIRONMENT = new InjectionToken('rxap-environment');
1
+ import { __decorate } from "tslib";
2
+ import { DatePipe } from "@angular/common";
3
+ import * as i0 from "@angular/core";
4
+ import { ChangeDetectionStrategy, Component, InjectionToken, inject } from "@angular/core";
5
+ const RXAP_ENVIRONMENT = new InjectionToken("rxap-environment");
6
6
  let EnvironmentComponent = class EnvironmentComponent {
7
7
  constructor() {
8
8
  this.environment = inject(RXAP_ENVIRONMENT);
9
9
  }
10
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: EnvironmentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
11
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.9", type: EnvironmentComponent, isStandalone: true, selector: "rxap-environment", host: { classAttribute: "rxap-environment" }, ngImport: i0, template: "<div class=\"p-4\">\n <h2 class=\"text-xl font-bold pb-2\">{{ environment.app }}</h2>\n <table class=\"table-auto\">\n @if (environment.name) {\n <tr>\n <th>Environment</th>\n <td>{{environment.name}}</td>\n </tr>\n }\n <tr>\n <th>Production</th>\n <td>{{environment.production}}</td>\n </tr>\n @if (environment.serviceWorker !== undefined) {\n <tr>\n <th>Service Worker</th>\n <td>{{environment.serviceWorker}}</td>\n </tr>\n }\n @if (environment.release) {\n <tr>\n <th>Release</th>\n <td>{{environment.release}}</td>\n </tr>\n }\n @if (environment.commit) {\n <tr>\n <th>Commit</th>\n <td>{{environment.commit}}</td>\n </tr>\n }\n @if (environment.timestamp) {\n <tr>\n <th>Timestamp</th>\n <td>{{environment.timestamp | date:'dd.MM.yy HH:mm:ss'}}</td>\n </tr>\n }\n @if (environment.branch) {\n <tr>\n <th>Branch</th>\n <td>{{environment.branch}}</td>\n </tr>\n }\n @if (environment.tag) {\n <tr>\n <th>Tag</th>\n <td>{{environment.tag}}</td>\n </tr>\n }\n <ng-content></ng-content>\n </table>\n</div>\n", styles: [".collapse-button{background-color:transparent;margin:8px 8px 20px;border:none;cursor:pointer;width:calc(100% - 16px)}table th{text-align:left;padding-right:16px}table th,table td{font-size:75%}\n"], dependencies: [{ kind: "pipe", type: DatePipe, name: "date" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
10
+ static {
11
+ this.ɵfac = i0.ɵɵngDeclareFactory({
12
+ minVersion: "12.0.0",
13
+ version: "22.3.0",
14
+ ngImport: i0,
15
+ type: EnvironmentComponent,
16
+ deps: [],
17
+ target: i0.ɵɵFactoryTarget.Component
18
+ });
19
+ }
20
+ static {
21
+ this.ɵcmp = i0.ɵɵngDeclareComponent({
22
+ minVersion: "17.0.0",
23
+ version: "22.3.0",
24
+ type: EnvironmentComponent,
25
+ isStandalone: true,
26
+ selector: "rxap-environment",
27
+ host: { classAttribute: "rxap-environment" },
28
+ ngImport: i0,
29
+ template: "<div class=\"p-4\">\n <h2 class=\"text-xl font-bold pb-2\">{{ environment.app }}</h2>\n <table class=\"table-auto\">\n @if (environment.name) {\n <tr>\n <th>Environment</th>\n <td>{{environment.name}}</td>\n </tr>\n }\n <tr>\n <th>Production</th>\n <td>{{environment.production}}</td>\n </tr>\n @if (environment.serviceWorker !== undefined) {\n <tr>\n <th>Service Worker</th>\n <td>{{environment.serviceWorker}}</td>\n </tr>\n }\n @if (environment.release) {\n <tr>\n <th>Release</th>\n <td>{{environment.release}}</td>\n </tr>\n }\n @if (environment.commit) {\n <tr>\n <th>Commit</th>\n <td>{{environment.commit}}</td>\n </tr>\n }\n @if (environment.timestamp) {\n <tr>\n <th>Timestamp</th>\n <td>{{environment.timestamp | date:'dd.MM.yy HH:mm:ss'}}</td>\n </tr>\n }\n @if (environment.branch) {\n <tr>\n <th>Branch</th>\n <td>{{environment.branch}}</td>\n </tr>\n }\n @if (environment.tag) {\n <tr>\n <th>Tag</th>\n <td>{{environment.tag}}</td>\n </tr>\n }\n <ng-content></ng-content>\n </table>\n</div>\n",
30
+ styles: [".collapse-button{background-color:transparent;margin:8px 8px 20px;border:none;cursor:pointer;width:calc(100% - 16px)}table th{text-align:left;padding-right:16px}table th,table td{font-size:75%}\n"],
31
+ dependencies: [{
32
+ kind: "pipe",
33
+ type: DatePipe,
34
+ name: "date"
35
+ }],
36
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
37
+ });
38
+ }
12
39
  };
13
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: EnvironmentComponent, decorators: [{
40
+ i0.ɵɵngDeclareClassMetadata({
41
+ minVersion: "12.0.0",
42
+ version: "22.3.0",
43
+ ngImport: i0,
44
+ type: EnvironmentComponent,
45
+ decorators: [{
14
46
  type: Component,
15
- args: [{ selector: 'rxap-environment', changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'rxap-environment' }, imports: [DatePipe], template: "<div class=\"p-4\">\n <h2 class=\"text-xl font-bold pb-2\">{{ environment.app }}</h2>\n <table class=\"table-auto\">\n @if (environment.name) {\n <tr>\n <th>Environment</th>\n <td>{{environment.name}}</td>\n </tr>\n }\n <tr>\n <th>Production</th>\n <td>{{environment.production}}</td>\n </tr>\n @if (environment.serviceWorker !== undefined) {\n <tr>\n <th>Service Worker</th>\n <td>{{environment.serviceWorker}}</td>\n </tr>\n }\n @if (environment.release) {\n <tr>\n <th>Release</th>\n <td>{{environment.release}}</td>\n </tr>\n }\n @if (environment.commit) {\n <tr>\n <th>Commit</th>\n <td>{{environment.commit}}</td>\n </tr>\n }\n @if (environment.timestamp) {\n <tr>\n <th>Timestamp</th>\n <td>{{environment.timestamp | date:'dd.MM.yy HH:mm:ss'}}</td>\n </tr>\n }\n @if (environment.branch) {\n <tr>\n <th>Branch</th>\n <td>{{environment.branch}}</td>\n </tr>\n }\n @if (environment.tag) {\n <tr>\n <th>Tag</th>\n <td>{{environment.tag}}</td>\n </tr>\n }\n <ng-content></ng-content>\n </table>\n</div>\n", styles: [".collapse-button{background-color:transparent;margin:8px 8px 20px;border:none;cursor:pointer;width:calc(100% - 16px)}table th{text-align:left;padding-right:16px}table th,table td{font-size:75%}\n"] }]
16
- }] });
47
+ args: [{
48
+ selector: "rxap-environment",
49
+ changeDetection: ChangeDetectionStrategy.OnPush,
50
+ host: { class: "rxap-environment" },
51
+ imports: [DatePipe],
52
+ template: "<div class=\"p-4\">\n <h2 class=\"text-xl font-bold pb-2\">{{ environment.app }}</h2>\n <table class=\"table-auto\">\n @if (environment.name) {\n <tr>\n <th>Environment</th>\n <td>{{environment.name}}</td>\n </tr>\n }\n <tr>\n <th>Production</th>\n <td>{{environment.production}}</td>\n </tr>\n @if (environment.serviceWorker !== undefined) {\n <tr>\n <th>Service Worker</th>\n <td>{{environment.serviceWorker}}</td>\n </tr>\n }\n @if (environment.release) {\n <tr>\n <th>Release</th>\n <td>{{environment.release}}</td>\n </tr>\n }\n @if (environment.commit) {\n <tr>\n <th>Commit</th>\n <td>{{environment.commit}}</td>\n </tr>\n }\n @if (environment.timestamp) {\n <tr>\n <th>Timestamp</th>\n <td>{{environment.timestamp | date:'dd.MM.yy HH:mm:ss'}}</td>\n </tr>\n }\n @if (environment.branch) {\n <tr>\n <th>Branch</th>\n <td>{{environment.branch}}</td>\n </tr>\n }\n @if (environment.tag) {\n <tr>\n <th>Tag</th>\n <td>{{environment.tag}}</td>\n </tr>\n }\n <ng-content></ng-content>\n </table>\n</div>\n",
53
+ styles: [".collapse-button{background-color:transparent;margin:8px 8px 20px;border:none;cursor:pointer;width:calc(100% - 16px)}table th{text-align:left;padding-right:16px}table th,table td{font-size:75%}\n"]
54
+ }]
55
+ }]
56
+ });
17
57
  function DetermineProductionEnvironmentName(environment) {
18
- if (environment.tier) {
58
+ if (environment.tier)
19
59
  return environment.tier;
20
- }
21
60
  else if (environment.tag) {
22
61
  const tagMatch = environment.tag.match(/^v\d+\.\d+\.\d+(-([^.]+)\.\d+)?$/);
23
- if (!tagMatch) {
24
- return undefined;
25
- }
26
- // if the tage has a chanel/digest use this as environment name
27
- return tagMatch[2] ?? 'production';
62
+ if (!tagMatch)
63
+ return;
64
+ return tagMatch[2] ?? "production";
28
65
  }
29
- else if (environment.branch) {
66
+ else if (environment.branch)
30
67
  return environment.branch;
31
- }
32
- return undefined;
33
68
  }
34
- function DetermineReleaseName(environment, defaultReleaseName = 'local-development') {
35
- if (environment.tag) {
69
+ function DetermineReleaseName(environment, defaultReleaseName = "local-development") {
70
+ if (environment.tag)
36
71
  return environment.tag;
37
- }
38
- else if (environment.branch) {
72
+ else if (environment.branch)
39
73
  return environment.branch;
40
- }
41
74
  return defaultReleaseName;
42
75
  }
43
76
  function IsNotReleaseVersion(environment) {
44
- if (!environment.tag) {
77
+ if (!environment.tag)
45
78
  return true;
46
- }
47
- if (environment.tier !== 'production') {
79
+ if (environment.tier !== "production")
48
80
  return true;
49
- }
50
81
  const tagMatch = environment.tag.match(/^v\d+\.\d+\.\d+(-([^.]+)\.\d+)?$/);
51
- if (!tagMatch) {
82
+ if (!tagMatch)
52
83
  return true;
53
- }
54
- if (tagMatch[2]) {
84
+ if (tagMatch[2])
55
85
  return true;
56
- }
57
86
  return false;
58
87
  }
59
88
  function ProvideEnvironment(environment) {
60
89
  return {
61
90
  provide: RXAP_ENVIRONMENT,
62
- useValue: environment,
91
+ useValue: environment
63
92
  };
64
93
  }
65
- /**
66
- * Loads the build.json and adds all keys to the environment object
67
- */
68
- async function UpdateEnvironment(environment, url = 'build.json') {
69
- await fetch(url)
70
- .then((response) => {
71
- if (!response.ok) {
72
- throw new Error('Could not load build.json');
73
- }
94
+ async function UpdateEnvironment(environment, url = "build.json") {
95
+ await fetch(url).then((response) => {
96
+ if (!response.ok)
97
+ throw new Error("Could not load build.json");
74
98
  return response.json();
75
- })
76
- .then((build) => Object.assign(environment, build))
77
- .catch(error => console.error(error.message));
99
+ }).then((build) => Object.assign(environment, build)).catch((error) => console.error(error.message));
78
100
  console.debug(`environment: '${environment.name}'`, environment);
79
101
  }
80
- // region environment
81
- // endregion
82
- /**
83
- * Generated bundle index. Do not edit.
84
- */
85
102
  export { DetermineProductionEnvironmentName, DetermineReleaseName, EnvironmentComponent, IsNotReleaseVersion, ProvideEnvironment, RXAP_ENVIRONMENT, UpdateEnvironment };
@@ -1 +1 @@
1
- {"version":3,"file":"rxap-environment.mjs","sources":["../../../../../packages/angular/environment/src/lib/environment/tokens.ts","../../../../../packages/angular/environment/src/lib/environment/environment.component.ts","../../../../../packages/angular/environment/src/lib/environment/environment.component.html","../../../../../packages/angular/environment/src/lib/determine-production-environment-name.ts","../../../../../packages/angular/environment/src/lib/determine-release-name.ts","../../../../../packages/angular/environment/src/lib/is-not-release-version.ts","../../../../../packages/angular/environment/src/lib/provide-environment.ts","../../../../../packages/angular/environment/src/lib/update-environment.ts","../../../../../packages/angular/environment/src/index.ts","../../../../../packages/angular/environment/src/rxap-environment.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\nimport { Environment } from '../environment';\n\nexport const RXAP_ENVIRONMENT = new InjectionToken<Environment>('rxap-environment');\n","import { DatePipe } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n inject,\n} from '@angular/core';\nimport { Showcase } from '@ng-prism/core';\nimport { Environment } from '../environment';\nimport { RXAP_ENVIRONMENT } from './tokens';\n\n@Showcase({\n title: 'Environment',\n category: 'Environment',\n description: 'Shows the build information of the running app. The values are read from the `RXAP_ENVIRONMENT` token, which the styleguide host provides with demo data.',\n status: 'stable',\n variants: [\n { name: 'Default' },\n ],\n})\n@Component({\n selector: 'rxap-environment',\n templateUrl: './environment.component.html',\n styleUrls: ['./environment.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n \n host: { class: 'rxap-environment' },\n imports: [DatePipe]\n})\nexport class EnvironmentComponent {\n\n public readonly environment: Environment = inject(RXAP_ENVIRONMENT);\n\n}\n","<div class=\"p-4\">\n <h2 class=\"text-xl font-bold pb-2\">{{ environment.app }}</h2>\n <table class=\"table-auto\">\n @if (environment.name) {\n <tr>\n <th>Environment</th>\n <td>{{environment.name}}</td>\n </tr>\n }\n <tr>\n <th>Production</th>\n <td>{{environment.production}}</td>\n </tr>\n @if (environment.serviceWorker !== undefined) {\n <tr>\n <th>Service Worker</th>\n <td>{{environment.serviceWorker}}</td>\n </tr>\n }\n @if (environment.release) {\n <tr>\n <th>Release</th>\n <td>{{environment.release}}</td>\n </tr>\n }\n @if (environment.commit) {\n <tr>\n <th>Commit</th>\n <td>{{environment.commit}}</td>\n </tr>\n }\n @if (environment.timestamp) {\n <tr>\n <th>Timestamp</th>\n <td>{{environment.timestamp | date:'dd.MM.yy HH:mm:ss'}}</td>\n </tr>\n }\n @if (environment.branch) {\n <tr>\n <th>Branch</th>\n <td>{{environment.branch}}</td>\n </tr>\n }\n @if (environment.tag) {\n <tr>\n <th>Tag</th>\n <td>{{environment.tag}}</td>\n </tr>\n }\n <ng-content></ng-content>\n </table>\n</div>\n","import { Environment } from './environment';\n\nexport function DetermineProductionEnvironmentName(environment: Environment) {\n if (environment.tier) {\n return environment.tier;\n } else if (environment.tag) {\n const tagMatch = environment.tag.match(/^v\\d+\\.\\d+\\.\\d+(-([^.]+)\\.\\d+)?$/);\n if (!tagMatch) {\n return undefined;\n }\n // if the tage has a chanel/digest use this as environment name\n return tagMatch[2] ?? 'production';\n } else if (environment.branch) {\n return environment.branch;\n }\n return undefined;\n}\n","import { Environment } from './environment';\n\nexport function DetermineReleaseName(environment: Environment, defaultReleaseName = 'local-development'): string {\n\n if (environment.tag) {\n return environment.tag;\n } else if (environment.branch) {\n return environment.branch;\n }\n return defaultReleaseName;\n\n}\n","import { Environment } from './environment';\n\nexport function IsNotReleaseVersion(environment: Environment): boolean {\n if (!environment.tag) {\n return true;\n }\n if (environment.tier !== 'production') {\n return true;\n }\n const tagMatch = environment.tag.match(/^v\\d+\\.\\d+\\.\\d+(-([^.]+)\\.\\d+)?$/);\n if (!tagMatch) {\n return true;\n }\n if (tagMatch[2]) {\n return true;\n }\n return false;\n}\n","import { Environment } from './environment';\nimport { RXAP_ENVIRONMENT } from './environment/tokens';\n\nexport function ProvideEnvironment(environment: Environment) {\n return {\n provide: RXAP_ENVIRONMENT,\n useValue: environment,\n };\n}\n","import { Environment } from './environment';\n\n/**\n * Loads the build.json and adds all keys to the environment object\n */\nexport async function UpdateEnvironment(environment: Environment, url = 'build.json') {\n await fetch(url)\n .then((response) => {\n if (!response.ok) {\n throw new Error('Could not load build.json');\n }\n return response.json();\n })\n .then((build) => Object.assign(environment, build))\n .catch(error => console.error(error.message));\n console.debug(`environment: '${ environment.name }'`, environment);\n}\n","// region environment\nexport * from './lib/environment/environment.component';\nexport * from './lib/environment/tokens';\n// endregion\n\n// region \nexport * from './lib/determine-production-environment-name';\nexport * from './lib/determine-release-name';\nexport * from './lib/environment';\nexport * from './lib/is-not-release-version';\nexport * from './lib/provide-environment';\nexport * from './lib/update-environment';\n// endregion\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;MAGa,gBAAgB,GAAG,IAAI,cAAc,CAAc,kBAAkB;;ACyB3E,IAAM,oBAAoB,GAA1B,MAAM,oBAAoB,CAAA;AAA1B,IAAA,WAAA,GAAA;AAEW,QAAA,IAAA,CAAA,WAAW,GAAgB,MAAM,CAAC,gBAAgB,CAAC;AAEpE,IAAA;8GAJY,oBAAoB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;kGAApB,oBAAoB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,kBAAA,EAAA,IAAA,EAAA,EAAA,cAAA,EA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,CAAC,IAAI,EAAE;AACxB,IAAA,CAAC;AACA,SAAA,IAAI,CAAC,CAAC,KAAK,KAAK,MAAM,CAAC,MAAM,CAAC,WAAW,EAAE,KAAK,CAAC;AACjD,SAAA,KAAK,CAAC,KAAK,IAAI,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IAC/C,OAAO,CAAC,KAAK,CAAC,CAAA,cAAA,EAAkB,WAAW,CAAC,IAAK,CAAA,CAAA,CAAG,EAAE,WAAW,CAAC;AACpE;;AChBA;AAYA;;ACZA;;AAEG;;;;"}
1
+ {"version":3,"file":"rxap-environment.mjs","names":[],"sources":["../../../../../packages/angular/environment/src/lib/environment/tokens.ts","../../../../../packages/angular/environment/src/lib/environment/environment.component.ts","../../../../../packages/angular/environment/src/lib/environment/environment.component.html","../../../../../packages/angular/environment/src/lib/determine-production-environment-name.ts","../../../../../packages/angular/environment/src/lib/determine-release-name.ts","../../../../../packages/angular/environment/src/lib/is-not-release-version.ts","../../../../../packages/angular/environment/src/lib/provide-environment.ts","../../../../../packages/angular/environment/src/lib/update-environment.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\nimport { Environment } from '../environment';\n\nexport const RXAP_ENVIRONMENT = new InjectionToken<Environment>('rxap-environment');\n","import { DatePipe } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n inject,\n} from '@angular/core';\nimport { Showcase } from '@ng-prism/core';\nimport { Environment } from '../environment';\nimport { RXAP_ENVIRONMENT } from './tokens';\n\n@Showcase({\n title: 'Environment',\n category: 'Environment',\n description: 'Shows the build information of the running app. The values are read from the `RXAP_ENVIRONMENT` token, which the styleguide host provides with demo data.',\n status: 'stable',\n variants: [\n { name: 'Default' },\n ],\n})\n@Component({\n selector: 'rxap-environment',\n templateUrl: './environment.component.html',\n styleUrls: ['./environment.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n \n host: { class: 'rxap-environment' },\n imports: [DatePipe]\n})\nexport class EnvironmentComponent {\n\n public readonly environment: Environment = inject(RXAP_ENVIRONMENT);\n\n}\n","<div class=\"p-4\">\n <h2 class=\"text-xl font-bold pb-2\">{{ environment.app }}</h2>\n <table class=\"table-auto\">\n @if (environment.name) {\n <tr>\n <th>Environment</th>\n <td>{{environment.name}}</td>\n </tr>\n }\n <tr>\n <th>Production</th>\n <td>{{environment.production}}</td>\n </tr>\n @if (environment.serviceWorker !== undefined) {\n <tr>\n <th>Service Worker</th>\n <td>{{environment.serviceWorker}}</td>\n </tr>\n }\n @if (environment.release) {\n <tr>\n <th>Release</th>\n <td>{{environment.release}}</td>\n </tr>\n }\n @if (environment.commit) {\n <tr>\n <th>Commit</th>\n <td>{{environment.commit}}</td>\n </tr>\n }\n @if (environment.timestamp) {\n <tr>\n <th>Timestamp</th>\n <td>{{environment.timestamp | date:'dd.MM.yy HH:mm:ss'}}</td>\n </tr>\n }\n @if (environment.branch) {\n <tr>\n <th>Branch</th>\n <td>{{environment.branch}}</td>\n </tr>\n }\n @if (environment.tag) {\n <tr>\n <th>Tag</th>\n <td>{{environment.tag}}</td>\n </tr>\n }\n <ng-content></ng-content>\n </table>\n</div>\n","import { Environment } from './environment';\n\nexport function DetermineProductionEnvironmentName(environment: Environment) {\n if (environment.tier) {\n return environment.tier;\n } else if (environment.tag) {\n const tagMatch = environment.tag.match(/^v\\d+\\.\\d+\\.\\d+(-([^.]+)\\.\\d+)?$/);\n if (!tagMatch) {\n return undefined;\n }\n // if the tage has a chanel/digest use this as environment name\n return tagMatch[2] ?? 'production';\n } else if (environment.branch) {\n return environment.branch;\n }\n return undefined;\n}\n","import { Environment } from './environment';\n\nexport function DetermineReleaseName(environment: Environment, defaultReleaseName = 'local-development'): string {\n\n if (environment.tag) {\n return environment.tag;\n } else if (environment.branch) {\n return environment.branch;\n }\n return defaultReleaseName;\n\n}\n","import { Environment } from './environment';\n\nexport function IsNotReleaseVersion(environment: Environment): boolean {\n if (!environment.tag) {\n return true;\n }\n if (environment.tier !== 'production') {\n return true;\n }\n const tagMatch = environment.tag.match(/^v\\d+\\.\\d+\\.\\d+(-([^.]+)\\.\\d+)?$/);\n if (!tagMatch) {\n return true;\n }\n if (tagMatch[2]) {\n return true;\n }\n return false;\n}\n","import { Environment } from './environment';\nimport { RXAP_ENVIRONMENT } from './environment/tokens';\n\nexport function ProvideEnvironment(environment: Environment) {\n return {\n provide: RXAP_ENVIRONMENT,\n useValue: environment,\n };\n}\n","import { Environment } from './environment';\n\n/**\n * Loads the build.json and adds all keys to the environment object\n */\nexport async function UpdateEnvironment(environment: Environment, url = 'build.json') {\n await fetch(url)\n .then((response) => {\n if (!response.ok) {\n throw new Error('Could not load build.json');\n }\n return response.json();\n })\n .then((build) => Object.assign(environment, build))\n .catch(error => console.error(error.message));\n console.debug(`environment: '${ environment.name }'`, environment);\n}\n"],"mappings":";;;;;AAGA,MAAa,mBAAmB,IAAI,eAA4B,kBAAkB;ACyB3E,IAAM,uBAAN,MAAM,qBAAoB;CAA1B,cAAA;EAEW,KAAA,cAA2B,OAAO,gBAAgB;CAEnE;CAJY;EAAA,KAAA,OAAA,GAAA,mBAAA;GAAA,YAAA;GAAA,SAAA;GAAA,UAAA;GAAA,MAAA;GAAoB,MAAA,CAAA;GAAA,QAAA,GAAA,gBAAA;EAAA,CAAA;CAAA;CAApB;EAAA,KAAA,OAAA,GAAA,qBAAA;GAAA,YAAA;GAAA,SAAA;GAAA,MAAA;GAAoB,cAAA;GAAA,UAAA;GAAA,MAAA,EAAA,gBAAA,mBAAA;GAAA,UAAA;GAAA,UC5BjC;GAoDA,QAAA,CAAA,qMAAA;GAAA,cAAA,CAAA;IAAA,MAAA;IAAA,MD1Bc;IAAQ,MAAA;GAAA,CAAA;GAAA,iBAAA,GAAA,wBAAA;EAAA,CAAA;CAAA;;AAET,uBAAoB,WAAA,CAlBhC,SAAS;CACR,OAAO;CACP,UAAU;CACV,aAAa;CACb,QAAQ;CACR,UAAU,CACR,EAAE,MAAM,UAAS,CAClB;AACF,CAAA,CAUY,G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AM,iBAAkB,YAAY,KAAK,IAAK,WAAW;AACnE"}
package/package.json CHANGED
@@ -1,15 +1,15 @@
1
1
  {
2
- "version": "21.0.1",
2
+ "version": "22.0.0-dev.1",
3
3
  "name": "@rxap/environment",
4
4
  "description": "Provides utilities and components for managing application environments in Angular, including determining environment names, release versions, and providing environment-specific configurations. It offers a component to display environment information and functions to update the environment with build details. The package also includes an init generator for setting up peer dependencies.\n",
5
5
  "license": "GPL-3.0-or-later",
6
6
  "dependencies": {
7
- "@nx/devkit": "22.7.5",
8
- "tslib": "2.6.2"
7
+ "@nx/devkit": "24.0.6",
8
+ "tslib": "2.9.1"
9
9
  },
10
10
  "peerDependencies": {
11
- "@angular/common": "^21.2.9",
12
- "@angular/core": "^21.2.9"
11
+ "@angular/common": "^22.0.0",
12
+ "@angular/core": "^22.0.0"
13
13
  },
14
14
  "author": {
15
15
  "name": "Merzough Münker",
@@ -34,11 +34,11 @@
34
34
  "packageGroup": [
35
35
  {
36
36
  "package": "@angular/common",
37
- "version": "21.2.9"
37
+ "version": "22.3.0"
38
38
  },
39
39
  {
40
40
  "package": "@angular/core",
41
- "version": "21.2.9"
41
+ "version": "22.3.0"
42
42
  }
43
43
  ]
44
44
  },