@react-querybuilder/antd 4.2.5 → 4.4.0

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.
@@ -1,6 +1,9 @@
1
- /// <reference types="react" />
2
- import type { ActionProps } from 'react-querybuilder';
1
+ import { Button } from 'antd';
2
+ import { ComponentPropsWithoutRef } from 'react';
3
+ import type { ActionWithRulesProps } from 'react-querybuilder';
4
+ declare type AntDActionProps = ActionWithRulesProps & ComponentPropsWithoutRef<typeof Button>;
3
5
  export declare const AntDActionElement: {
4
- ({ className, handleOnClick, label, title, disabled, disabledTranslation, }: ActionProps): JSX.Element;
6
+ ({ className, handleOnClick, label, title, disabled, disabledTranslation, testID: _testID, rules: _rules, level: _level, path: _path, context: _context, validation: _validation, ...extraProps }: AntDActionProps): JSX.Element;
5
7
  displayName: string;
6
8
  };
9
+ export {};
@@ -1,3 +1,6 @@
1
- /// <reference types="react" />
1
+ import { HolderOutlined } from '@ant-design/icons';
2
+ import { type ComponentPropsWithRef } from 'react';
2
3
  import type { DragHandleProps } from 'react-querybuilder';
3
- export declare const AntDDragHandle: import("react").ForwardRefExoticComponent<DragHandleProps & import("react").RefAttributes<HTMLSpanElement>>;
4
+ declare type AntDDragHandleProps = DragHandleProps & ComponentPropsWithRef<typeof HolderOutlined>;
5
+ export declare const AntDDragHandle: import("react").ForwardRefExoticComponent<Pick<AntDDragHandleProps, "id" | "value" | "name" | "defaultValue" | "placeholder" | "cite" | "data" | "dir" | "form" | "slot" | "span" | "style" | "summary" | "pattern" | "type" | "list" | "checked" | "multiple" | "children" | "onClick" | "color" | "hidden" | "onChange" | "prefix" | "size" | "controls" | "key" | "download" | "href" | "hrefLang" | "media" | "rel" | "target" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "draggable" | "lang" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "step" | "shape" | "default" | "max" | "required" | "high" | "low" | "height" | "width" | "start" | "open" | "content" | "rotate" | "acceptCharset" | "action" | "method" | "noValidate" | "nonce" | "async" | "manifest" | "wrap" | "src" | "accept" | "allowFullScreen" | "allowTransparency" | "alt" | "as" | "autoComplete" | "autoPlay" | "capture" | "cellPadding" | "cellSpacing" | "charSet" | "challenge" | "classID" | "cols" | "colSpan" | "coords" | "crossOrigin" | "dateTime" | "defer" | "encType" | "frameBorder" | "headers" | "htmlFor" | "httpEquiv" | "integrity" | "keyParams" | "keyType" | "kind" | "loop" | "marginHeight" | "marginWidth" | "maxLength" | "mediaGroup" | "min" | "minLength" | "muted" | "optimum" | "playsInline" | "poster" | "preload" | "readOnly" | "reversed" | "rows" | "rowSpan" | "sandbox" | "scope" | "scoped" | "scrolling" | "seamless" | "selected" | "sizes" | "srcDoc" | "srcLang" | "srcSet" | "useMap" | "wmode" | "spin" | "twoToneColor" | keyof DragHandleProps> & import("react").RefAttributes<HTMLSpanElement>>;
6
+ export {};
@@ -1,6 +1,9 @@
1
- /// <reference types="react" />
1
+ import { Switch } from 'antd';
2
+ import type { ComponentPropsWithoutRef } from 'react';
2
3
  import type { NotToggleProps } from 'react-querybuilder';
4
+ declare type AntDNotToggleProps = NotToggleProps & ComponentPropsWithoutRef<typeof Switch>;
3
5
  export declare const AntDNotToggle: {
4
- ({ className, handleOnChange, label, checked, title, disabled, }: NotToggleProps): JSX.Element;
6
+ ({ className, handleOnChange, label, checked, title, disabled, path: _path, context: _context, validation: _validation, testID: _testID, ...extraProps }: AntDNotToggleProps): JSX.Element;
5
7
  displayName: string;
6
8
  };
