Skip to content

Commit

Permalink
feat(fe-definition-config): 完善各滤镜节点类型定义-如in设为hidden、设置部分属性为number
Browse files Browse the repository at this point in the history
  • Loading branch information
gogoend committed Nov 6, 2022
1 parent 52daf1f commit 54cb6c8
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ export const feTurbulence: SVGFilterConfig.Node = {
]
},
baseFrequency: {
defaultValue: '0.05'
type: 'number',
defaultValue: 0.05
},
numOctaves: {
type: 'number',
Expand All @@ -84,10 +85,18 @@ export const feTurbulence: SVGFilterConfig.Node = {
export const feDropShadow: SVGFilterConfig.Node = {
type: 'normal',
ports: {
in: {},
dx: {},
dy: {},
stdDeviation: {},
in: {
type: 'hidden'
},
dx: {
type: 'number'
},
dy: {
type: 'number'
},
stdDeviation: {
type: 'number'
},
seed: {},
'flood-color': {},
'flood-opacity': {}
Expand All @@ -98,25 +107,31 @@ export const feMerge: SVGFilterConfig.Node = {
type: 'merge',
ports: {
in: {
type: 'text'
type: 'hidden'
}
}
}

export const feOffset: SVGFilterConfig.Node = {
type: 'normal',
ports: {
in: {},
dx: {},
dy: {}
in: {
type: 'hidden'
},
dx: {
type: 'number'
},
dy: {
type: 'number'
}
}
}

export const feColorMatrix: SVGFilterConfig.Node = {
type: 'normal',
ports: {
in: {

type: 'hidden'
},
type: {
type: 'text',
Expand All @@ -137,15 +152,21 @@ export const feColorMatrix: SVGFilterConfig.Node = {
export const feTile: SVGFilterConfig.Node = {
type: 'normal',
ports: {
in: {}
in: {
type: 'hidden'
}
}
}

export const feDisplacementMap: SVGFilterConfig.Node = {
type: 'normal',
ports: {
in: {},
in2: {},
in: {
type: 'hidden'
},
in2: {
type: 'hidden'
},
scale: {},
xChannelSelector: {},
yChannelSelector: {}
Expand All @@ -162,8 +183,12 @@ export const feImage: SVGFilterConfig.Node = {
export const feBlend: SVGFilterConfig.Node = {
type: 'normal',
ports: {
in: {},
in2: {},
in: {
type: 'hidden'
},
in2: {
type: 'hidden'
},
mode: {
defaultValue: 'normal',
enum: [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export namespace SVGFilterConfig {
type: 'merge';
ports: {
in: {
type: 'text'
type: 'hidden'
}
}
}
Expand Down

0 comments on commit 54cb6c8

Please sign in to comment.