@automattic/jetpack-shared-extension-utils 1.4.10 → 1.4.12

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
@@ -5,6 +5,17 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [1.4.12] - 2026-02-16
9
+ ### Changed
10
+ - Update package dependencies. [#47099]
11
+
12
+ ## [1.4.11] - 2026-02-10
13
+ ### Added
14
+ - Shared Extension Utils: Add separate site type utils export. [#46938]
15
+
16
+ ### Removed
17
+ - Remove Chrome AI tokens type and mapping. [#46896]
18
+
8
19
  ## [1.4.10] - 2026-02-04
9
20
  ### Changed
10
21
  - Update dependencies. [#46944]
@@ -859,6 +870,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
859
870
  ### Changed
860
871
  - Core: prepare utility for release
861
872
 
873
+ [1.4.12]: https://github.com/Automattic/jetpack-shared-extension-utils/compare/1.4.11...1.4.12
874
+ [1.4.11]: https://github.com/Automattic/jetpack-shared-extension-utils/compare/1.4.10...1.4.11
862
875
  [1.4.10]: https://github.com/Automattic/jetpack-shared-extension-utils/compare/1.4.9...1.4.10
863
876
  [1.4.9]: https://github.com/Automattic/jetpack-shared-extension-utils/compare/1.4.8...1.4.9
864
877
  [1.4.8]: https://github.com/Automattic/jetpack-shared-extension-utils/compare/1.4.7...1.4.8
@@ -0,0 +1,5 @@
1
+ import type { ConnectionScriptData } from '@automattic/jetpack-connection';
2
+
3
+ interface Window {
4
+ JP_CONNECTION_INITIAL_STATE: ConnectionScriptData;
5
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@automattic/jetpack-shared-extension-utils",
3
- "version": "1.4.10",
3
+ "version": "1.4.12",
4
4
  "description": "Utility functions used by the block editor extensions",
5
5
  "homepage": "https://github.com/Automattic/jetpack/tree/HEAD/projects/js-packages/shared-extension-utils/#readme",
6
6
  "bugs": {
@@ -20,6 +20,7 @@
20
20
  },
21
21
  "./components": "./src/components/index.js",
22
22
  "./icons": "./src/icons.js",
23
+ "./site-type-utils": "./src/site-type-utils.js",
23
24
  "./store/wordpress-com": "./src/store/wordpress-com/index.ts",
24
25
  "./store/wordpress-com/types": "./src/store/wordpress-com/types.ts"
25
26
  },
@@ -31,9 +32,9 @@
31
32
  "dependencies": {
32
33
  "@automattic/color-studio": "4.1.0",
33
34
  "@automattic/jetpack-analytics": "^1.0.7",
34
- "@automattic/jetpack-base-styles": "^1.0.15",
35
- "@automattic/jetpack-components": "^1.4.11",
36
- "@automattic/jetpack-connection": "^1.4.32",
35
+ "@automattic/jetpack-base-styles": "^1.0.16",
36
+ "@automattic/jetpack-components": "^1.4.13",
37
+ "@automattic/jetpack-connection": "^1.4.34",
37
38
  "@automattic/jetpack-script-data": "^0.5.4",
38
39
  "@types/jest": "30.0.0",
39
40
  "@wordpress/api-fetch": "7.39.0",
@@ -53,10 +54,10 @@
53
54
  },
54
55
  "devDependencies": {
55
56
  "@automattic/jetpack-webpack-config": "workspace:*",
56
- "@babel/core": "7.28.4",
57
- "@babel/plugin-transform-react-jsx": "7.27.1",
58
- "@babel/preset-react": "7.27.1",
59
- "@babel/runtime": "7.28.4",
57
+ "@babel/core": "7.29.0",
58
+ "@babel/plugin-transform-react-jsx": "7.28.6",
59
+ "@babel/preset-react": "7.28.5",
60
+ "@babel/runtime": "7.28.6",
60
61
  "@testing-library/dom": "10.4.1",
61
62
  "@testing-library/react": "16.3.0",
62
63
  "@testing-library/user-event": "14.6.1",
@@ -1,5 +1,5 @@
1
1
  import jetpackAnalytics from '@automattic/jetpack-analytics';
2
- import { useConnection } from '@automattic/jetpack-connection';
2
+ import useConnection from '@automattic/jetpack-connection/use-connection';
3
3
  import { useEffect, useState, useCallback } from '@wordpress/element';
4
4
 
5
5
  const { tracks } = jetpackAnalytics;
@@ -49,7 +49,6 @@ export function mapAiFeatureResponseToAiFeatureProps(
49
49
  tierPlansEnabled: !! response[ 'tier-plans-enabled' ],
50
50
  costs: response.costs,
51
51
  featuresControl: response[ 'features-control' ],
52
- chromeAiTokens: response[ 'chrome-ai-tokens' ],
53
52
  };
54
53
  }
55
54
 
@@ -91,10 +91,6 @@ export type FeatureControl = {
91
91
 
92
92
  export type FeaturesControl = { [ key: string ]: FeatureControl };
93
93
 
94
- export type ChromeAiTokens = {
95
- [ key: string ]: string;
96
- };
97
-
98
94
  export type AiFeatureProps = {
99
95
  hasFeature: boolean;
100
96
  isOverLimit: boolean;
@@ -118,7 +114,6 @@ export type AiFeatureProps = {
118
114
  };
119
115
  };
120
116
  featuresControl?: FeaturesControl;
121
- chromeAiTokens?: ChromeAiTokens;
122
117
  };
123
118
 
124
119
  // Type used in the `wordpress-com/plans` store.
@@ -163,5 +158,4 @@ export type SiteAIAssistantFeatureEndpointResponseProps = {
163
158
  };
164
159
  };
165
160
  'features-control'?: FeaturesControl;
166
- 'chrome-ai-tokens'?: ChromeAiTokens;
167
161
  };