From a59cbeaf9408fdc350f94c9f9dca647a764c8f01 Mon Sep 17 00:00:00 2001 From: Kevin Moore Date: Mon, 13 Jan 2025 14:28:52 -0600 Subject: [PATCH] [os_detect] move to pkg:web, prepare publish (#850) --- .github/workflows/os_detect.yaml | 2 +- pkgs/os_detect/CHANGELOG.md | 3 ++- pkgs/os_detect/lib/src/osid_html.dart | 2 +- pkgs/os_detect/pubspec.yaml | 3 ++- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/os_detect.yaml b/.github/workflows/os_detect.yaml index 35d6b06e..5405e336 100644 --- a/.github/workflows/os_detect.yaml +++ b/.github/workflows/os_detect.yaml @@ -69,5 +69,5 @@ jobs: run: dart test --platform vm if: always() && steps.install.outcome == 'success' - name: Run Chrome tests - run: dart test --platform chrome + run: dart test --platform chrome --compiler dart2wasm,dart2js if: always() && steps.install.outcome == 'success' diff --git a/pkgs/os_detect/CHANGELOG.md b/pkgs/os_detect/CHANGELOG.md index 9511042f..e3127410 100644 --- a/pkgs/os_detect/CHANGELOG.md +++ b/pkgs/os_detect/CHANGELOG.md @@ -1,5 +1,6 @@ -## 2.0.3-wip +## 2.0.3 +- Move to `package:web`. - Require Dart 3.5 ## 2.0.2 diff --git a/pkgs/os_detect/lib/src/osid_html.dart b/pkgs/os_detect/lib/src/osid_html.dart index a5d896fb..ad84a9a6 100644 --- a/pkgs/os_detect/lib/src/osid_html.dart +++ b/pkgs/os_detect/lib/src/osid_html.dart @@ -2,7 +2,7 @@ // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file. -import 'dart:html'; +import 'package:web/web.dart'; import 'os_kind.dart' show BrowserOS; import 'os_override.dart'; diff --git a/pkgs/os_detect/pubspec.yaml b/pkgs/os_detect/pubspec.yaml index 77281cdf..2e2c0c31 100644 --- a/pkgs/os_detect/pubspec.yaml +++ b/pkgs/os_detect/pubspec.yaml @@ -1,5 +1,5 @@ name: os_detect -version: 2.0.3-wip +version: 2.0.3 description: Platform independent OS detection. repository: https://github.com/dart-lang/core/tree/main/pkgs/os_detect issue_tracker: https://github.com/dart-lang/core/issues?q=is%3Aissue+is%3Aopen+label%3Apackage%3Aos_detect @@ -9,6 +9,7 @@ environment: dependencies: meta: ^1.9.0 + web: ^1.0.0 dev_dependencies: dart_flutter_team_lints: ^3.0.0