buildPreview method

Widget buildPreview({
  1. DividerProperties? properties,
  2. DividerNode? node,
  3. double? height,
  4. double? width,
  5. ValueChanged<bool>? onChanged,
  6. WidgetBuildSettings settings = const WidgetBuildSettings(debugLabel: 'buildPreview'),
})

Implementation

Widget buildPreview({
  DividerProperties? properties,
  DividerNode? node,
  double? height,
  double? width,
  ValueChanged<bool>? onChanged,
  WidgetBuildSettings settings =
      const WidgetBuildSettings(debugLabel: 'buildPreview'),
}) {
  final previewNode = DividerNode(
    properties: properties ?? node?.properties ?? DividerProperties(),
    id: '',
    name: 'Divider',
    basicBoxLocal: NodeBox(0, 0, width ?? 32, height ?? 32),
    retainedOuterBoxLocal: NodeBox(0, 0, width ?? 32, height ?? 32),
  );
  return PassiveDividerWidget(
    node: previewNode,
    onChanged: onChanged,
    settings: settings,
  );
}