@hubspot/ui-extensions 0.8.14 → 0.8.17

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.
@@ -256,3 +256,18 @@ export declare const StepperInput: "StepperInput" & {
256
256
  readonly props?: types.StepperInputProps | undefined;
257
257
  readonly children?: true | undefined;
258
258
  } & import("@remote-ui/react").ReactComponentTypeFromRemoteComponentType<import("@remote-ui/types").RemoteComponentType<"StepperInput", types.StepperInputProps, true>>;
259
+ export declare const Modal: "Modal" & {
260
+ readonly type?: "Modal" | undefined;
261
+ readonly props?: types.ModalProps | undefined;
262
+ readonly children?: true | undefined;
263
+ } & import("@remote-ui/react").ReactComponentTypeFromRemoteComponentType<import("@remote-ui/types").RemoteComponentType<"Modal", types.ModalProps, true>>;
264
+ export declare const ModalBody: "ModalBody" & {
265
+ readonly type?: "ModalBody" | undefined;
266
+ readonly props?: types.ModalBodyProps | undefined;
267
+ readonly children?: true | undefined;
268
+ } & import("@remote-ui/react").ReactComponentTypeFromRemoteComponentType<import("@remote-ui/types").RemoteComponentType<"ModalBody", types.ModalBodyProps, true>>;
269
+ export declare const ModalFooter: "ModalFooter" & {
270
+ readonly type?: "ModalFooter" | undefined;
271
+ readonly props?: types.ModalFooterProps | undefined;
272
+ readonly children?: true | undefined;
273
+ } & import("@remote-ui/react").ReactComponentTypeFromRemoteComponentType<import("@remote-ui/types").RemoteComponentType<"ModalFooter", types.ModalFooterProps, true>>;
@@ -54,3 +54,6 @@ export const PanelFooter = createRemoteReactComponent('PanelFooter');
54
54
  export const PanelBody = createRemoteReactComponent('PanelBody');
55
55
  export const PanelSection = createRemoteReactComponent('PanelSection');
56
56
  export const StepperInput = createRemoteReactComponent('StepperInput');
57
+ export const Modal = createRemoteReactComponent('Modal');
58
+ export const ModalBody = createRemoteReactComponent('ModalBody');
59
+ export const ModalFooter = createRemoteReactComponent('ModalFooter');
package/dist/types.d.ts CHANGED
@@ -870,10 +870,12 @@ export interface CheckboxProps {
870
870
  * The current status of the input.
871
871
  */
872
872
  checked?: boolean;
873
+ /** @deprecated use readOnly instead */
874
+ readonly?: boolean;
873
875
  /**
874
876
  * When set to `true`, the option cannot be selected.
875
877
  */
876
- readonly?: boolean;
878
+ readOnly?: boolean;
877
879
  /**
878
880
  * The string that displays below the toggle.
879
881
  */
@@ -1545,9 +1547,13 @@ export interface ExampleCrmComponentProps {
1545
1547
  /** @ignore */
1546
1548
  export type PanelAction = (panelId: string) => void;
1547
1549
  /** @ignore */
1550
+ export type ModalAction = (modalId: string) => void;
1551
+ /** @ignore */
1548
1552
  export interface Reactions {
1549
1553
  openPanel: PanelAction;
1550
1554
  closePanel: PanelAction;
1555
+ openModal: ModalAction;
1556
+ closeModal: ModalAction;
1551
1557
  }
1552
1558
  /** @ignore */
1553
1559
  export interface ExtensionPointApi<ExtensionPointName extends keyof ExtensionPoints> {
@@ -2035,6 +2041,64 @@ export interface PanelSectionProps {
2035
2041
  */
2036
2042
  children: React.ReactNode;
2037
2043
  }
2044
+ export interface ModalProps {
2045
+ /**
2046
+ * Accessibility label.
2047
+ *
2048
+ */
2049
+ 'aria-label'?: string;
2050
+ /**
2051
+ * The main content of the modal when it opens.
2052
+ *
2053
+ */
2054
+ children?: React.ReactNode;
2055
+ /**
2056
+ * A unique ID for the modal
2057
+ *
2058
+ */
2059
+ id: string;
2060
+ /**
2061
+ * A function that will be invoked when the modal has finished opening.
2062
+ *
2063
+ */
2064
+ onOpen?: () => void;
2065
+ /**
2066
+ * A function that will be invoked when the modal has finished closing.
2067
+ *
2068
+ */
2069
+ onClose?: () => void;
2070
+ /**
2071
+ * The width of the modal
2072
+ *
2073
+ * @defaultValue `"sm"`
2074
+ */
2075
+ width?: TShirtSizes['sm'] | TShirtSizes['md'] | TShirtSizes['lg'];
2076
+ /**
2077
+ * The title of the modal
2078
+ *
2079
+ */
2080
+ title?: string;
2081
+ /**
2082
+ * The variant of the modal
2083
+ *
2084
+ * @defaultValue `"default"`
2085
+ */
2086
+ variant?: 'danger' | 'default';
2087
+ }
2088
+ export interface ModalBodyProps {
2089
+ /**
2090
+ * The main content of the modal
2091
+ *
2092
+ */
2093
+ children: React.ReactNode;
2094
+ }
2095
+ export interface ModalFooterProps {
2096
+ /**
2097
+ * The footer of the modal
2098
+ *
2099
+ */
2100
+ children: React.ReactNode;
2101
+ }
2038
2102
  export interface PanelBodyProps {
2039
2103
  /**
2040
2104
  * The main content of the body
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hubspot/ui-extensions",
3
- "version": "0.8.14",
3
+ "version": "0.8.17",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -14,7 +14,7 @@
14
14
  "test": "echo 'No tests configured for @hubspot/ui-extensions'"
15
15
  },
16
16
  "files": [
17
- "dist/**/*"
17
+ "dist"
18
18
  ],
19
19
  "publishConfig": {
20
20
  "access": "public"
@@ -51,5 +51,5 @@
51
51
  "devDependencies": {
52
52
  "typescript": "5.0.4"
53
53
  },
54
- "gitHead": "1850d1e7967463bfec84fddaa9d5b167a76b55a7"
54
+ "gitHead": "c056fcf4f48454c6f4cd7986fd1f5b5f619d1605"
55
55
  }