diff --git a/website/docs/api/composite-layers/flow-layer.zh.md b/website/docs/api/composite-layers/flow-layer.zh.md index 51843e24e..4b42cbf32 100644 --- a/website/docs/api/composite-layers/flow-layer.zh.md +++ b/website/docs/api/composite-layers/flow-layer.zh.md @@ -563,6 +563,69 @@ order: 4 } ``` +### state + +交互反馈。 + +#### `active` + +`boolean | FLowLayerActiveOptions` optional + +高亮交互 + +#### FLowLayerActiveOptions 配置如下: + +| 属性 | 描述 | 类型 | 默认值 | 是否必填 | +| ------------------ | ---------------------------- | ------------------------------------------ | ------- | -------- | +| enableCircleSpread | 是否自动高亮该其关联的客流线 | `boolean` | `false` | optional | +| enableLineSpread | 是否自动高亮该其关联的客流点 | `boolean` | `false` | optional | +| circleColor | 客流点颜色 | `string|PointLayerOptions['color'] ` | `-` | optional | +| circleStrokeColor | 客流点边框颜色 | `string|PointLayerStyleOptions['stroke']` | `-` | optional | +| lineColor | 客流线填充颜色 | `string|LineLayerOptions['color']` | `-` | optional | +| lineStroke | 客流线边框颜色 | `string|LineLayerStyleOptions['stroke']` | `-` | optional | + +```js +// 关闭高亮交互 +{ + state: { + active: false; + } +} +// 开启高亮交互 +{ + state:{ + active:{ + enableCircleSpread: true, + circleColor: '#2f54eb', + } + } +} +``` + +#### `select` + +`boolean | FLowLayerActiveOptions` optional + +选中交互 + +```js +// 关闭选中交互 +{ + state: { + active: false; + } +} +// 开启高亮交互 +{ + state:{ + active:{ + enableLineSpread: true, + lineColor: '#2f54eb', + } + } +} +``` + ## 二、属性 diff --git a/website/docs/common/composite-layers/composite-common/method.zh.md b/website/docs/common/composite-layers/composite-common/method.zh.md index 53a8240fe..23b85a7a4 100644 --- a/website/docs/common/composite-layers/composite-common/method.zh.md +++ b/website/docs/common/composite-layers/composite-common/method.zh.md @@ -118,62 +118,6 @@ layer.boxSelect(bounds: [number, number, number, number], callback: (...args: an layer.getLegend(name: string): ILegend; ``` -### state - -交互反馈。 - -#### `active` - -`boolean | FLowLayerActiveOptions` optional default: `false` -高亮交互 - -```js -{ - state: { - active: false; - } -} -``` - -```js -{ - state:{ - active:{ - enableCircleSpread: true, - enableLineSpread: true, - circleColor: '#2f54eb', - circleStrokeColor: '#2f54eb', - lineColor: '#2f54eb', - lineStroke: '#2f54eb'; - } - } -} -``` - -#### FLowLayerActiveOptions 配置如下: - -| 属性 | 描述 | 类型 | 默认值 | 是否必填 | -| ------------------ | ---------------------------- | ------------------------------------------ | ------- | -------- | -| enableCircleSpread | 是否自动高亮该其关联的客流线 | `boolean` | `false` | optional | -| enableLineSpread | 是否自动高亮该其关联的客流点 | `boolean` | `false` | optional | -| circleColor | 客流点颜色 | `string|PointLayerOptions['color'] ` | `-` | optional | -| circleStrokeColor | 客流点边框颜色 | `string|PointLayerStyleOptions['stroke']` | `-` | optional | -| lineColor | 客流线填充颜色 | `string|LineLayerOptions['color']` | `-` | optional | -| lineStroke | 客流线边框颜色 | `string|LineLayerStyleOptions['stroke']` | `-` | optional | - -#### `select` - -`boolean | FLowLayerActiveOptions` optional default: `false` -选中交互 - -```js -{ - state: { - select: false; - } -} -``` - ### getLegendItems 获取图例数据。