rtcpts 0.0.5 → 0.0.6

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/README.md CHANGED
@@ -4,6 +4,16 @@ RTCPT 是一个基于 Vue 3、TypeScript 和 Quasar 构建的现代企业级组
4
4
 
5
5
  [在线文档](https://ngiot-frontend-cpt.redteatest.com/zh-cn/)
6
6
 
7
+ ### 分支管理
8
+
9
+ 1. **创建开发分支**: 开发新功能或修复问题时,应基于 `dev` 分支创建对应的功能分支。分支命名格式为 `feat/`、`fix/`、
10
+ `refactor/`、`docs/`、`perf/` 或 `chore/` 前缀,后跟具体描述。
11
+
12
+ 2. **提交代码审查**: 完成开发后,通过 Pull Request (PR) 或 Merge Request (MR) 提交至 `dev` 分支进行代码审查。提交后可保留自建分支,无需删除。
13
+
14
+ 3. **版本发布流程**: 在 `dev` 分支完成构建后(执行 `npm run build-all`),需先执行 `npm login` 进行身份验证,随后执行
15
+ `npm run patch` 发布新版本。
16
+
7
17
  ## 项目特点
8
18
 
9
19
  - 基于 Quasar 的现代化 UI 组件
@@ -20,9 +30,9 @@ RTCPT 是一个基于 Vue 3、TypeScript 和 Quasar 构建的现代企业级组
20
30
 
21
31
  ### 1. 核心分支 (Core Branches)
22
32
 
23
- | 分支名 | 说明 |
24
- |:-------| :--- |
25
- | `dev` | 开发分支。日常功能集成的基准分支,所有 PR 默认合并至此。 |
33
+ | 分支名 | 说明 |
34
+ |:------|:-------------------------------|
35
+ | `dev` | 开发分支。日常功能集成的基准分支,所有 PR 默认合并至此。 |
26
36
 
27
37
  ---
28
38
 
@@ -31,32 +41,44 @@ RTCPT 是一个基于 Vue 3、TypeScript 和 Quasar 构建的现代企业级组
31
41
  所有短期分支应遵循 `类别/描述` 的格式,使用小写字母并以中划线分隔。
32
42
 
33
43
  #### 功能开发 (Feature)
44
+
34
45
  用于开发新组件或新特性。
46
+
35
47
  - 格式: `feat/description`
36
48
  - 示例: `git checkout -b feat/button-component`
37
49
 
38
50
  #### 缺陷修复 (Bugfix)
51
+
39
52
  用于修复组件 Bug。
53
+
40
54
  - 格式: `fix/description`
41
55
  - 示例: `git checkout -b fix/select-dropdown-overflow`
42
56
 
43
57
  #### 代码重构 (Refactor)
58
+
44
59
  不影响功能逻辑的代码结构调整。
60
+
45
61
  - 格式: `refactor/description`
46
62
  - 示例: `git checkout -b refactor/use-callback-optimization`
47
63
 
48
64
  #### 文档更新 (Docs)
65
+
49
66
  仅涉及文档、注释、Storybook 示例的修改。
67
+
50
68
  - 格式: `docs/description`
51
69
  - 示例: `git checkout -b docs/add-api-tables`
52
70
 
53
71
  #### 性能优化 (Perf)
72
+
54
73
  专门针对组件渲染性能或包体积的优化。
74
+
55
75
  - 格式: `perf/description`
56
76
  - 示例: `git checkout -b perf/reduce-bundle-size`
57
77
 
58
78
  #### 辅助任务 (Chore)
79
+
59
80
  构建流程、依赖库更新、CI 配置等非业务逻辑修改。
81
+
60
82
  - 格式: `chore/description`
61
83
  - 示例: `git checkout -b chore/upgrade-react-18`
62
84
 
@@ -120,8 +120,10 @@ declare const _default: DefineComponent<ExtractPropTypes<{
120
120
  option?: Slot<void | undefined> | undefined;
121
121
  'value-display'?: Slot<void | undefined> | undefined;
122
122
  }>;
123
+ handleManualChange: (val: TModelValue) => void;
123
124
  }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
124
125
  'update:modelValue': (value: TModelValue) => true;
