@archbase/components 3.0.0 → 3.0.3

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 (131) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +56 -0
  3. package/dist/buttons/ArchbaseActionButtons.d.ts +1 -1
  4. package/dist/charts/vis-timeline/ArchbaseVisTimeline.d.ts +1 -1
  5. package/dist/charts/vis-timeline/ArchbaseVisTimeline.types.d.ts +1 -1
  6. package/dist/charts/vis-timeline/utils/timelineOptions.d.ts +1 -1
  7. package/dist/datagrid/components/index.d.ts +2 -2
  8. package/dist/datagrid/components/pagination/grid-pagination.d.ts +1 -1
  9. package/dist/datagrid/components/toolbar/global-search-input.d.ts +1 -1
  10. package/dist/datagrid/components/toolbar/grid-toolbar.d.ts +1 -1
  11. package/dist/datagrid/hooks/use-grid-details-panel.d.ts +2 -2
  12. package/dist/datagrid/main/archbase-data-grid-pagination.d.ts +1 -1
  13. package/dist/datagrid/main/archbase-data-grid-toolbar.d.ts +1 -1
  14. package/dist/datagrid/main/archbase-data-grid-types.d.ts +28 -3
  15. package/dist/datagrid/main/archbase-data-grid-utils.d.ts +1 -1
  16. package/dist/datagrid/main/archbase-detail-panel-component.d.ts +1 -1
  17. package/dist/datagrid/main/archbase-expand-button.d.ts +1 -1
  18. package/dist/datagrid/main/archbase-grid-popover.d.ts +1 -1
  19. package/dist/datagrid/modals/print-data.d.ts +0 -1
  20. package/dist/editors/ArchbaseAsyncMultiSelect.d.ts +1 -1
  21. package/dist/editors/ArchbaseAsyncSelect.context.d.ts +1 -1
  22. package/dist/editors/ArchbaseAsyncSelect.d.ts +1 -5
  23. package/dist/editors/ArchbaseAvatarEdit.d.ts +2 -2
  24. package/dist/editors/ArchbaseCheckbox.d.ts +2 -3
  25. package/dist/editors/ArchbaseChip.d.ts +2 -3
  26. package/dist/editors/ArchbaseChipGroup.d.ts +1 -1
  27. package/dist/editors/ArchbaseDatePickerEdit.d.ts +3 -3
  28. package/dist/editors/ArchbaseDatePickerRange.d.ts +1 -2
  29. package/dist/editors/ArchbaseDateTimePickerEdit.d.ts +2 -3
  30. package/dist/editors/ArchbaseDateTimePickerRange.d.ts +2 -3
  31. package/dist/editors/ArchbaseEdit.d.ts +2 -7
  32. package/dist/editors/ArchbaseFileAttachment.d.ts +1 -1
  33. package/dist/editors/ArchbaseImageEdit.d.ts +2 -2
  34. package/dist/editors/ArchbaseJsonEdit.d.ts +2 -3
  35. package/dist/editors/ArchbaseLookupEdit.d.ts +2 -3
  36. package/dist/editors/ArchbaseLookupNumber.d.ts +2 -3
  37. package/dist/editors/ArchbaseMarkdownEdit.d.ts +1 -1
  38. package/dist/editors/ArchbaseMaskEdit.d.ts +3 -8
  39. package/dist/editors/ArchbaseNumberEdit.d.ts +1 -2
  40. package/dist/editors/ArchbasePasswordEdit.d.ts +2 -3
  41. package/dist/editors/ArchbaseRadioGroup.d.ts +2 -3
  42. package/dist/editors/ArchbaseRating.d.ts +1 -1
  43. package/dist/editors/ArchbaseRichTextEdit.d.ts +3 -3
  44. package/dist/editors/ArchbaseSelect.context.d.ts +1 -1
  45. package/dist/editors/ArchbaseSelect.d.ts +1 -1
  46. package/dist/editors/ArchbaseSwitch.d.ts +2 -3
  47. package/dist/editors/ArchbaseTextArea.d.ts +2 -3
  48. package/dist/editors/ArchbaseTimeEdit.d.ts +2 -3
  49. package/dist/editors/ArchbaseTimeRangeSelector.d.ts +1 -1
  50. package/dist/editors/ArchbaseTreeSelect.d.ts +1 -1
  51. package/dist/editors/index.d.ts +5 -5
  52. package/dist/filters/ArchbaseCompositeFilters.d.ts +1 -1
  53. package/dist/filters/ArchbaseCompositeFilters.types.d.ts +1 -1
  54. package/dist/filters/ArchbaseCompositeFilters.utils.d.ts +1 -1
  55. package/dist/filters/components/FilterPill.d.ts +1 -1
  56. package/dist/filters/hooks/useArchbaseFilterHistory.d.ts +1 -1
  57. package/dist/filters/hooks/useArchbaseFilterPresets.d.ts +1 -1
  58. package/dist/filters/hooks/useArchbaseFilters.d.ts +1 -1
  59. package/dist/filters/hooks/useArchbaseQuickFilters.d.ts +1 -1
  60. package/dist/hooks/useArchbaseListContext.d.ts +1 -1
  61. package/dist/hooks/useArchbaseNavigateParams.d.ts +2 -2
  62. package/dist/hooks/useArchbaseVisible.d.ts +1 -1
  63. package/dist/image/ArchbaseImage.d.ts +1 -1
  64. package/dist/image/editor/components/BasicFilters/BasicFilter.d.ts +1 -1
  65. package/dist/image/editor/components/CropprWrapper/ArchbaseCropperWrapper.d.ts +1 -2
  66. package/dist/image/editor/components/EditImage/ArchbaseEditImage.d.ts +1 -2
  67. package/dist/image/editor/components/Input/Input.d.ts +1 -1
  68. package/dist/image/editor/components/Tab/Tab.d.ts +1 -2
  69. package/dist/image/editor/functions/croppr/core.d.ts +1 -5
  70. package/dist/image/editor/functions/croppr/croppr.d.ts +1 -10
  71. package/dist/image/editor/functions/croppr/index.d.ts +1 -1
  72. package/dist/image/editor/index.d.ts +1 -2
  73. package/dist/index.d.ts +0 -3
  74. package/dist/index.js +5315 -5379
  75. package/dist/jsonschema/JsonSchemaEditor/ArchbaseJsonSchemaEditor.context.d.ts +1 -1
  76. package/dist/list/ArchbaseList.context.d.ts +1 -1
  77. package/dist/list/ArchbaseList.d.ts +1 -1
  78. package/dist/list/index.d.ts +1 -1
  79. package/dist/list/treeview/ArchbaseTreeView.d.ts +1 -1
  80. package/dist/list/treeview/ArchbaseTreeViewItem.d.ts +1 -1
  81. package/dist/list-view/ArchbaseListViewTable.d.ts +1 -1
  82. package/dist/markdown/ArchbaseMarkdown.d.ts +1 -1
  83. package/dist/markdown/ArchbaseMarkdown.types.d.ts +2 -2
  84. package/dist/markdown/components/CodeBlock.d.ts +2 -2
  85. package/dist/markdown/components/LinkRenderer.d.ts +1 -1
  86. package/dist/masonry/ArchbaseMasonry.context.d.ts +1 -1
  87. package/dist/masonry/ArchbaseMasonry.d.ts +1 -5
  88. package/dist/masonry/index.d.ts +1 -1
  89. package/dist/notification/ArchbaseAlert.d.ts +1 -5
  90. package/dist/onboarding/ArchbaseOnboardingTour.d.ts +1 -1
  91. package/dist/printer/ArchbaseThermalPrinter.d.ts +1 -1
  92. package/dist/printer/ArchbaseThermalPrinter.types.d.ts +1 -1
  93. package/dist/printer/utils/escpos.d.ts +1 -1
  94. package/dist/theme-editor/ArchbaseThemeEditor.d.ts +1 -1
  95. package/dist/theme-editor/ArchbaseThemeEditor.types.d.ts +2 -2
  96. package/dist/theme-editor/utils/themeExport.d.ts +2 -2
  97. package/dist/themes/ArchbaseThemeEditor.d.ts +2 -3
  98. package/dist/video/ArchbaseVideoPlayer.d.ts +1 -1
  99. package/dist/video/ArchbaseVideoPlayer.types.d.ts +1 -1
  100. package/dist/video/hooks/useVideoPlayer.d.ts +5 -5
  101. package/dist/viewers/ArchbasePDFViewer.annotations.d.ts +1 -1
  102. package/dist/viewers/ArchbasePDFViewer.d.ts +1 -1
  103. package/dist/viewers/ArchbasePDFViewer.toolbar.d.ts +1 -1
  104. package/dist/viewers/ArchbasePDFViewer.types.d.ts +2 -2
  105. package/dist/viewers/file-preview/ArchbaseFilePreviewer.d.ts +1 -1
  106. package/dist/viewers/file-preview/ArchbaseFilePreviewer.types.d.ts +1 -1
  107. package/dist/viewers/file-preview/utils/fileTypeDetector.d.ts +1 -1
  108. package/package.json +21 -21
  109. package/src/datagrid/main/archbase-data-grid-pagination.tsx +16 -5
  110. package/src/datagrid/main/archbase-data-grid-toolbar.tsx +15 -4
  111. package/src/datagrid/main/archbase-data-grid-types.tsx +32 -0
  112. package/src/datagrid/main/archbase-data-grid.tsx +64 -4
  113. package/src/index.ts +0 -1
  114. package/dist/archbase-components-3.0.0.tgz +0 -0
  115. package/dist/debug/index.d.ts +0 -4
  116. package/dist/debug/jsonpathpicker/ArchbaseJsonPathPicker.d.ts +0 -37
  117. package/dist/debug/jsonpathpicker/index.d.ts +0 -1
  118. package/dist/debug/jsonview/ArchbaseJsonViewDataRenderer.d.ts +0 -34
  119. package/dist/debug/jsonview/ArchbaseJsonViewDataTypeDetection.d.ts +0 -8
  120. package/dist/debug/jsonview/index.d.ts +0 -11
  121. package/dist/debug/objectinspector/ArchbaseDebugInspector.d.ts +0 -23
  122. package/dist/debug/objectinspector/ArchbaseFloatingWindow.d.ts +0 -24
  123. package/dist/debug/objectinspector/ArchbaseObjectInspector.d.ts +0 -6
  124. package/dist/debug/objectinspector/index.d.ts +0 -3
  125. package/dist/spreadsheet/ArchbaseSpreadsheetImport.d.ts +0 -4
  126. package/dist/spreadsheet/ArchbaseSpreadsheetImport.types.d.ts +0 -65
  127. package/dist/spreadsheet/index.d.ts +0 -2
  128. package/src/debug/jsonview/styles.module.css.d.ts +0 -4
  129. package/src/spreadsheet/ArchbaseSpreadsheetImport.tsx +0 -223
  130. package/src/spreadsheet/ArchbaseSpreadsheetImport.types.ts +0 -66
  131. package/src/spreadsheet/index.ts +0 -10
