@fluentui/react-charts 0.0.0-nightly-20251209-0407.1 → 0.0.0-nightly-20251211-0406.1

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.
Files changed (31) hide show
  1. package/CHANGELOG.md +13 -13
  2. package/dist/index.d.ts +26 -6
  3. package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.js +87 -49
  4. package/lib/components/CommonComponents/Annotations/ChartAnnotationLayer.js.map +1 -1
  5. package/lib/components/CommonComponents/CartesianChart.types.js.map +1 -1
  6. package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js +84 -158
  7. package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
  8. package/lib/components/GanttChart/GanttChart.js +1 -1
  9. package/lib/components/GanttChart/GanttChart.js.map +1 -1
  10. package/lib/components/LineChart/LineChart.js +60 -40
  11. package/lib/components/LineChart/LineChart.js.map +1 -1
  12. package/lib/components/ScatterChart/ScatterChart.js +6 -2
  13. package/lib/components/ScatterChart/ScatterChart.js.map +1 -1
  14. package/lib/types/ChartAnnotation.js.map +1 -1
  15. package/lib/utilities/utilities.js +18 -9
  16. package/lib/utilities/utilities.js.map +1 -1
  17. package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.js +87 -49
  18. package/lib-commonjs/components/CommonComponents/Annotations/ChartAnnotationLayer.js.map +1 -1
  19. package/lib-commonjs/components/CommonComponents/CartesianChart.types.js.map +1 -1
  20. package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js +84 -158
  21. package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
  22. package/lib-commonjs/components/GanttChart/GanttChart.js +1 -1
  23. package/lib-commonjs/components/GanttChart/GanttChart.js.map +1 -1
  24. package/lib-commonjs/components/LineChart/LineChart.js +60 -40
  25. package/lib-commonjs/components/LineChart/LineChart.js.map +1 -1
  26. package/lib-commonjs/components/ScatterChart/ScatterChart.js +6 -2
  27. package/lib-commonjs/components/ScatterChart/ScatterChart.js.map +1 -1
  28. package/lib-commonjs/types/ChartAnnotation.js.map +1 -1
  29. package/lib-commonjs/utilities/utilities.js +18 -9
  30. package/lib-commonjs/utilities/utilities.js.map +1 -1
  31. package/package.json +13 -13
@@ -377,62 +377,6 @@ const toFiniteNumber = (value)=>{
377
377
  const numeric = typeof value === 'number' ? value : Number(value);
378
378
  return Number.isFinite(numeric) ? numeric : undefined;
379
379
  };
