feat:add control interface
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
export class Control {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
export class SelectControl {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
export class TextControl {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
export enum ControlType {
|
||||
TEXT = 'text',
|
||||
SELECT = 'select'
|
||||
}
|
||||
@@ -6,5 +6,6 @@ export enum ElementType {
|
||||
SUPERSCRIPT = 'superscript',
|
||||
SUBSCRIPT = 'subscript',
|
||||
SEPARATOR = 'separator',
|
||||
PAGE_BREAK = 'pageBreak'
|
||||
PAGE_BREAK = 'pageBreak',
|
||||
CONTROL = 'control'
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
import { ControlType } from '../dataset/enum/Control'
|
||||
|
||||
export interface IValueSet {
|
||||
value: string;
|
||||
code: string;
|
||||
}
|
||||
|
||||
export interface IControl {
|
||||
type: ControlType;
|
||||
value: string;
|
||||
conceptId: string;
|
||||
prefix?: string;
|
||||
postfix?: string;
|
||||
valueSets?: IValueSet[]
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
import { ElementType } from '../dataset/enum/Element'
|
||||
import { RowFlex } from '../dataset/enum/Row'
|
||||
import { IControl } from './Control'
|
||||
import { IColgroup } from './table/Colgroup'
|
||||
import { ITr } from './table/Tr'
|
||||
|
||||
@@ -57,6 +58,7 @@ export type IElement = IElementBasic
|
||||
& IHyperlinkElement
|
||||
& ISuperscriptSubscript
|
||||
& ISeparator
|
||||
& { control?: IControl }
|
||||
|
||||
export interface IElementMetrics {
|
||||
width: number;
|
||||
|
||||
Reference in New Issue
Block a user