@featurevisor/types 1.27.5 → 1.28.0
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/CHANGELOG.md +11 -0
- package/LICENSE +1 -1
- package/lib/index.d.ts +15 -1
- package/package.json +2 -2
- package/src/index.ts +17 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [1.28.0](https://github.com/featurevisor/featurevisor/compare/v1.27.6...v1.28.0) (2025-01-21)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* datafile schema v2 ([#334](https://github.com/featurevisor/featurevisor/issues/334)) ([ee91c78](https://github.com/featurevisor/featurevisor/commit/ee91c781ad8e3347c828cea63279f5b9931a24e7))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
6
17
|
## [1.27.5](https://github.com/featurevisor/featurevisor/compare/v1.27.4...v1.27.5) (2024-12-21)
|
|
7
18
|
|
|
8
19
|
**Note:** Version bump only for package @featurevisor/types
|
package/LICENSE
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
The MIT License (MIT)
|
|
2
2
|
|
|
3
|
-
Copyright (c)
|
|
3
|
+
Copyright (c) 2025 Fahad Heylaal (https://fahad19.com)
|
|
4
4
|
|
|
5
5
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
6
|
of this software and associated documentation files (the "Software"), to deal
|
package/lib/index.d.ts
CHANGED
|
@@ -148,13 +148,27 @@ export interface Feature {
|
|
|
148
148
|
force?: Force[];
|
|
149
149
|
ranges?: Range[];
|
|
150
150
|
}
|
|
151
|
-
export interface
|
|
151
|
+
export interface DatafileContentV1 {
|
|
152
152
|
schemaVersion: string;
|
|
153
153
|
revision: string;
|
|
154
154
|
attributes: Attribute[];
|
|
155
155
|
segments: Segment[];
|
|
156
156
|
features: Feature[];
|
|
157
157
|
}
|
|
158
|
+
export interface DatafileContentV2 {
|
|
159
|
+
schemaVersion: string;
|
|
160
|
+
revision: string;
|
|
161
|
+
attributes: {
|
|
162
|
+
[key: AttributeKey]: Attribute;
|
|
163
|
+
};
|
|
164
|
+
segments: {
|
|
165
|
+
[key: SegmentKey]: Segment;
|
|
166
|
+
};
|
|
167
|
+
features: {
|
|
168
|
+
[key: FeatureKey]: Feature;
|
|
169
|
+
};
|
|
170
|
+
}
|
|
171
|
+
export type DatafileContent = DatafileContentV1 | DatafileContentV2;
|
|
158
172
|
export interface OverrideFeature {
|
|
159
173
|
enabled: boolean;
|
|
160
174
|
variation?: VariationValue;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@featurevisor/types",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.28.0",
|
|
4
4
|
"description": "Common Typescript types for Featurevisor",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "lib/index.js",
|
|
@@ -40,5 +40,5 @@
|
|
|
40
40
|
"url": "https://github.com/featurevisor/featurevisor/issues"
|
|
41
41
|
},
|
|
42
42
|
"license": "MIT",
|
|
43
|
-
"gitHead": "
|
|
43
|
+
"gitHead": "2ae2980762184d9c47b878edffd0ec36d267df3b"
|
|
44
44
|
}
|
package/src/index.ts
CHANGED
|
@@ -249,7 +249,7 @@ export interface Feature {
|
|
|
249
249
|
ranges?: Range[]; // if in a Group (mutex), these are the available slot ranges
|
|
250
250
|
}
|
|
251
251
|
|
|
252
|
-
export interface
|
|
252
|
+
export interface DatafileContentV1 {
|
|
253
253
|
schemaVersion: string;
|
|
254
254
|
revision: string;
|
|
255
255
|
attributes: Attribute[];
|
|
@@ -257,6 +257,22 @@ export interface DatafileContent {
|
|
|
257
257
|
features: Feature[];
|
|
258
258
|
}
|
|
259
259
|
|
|
260
|
+
export interface DatafileContentV2 {
|
|
261
|
+
schemaVersion: string;
|
|
262
|
+
revision: string;
|
|
263
|
+
attributes: {
|
|
264
|
+
[key: AttributeKey]: Attribute;
|
|
265
|
+
};
|
|
266
|
+
segments: {
|
|
267
|
+
[key: SegmentKey]: Segment;
|
|
268
|
+
};
|
|
269
|
+
features: {
|
|
270
|
+
[key: FeatureKey]: Feature;
|
|
271
|
+
};
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
export type DatafileContent = DatafileContentV1 | DatafileContentV2;
|
|
275
|
+
|
|
260
276
|
export interface OverrideFeature {
|
|
261
277
|
enabled: boolean;
|
|
262
278
|
variation?: VariationValue;
|