diff --git a/tdesign-component/analysis_options.yaml b/tdesign-component/analysis_options.yaml index 660a4e245..36af5adae 100644 --- a/tdesign-component/analysis_options.yaml +++ b/tdesign-component/analysis_options.yaml @@ -134,7 +134,7 @@ linter: - empty_statements # 不要出现可以在编译阶段推算出恒true或者false的条件判断 - invariant_booleans - # 当containns方法的参数和可枚举的类型不同,不要触发可枚举类型的contains方法 + # 当contains方法的参数和可枚举的类型不同,不要触发可枚举类型的contains方法 - iterable_contains_unrelated_type # 用小写加下划线做库的命名 - library_prefixes diff --git a/tdesign-component/example/assets/code/checkbox._verticleCheckbox.txt b/tdesign-component/example/assets/code/checkbox._verticleCheckbox.txt deleted file mode 100644 index 7b87001d5..000000000 --- a/tdesign-component/example/assets/code/checkbox._verticleCheckbox.txt +++ /dev/null @@ -1,29 +0,0 @@ - - Widget _verticalCheckbox(BuildContext context) { - return TDCheckboxGroupContainer( - selectIds: const ['index:1'], - child: ListView.builder( - padding: EdgeInsets.zero, - shrinkWrap: true, - physics: const NeverScrollableScrollPhysics(), - itemBuilder: (BuildContext context, int index) { - var title = '多选'; - var subTitle = ''; - if (index == 2) { - title = '多选标题多行多选标题多行多选标题多行多选标题多行多选标题多行多选标题多行'; - } - if (index == 3) { - subTitle = '描述信息描述信息描述信息描述信息描述信息描述信息描述信息描述信息描述信息'; - } - return TDCheckbox( - id: 'index:$index', - title: title, - titleMaxLine: 2, - subTitleMaxLine: 2, - subTitle: subTitle, - ); - }, - itemCount: 4, - ), - ); - } \ No newline at end of file diff --git a/tdesign-component/example/assets/code/radio._verticleRadios.txt b/tdesign-component/example/assets/code/radio._verticalRadios.txt similarity index 100% rename from tdesign-component/example/assets/code/radio._verticleRadios.txt rename to tdesign-component/example/assets/code/radio._verticalRadios.txt diff --git a/tdesign-component/example/ios/Runner/Base.lproj/Main.storyboard b/tdesign-component/example/ios/Runner/Base.lproj/Main.storyboard index f3c28516f..9caf036fb 100644 --- a/tdesign-component/example/ios/Runner/Base.lproj/Main.storyboard +++ b/tdesign-component/example/ios/Runner/Base.lproj/Main.storyboard @@ -6,7 +6,7 @@ - + diff --git a/tdesign-component/example/lib/base/intl_resouce_delegate.dart b/tdesign-component/example/lib/base/intl_resource_delegate.dart similarity index 100% rename from tdesign-component/example/lib/base/intl_resouce_delegate.dart rename to tdesign-component/example/lib/base/intl_resource_delegate.dart diff --git a/tdesign-component/example/lib/main.dart b/tdesign-component/example/lib/main.dart index 04078e0f3..763298943 100644 --- a/tdesign-component/example/lib/main.dart +++ b/tdesign-component/example/lib/main.dart @@ -5,7 +5,7 @@ import 'package:tdesign_flutter/src/util/log.dart'; import 'package:tdesign_flutter/tdesign_flutter.dart'; import 'base/example_route.dart'; -import 'base/intl_resouce_delegate.dart'; +import 'base/intl_resource_delegate.dart'; import 'config.dart'; import 'home.dart'; @@ -86,7 +86,7 @@ class _MyAppState extends State { Map _getRoutes() { if (PlatformUtil.isWeb) { return {for (var model in examplePageList) model.name: (context) => model.pageBuilder.call(context, model)} - ..putIfAbsent('/', () => (context) => const MyHomePage(title: 'TDesgin Flutter 组件库')); + ..putIfAbsent('/', () => (context) => const MyHomePage(title: 'TDesign Flutter 组件库')); } else { return const {}; } diff --git a/tdesign-site/CHANGELOG.md b/tdesign-site/CHANGELOG.md index 10aa27276..ba767661d 100644 --- a/tdesign-site/CHANGELOG.md +++ b/tdesign-site/CHANGELOG.md @@ -166,7 +166,7 @@ docClass: timeline ## 0.0.7 -* 修改 exmaple的main.dart +* 修改 example的main.dart ## 0.0.6 diff --git a/tdesign-site/script/generate-changelog.js b/tdesign-site/script/generate-changelog.js index f8001717d..a802b677a 100644 --- a/tdesign-site/script/generate-changelog.js +++ b/tdesign-site/script/generate-changelog.js @@ -18,7 +18,7 @@ function updateVersion() { rl.on('line', (input) => { let newVersion = ''; if (!input) { - newVersion = pkg.version.replace(/(\d+\.\d+\.)(\d+)/, (verion, $1, $2) => $1 + (Number($2) + 1)); + newVersion = pkg.version.replace(/(\d+\.\d+\.)(\d+)/, (version, $1, $2) => $1 + (Number($2) + 1)); } else if (!VERSION_REG.test(input)) { console.log('\x1B[31m%s\x1B[0m', '\n⚡ 不要搞事年轻人,请输入正确版本号格式!\n'); rl.prompt(); diff --git a/tdesign-site/script/prerender.mjs b/tdesign-site/script/prerender.mjs index 61b62a718..b130507de 100644 --- a/tdesign-site/script/prerender.mjs +++ b/tdesign-site/script/prerender.mjs @@ -54,7 +54,7 @@ async function initPreviewServer() { fs.mkdirSync(path.dirname(filePath)); } catch {} - console.log('\x1b[32m', `writting ${url}... \n`); + console.log('\x1b[32m', `writing ${url}... \n`); fs.writeFileSync(filePath, html); } diff --git a/tdesign-site/script/test/transform.js b/tdesign-site/script/test/transform.js index 26e54b50d..0ac53ea8f 100644 --- a/tdesign-site/script/test/transform.js +++ b/tdesign-site/script/test/transform.js @@ -1,4 +1,4 @@ -// 由于开启 vritualHost=true 之后,selectComponent 无法获取,暂时在单测关闭 virtualHost +// 由于开启 virtualHost=true 之后,selectComponent 无法获取,暂时在单测关闭 virtualHost const path = require('path'); const babelJest = require('babel-jest'); diff --git a/tdesign-site/site/docs/custom-theme.md b/tdesign-site/site/docs/custom-theme.md index 750c103b1..8a3ad9b4e 100644 --- a/tdesign-site/site/docs/custom-theme.md +++ b/tdesign-site/site/docs/custom-theme.md @@ -62,4 +62,4 @@ page { } ``` -> 目前仅有部分组件支持自定义主题,支持的组件在其文档有陈列对应的 CSS Varialbes,可以访问 [tab-bar-item.less](https://github.com/Tencent/tdesign-miniprogram/blob/develop/src/tab-bar-item/tab-bar-item.less) \ No newline at end of file +> 目前仅有部分组件支持自定义主题,支持的组件在其文档有陈列对应的 CSS Variables,可以访问 [tab-bar-item.less](https://github.com/Tencent/tdesign-miniprogram/blob/develop/src/tab-bar-item/tab-bar-item.less) \ No newline at end of file diff --git a/tdesign-site/site/plugin-tdoc/transforms.ts b/tdesign-site/site/plugin-tdoc/transforms.ts index 965a7f604..06ca728e4 100644 --- a/tdesign-site/site/plugin-tdoc/transforms.ts +++ b/tdesign-site/site/plugin-tdoc/transforms.ts @@ -6,7 +6,7 @@ let demoCodesImports: Record = {}; export default { before({ source, file, md }: any) { - const resouceDir = path.dirname(file); + const resourceDir = path.dirname(file); const reg = file.match(/src\/(\S*)(?=\/\S*.md)/); const name = reg && reg[1]; demoCodesImports = {}; @@ -23,7 +23,7 @@ export default { // 替换成对应 demo 文件 source = source.replace(/{{\s+(.+)\s+}}/g, (_: string, demoDirName: string) => { - const demoPath = path.resolve(resouceDir, `./_example/${demoDirName}`); + const demoPath = path.resolve(resourceDir, `./_example/${demoDirName}`); if (!fs.existsSync(demoPath)) { console.log('\x1B[36m%s\x1B[0m', `${name} 组件需要实现 _example/${demoDirName} 示例!`); return '\n

DEMO (🚧建设中)...

';