@atlaskit/tmp-editor-statsig 1.2.0 → 1.3.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 CHANGED
@@ -1,5 +1,13 @@
1
1
  # @atlaskit/editor-statsig-tmp
2
2
 
3
+ ## 1.3.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#134006](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/134006)
8
+ [`51179090981ef`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/51179090981ef) -
9
+ EDF-1302 updated condensed dloating toolbar feature flag to use statsig instrumentation
10
+
3
11
  ## 1.2.0
4
12
 
5
13
  ### Minor Changes
@@ -7,6 +7,11 @@ exports.editorExperimentsConfig = void 0;
7
7
  function isBoolean(value) {
8
8
  return typeof value === 'boolean';
9
9
  }
10
+ function oneOf(values) {
11
+ return function (value) {
12
+ return values.includes(value);
13
+ };
14
+ }
10
15
  /**
11
16
  * When adding a new experiment, you need to add it here.
12
17
  * Please follow the pattern established in the examples and any
@@ -29,7 +34,7 @@ var editorExperimentsConfig = exports.editorExperimentsConfig = {
29
34
  confluence: 'confluence_editor_experiment_test_new_package_multivariate'
30
35
  },
31
36
  param: 'variant',
32
- typeGuard: isBoolean,
37
+ typeGuard: oneOf(['one', 'two', 'three']),
33
38
  // Note -- you need to specify the type of the default value as the union of all possible values
34
39
  // This is used to provide type safety on consumption
35
40
  defaultValue: 'one'
@@ -52,5 +57,14 @@ var editorExperimentsConfig = exports.editorExperimentsConfig = {
52
57
  param: 'isEnabled',
53
58
  typeGuard: isBoolean,
54
59
  defaultValue: false
60
+ },
61
+ // Added 2024-08-23
62
+ 'platform-editor-ai-condensed-floating-toobar': {
63
+ productKeys: {
64
+ confluence: 'platform_editor_ai_condensed_floating_toobar'
65
+ },
66
+ param: 'isEnabled',
67
+ typeGuard: isBoolean,
68
+ defaultValue: false
55
69
  }
56
70
  };
@@ -1,6 +1,11 @@
1
1
  function isBoolean(value) {
2
2
  return typeof value === 'boolean';
3
3
  }
4
+ function oneOf(values) {
5
+ return value => {
6
+ return values.includes(value);
7
+ };
8
+ }
4
9
  /**
5
10
  * When adding a new experiment, you need to add it here.
6
11
  * Please follow the pattern established in the examples and any
@@ -23,7 +28,7 @@ export const editorExperimentsConfig = {
23
28
  confluence: 'confluence_editor_experiment_test_new_package_multivariate'
24
29
  },
25
30
  param: 'variant',
26
- typeGuard: isBoolean,
31
+ typeGuard: oneOf(['one', 'two', 'three']),
27
32
  // Note -- you need to specify the type of the default value as the union of all possible values
28
33
  // This is used to provide type safety on consumption
29
34
  defaultValue: 'one'
@@ -46,5 +51,14 @@ export const editorExperimentsConfig = {
46
51
  param: 'isEnabled',
47
52
  typeGuard: isBoolean,
48
53
  defaultValue: false
54
+ },
55
+ // Added 2024-08-23
56
+ 'platform-editor-ai-condensed-floating-toobar': {
57
+ productKeys: {
58
+ confluence: 'platform_editor_ai_condensed_floating_toobar'
59
+ },
60
+ param: 'isEnabled',
61
+ typeGuard: isBoolean,
62
+ defaultValue: false
49
63
  }
50
64
  };
@@ -1,6 +1,11 @@
1
1
  function isBoolean(value) {
2
2
  return typeof value === 'boolean';
3
3
  }
4
+ function oneOf(values) {
5
+ return function (value) {
6
+ return values.includes(value);
7
+ };
8
+ }
4
9
  /**
5
10
  * When adding a new experiment, you need to add it here.
6
11
  * Please follow the pattern established in the examples and any
@@ -23,7 +28,7 @@ export var editorExperimentsConfig = {
23
28
  confluence: 'confluence_editor_experiment_test_new_package_multivariate'
24
29
  },
25
30
  param: 'variant',
26
- typeGuard: isBoolean,
31
+ typeGuard: oneOf(['one', 'two', 'three']),
27
32
  // Note -- you need to specify the type of the default value as the union of all possible values
28
33
  // This is used to provide type safety on consumption
29
34
  defaultValue: 'one'
@@ -46,5 +51,14 @@ export var editorExperimentsConfig = {
46
51
  param: 'isEnabled',
47
52
  typeGuard: isBoolean,
48
53
  defaultValue: false
54
+ },
55
+ // Added 2024-08-23
56
+ 'platform-editor-ai-condensed-floating-toobar': {
57
+ productKeys: {
58
+ confluence: 'platform_editor_ai_condensed_floating_toobar'
59
+ },
60
+ param: 'isEnabled',
61
+ typeGuard: isBoolean,
62
+ defaultValue: false
49
63
  }
50
64
  };
@@ -19,7 +19,7 @@ export declare const editorExperimentsConfig: {
19
19
  confluence: string;
20
20
  };
21
21
  param: string;
22
- typeGuard: typeof isBoolean;
22
+ typeGuard: (value: unknown) => value is "one" | "two" | "three";
23
23
  defaultValue: "one" | "two" | "three";
24
24
  };
25
25
  'test-new-experiments-package': {
@@ -39,5 +39,13 @@ export declare const editorExperimentsConfig: {
39
39
  typeGuard: typeof isBoolean;
40
40
  defaultValue: boolean;
41
41
  };
42
+ 'platform-editor-ai-condensed-floating-toobar': {
43
+ productKeys: {
44
+ confluence: string;
45
+ };
46
+ param: string;
47
+ typeGuard: typeof isBoolean;
48
+ defaultValue: boolean;
49
+ };
42
50
  };
43
51
  export {};
@@ -19,7 +19,7 @@ export declare const editorExperimentsConfig: {
19
19
  confluence: string;
20
20
  };
21
21
  param: string;
22
- typeGuard: typeof isBoolean;
22
+ typeGuard: (value: unknown) => value is "one" | "two" | "three";
23
23
  defaultValue: "one" | "two" | "three";
24
24
  };
25
25
  'test-new-experiments-package': {
@@ -39,5 +39,13 @@ export declare const editorExperimentsConfig: {
39
39
  typeGuard: typeof isBoolean;
40
40
  defaultValue: boolean;
41
41
  };
42
+ 'platform-editor-ai-condensed-floating-toobar': {
43
+ productKeys: {
44
+ confluence: string;
45
+ };
46
+ param: string;
47
+ typeGuard: typeof isBoolean;
48
+ defaultValue: boolean;
49
+ };
42
50
  };
43
51
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/tmp-editor-statsig",
3
- "version": "1.2.0",
3
+ "version": "1.3.0",
4
4
  "description": "Temp plugin to ease use of statsig feature flags until platform feature flags are available",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",