9
+ export {};
@@ -1,6 +1,6 @@
1
1
  /// <reference types="react" />
2
2
  import type { ValueEditorProps } from 'react-querybuilder';
3
3
  export declare const AntDValueEditor: {
4
- ({ fieldData, operator, value, handleOnChange, title, className, type, inputType, values, disabled, ...props }: ValueEditorProps): JSX.Element | null;
4
+ ({ fieldData, operator, value, handleOnChange, title, className, type, inputType, values, valueSource: _vs, disabled, ...props }: ValueEditorProps): JSX.Element | null;
5
5
  displayName: string;
6
6
  };
@@ -1,6 +1,9 @@
1
- /// <reference types="react" />
2
- import type { ValueSelectorProps } from 'react-querybuilder';
1
+ import { Select } from 'antd';
2
+ import { type ComponentPropsWithoutRef } from 'react';
3
+ import type { VersatileSelectorProps } from 'react-querybuilder';
4
+ declare type AntDValueSelectorProps = VersatileSelectorProps & Omit<ComponentPropsWithoutRef<typeof Select>, 'onChange' | 'defaultValue'>;
3
5
  export declare const AntDValueSelector: {
4
- ({ className, handleOnChange, options, value, title, disabled, multiple, }: ValueSelectorProps): JSX.Element;
6
+ ({ className, handleOnChange, options, value, title, disabled, multiple, testID: _testID, rules: _rules, level: _level, path: _path, context: _context, validation: _validation, operator: _operator, field: _field, fieldData: _fieldData, ...extraProps }: AntDValueSelectorProps): JSX.Element;
5
7
  displayName: string;
6
8
  };
9
+ export {};
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
- import type { Field, NameLabelPair, OptionGroup } from 'react-querybuilder';
3
- export declare const isOptionGroupArray: (arr: Field['values']) => arr is OptionGroup<NameLabelPair>[];
4
- export declare const toOptions: (arr?: NameLabelPair[] | OptionGroup<NameLabelPair>[] | undefined) => JSX.Element[] | null;
2
+ import { isOptionGroupArray, type NameLabelPair, type OptionGroup } from 'react-querybuilder';
3
+ export { isOptionGroupArray };
4
+ export declare const toOptions: (arr?: NameLabelPair[] | OptionGroup[]) => JSX.Element[] | null;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@react-querybuilder/antd",
3
3
  "description": "Custom Ant Design components for react-querybuilder",
4
- "version": "4.2.5",
4
+ "version": "4.4.0",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -19,16 +19,18 @@
19
19
  "license": "MIT",
20
20
  "homepage": "https://react-querybuilder.js.org/",
21
21
  "scripts": {
22
+ "start": "vite",
22
23
  "build": "vite build && tsc --emitDeclarationOnly",
23
24
  "type-check": "tsc --noEmit",
24
25
  "type-check:watch": "yarn type-check --watch"
25
26
  },
26
27
  "devDependencies": {
27
28
  "@ant-design/icons": "^4.7.0",
28
- "@types/react": "^17.0.0",
29
+ "@types/react": "^18.0.0",
30
+ "@vitejs/plugin-react": "^1.3.0",
29
31
  "antd": "^4.17.3",
30
- "react": "^17.0.1",
31
- "react-querybuilder": "^4.2.5",
32
+ "react": "^18.1.0",
33
+ "react-querybuilder": "^4.4.0",
32
34
  "typescript": "^4.5.0"
33
35
  },
34
36
  "peerDependencies": {
@@ -37,5 +39,5 @@
37
39
  "react": ">=16.8.0",
38
40
  "react-querybuilder": ">=4"
39
41
  },
40
- "gitHead": "5b1471d08454d1a5cefb666ceea6cc468ffc32e1"
42
+ "gitHead": "3f95f2782b129276b14231546fafee35b465bd08"
41
43
  }