380
- /**
381
- * Normalizes Plotly axis reference strings so equivalent aliases (e.g. `xaxis1`, `x1`) collapse to the base axis id.
382
- */ const normalizeAxisRef = (ref, axis)=>{
383
- if (!ref) {
384
- return axis;
385
- }
386
- const normalized = ref.toLowerCase();
387
- if (normalized === axis || normalized === `${axis}axis` || normalized === `${axis}axis1` || normalized === `${axis}1`) {
388
- return axis;
389
- }
390
- const match = normalized.match(/^([xy])(axis)?(\d+)$/);
391
- if (match && match[1] === axis && match[3]) {
392
- return match[3] === '1' ? axis : `${axis}${match[3]}`;
393
- }
394
- return normalized;
395
- };
396
- /**
397
- * Scans the data traces bound to a given axis and returns the numeric min/max values plotted on that axis.
398
- */ const getAxisNumericRangeFromData = (axis, ref, layout, data)=>{
399
- if (!data || data.length === 0) {
400
- return undefined;
401
- }
402
- const axisLayout = getAxisLayoutByRef(layout, ref, axis);
403
- const targetRef = normalizeAxisRef(ref, axis);
404
- const traceAxisKey = axis === 'x' ? 'xaxis' : 'yaxis';
405
- let minValue;
406
- let maxValue;
407
- data.forEach((trace)=>{
408
- const plotTrace = trace;
409
- const traceAxisRef = normalizeAxisRef(plotTrace[traceAxisKey], axis);
410
- if (traceAxisRef !== targetRef) {
411
- return;
412
- }
413
- const values = axis === 'x' ? plotTrace.x : plotTrace.y;
414
- if (!(0, _chartutilities.isArrayOrTypedArray)(values)) {
415
- return;
416
- }
417
- const arrayLike = values;
418
- for(let index = 0; index < arrayLike.length; index++){
419
- const value = arrayLike[index];
420
- const numeric = toNumericValue(convertDataValue(value, axisLayout));
421
- if (numeric === undefined || Number.isNaN(numeric)) {
422
- continue;
423
- }
424
- minValue = minValue === undefined ? numeric : Math.min(minValue, numeric);
425
- maxValue = maxValue === undefined ? numeric : Math.max(maxValue, numeric);
426
- }
427
- });
428
- if (minValue === undefined || maxValue === undefined || minValue === maxValue) {
429
- return undefined;
430
- }
431
- return [
432
- minValue,
433
- maxValue
434
- ];
435
- };
436
380
  /**
437
381
  * Converts Plotly's bottom-origin relative Y coordinate into the SVG top-origin space used by our overlay.
438
382
  */ const transformRelativeYForChart = (value)=>{
@@ -533,49 +477,32 @@ const appendPx = (value)=>{
533
477
  if (value === undefined || value === null) {
534
478
  return undefined;
535
479
  }
536
- if ((axisLayout === null || axisLayout === void 0 ? void 0 : axisLayout.type) === 'date' || (0, _chartutilities.isDate)(value)) {
480
+ const axisType = axisLayout === null || axisLayout === void 0 ? void 0 : axisLayout.type;
481
+ if (axisType === 'date') {
537
482
  const dateValue = value instanceof Date ? value : new Date(value);
538
483
  return Number.isNaN(dateValue.getTime()) ? undefined : dateValue;
539
484
  }
540
- if (typeof value === 'number') {
541
- return value;
542
- }
543
- if ((axisLayout === null || axisLayout === void 0 ? void 0 : axisLayout.type) === 'linear' || (axisLayout === null || axisLayout === void 0 ? void 0 : axisLayout.type) === 'log') {
544
- const numeric = Number(value);
545
- return Number.isFinite(numeric) ? numeric : undefined;
546
- }
547
485
  if (value instanceof Date) {
548
- return value;
549
- }
550
- return value;
551
- };
552
- const toNumericValue = (value)=>{
553
- if (value instanceof Date) {
554
- const timestamp = value.getTime();
555
- return Number.isFinite(timestamp) ? timestamp : undefined;
486
+ return Number.isNaN(value.getTime()) ? undefined : value;
556
487
  }
557
488
  if (typeof value === 'number') {
558
489
  return Number.isFinite(value) ? value : undefined;
559
490
  }
560
- if (typeof value === 'string') {
491
+ if (axisType === 'linear' || axisType === 'log') {
561
492
  const numeric = Number(value);
562
493
  return Number.isFinite(numeric) ? numeric : undefined;
563
494
  }
564
- return undefined;
565
- };
566
- const toRelativeCoordinate = (value, axisLayout, fallbackRange)=>{
567
- const range = Array.isArray(axisLayout === null || axisLayout === void 0 ? void 0 : axisLayout.range) ? axisLayout.range : undefined;
568
- let start = range && range.length >= 2 ? toNumericValue(convertDataValue(range[0], axisLayout)) : undefined;
569
- let end = range && range.length >= 2 ? toNumericValue(convertDataValue(range[1], axisLayout)) : undefined;
570
- if ((start === undefined || end === undefined || start === end) && fallbackRange) {
571
- [start, end] = fallbackRange;
572
- }
573
- const current = toNumericValue(convertDataValue(value, axisLayout));
574
- if (start === undefined || end === undefined || current === undefined || start === end) {
575
- return undefined;
495
+ if (typeof value === 'string') {
496
+ const shouldTryParseDate = axisType === undefined || axisType === '-' || axisType === null;
497
+ if (shouldTryParseDate && (0, _chartutilities.isDate)(value)) {
498
+ const parsedDate = new Date(value);
499
+ if (!Number.isNaN(parsedDate.getTime()) && parsedDate.getFullYear() >= 1900) {
500
+ return parsedDate;
501
+ }
502
+ }
503
+ return value;
576
504
  }
577
- const relative = (current - start) / (end - start);
578
- return Number.isFinite(relative) ? relative : undefined;
505
+ return value;
579
506
  };
580
507
  const createAnnotationId = (text, index)=>{
581
508
  const normalized = text.replace(/\s+/g, ' ').trim();
@@ -640,10 +567,35 @@ const mapArrowDashToPattern = (value)=>{
640
567
  return value;
641
568
  }
642
569
  };
570
+ const mapRefTypeToCoordinateType = (refType)=>{
571
+ return refType === 'axis' ? 'data' : refType;
572
+ };
573
+ const normalizeCoordinateValueForType = (coordinateType, value)=>{
574
+ if (coordinateType === 'data') {
575
+ return value;
576
+ }
577
+ return typeof value === 'number' && Number.isFinite(value) ? value : undefined;
578
+ };
579
+ const getAnnotationCoordinateValue = (axis, refType, annotation, layout)=>{
580
+ if (refType === 'axis') {
581
+ const axisRef = axis === 'x' ? annotation === null || annotation === void 0 ? void 0 : annotation.xref : annotation === null || annotation === void 0 ? void 0 : annotation.yref;
582
+ const axisLayout = getAxisLayoutByRef(layout, axisRef, axis);
583
+ const rawValue = axis === 'x' ? annotation === null || annotation === void 0 ? void 0 : annotation.x : annotation === null || annotation === void 0 ? void 0 : annotation.y;
584
+ return convertDataValue(rawValue, axisLayout);
585
+ }
586
+ const numericValue = toFiniteNumber(axis === 'x' ? annotation === null || annotation === void 0 ? void 0 : annotation.x : annotation === null || annotation === void 0 ? void 0 : annotation.y);
587
+ if (numericValue === undefined) {
588
+ return undefined;
589
+ }
590
+ if (refType === 'relative') {
591
+ return axis === 'y' ? transformRelativeYForChart(numericValue) : numericValue;
592
+ }
593
+ return numericValue;
594
+ };
643
595
  /**
644
596
  * Converts a Plotly annotation definition into the internal `ChartAnnotation` format, translating coordinates,
645
597
  * layout alignment, styling, and connector metadata while skipping unsupported configurations.
646
- */ const convertPlotlyAnnotation = (annotation, layout, data, index)=>{
598
+ */ const convertPlotlyAnnotation = (annotation, layout, index)=>{
647
599
  if (!annotation || annotation.visible === false) {
648
600
  return undefined;
649
601
  }
@@ -652,77 +604,51 @@ const mapArrowDashToPattern = (value)=>{
652
604
  if (!xRefType || !yRefType) {
653
605
  return undefined;
654
606
  }
607
+ const xValue = getAnnotationCoordinateValue('x', xRefType, annotation, layout);
608
+ const yValue = getAnnotationCoordinateValue('y', yRefType, annotation, layout);
609
+ if (xValue === undefined || yValue === undefined) {
610
+ return undefined;
611
+ }
612
+ const xCoordinateType = mapRefTypeToCoordinateType(xRefType);
613
+ const yCoordinateType = mapRefTypeToCoordinateType(yRefType);
614
+ const normalizedX = normalizeCoordinateValueForType(xCoordinateType, xValue);
615
+ const normalizedY = normalizeCoordinateValueForType(yCoordinateType, yValue);
616
+ if (normalizedX === undefined || normalizedY === undefined) {
617
+ return undefined;
618
+ }
619
+ const yRefNormalized = typeof annotation.yref === 'string' ? annotation.yref.toLowerCase() : undefined;
620
+ const yAxisProps = yCoordinateType === 'data' && yRefNormalized === 'y2' ? {
621
+ yAxis: 'secondary'
622
+ } : undefined;
655
623
  let coordinates;
656
- if (xRefType === 'axis' && yRefType === 'axis') {
657
- const xAxisLayout = getAxisLayoutByRef(layout, annotation.xref, 'x');
658
- const yAxisLayout = getAxisLayoutByRef(layout, annotation.yref, 'y');
659
- const xValue = convertDataValue(annotation.x, xAxisLayout);
660
- const yValue = convertDataValue(annotation.y, yAxisLayout);
661
- if (xValue === undefined || yValue === undefined) {
662
- return undefined;
663
- }
664
- const yRefNormalized = typeof annotation.yref === 'string' ? annotation.yref.toLowerCase() : undefined;
624
+ if (xCoordinateType === 'data' && yCoordinateType === 'data') {
665
625
  coordinates = {
666
626
  type: 'data',
667
- x: xValue,
668
- y: yValue,
669
- ...yRefNormalized === 'y2' ? {
670
- yAxis: 'secondary'
671
- } : {}
627
+ x: normalizedX,
628
+ y: normalizedY,
629
+ ...yAxisProps !== null && yAxisProps !== void 0 ? yAxisProps : {}
672
630
  };
673
- } else if (xRefType === 'relative' && yRefType === 'relative') {
674
- const xValue = toFiniteNumber(annotation.x);
675
- const yValue = toFiniteNumber(annotation.y);
676
- const chartRelativeY = transformRelativeYForChart(yValue);
677
- if (xValue === undefined || chartRelativeY === undefined) {
678
- return undefined;
679
- }
631
+ } else if (xCoordinateType === 'relative' && yCoordinateType === 'relative') {
680
632
  coordinates = {
681
633
  type: 'relative',
682
- x: xValue,
683
- y: chartRelativeY
634
+ x: normalizedX,
635
+ y: normalizedY
684
636
  };
685
- } else if (xRefType === 'relative' && yRefType === 'axis') {
686
- const xValue = toFiniteNumber(annotation.x);
687
- const yAxisLayout = getAxisLayoutByRef(layout, annotation.yref, 'y');
688
- const yFallbackRange = getAxisNumericRangeFromData('y', annotation.yref, layout, data);
689
- const yRelative = toRelativeCoordinate(annotation.y, yAxisLayout, yFallbackRange);
690
- const chartRelativeY = transformRelativeYForChart(yRelative);
691
- if (xValue === undefined || chartRelativeY === undefined) {
692
- return undefined;
693
- }
694
- coordinates = {
695
- type: 'relative',
696
- x: xValue,
697
- y: chartRelativeY
698
- };
699
- } else if (xRefType === 'axis' && yRefType === 'relative') {
700
- const yValue = toFiniteNumber(annotation.y);
701
- const xAxisLayout = getAxisLayoutByRef(layout, annotation.xref, 'x');
702
- const xFallbackRange = getAxisNumericRangeFromData('x', annotation.xref, layout, data);
703
- const xRelative = toRelativeCoordinate(annotation.x, xAxisLayout, xFallbackRange);
704
- const chartRelativeY = transformRelativeYForChart(yValue);
705
- if (xRelative === undefined || chartRelativeY === undefined) {
706
- return undefined;
707
- }
708
- coordinates = {
709
- type: 'relative',
710
- x: xRelative,
711
- y: chartRelativeY
712
- };
713
- } else if (xRefType === 'pixel' && yRefType === 'pixel') {
714
- const xValue = toFiniteNumber(annotation.x);
715
- const yValue = toFiniteNumber(annotation.y);
716
- if (xValue === undefined || yValue === undefined) {
717
- return undefined;
718
- }
637
+ } else if (xCoordinateType === 'pixel' && yCoordinateType === 'pixel') {
719
638
  coordinates = {
720
639
  type: 'pixel',
721
- x: xValue,
722
- y: yValue
640
+ x: normalizedX,
641
+ y: normalizedY
723
642
  };
724
643
  } else {
725
- return undefined;
644
+ coordinates = {
645
+ type: 'mixed',
646
+ xCoordinateType,
647
+ yCoordinateType,
648
+ x: normalizedX,
649
+ y: normalizedY,
650
+ ...yAxisProps !== null && yAxisProps !== void 0 ? yAxisProps : {}
651
+ };
726
652
  }
727
653
  const textValue = annotation.text;
728
654
  const rawText = textValue === undefined || textValue === null ? '' : String(textValue);
@@ -879,14 +805,14 @@ const mapArrowDashToPattern = (value)=>{
879
805
  }
880
806
  return chartAnnotation;
881
807
  };
882
- const getChartAnnotationsFromLayout = (layout, data, isMultiPlot)=>{
808
+ const getChartAnnotationsFromLayout = (layout, isMultiPlot)=>{
883
809
  if (isMultiPlot || !(layout === null || layout === void 0 ? void 0 : layout.annotations)) {
884
810
  return undefined;
885
811
  }
886
812
  const annotationsArray = Array.isArray(layout.annotations) ? layout.annotations : [
887
813
  layout.annotations
888
814
  ];
889
- const converted = annotationsArray.map((annotation, index)=>convertPlotlyAnnotation(annotation, layout, data, index)).filter((annotation)=>annotation !== undefined);
815
+ const converted = annotationsArray.map((annotation, index)=>convertPlotlyAnnotation(annotation, layout, index)).filter((annotation)=>annotation !== undefined);
890
816
  return converted.length > 0 ? converted : undefined;
891
817
  };
892
818
  const normalizeObjectArrayForGVBC = (data, xLabels)=>{
@@ -963,7 +889,7 @@ const normalizeObjectArrayForGVBC = (data, xLabels)=>{
963
889
  const transformPlotlyJsonToAnnotationChartProps = (input, isMultiPlot, _colorMap, _colorwayType, _isDarkTheme)=>{
964
890
  var _layoutWithMeta_meta, _input_layout, _input_layout1, _input_layout2, _input_layout3, _input_layout_font, _input_layout4, _input_layout_font1, _input_layout5, _input_layout6;
965
891
  var _getChartAnnotationsFromLayout;
966
- const annotations = (_getChartAnnotationsFromLayout = getChartAnnotationsFromLayout(input.layout, input.data, isMultiPlot)) !== null && _getChartAnnotationsFromLayout !== void 0 ? _getChartAnnotationsFromLayout : [];
892
+ const annotations = (_getChartAnnotationsFromLayout = getChartAnnotationsFromLayout(input.layout, isMultiPlot)) !== null && _getChartAnnotationsFromLayout !== void 0 ? _getChartAnnotationsFromLayout : [];
967
893
  const titles = getTitles(input.layout);
968
894
  const layoutTitle = titles.chartTitle || undefined;
969
895
  const layoutWithMeta = input.layout;
@@ -1219,7 +1145,7 @@ const transformPlotlyJsonToVSBCProps = (input, isMultiPlot, colorMap, colorwayTy
1219
1145
  }
1220
1146
  });
1221
1147
  const vsbcData = Object.values(mapXToDataPoints);
1222
- const annotations = getChartAnnotationsFromLayout(input.layout, input.data, isMultiPlot);
1148
+ const annotations = getChartAnnotationsFromLayout(input.layout, isMultiPlot);
1223
1149
  var _input_layout_height;
1224
1150
  return {
1225
1151
  data: vsbcData,
@@ -1356,7 +1282,7 @@ const transformPlotlyJsonToGVBCProps = (input, isMultiPlot, colorMap, colorwayTy
1356
1282
  });
1357
1283
  }
1358
1284
  });
1359
- const annotations = getChartAnnotationsFromLayout(processedInput.layout, processedInput.data, isMultiPlot);
1285
+ const annotations = getChartAnnotationsFromLayout(processedInput.layout, isMultiPlot);
1360
1286
  var _processedInput_layout_height;
1361
1287
  return {
1362
1288
  dataV2: gvbcDataV2,
@@ -1446,7 +1372,7 @@ const transformPlotlyJsonToVBCProps = (input, isMultiPlot, colorMap, colorwayTyp
1446
1372
  });
1447
1373
  });
1448
1374
  });
1449
- const annotations = getChartAnnotationsFromLayout(input.layout, input.data, isMultiPlot);
1375
+ const annotations = getChartAnnotationsFromLayout(input.layout, isMultiPlot);
1450
1376
  var _input_layout_height;
1451
1377
  return {
1452
1378
  data: vbcData,
@@ -1668,7 +1594,7 @@ const transformPlotlyJsonToScatterTraceProps = (input, isMultiPlot, chartType, c
1668
1594
  ...lineShape
1669
1595
  ]
1670
1596
  };
1671
- const annotations = getChartAnnotationsFromLayout(input.layout, input.data, isMultiPlot);
1597
+ const annotations = getChartAnnotationsFromLayout(input.layout, isMultiPlot);
1672
1598
  var _input_layout_height;
1673
1599
  const commonProps = {
1674
1600
  supportNegativeData: true,
@@ -1797,14 +1723,14 @@ const transformPlotlyJsonToGanttChartProps = (input, isMultiPlot, colorMap, colo
1797
1723
  // extract colors for each series only once
1798
1724
  const extractedColors = (0, _PlotlyColorAdapter.extractColor)((_input_layout = input.layout) === null || _input_layout === void 0 ? void 0 : (_input_layout_template = _input_layout.template) === null || _input_layout_template === void 0 ? void 0 : (_input_layout_template_layout = _input_layout_template.layout) === null || _input_layout_template_layout === void 0 ? void 0 : _input_layout_template_layout.colorway, colorwayType, (_series_marker = series.marker) === null || _series_marker === void 0 ? void 0 : _series_marker.color, colorMap, isDarkTheme);
1799
1725
  series.y.forEach((yVal, i)=>{
1800
- var _series_marker, _series_marker1, _series_marker_color, _series_marker2, _input_layout_template_layout, _input_layout_template, _input_layout, _series_base, _series_x;
1726
+ var _series_marker, _series_marker1, _series_marker_color, _series_marker2, _input_layout_template_layout, _input_layout_template, _input_layout, _series_x;
1801
1727
  if ((0, _chartutilities.isInvalidValue)(yVal)) {
1802
1728
  return;
1803
1729
  }
1804
1730
  // resolve color for each legend's bars from the colorscale or extracted colors
1805
1731
  const color = colorScale ? colorScale((0, _chartutilities.isArrayOrTypedArray)((_series_marker = series.marker) === null || _series_marker === void 0 ? void 0 : _series_marker.color) ? (_series_marker2 = series.marker) === null || _series_marker2 === void 0 ? void 0 : (_series_marker_color = _series_marker2.color) === null || _series_marker_color === void 0 ? void 0 : _series_marker_color[i % ((_series_marker1 = series.marker) === null || _series_marker1 === void 0 ? void 0 : _series_marker1.color).length] : 0) : (0, _PlotlyColorAdapter.resolveColor)(extractedColors, i, legend, colorMap, (_input_layout = input.layout) === null || _input_layout === void 0 ? void 0 : (_input_layout_template = _input_layout.template) === null || _input_layout_template === void 0 ? void 0 : (_input_layout_template_layout = _input_layout_template.layout) === null || _input_layout_template_layout === void 0 ? void 0 : _input_layout_template_layout.colorway, isDarkTheme);
1806
1732
  const opacity = (0, _PlotlyColorAdapter.getOpacity)(series, i);
1807
- const base = +resolveGanttXValue((_series_base = series.base) === null || _series_base === void 0 ? void 0 : _series_base[i]);
1733
+ const base = +resolveGanttXValue((0, _chartutilities.isArrayOrTypedArray)(series.base) ? series.base[i] : series.base);
1808
1734
  const xVal = +resolveGanttXValue((_series_x = series.x) === null || _series_x === void 0 ? void 0 : _series_x[i]);
1809
1735
  var _rgb_copy_formatHex8;
1810
1736
  ganttData.push({
@@ -3015,7 +2941,7 @@ const getGridProperties = (schema, isMultiPlot, validTracesInfo)=>{
3015
2941
  }
3016
2942
  const isValidArray = (0, _chartutilities.isArrayOrTypedArray)(ax === null || ax === void 0 ? void 0 : ax.categoryarray) && ax.categoryarray.length > 0;
3017
2943
  if (isValidArray && (!(ax === null || ax === void 0 ? void 0 : ax.categoryorder) || ax.categoryorder === 'array')) {
3018
- result[propName] = ax.categoryarray;
2944
+ result[propName] = (ax === null || ax === void 0 ? void 0 : ax.autorange) === 'reversed' ? ax.categoryarray.slice().reverse() : ax.categoryarray;
3019
2945
  return;
3020
2946
  }
3021
2947
  if (!(ax === null || ax === void 0 ? void 0 : ax.categoryorder) || ax.categoryorder === 'trace' || ax.categoryorder === 'array') {