126
+ 'manual-change': (value: TModelValue) => true;
125
127
  }, string, PublicProps, Readonly< ExtractPropTypes<{
126
128
  modelValue: {
127
129
  type: PropType<TModelValue>;
@@ -218,6 +220,7 @@ declare const _default: DefineComponent<ExtractPropTypes<{
218
220
  };
219
221
  }>> & Readonly<{
220
222
  "onUpdate:modelValue"?: ((value: any) => any) | undefined;
223
+ "onManual-change"?: ((value: any) => any) | undefined;
221
224
  }>, {
222
225
  dense: boolean | undefined;
223
226
  options: any[];
@@ -1,27 +1,26 @@
1
- import { QInput, QPagination, QSelect, ComponentConstructor } from 'quasar';
2
- import { DefineComponent, ExtractPropTypes, ComputedRef, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
3
- import { t } from '../../composables/useI18n.ts';
4
- export interface PaginationInfo {
1
+ export type PaginationParameter = Pick<Paginator, 'page' | 'rowsPerPage'>;
2
+ export interface Paginator {
5
3
  page: number;
6
4
  rowsPerPage: number;
7
5
  rowsNumber: number;
8
6
  }
9
- declare const _default: DefineComponent<ExtractPropTypes<{
10
- paginationInfo: {
11
- type: () => PaginationInfo;
12
- default: () => {
13
- page: number;
14
- rowsPerPage: number;
15
- rowsNumber: number;
16
- };
17
- };
18
- }>, {
19
- t: t;
20
- internalInfo: {
21
- totalPage: number;
22
- currentPage: string | number;
23
- page: number;
24
- rowsPerPage: number;
7
+ export type UsePaginationOptions = {
8
+ page?: number;
9
+ rowsPerPage?: number;
10
+ rowsNumber?: number;
11
+ };
12
+ export type UsePaginationReturn = {
13
+ paginationInfo: Paginator;
14
+ getNum: () => number;
15
+ getPaginationParam: () => PaginationParameter;
16
+ setNum: (value?: number) => void;
17
+ setSize: (value?: number) => void;
18
+ setTotal: (value?: number) => void;
19
+ };
20
+ export declare const DEFAULT_ROWS_PER_PAGE = 15;
21
+ export declare const ROWS_PER_PAGE_OPTIONS: number[];
22
+ export declare function usePagination(options?: UsePaginationOptions): UsePaginationReturn;
23
+ rowsPerPage: number;
25
24
  rowsNumber: number;
26
25
  };
27
26
  rowNumbersArr: number[];
@@ -8,8 +8,17 @@ declare const _default: {
8
8
  collapseAll: string;
9
9
  viewAll: string;
10
10
  loading: string;
11
+ add: string;
12
+ update: string;
13
+ delete: string;
14
+ detail: string;
15
+ };
16
+ table: {
17
+ action: string;
11
18
  };
12
19
  messages: {
20
+ success: string;
21
+ error: string;
13
22
  pleaseEnter: string;
14
23
  pleasePressEnterEnter: string;
15
24
  pleaseSelect: string;
@@ -8,8 +8,17 @@ declare const _default: {
8
8
  collapseAll: string;
9
9
  viewAll: string;
10
10
  loading: string;
11
+ add: string;
12
+ update: string;
13
+ delete: string;
14
+ detail: string;
15
+ };
16
+ table: {
17
+ action: string;
11
18
  };
12
19
  messages: {
20
+ success: string;
21
+ error: string;
13
22
  pleaseEnter: string;
14
23
  pleasePressEnterEnter: string;
15
24
  pleaseSelect: string;
@@ -7,9 +7,18 @@ const e = {
7
7
  expandAll: "Expand",
8
8
  collapseAll: "Collapse",
9
9
  viewAll: "View All",
10
- loading: "Loading..."
10
+ loading: "Loading...",
11
+ add: "Add",
12
+ update: "Edit",
13
+ delete: "Delete",
14
+ detail: "Detail"
15
+ },
16
+ table: {
17
+ action: "Action"
11
18
  },
12
19
  messages: {
20
+ success: "Operation successful",
21
+ error: "Operation failed",
13
22
  pleaseEnter: "Please enter",
14
23
  pleasePressEnterEnter: "Please press Enter to enter",
15
24
  pleaseSelect: "Please select",
@@ -7,9 +7,18 @@ const e = {
7
7
  expandAll: "展开",
8
8
  collapseAll: "收起",
9
9
  viewAll: "查看全部",
10
- loading: "加载中..."
10
+ loading: "加载中...",
11
+ add: "新增",
12
+ update: "编辑",
13
+ delete: "删除",
14
+ detail: "详情"
15
+ },
16
+ table: {
17
+ action: "操作"
11
18
  },
12
19
  messages: {
20
+ success: "操作成功",
21
+ error: "操作失败",
13
22
  pleaseEnter: "请输入",
14
23
  pleasePressEnterEnter: "请按回车键确认",
15
24
  pleaseSelect: "请选择",
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={action:{confirm:"Confirm",cancel:"Cancel",query:"Query",reset:"Reset",expandAll:"Expand",collapseAll:"Collapse",viewAll:"View All",loading:"Loading...",add:"Add",update:"Edit",delete:"Delete",detail:"Detail"},table:{action:"Action"},messages:{success:"Operation successful",error:"Operation failed",pleaseEnter:"Please enter",pleasePressEnterEnter:"Please press Enter to enter",pleaseSelect:"Please select",noData:"No data",date:{start:"Start Date",end:"End Date",confirm:"Confirm",hour:"Hour",minute:"Minute",second:"Second",scrollTooltip:"You can scroll the mouse wheel to change the time value"},loading:"Loading...",formRules:{required:"Required",arrMaxLength:"Select up to {max} items",percentageInvalid:"Enter a valid percentage (0-100)",over0:"Value must be greater than 0%",less100:"Value must be less than 100%",addressInvalid:"Invalid format, e.g. {example}",emailInvalid:"Invalid email address",invalidPort:"Invalid port number",rangeInt:"Value must be an integer between {min} and {max}",rangeNumber:"Value must be between {min} and {max}",invalidInput:"Invalid input",alreadyExists:"Already exists",positiveInt:"Value must be a positive integer",nonNegativeInt:"Value must be a non-negative integer",duplicateItemNotAllowed:"Duplicate item not allowed, {value} already exists",maxLengthExceeded:"Maximum {max} items allowed"},jQFile:{click_or_drag_file:"Click to upload",file_type_is:"Supported file types: {type}",max_file_size:"Maximum file size: {size}",unsupportFileFormat:"Unsupported file format",maxFileSizeIs:"Maximum file size: {max} MB"},pagination:{pieces_page:"Pieces/page",goto:"Goto",total:"Total {total} items"}}};exports.default=e;
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={action:{confirm:"确认",cancel:"取消",query:"搜索",reset:"重置",expandAll:"展开",collapseAll:"收起",viewAll:"查看全部",loading:"加载中...",add:"新增",update:"编辑",delete:"删除",detail:"详情"},table:{action:"操作"},messages:{success:"操作成功",error:"操作失败",pleaseEnter:"请输入",pleasePressEnterEnter:"请按回车键确认",pleaseSelect:"请选择",noData:"无数据",date:{start:"起始时间",end:"结束时间",confirm:"确认",hour:"时",minute:"分",second:"秒",scrollTooltip:"可以滚动鼠标滚轮改变时间值"},loading:"加载中...",formRules:{required:"必填",arrMaxLength:"最多选择 {max} 项",percentageInvalid:"请输入有效的百分比(0-100)",over0:"值必须大于 0%",less100:"值必须小于 100%",addressInvalid:"格式不正确,例如:{example}",emailInvalid:"邮箱格式不正确",invalidPort:"端口号格式不正确",rangeInt:"值必须是 {min} 到 {max} 之间的整数",rangeNumber:"值必须在 {min} 到 {max} 之间",invalidInput:"无效输入",alreadyExists:"已存在",positiveInt:"值必须是正整数",nonNegativeInt:"值必须是非负整数",duplicateItemNotAllowed:"不允许重复项,{value} 已存在",maxLengthExceeded:"最多添加 {max} 项"},jQFile:{click_or_drag_file:"点击或拖拽文件到此处上传",file_type_is:"支持的文件类型: {type}",max_file_size:"最大文件大小: {size}",unsupportFileFormat:"不支持的文件格式",maxFileSizeIs:"最大文件大小为 {max} MB"},pagination:{pieces_page:"条/页",goto:"跳转",total:"共 {total} 条"}}};exports.default=e;