Skip to content

Commit d1eaca0

Browse files
committed
release: 7.0.3
1 parent df664c3 commit d1eaca0

13 files changed

Lines changed: 400 additions & 20 deletions

CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,19 @@
22

33
## Unreleased
44

5+
## 7.0.3 - 2026-04-18
6+
7+
### New Features
8+
- Added a pubspec.yaml notification toolbar action to run `flutter pub get` with supported China mirrors directly from the IDE.
9+
- Added an in-IDE command output dialog for inspecting `flutter pub get` results without leaving the editor.
10+
11+
### Improvements
12+
- Added a settings toggle and toolbar menu action so the pubspec.yaml notification bar can be hidden or re-enabled at any time.
13+
- Refined China mirror presets to keep matched pub and Flutter storage endpoints, and highlighted the recommended CFUG mirror.
14+
15+
### Localization
16+
- Added zh/en/hk/ja/ko translations for the new pubspec.yaml toolbar actions, mirror workflow, and output viewer.
17+
518
## 7.0.2 - 2026-04-16
619

720
### New Features

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
kotlin.stdlib.default.dependency=false
2-
pluginVersion=7.0.2
2+
pluginVersion=7.0.3
33
dartVersion=503.0.0
44
sinceBuildVersion=252
55
kotlin.daemon.jvmargs=-Xmx5024m

src/main/kotlin/shop/itbug/flutterx/config/PluginConfig.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import com.intellij.openapi.project.guessProjectDir
88
class PluginSetting : BaseState() {
99
var showRiverpodInlay by property(true)
1010
var autoImportRiverpodText by string("package:hooks_riverpod/hooks_riverpod.dart")
11+
var showPubspecYamlNotificationBar by property(true)
1112
var openAndroidDirectoryInAS by property(true)
1213
var openIosDirectoryInXcode by property(true)
1314
var openMacosDirectoryInXcode by property(true)
@@ -83,4 +84,4 @@ class PluginConfig(val project: Project) : SimplePersistentStateComponent<Plugin
8384
}
8485

8586

86-
}
87+
}

src/main/kotlin/shop/itbug/flutterx/constance/AppConfig.kt

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,18 @@ import shop.itbug.flutterx.i18n.PluginBundle
66

77

88
/// pub.dev镜像站点
9-
enum class DartPubMirrorImage(val title: String, val url: String) {
9+
enum class DartPubMirrorImage(val title: String, val url: String, val flutterStorageBaseUrl: String? = null) {
1010
DefaultPub(PluginBundle.defaultText(), Links.PUB_SERVER_URL),
11-
FlutterChina("Flutter 社区 (CFUG)", Links.PUB_CFUG),
12-
ShanghaiPub("上海交通大学镜像组", Links.SHANGHAI_PUB_SERVER_URL),
13-
QingHuaPub("清华大学TUNA协会", Links.QINGHUA_PUB_SERVER_URL);
11+
FlutterChina("Flutter 社区 (CFUG) · ${PluginBundle.get("sugg")}", Links.PUB_CFUG, Links.FLUTTER_STORAGE_BASE_URL_BY_CN),
12+
QingHuaPub("清华大学TUNA协会", Links.QINGHUA_PUB_SERVER_URL, Links.QINGHUA_FLUTTER_STORAGE_BASE_URL);
13+
14+
val isChinaMirror: Boolean
15+
get() = flutterStorageBaseUrl != null
16+
17+
companion object {
18+
val chinaMirrors: List<DartPubMirrorImage>
19+
get() = entries.filter { it.isChinaMirror }
20+
}
1421

1522
override fun toString(): String = title
1623
}
@@ -25,4 +32,3 @@ enum class FlutterCheckUrlMirrorImage(val title: String, val url: String) {
2532

2633

2734
val dartKeys = setOf("do", "abstract", "else", "in", "is", "as", "on", "if", "set", "this")
28-

src/main/kotlin/shop/itbug/flutterx/constance/StringConstance.kt

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,18 +54,19 @@ object Links {
5454
const val DEFAULT_FLUTTER_VERSION_INFO_URL_BY_CN =
5555
"https://storage.flutter-io.cn/flutter_infra_release/releases/releases_macos.json"
5656

57+
// flutter storage mirror
58+
const val FLUTTER_STORAGE_BASE_URL_BY_CN = "https://storage.flutter-io.cn"
59+
5760

5861
//pub服务器地址
5962
const val PUB_SERVER_URL = "https://pub.dartlang.org"
6063

6164
//中国区
6265
const val PUB_CFUG = "https://pub.flutter-io.cn"
6366

64-
//上海交通大学
65-
const val SHANGHAI_PUB_SERVER_URL = "https://mirror.sjtu.edu.cn/dart-pub"
66-
6767
//清华大学 TUNA 协会
6868
const val QINGHUA_PUB_SERVER_URL = "https://mirrors.tuna.tsinghua.edu.cn/dart-pub"
69+
const val QINGHUA_FLUTTER_STORAGE_BASE_URL = "https://mirrors.tuna.tsinghua.edu.cn/flutter"
6970

7071
fun generateDocCommit(link: String): String {
7172
return "<a href='$link'>${PluginBundle.doc}</a>"
@@ -77,4 +78,4 @@ fun Panel.documentCommentRow(link: String) {
7778
row {
7879
comment(Links.generateDocCommit(link))
7980
}
80-
}
81+
}
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
package shop.itbug.flutterx.dialog
2+
3+
import com.intellij.openapi.project.Project
4+
import com.intellij.openapi.ui.DialogWrapper
5+
import com.intellij.ui.components.JBScrollPane
6+
import com.intellij.ui.components.JBTextArea
7+
import com.intellij.util.ui.JBUI
8+
import javax.swing.JComponent
9+
10+
class CommandOutputDialog(
11+
project: Project,
12+
private val dialogTitle: String,
13+
private val output: String
14+
) : DialogWrapper(project, true) {
15+
16+
init {
17+
title = dialogTitle
18+
init()
19+
}
20+
21+
override fun createCenterPanel(): JComponent {
22+
val textArea = JBTextArea(output).apply {
23+
isEditable = false
24+
lineWrap = false
25+
wrapStyleWord = false
26+
caretPosition = 0
27+
}
28+
29+
return JBScrollPane(textArea).apply {
30+
preferredSize = JBUI.size(900, 520)
31+
}
32+
}
33+
}

0 commit comments

Comments
 (0)