@@ -1,5 +1,5 @@
1
1
  import { SetNestedObjectValueOperation } from '@archbase/core';
2
- import React from 'react';
2
+ import { default as React } from 'react';
3
3
  export interface ArchbaseJsonSchemaEditorContextValue {
4
4
  handleChange?: (path: string, value: any, operation?: SetNestedObjectValueOperation) => void;
5
5
  }
@@ -1,4 +1,4 @@
1
- import React from 'react';
1
+ import { default as React } from 'react';
2
2
  import { IArchbaseDataSourceBase } from '@archbase/data';
3
3
  export interface ArchbaseListContextValue<T, ID> {
4
4
  /** Indica se a lista esta desabilitada */
@@ -1,4 +1,4 @@
1
- import React, { FocusEventHandler } from 'react';
1
+ import { default as React, FocusEventHandler } from 'react';
2
2
  import { IArchbaseDataSourceBase } from '@archbase/data';
3
3
  export interface ArchbaseListCustomItemProps<T, _ID> {
4
4
  /** Chave */
@@ -1,4 +1,4 @@
1
- import ArchbaseListContext from './ArchbaseList.context';
1
+ import { default as ArchbaseListContext } from './ArchbaseList.context';
2
2
  export { ArchbaseList } from './ArchbaseList';
3
3
  export type { ArchbaseListProps, ArchbaseListCustomItemProps } from './ArchbaseList';
4
4
  export { ArchbaseListItem } from './ArchbaseListItem';
@@ -1,4 +1,4 @@
1
- import React, { ReactNode } from 'react';
1
+ import { default as React, ReactNode } from 'react';
2
2
  import { ArchbaseTreeNode } from './ArchbaseTreeView.types';
3
3
  export interface ArchbaseTreeViewProps {
4
4
  id: string;
@@ -1,4 +1,4 @@
1
- import React, { ReactNode } from 'react';
1
+ import { default as React, ReactNode } from 'react';
2
2
  import { ArchbaseTreeNode, ArchbaseTreeViewOptions } from './ArchbaseTreeView.types';
3
3
  export interface ArchbaseTreeViewItemProps {
4
4
  id: string;
@@ -1,4 +1,4 @@
1
- import React, { ReactNode } from 'react';
1
+ import { default as React, ReactNode } from 'react';
2
2
  export interface ArchbaseListViewColumn<T = any> {
3
3
  /**
4
4
  * Identificador único da coluna (key)
@@ -1,4 +1,4 @@
1
- import type { ArchbaseMarkdownProps } from './ArchbaseMarkdown.types';
1
+ import { ArchbaseMarkdownProps } from './ArchbaseMarkdown.types';
2
2
  /**
3
3
  * Componente ArchbaseMarkdown - Renderização de Markdown em React
4
4
  *
@@ -1,5 +1,5 @@
1
- import type { CSSProperties, ReactNode, ElementType } from 'react';
2
- import type { PluggableList } from 'unified';
1
+ import { CSSProperties, ReactNode, ElementType } from 'react';
2
+ import { PluggableList } from 'unified';
3
3
  /**
4
4
  * Estilo de syntax highlighting para blocos de código
5
5
  */
@@ -1,5 +1,5 @@
1
- import type { ReactNode } from 'react';
2
- import type { CodeBlockProps } from '../ArchbaseMarkdown.types';
1
+ import { ReactNode } from 'react';
2
+ import { CodeBlockProps } from '../ArchbaseMarkdown.types';
3
3
  /**
4
4
  * Componente para renderização de blocos de código
5
5
  *
@@ -1,4 +1,4 @@
1
- import type { LinkRendererProps } from '../ArchbaseMarkdown.types';
1
+ import { LinkRendererProps } from '../ArchbaseMarkdown.types';
2
2
  /**
3
3
  * Renderizador de links para Markdown
4
4
  *
@@ -1,4 +1,4 @@
1
- import React from 'react';
1
+ import { default as React } from 'react';
2
2
  import { IArchbaseDataSourceBase } from '@archbase/data';
3
3
  export interface ArchbaseMasonryContextValue<T, ID> {
4
4
  /** Fonte de dados do masonry (V1 ou V2) */
@@ -1,8 +1,4 @@
1
- /**
2
- * ArchbaseMasonry — layout masonry responsivo com provider de contexto.
3
- * @status stable
4
- */
5
- import React, { ReactNode } from 'react';
1
+ import { default as React, ReactNode } from 'react';
6
2
  export interface ArchbaseMasonryCustomItemProps<T, _ID> {
7
3
  /** Chave */
8
4
  key: string;
@@ -1,4 +1,4 @@
1
- import ArchbaseMasonryContext, { ArchbaseMasonryProvider } from './ArchbaseMasonry.context';
1
+ import { default as ArchbaseMasonryContext, ArchbaseMasonryProvider } from './ArchbaseMasonry.context';
2
2
  export { ArchbaseMasonry, ArchbaseMasonryResponsive } from './ArchbaseMasonry';
3
3
  export type { ArchbaseMasonryCustomItemProps } from './ArchbaseMasonry';
4
4
  export type { ArchbaseMasonryContextValue } from './ArchbaseMasonry.context';
@@ -1,9 +1,5 @@
1
- /**
2
- * ArchbaseAlert — wrapper de alerta (Mantine Alert) para feedback rápido.
3
- * @status stable
4
- */
5
1
  import { AlertProps, AlertVariant, MantineColor } from '@mantine/core';
6
- import React from 'react';
2
+ import { default as React } from 'react';
7
3
  export interface ArchbaseAlertProps extends AlertProps {
8
4
  title?: React.ReactNode;
9
5
  variant?: AlertVariant | string;
@@ -1,5 +1,5 @@
1
1
  import { ReactNode } from 'react';
2
- import type { OnboardingTourStep } from '@gfazioli/mantine-onboarding-tour';
2
+ import { OnboardingTourStep } from '@gfazioli/mantine-onboarding-tour';
3
3
  export interface ArchbaseOnboardingTourStep {
4
4
  /**
5
5
  * ID único do step
@@ -1,4 +1,4 @@
1
- import type { ArchbaseThermalPrinterProps, ReceiptData } from './ArchbaseThermalPrinter.types';
1
+ import { ArchbaseThermalPrinterProps, ReceiptData } from './ArchbaseThermalPrinter.types';
2
2
  /**
3
3
  * Componente ArchbaseThermalPrinter - Impressão térmica ESC/POS
4
4
  *
@@ -1,4 +1,4 @@
1
- import type { CSSProperties, ReactNode } from 'react';
1
+ import { CSSProperties, ReactNode } from 'react';
2
2
  /**
3
3
  * Larguras de papel em mm
4
4
  */
@@ -1,4 +1,4 @@
1
- import type { PaperWidth, PrintDensity, CutMode, TextAlign, FontSize, BarStyle } from '../ArchbaseThermalPrinter.types';
1
+ import { PaperWidth, PrintDensity, CutMode, TextAlign, FontSize, BarStyle } from '../ArchbaseThermalPrinter.types';
2
2
  /**
3
3
  * Comandos ESC/POS básicos
4
4
  */
@@ -1,4 +1,4 @@
1
- import type { ArchbaseThemeEditorProps } from './ArchbaseThemeEditor.types';
1
+ import { ArchbaseThemeEditorProps } from './ArchbaseThemeEditor.types';
2
2
  /**
3
3
  * Componente ArchbaseThemeEditor - Editor de temas Mantine
4
4
  *
@@ -1,5 +1,5 @@
1
- import type { CSSProperties, ReactNode } from 'react';
2
- import type { MantineTheme } from '@mantine/core';
1
+ import { CSSProperties, ReactNode } from 'react';
2
+ import { MantineTheme } from '@mantine/core';
3
3
  /**
4
4
  * Formato de exportação do tema
5
5
  */
@@ -1,5 +1,5 @@
1
- import type { MantineTheme } from '@mantine/core';
2
- import type { ThemeExportFormat } from '../ArchbaseThemeEditor.types';
1
+ import { MantineTheme } from '@mantine/core';
2
+ import { ThemeExportFormat } from '../ArchbaseThemeEditor.types';
3
3
  /**
4
4
  * Presets de cores
5
5
  */
@@ -1,7 +1,6 @@
1
1
  import { MantineSize } from '@mantine/core';
2
- import type { CSSProperties, FocusEventHandler, ReactNode } from 'react';
3
- import React from 'react';
4
- import type { IArchbaseDataSourceBase } from '@archbase/data';
2
+ import { CSSProperties, FocusEventHandler, ReactNode, default as React } from 'react';
3
+ import { IArchbaseDataSourceBase } from '@archbase/data';
5
4
  export interface ArchbaseThemeEditorProps<T, ID> {
6
5
  /** Fonte de dados onde será atribuido o valor do edit (V1 ou V2) */
7
6
  dataSource?: IArchbaseDataSourceBase<T>;
@@ -1,4 +1,4 @@
1
- import type { ArchbaseVideoPlayerProps } from './ArchbaseVideoPlayer.types';
1
+ import { ArchbaseVideoPlayerProps } from './ArchbaseVideoPlayer.types';
2
2
  /**
3
3
  * Componente ArchbaseVideoPlayer - Player de vídeo completo
4
4
  *
@@ -1,4 +1,4 @@
1
- import type { CSSProperties, ReactNode } from 'react';
1
+ import { CSSProperties, ReactNode } from 'react';
2
2
  /**
3
3
  * Formatos de vídeo suportados
4
4
  */
@@ -1,4 +1,4 @@
1
- import type { VideoSource, PlayerState, BufferState, VideoQuality, TextTrack, AutoplayBehavior } from '../ArchbaseVideoPlayer.types';
1
+ import { VideoSource, PlayerState, BufferState, VideoQuality, TextTrack, AutoplayBehavior } from '../ArchbaseVideoPlayer.types';
2
2
  interface UseVideoPlayerOptions {
3
3
  src: VideoSource | VideoSource[];
4
4
  autoplay?: AutoplayBehavior;
@@ -15,8 +15,8 @@ interface UseVideoPlayerOptions {
15
15
  * Hook customizado para gerenciar estado e lógica do player de vídeo
16
16
  */
17
17
  export declare function useVideoPlayer({ src, autoplay, loop, muted, volume, startTime, qualities, textTracks, defaultSubtitles, preload, }: UseVideoPlayerOptions): {
18
- videoRef: import("react").RefObject<HTMLVideoElement>;
19
- containerRef: import("react").RefObject<HTMLDivElement>;
18
+ videoRef: import('react').RefObject<HTMLVideoElement>;
19
+ containerRef: import('react').RefObject<HTMLDivElement>;
20
20
  playerState: PlayerState;
21
21
  isPlaying: boolean;
22
22
  currentTime: number;
@@ -42,8 +42,8 @@ export declare function useVideoPlayer({ src, autoplay, loop, muted, volume, sta
42
42
  setPlaybackRate: (rate: number) => void;
43
43
  toggleFullscreen: () => void;
44
44
  togglePiP: () => void;
45
- setSelectedQuality: import("react").Dispatch<import("react").SetStateAction<string>>;
46
- setSubtitlesEnabled: import("react").Dispatch<import("react").SetStateAction<boolean>>;
45
+ setSelectedQuality: import('react').Dispatch<import('react').SetStateAction<string>>;
46
+ setSubtitlesEnabled: import('react').Dispatch<import('react').SetStateAction<boolean>>;
47
47
  handleLoadStart: () => void;
48
48
  handleLoadedMetadata: () => void;
49
49
  handleCanPlay: () => void;
@@ -1,4 +1,4 @@
1
- import type { PDFAnnotation } from './ArchbasePDFViewer.types';
1
+ import { PDFAnnotation } from './ArchbasePDFViewer.types';
2
2
  interface ArchbasePDFAnnotationsProps {
3
3
  annotations: PDFAnnotation[];
4
4
  onAnnotationAdd?: (annotation: PDFAnnotation) => void;
@@ -1,2 +1,2 @@
1
- import type { ArchbasePDFViewerProps } from './ArchbasePDFViewer.types';
1
+ import { ArchbasePDFViewerProps } from './ArchbasePDFViewer.types';
2
2
  export declare function ArchbasePDFViewer<T, ID>({ dataSource, dataField, file: fileProp, width, height, page: initialPage, scale: initialScale, rotation: initialRotation, toolbar, textLayer, renderMode, toolbarPosition, onPageChange, onZoomChange, onLoadSuccess, onLoadError, annotations, onAnnotationAdd, onAnnotationRemove, onAnnotationUpdate, enableAnnotations, showAnnotationsList, disabled, loading, error, style, className, }: ArchbasePDFViewerProps<T, ID>): import("react/jsx-runtime").JSX.Element;
@@ -1,4 +1,4 @@
1
- import type { PDFToolbarActions } from './ArchbasePDFViewer.types';
1
+ import { PDFToolbarActions } from './ArchbasePDFViewer.types';
2
2
  interface ArchbasePDFViewerToolbarProps {
3
3
  currentPage: number;
4
4
  totalPages: number;
@@ -1,5 +1,5 @@
1
- import type { CSSProperties, ReactNode } from 'react';
2
- import type { IArchbaseDataSourceBase } from '@archbase/data';
1
+ import { CSSProperties, ReactNode } from 'react';
2
+ import { IArchbaseDataSourceBase } from '@archbase/data';
3
3
  export type PDFSource = string | Uint8Array | {
4
4
  url: string;
5
5
  } | {
@@ -1,4 +1,4 @@
1
- import type { ArchbaseFilePreviewerProps } from './ArchbaseFilePreviewer.types';
1
+ import { ArchbaseFilePreviewerProps } from './ArchbaseFilePreviewer.types';
2
2
  /**
3
3
  * Componente ArchbaseFilePreviewer - Preview de múltiplos tipos de arquivo
4
4
  *
@@ -1,4 +1,4 @@
1
- import type { CSSProperties, ReactNode } from 'react';
1
+ import { CSSProperties, ReactNode } from 'react';
2
2
  /**
3
3
  * Tipos de arquivo suportados para preview
4
4
  */
@@ -1,4 +1,4 @@
1
- import type { FileType, FileSource } from '../ArchbaseFilePreviewer.types';
1
+ import { FileType, FileSource } from '../ArchbaseFilePreviewer.types';
2
2
  /**
3
3
  * Detecta o tipo de arquivo baseado na extensão
4
4
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@archbase/components",
3
- "version": "3.0.0",
3
+ "version": "3.0.3",
4
4
  "description": "UI Components for Archbase React v3 - Form editors, data visualization, and business components",
5
5
  "author": "Edson Martins <edsonmartins2005@gmail.com>",
6
6
  "license": "MIT",
@@ -34,10 +34,14 @@
34
34
  "@mantine/modals": "8.3.12",
35
35
  "@mantine/notifications": "8.3.12",
36
36
  "@tabler/icons-react": "^3.26.0",
37
- "react": "^18.3.0 || ^19.0.0",
38
- "react-dom": "^18.3.0 || ^19.0.0"
37
+ "react": "^18.3.0 || ^19.2.0",
38
+ "react-dom": "^18.3.0 || ^19.2.0"
39
39
  },
40
40
  "dependencies": {
41
+ "@archbase/core": "3.0.3",
42
+ "@archbase/data": "3.0.3",
43
+ "@archbase/layout": "3.0.3",
44
+ "@datou/react-vis-timeline": "^1.4.0",
41
45
  "@gfazioli/mantine-list-view-table": "^1.1.9",
42
46
  "@gfazioli/mantine-onboarding-tour": "^2.6.5",
43
47
  "@mui/x-data-grid": "^7.28.3",
@@ -71,6 +75,7 @@
71
75
  "jwt-decode": "^3.1.2",
72
76
  "libphonenumber-js": "^1.11.3",
73
77
  "lodash": "^4.17.21",
78
+ "markdown-it": "^14.1.0",
74
79
  "outlayer": "^2.1.1",
75
80
  "overlayscrollbars": "^2.8.3",
76
81
  "pdfjs-dist": "^4.0.379",
@@ -83,6 +88,7 @@
83
88
  "react-color": "^2.19.3",
84
89
  "react-date-object": "^2.1.8",
85
90
  "react-easy-crop": "^4.7.4",
91
+ "react-file-previewer": "^0.4.2",
86
92
  "react-final-form": "^6.5.9",
87
93
  "react-frame-component": "^5.2.7",
88
94
  "react-grid-system": "^8.2.0",
@@ -92,6 +98,8 @@
92
98
  "react-inspector": "^6.0.2",
93
99
  "react-intersection-observer": "^9.10.3",
94
100
  "react-konva": "^18.2.10",
101
+ "react-markdown": "^9.0.1",
102
+ "react-markdown-editor-lite": "^1.3.5",
95
103
  "react-masonry-component": "^6.3.0",
96
104
  "react-modal": "^3.16.1",
97
105
  "react-multi-date-picker": "4.1.2",
@@ -99,20 +107,13 @@
99
107
  "react-router": "^6.22.0",
100
108
  "react-router-dom": "^6.22.0",
101
109
  "react-speech-recognition": "^3.10.0",
102
- "react-spreadsheet-import": "^4.7.1",
110
+ "react-thermal-printer": "^0.22.0",
103
111
  "react-to-print": "^2.15.1",
104
112
  "react-use-audio-player": "^2.2.0",
105
113
  "react-video-js-player": "^1.1.1",
106
- "react-markdown": "^9.0.1",
107
- "remark-gfm": "^4.0.0",
108
- "rehype-raw": "^7.0.0",
109
114
  "rehype-external-links": "^3.0.0",
110
- "react-thermal-printer": "^0.22.0",
111
- "react-file-previewer": "^0.4.2",
112
- "react-markdown-editor-lite": "^1.3.5",
113
- "markdown-it": "^14.1.0",
114
- "@datou/react-vis-timeline": "^1.4.0",
115
- "vis-timeline": "^7.7.3",
115
+ "rehype-raw": "^7.0.0",
116
+ "remark-gfm": "^4.0.0",
116
117
  "suneditor": "^2.46.3",
117
118
  "suneditor-react": "^3.6.1",
118
119
  "use-debounce": "^10.0.1",
@@ -120,23 +121,22 @@
120
121
  "uuid": "^9.0.1",
121
122
  "validator": "^13.12.0",
122
123
  "video.js": "^8.10.0",
123
- "xlsx": "^0.18.5",
124
- "@archbase/core": "3.0.0",
125
- "@archbase/data": "3.0.0",
126
- "@archbase/layout": "3.0.0"
124
+ "vis-timeline": "^7.7.3",
125
+ "xlsx": "^0.18.5"
127
126
  },
128
127
  "devDependencies": {
129
128
  "@types/d3": "^7.4.3",
130
129
  "@types/lodash": "^4.17.13",
131
130
  "@types/node": "^22.16.1",
132
- "@types/react": "^19.0.4",
131
+ "@types/react": "^19.0.6",
133
132
  "@types/react-dom": "^19.0.2",
134
133
  "@vitejs/plugin-react": "^4.3.4",
135
- "react": "^19.0.0",
136
- "react-dom": "^19.0.0",
134
+ "react": "^19.2.3",
135
+ "react-dom": "^19.2.3",
137
136
  "sass-embedded": "^1.80.7",
138
137
  "typescript": "~5.7.2",
139
138
  "vite": "^6.0.3",
139
+ "vite-plugin-dts": "^4.5.4",
140
140
  "vitest": "^2.1.8"
141
141
  },
142
142
  "publishConfig": {
@@ -144,7 +144,7 @@
144
144
  },
145
145
  "scripts": {
146
146
  "dev": "NODE_OPTIONS=\"--max-old-space-size=16384\" vite build --watch",
147
- "build": "NODE_OPTIONS=\"--max-old-space-size=16384\" vite build && NODE_OPTIONS=\"--max-old-space-size=16384\" tsc --emitDeclarationOnly || true",
147
+ "build": "NODE_OPTIONS=\"--max-old-space-size=16384\" vite build",
148
148
  "test": "vitest run",
149
149
  "test:watch": "vitest",
150
150
  "test:coverage": "vitest run --coverage",
@@ -13,7 +13,11 @@ export const ArchbaseDataGridPagination = React.memo<ArchbaseDataGridPaginationP
13
13
  onPaginationModelChange,
14
14
  paginationLabels,
15
15
  bottomToolbarMinHeight,
16
- theme
16
+ theme,
17
+ // Props para controle de bordas e espaçamento
18
+ withBorder = true,
19
+ padding = '8px 12px',
20
+ borderRadius,
17
21
  }) => {
18
22
  // Garantir que totalRecords seja um número válido e finito
19
23
  const safeTotalRecords = Number.isFinite(totalRecords) && !isNaN(totalRecords) && totalRecords >= 0
@@ -28,14 +32,21 @@ export const ArchbaseDataGridPagination = React.memo<ArchbaseDataGridPaginationP
28
32
  Math.max(1, paginationModel.pageSize) : 10
29
33
  };
30
34
 
35
+ // Calcular o padding final
36
+ const finalPadding = typeof padding === 'number' ? `${padding}px` : padding;
37
+ // Calcular o border radius final
38
+ const finalBorderRadius = borderRadius !== undefined
39
+ ? (typeof borderRadius === 'number' ? `${borderRadius}px` : borderRadius)
40
+ : theme.radius.sm;
41
+
31
42
  return (
32
43
  <Paper
33
44
  style={{
34
45
  minHeight: bottomToolbarMinHeight || 'auto',
35
- padding: '8px 16px',
36
- borderTop: `1px solid ${theme.colors.gray[theme.colorScheme === 'dark' ? 8 : 3]}`,
37
- borderBottomLeftRadius: theme.radius.sm,
38
- borderBottomRightRadius: theme.radius.sm
46
+ padding: finalPadding,
47
+ borderTop: withBorder ? `1px solid ${theme.colors.gray[theme.colorScheme === 'dark' ? 8 : 3]}` : 'none',
48
+ borderBottomLeftRadius: finalBorderRadius,
49
+ borderBottomRightRadius: finalBorderRadius
39
50
  }}
40
51
  >
41
52
  <GridPagination
@@ -35,6 +35,10 @@ export const ArchbaseDataGridToolbar = React.memo<ArchbaseDataGridToolbarProps>(
35
35
  activeFilters,
36
36
  onFiltersChange,
37
37
  hideMuiFilters = false,
38
+ // Props para controle de bordas e espaçamento
39
+ withBorder = true,
40
+ padding = '8px 12px',
41
+ borderRadius,
38
42
  }) => {
39
43
  // Estado local para o filtro global para manter o valor entre re-renderizações
40
44
  const [globalFilterValue, setGlobalFilterValue] = useState(filterModel.quickFilterValues?.[0] || '');
@@ -83,15 +87,22 @@ export const ArchbaseDataGridToolbar = React.memo<ArchbaseDataGridToolbarProps>(
83
87
  if (!toolbarLeftContent && !enableGlobalFilter && !enableTopToolbarActions) {
84
88
  return null;
85
89
  }
90
+ // Calcular o padding final
91
+ const finalPadding = typeof padding === 'number' ? `${padding}px` : padding;
92
+ // Calcular o border radius final
93
+ const finalBorderRadius = borderRadius !== undefined
94
+ ? (typeof borderRadius === 'number' ? `${borderRadius}px` : borderRadius)
95
+ : theme.radius.sm;
96
+
86
97
  return (
87
98
  <Paper
88
99
  style={{
89
100
  display: 'flex',
90
101
  justifyContent: 'space-between',
91
- padding: '8px 16px',
92
- borderBottom: `1px solid ${theme.colors.gray[theme.colorScheme === 'dark' ? 8 : 3]}`,
93
- borderTopLeftRadius: theme.radius.sm,
94
- borderTopRightRadius: theme.radius.sm
102
+ padding: finalPadding,
103
+ borderBottom: withBorder ? `1px solid ${theme.colors.gray[theme.colorScheme === 'dark' ? 8 : 3]}` : 'none',
104
+ borderTopLeftRadius: finalBorderRadius,
105
+ borderTopRightRadius: finalBorderRadius
95
106
  }}
96
107
  >
97
108
  {/* Lado esquerdo da toolbar */}
@@ -42,6 +42,10 @@ export interface ArchbaseDataGridRef<T = any> {
42
42
  collapseRow: (rowId: GridRowId) => void;
43
43
  collapseAllRows: () => void;
44
44
  getExpandedRows: () => GridRowId[];
45
+ /**
46
+ * Obtém o modelo de filtro atual
47
+ */
48
+ getFilterModel: () => GridFilterModel;
45
49
  }
46
50
 
47
51
  // Props para o Toolbar
@@ -80,6 +84,14 @@ export interface ArchbaseDataGridToolbarProps {
80
84
  activeFilters?: ArchbaseActiveFilter[];
81
85
  onFiltersChange?: (filters: ArchbaseActiveFilter[], rsql?: string) => void;
82
86
  hideMuiFilters?: boolean;
87
+
88
+ // Props para controle de bordas e espaçamento
89
+ /** Exibir borda inferior da toolbar. Default: true */
90
+ withBorder?: boolean;
91
+ /** Padding da toolbar. Default: '8px 12px' */
92
+ padding?: string | number;
93
+ /** Border radius da toolbar. Default: theme.radius.sm */
94
+ borderRadius?: string | number;
83
95
  }
84
96
 
85
97
  // Props para o componente ArchbaseDataGridPagination
@@ -95,6 +107,14 @@ export interface ArchbaseDataGridPaginationProps {
95
107
  };
96
108
  bottomToolbarMinHeight?: string | number;
97
109
  theme: any;
110
+
111
+ // Props para controle de bordas e espaçamento
112
+ /** Exibir borda superior da paginação. Default: true */
113
+ withBorder?: boolean;
114
+ /** Padding da paginação. Default: '8px 12px' */
115
+ padding?: string | number;
116
+ /** Border radius da paginação. Default: theme.radius.sm */
117
+ borderRadius?: string | number;
98
118
  }
99
119
 
100
120
  /**
@@ -240,6 +260,16 @@ export interface ArchbaseDataGridProps<T extends object = any, ID = any> {
240
260
  columnAutoWidth?: boolean;
241
261
  rowHeight?: number;
242
262
 
263
+ // Propriedades de controle de bordas internas
264
+ /** Exibir borda inferior da toolbar. Default: true */
265
+ withToolbarBorder?: boolean;
266
+ /** Exibir borda superior da paginação. Default: true */
267
+ withPaginationBorder?: boolean;
268
+ /** Padding da toolbar. Default: '8px 12px' */
269
+ toolbarPadding?: string | number;
270
+ /** Padding da paginação. Default: '8px 12px' */
271
+ paginationPadding?: string | number;
272
+
243
273
  // Propriedades de exportação e impressão
244
274
  printTitle?: string;
245
275
  logoPrint?: string;
@@ -249,6 +279,7 @@ export interface ArchbaseDataGridProps<T extends object = any, ID = any> {
249
279
  // Propriedades de layout
250
280
  toolbarAlignment?: 'left' | 'right' | 'center';
251
281
  positionActionsColumn?: 'first' | 'last';
282
+ actionsColumnWidth?: number;
252
283
  toolbarLeftContent?: ReactNode;
253
284
  bottomToolbarMinHeight?: string | number;
254
285
 
@@ -263,6 +294,7 @@ export interface ArchbaseDataGridProps<T extends object = any, ID = any> {
263
294
  onCellDoubleClick?: (params: { id: any; columnName: string; rowData: T }) => void;
264
295
  onExport?: (callback: () => void) => void;
265
296
  onPrint?: (callback: () => void) => void;
297
+ onFilterModelChange?: (filterModel: any) => void;
266
298
 
267
299
  // Referência para o grid
268
300
  gridRef?: RefObject<ArchbaseDataGridRef<T>> | MutableRefObject<ArchbaseDataGridRef<T> | null>;