From 3dcfbee8a3395cd144c630d728ea2e645e3e7726 Mon Sep 17 00:00:00 2001 From: gaojianhao Date: Thu, 28 Mar 2024 14:37:14 +0800 Subject: [PATCH 1/6] Add new ets interface warmupServiceWorker. Signed-off-by: gaojianhao --- api/@ohos.web.webview.d.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/api/@ohos.web.webview.d.ts b/api/@ohos.web.webview.d.ts index b9e77b272..02b76a160 100644 --- a/api/@ohos.web.webview.d.ts +++ b/api/@ohos.web.webview.d.ts @@ -4419,6 +4419,16 @@ declare namespace webview { * @since 12 */ static clearPrefetchedResource(cacheKeyList: Array): void; + + /** + * Warmup the registered serviceworker associated the url. + * @param { string } url - The url. + * @throws { BusinessError } 17100002 - Invalid url. + * @syscap SystemCapability.Web.Webview.Core + * @atomicservice + * @since 12 + */ + static warmupServiceWorker(url: string): void; } /** From d4494d555fa566378f0f4c57b049cdf67533add1 Mon Sep 17 00:00:00 2001 From: gaojianhao Date: Mon, 8 Apr 2024 10:21:04 +0800 Subject: [PATCH 2/6] fix interface warmupServiceWorker. Signed-off-by: gaojianhao --- api/@ohos.web.webview.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/@ohos.web.webview.d.ts b/api/@ohos.web.webview.d.ts index 835429927..b9820c8c9 100644 --- a/api/@ohos.web.webview.d.ts +++ b/api/@ohos.web.webview.d.ts @@ -4502,7 +4502,7 @@ declare namespace webview { */ precompileJavaScript(url: string, script: string | Uint8Array, cacheOptions: CacheOptions): Promise; - /* + /** * Warmup the registered serviceworker associated the url. * @param { string } url - The url. * @throws { BusinessError } 17100002 - Invalid url. From 8ef2e3878938f9f104cde22a4b6b98fc4cf6b9e7 Mon Sep 17 00:00:00 2001 From: gaojianhao Date: Mon, 8 Apr 2024 10:40:24 +0800 Subject: [PATCH 3/6] fix index interface warmupServiceWorker. Signed-off-by: gaojianhao --- api/@ohos.web.webview.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/@ohos.web.webview.d.ts b/api/@ohos.web.webview.d.ts index b9820c8c9..75143612c 100644 --- a/api/@ohos.web.webview.d.ts +++ b/api/@ohos.web.webview.d.ts @@ -4502,7 +4502,7 @@ declare namespace webview { */ precompileJavaScript(url: string, script: string | Uint8Array, cacheOptions: CacheOptions): Promise; - /** +/** * Warmup the registered serviceworker associated the url. * @param { string } url - The url. * @throws { BusinessError } 17100002 - Invalid url. From 04bb4a445520e1878e74554278c7e9b4e76e7657 Mon Sep 17 00:00:00 2001 From: gaojianhao Date: Mon, 8 Apr 2024 11:10:51 +0800 Subject: [PATCH 4/6] fix dote. Signed-off-by: gaojianhao --- api/@ohos.web.webview.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/@ohos.web.webview.d.ts b/api/@ohos.web.webview.d.ts index 2badca01b..9ccb32384 100644 --- a/api/@ohos.web.webview.d.ts +++ b/api/@ohos.web.webview.d.ts @@ -4502,7 +4502,7 @@ declare namespace webview { */ precompileJavaScript(url: string, script: string | Uint8Array, cacheOptions: CacheOptions): Promise; -/** + /** * Warmup the registered serviceworker associated the url. * @param { string } url - The url. * @throws { BusinessError } 17100002 - Invalid url. From 6b94c025fe870b2161c0a155aedd48c74a5defc9 Mon Sep 17 00:00:00 2001 From: gaojianhao Date: Fri, 12 Apr 2024 09:40:11 +0800 Subject: [PATCH 5/6] add space between service and worker. Signed-off-by: gaojianhao --- api/@ohos.web.webview.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/@ohos.web.webview.d.ts b/api/@ohos.web.webview.d.ts index 7ec96baed..b09005457 100644 --- a/api/@ohos.web.webview.d.ts +++ b/api/@ohos.web.webview.d.ts @@ -4527,7 +4527,7 @@ declare namespace webview { static clearHostIP(hostName: string): void; /** - * Warmup the registered serviceworker associated the url. + * Warmup the registered service worker associated the url. * @param { string } url - The url. * @throws { BusinessError } 17100002 - Invalid url. * @syscap SystemCapability.Web.Webview.Core From 3932074a3c9935d8d786d5f65b72a2980c742cd8 Mon Sep 17 00:00:00 2001 From: gaojianhao Date: Fri, 12 Apr 2024 09:59:16 +0800 Subject: [PATCH 6/6] delete word in the white list. Signed-off-by: gaojianhao --- .../api_check_plugin/plugin/dictionaries_supplementary.txt | 1 - 1 file changed, 1 deletion(-) diff --git a/build-tools/api_check_plugin/plugin/dictionaries_supplementary.txt b/build-tools/api_check_plugin/plugin/dictionaries_supplementary.txt index 4c1935544..3cff5b502 100644 --- a/build-tools/api_check_plugin/plugin/dictionaries_supplementary.txt +++ b/build-tools/api_check_plugin/plugin/dictionaries_supplementary.txt @@ -1040,7 +1040,6 @@ unprepare unchained sandboxes sar -serviceworker adapts followx precomposited