urit-qf-ui 0.0.4 → 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/dist/style.css CHANGED
@@ -1 +1 @@
1
- .u-input[data-v-52ab7cd5]{display:flex;width:100%}.u-input.u-input-label-left .u-input-label[data-v-52ab7cd5]{padding-top:10px;flex-shrink:0;text-align:right;padding-right:12px;font-size:14px;color:#606266}.u-input.u-input-label-left .u-input-field[data-v-52ab7cd5]{flex:1}.u-input.u-input-label-top[data-v-52ab7cd5]{flex-direction:column}.u-input.u-input-label-top .u-input-label[data-v-52ab7cd5]{font-size:14px;color:#606266;margin-bottom:4px}.u-select[data-v-71f6d35a]{display:flex;width:100%}.u-select.u-select-label-left .u-select-label[data-v-71f6d35a]{padding-top:10px;flex-shrink:0;text-align:right;padding-right:12px;font-size:14px;color:#606266}.u-select.u-select-label-left .u-select-field[data-v-71f6d35a]{flex:1}.u-select.u-select-label-top[data-v-71f6d35a]{flex-direction:column}.u-select.u-select-label-top .u-select-label[data-v-71f6d35a]{font-size:14px;color:#606266;margin-bottom:4px}.u-designer[data-v-eff86d95]{display:flex;flex-direction:column;height:100%;width:100%;background:#f5f5f5}.u-designer-header[data-v-eff86d95]{height:50px;background:#fff;border-bottom:1px solid #e8e8e8;display:flex;align-items:center;padding:0 16px}.u-designer-header .header-title[data-v-eff86d95]{font-size:16px;font-weight:600;color:#333}.u-designer-body[data-v-eff86d95]{flex:1;display:flex;overflow:hidden}.u-designer-left[data-v-eff86d95]{width:200px;background:#fff;border-right:1px solid #e8e8e8;display:flex;flex-direction:column}.u-designer-left .panel-title[data-v-eff86d95]{padding:12px;font-size:14px;font-weight:600;color:#333;border-bottom:1px solid #e8e8e8}.u-designer-left .component-list[data-v-eff86d95]{flex:1;overflow-y:auto;padding:8px}.u-designer-left .component-item[data-v-eff86d95]{display:flex;align-items:center;gap:8px;padding:10px 12px;margin-bottom:4px;border-radius:4px;cursor:pointer;transition:background .2s}.u-designer-left .component-item[data-v-eff86d95]:hover{background:#f0f7ff}.u-designer-left .component-item span[data-v-eff86d95]{font-size:13px;color:#333}.u-designer-center[data-v-eff86d95]{flex:1;display:flex;flex-direction:column;overflow:hidden}.u-designer-center .preview-area[data-v-eff86d95]{flex:1;overflow:auto;padding:20px}.u-designer-center .preview-content[data-v-eff86d95]{min-height:100%;background:#fff;border-radius:4px;padding:20px}.u-designer-center .preview-widget[data-v-eff86d95]{position:relative;padding:8px;margin-bottom:8px;border:2px solid transparent;border-radius:4px;cursor:pointer;transition:all .2s}.u-designer-center .preview-widget[data-v-eff86d95]:hover{border-color:#e8e8e8}.u-designer-center .preview-widget.selected[data-v-eff86d95]{border-color:#1976d2;background:#f0f7ff}.u-designer-center .preview-widget .widget-preview[data-v-eff86d95]{display:flex;align-items:center;gap:12px}.u-designer-center .preview-widget .widget-label[data-v-eff86d95]{min-width:80px;text-align:right;font-size:14px;color:#606266}.u-designer-center .preview-widget .widget-actions[data-v-eff86d95]{position:absolute;top:4px;right:4px;display:none;gap:4px}.u-designer-center .preview-widget:hover .widget-actions[data-v-eff86d95]{display:flex}.u-designer-center .empty-tip[data-v-eff86d95]{text-align:center;padding:60px 20px;color:#999;font-size:14px}.u-designer-right[data-v-eff86d95]{width:280px;background:#fff;border-left:1px solid #e8e8e8;display:flex;flex-direction:column}.u-designer-right .panel-title[data-v-eff86d95]{padding:12px;font-size:14px;font-weight:600;color:#333;border-bottom:1px solid #e8e8e8}.u-designer-right .property-panel[data-v-eff86d95]{flex:1;overflow-y:auto;padding:12px}.u-designer-right .property-section[data-v-eff86d95]{margin-bottom:16px}.u-designer-right .property-section .section-title[data-v-eff86d95]{font-size:13px;font-weight:600;color:#333;margin-bottom:12px;padding-bottom:8px;border-bottom:1px solid #f0f0f0}.u-designer-right .property-section .property-item[data-v-eff86d95]{margin-bottom:12px}.u-designer-right .property-section .action-buttons[data-v-eff86d95]{display:flex;gap:8px}.u-designer-right .empty-property[data-v-eff86d95]{flex:1;display:flex;align-items:center;justify-content:center;color:#999;font-size:13px}
1
+ .u-input[data-v-52ab7cd5]{display:flex;width:100%}.u-input.u-input-label-left .u-input-label[data-v-52ab7cd5]{padding-top:10px;flex-shrink:0;text-align:right;padding-right:12px;font-size:14px;color:#606266}.u-input.u-input-label-left .u-input-field[data-v-52ab7cd5]{flex:1}.u-input.u-input-label-top[data-v-52ab7cd5]{flex-direction:column}.u-input.u-input-label-top .u-input-label[data-v-52ab7cd5]{font-size:14px;color:#606266;margin-bottom:4px}.u-select[data-v-71f6d35a]{display:flex;width:100%}.u-select.u-select-label-left .u-select-label[data-v-71f6d35a]{padding-top:10px;flex-shrink:0;text-align:right;padding-right:12px;font-size:14px;color:#606266}.u-select.u-select-label-left .u-select-field[data-v-71f6d35a]{flex:1}.u-select.u-select-label-top[data-v-71f6d35a]{flex-direction:column}.u-select.u-select-label-top .u-select-label[data-v-71f6d35a]{font-size:14px;color:#606266;margin-bottom:4px}.u-render-item[data-v-cbf2cb18]{margin-bottom:12px;cursor:pointer;padding:4px;border:2px solid transparent;border-radius:4px}.u-render-item.is-selected[data-v-cbf2cb18]{border-color:#1976d2;background-color:#f5f5f5}
@@ -1,17 +1,17 @@
1
1
  import { WidgetConfig } from './types';
2
2
  interface Props {
3
- widgetList?: WidgetConfig[];
4
- componentMap?: Record<string, string>;
5
- modelValue?: Record<string, any>;
3
+ layout?: WidgetConfig[];
4
+ selectedField?: string;
6
5
  }
7
6
  declare const _default: import('vue').DefineComponent<Props, {
8
- getFormData: () => {
9
- [x: string]: any;
10
- };
11
- setFormData: (data: Record<string, any>) => void;
12
- }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{}>, {
13
- modelValue: Record<string, any>;
14
- widgetList: WidgetConfig[];
15
- componentMap: Record<string, string>;
7
+ setLayout: (list: WidgetConfig[]) => void;
8
+ getLayout: () => WidgetConfig[];
9
+ }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
10
+ "item-click": (field: string) => any;
11
+ }, string, import('vue').PublicProps, Readonly<Props> & Readonly<{
12
+ "onItem-click"?: ((field: string) => any) | undefined;
13
+ }>, {
14
+ layout: WidgetConfig[];
15
+ selectedField: string;
16
16
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
17
17
  export default _default;
@@ -1,28 +1,6 @@
1
1
  export interface WidgetConfig {
2
2
  field: string;
3
3
  type: string;
4
- label: string;
5
- [key: string]: any;
6
- }
7
- export interface PropertyConfig {
8
- name: string;
9
- label: string;
10
- type: 'string' | 'number' | 'boolean' | 'select';
11
- options?: {
12
- label: string;
13
- value: any;
14
- }[];
15
- defaultValue?: any;
16
- }
17
- export interface ComponentRegister {
18
- type: string;
19
- label: string;
20
- icon: string;
21
- component: string;
22
- properties: PropertyConfig[];
23
- }
24
- export interface UDesignerRef {
25
- getWidgetList: () => WidgetConfig[];
26
- setWidgetList: (list: WidgetConfig[]) => void;
27
- clearDesigner: () => void;
4
+ fieldLabel: string;
5
+ values: Record<string, any>;
28
6
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "urit-qf-ui",
3
- "version": "0.0.4",
3
+ "version": "0.0.6",
4
4
  "type": "module",
5
5
  "main": "./dist/index.umd.cjs",
6
6
  "module": "./dist/index.js",
@@ -9,7 +9,8 @@
9
9
  ".": {
10
10
  "import": "./dist/index.js",
11
11
  "require": "./dist/index.umd.cjs"
12
- }
12
+ },
13
+ "./style.css": "./dist/style.css"
13
14
  },
14
15
  "files": [
15
16
  "dist"
@@ -1,17 +0,0 @@
1
- export declare const UInputDesignerConfig: {
2
- type: string;
3
- label: string;
4
- icon: string;
5
- component: string;
6
- properties: ({
7
- name: string;
8
- label: string;
9
- type: string;
10
- defaultValue: string;
11
- } | {
12
- name: string;
13
- label: string;
14
- type: string;
15
- defaultValue: boolean;
16
- })[];
17
- };
@@ -1,28 +0,0 @@
1
- export declare const USelectDesignerConfig: {
2
- type: string;
3
- label: string;
4
- icon: string;
5
- component: string;
6
- properties: ({
7
- name: string;
8
- label: string;
9
- type: string;
10
- defaultValue: string;
11
- options?: undefined;
12
- } | {
13
- name: string;
14
- label: string;
15
- type: string;
16
- options: {
17
- label: string;
18
- value: string;
19
- }[];
20
- defaultValue?: undefined;
21
- } | {
22
- name: string;
23
- label: string;
24
- type: string;
25
- defaultValue: boolean;
26
- options?: undefined;
27
- })[];
28
- };
@@ -1,17 +0,0 @@
1
- import { WidgetConfig, ComponentRegister } from './types';
2
- interface Props {
3
- components: ComponentRegister[];
4
- }
5
- declare const _default: import('vue').DefineComponent<Props, {
6
- getWidgetList: () => {
7
- [x: string]: any;
8
- field: string;
9
- type: string;
10
- label: string;
11
- }[];
12
- setWidgetList: (list: WidgetConfig[]) => void;
13
- clearDesigner: () => void;
14
- }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{}>, {
15
- components: ComponentRegister[];
16
- }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
17
- export default _default;
@@ -1,51 +0,0 @@
1
- /**
2
- * UForm 设计器组件注册表
3
- * 汇总各组件的设计器配置
4
- */
5
- export type { PropertyConfig, ComponentRegister } from './types';
6
- export declare function generateId(): string;
7
- export declare const componentMap: Record<string, string>;
8
- export declare const designerComponents: ({
9
- type: string;
10
- label: string;
11
- icon: string;
12
- component: string;
13
- properties: ({
14
- name: string;
15
- label: string;
16
- type: string;
17
- defaultValue: string;
18
- } | {
19
- name: string;
20
- label: string;
21
- type: string;
22
- defaultValue: boolean;
23
- })[];
24
- } | {
25
- type: string;
26
- label: string;
27
- icon: string;
28
- component: string;
29
- properties: ({
30
- name: string;
31
- label: string;
32
- type: string;
33
- defaultValue: string;
34
- options?: undefined;
35
- } | {
36
- name: string;
37
- label: string;
38
- type: string;
39
- options: {
40
- label: string;
41
- value: string;
42
- }[];
43
- defaultValue?: undefined;
44
- } | {
45
- name: string;
46
- label: string;
47
- type: string;
48
- defaultValue: boolean;
49
- options?: undefined;
50
- })[];
51
- })[];