pixelize-design-library 2.1.27 → 2.1.29

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,4 +1,4 @@
1
1
  import React from "react";
2
2
  import { ContactFormProps } from "./ContactFormProps";
3
- declare const ContactForm: ({ apiKey, customFields, getCustomValues, isDisabled, organizationId, customerId, buttonColorScheme }: ContactFormProps) => React.JSX.Element;
3
+ declare const ContactForm: ({ apiKey, customFields, getCustomValues, isDisabled, organizationId, customerId, buttonColorScheme, buttonSx, }: ContactFormProps) => React.JSX.Element;
4
4
  export default ContactForm;
@@ -82,7 +82,7 @@ var InputTextArea_1 = __importDefault(require("../InputTextArea/InputTextArea"))
82
82
  var Button_1 = __importDefault(require("../Button/Button"));
83
83
  var ContactForm = function (_a) {
84
84
  var _b;
85
- var apiKey = _a.apiKey, customFields = _a.customFields, getCustomValues = _a.getCustomValues, _c = _a.isDisabled, isDisabled = _c === void 0 ? false : _c, organizationId = _a.organizationId, customerId = _a.customerId, _d = _a.buttonColorScheme, buttonColorScheme = _d === void 0 ? "primary" : _d;
85
+ var apiKey = _a.apiKey, customFields = _a.customFields, getCustomValues = _a.getCustomValues, _c = _a.isDisabled, isDisabled = _c === void 0 ? false : _c, organizationId = _a.organizationId, customerId = _a.customerId, _d = _a.buttonColorScheme, buttonColorScheme = _d === void 0 ? "primary" : _d, buttonSx = _a.buttonSx;
86
86
  var colors = (0, useCustomTheme_1.useCustomTheme)().colors;
87
87
  var _e = (0, react_1.useState)({
88
88
  firstName: "",
@@ -211,8 +211,6 @@ var ContactForm = function (_a) {
211
211
  react_1.default.createElement(react_2.Text, { fontSize: "sm", mb: 1 }, "Enquiry"),
212
212
  react_1.default.createElement(react_2.Box, null,
213
213
  react_1.default.createElement(InputTextArea_1.default, { placeholder: "Enter your enquiry", rows: 4, width: "100%", value: formData.enquiry, onChange: function (e) { return handleChange("enquiry", e.target.value); } }))),
214
- react_1.default.createElement(Button_1.default, { type: "submit", isDisabled: isDisabled, colorScheme: buttonColorScheme, width: "full", sx: {
215
- mt: 2
216
- } }, "Send Message")))));
214
+ react_1.default.createElement(Button_1.default, { type: "submit", isDisabled: isDisabled, colorScheme: buttonColorScheme, width: "full", sx: buttonSx }, "Send Message")))));
217
215
  };
218
216
  exports.default = ContactForm;
@@ -1,3 +1,4 @@
1
+ import { SystemStyleObject } from "@chakra-ui/react";
1
2
  import { ReactNode } from "react";
2
3
  export interface ContactFormProps {
3
4
  apiKey?: string;
@@ -7,4 +8,5 @@ export interface ContactFormProps {
7
8
  customFields?: ReactNode;
8
9
  getCustomValues?: () => Record<string, any>;
9
10
  buttonColorScheme?: "primary" | "blue" | "cyan" | "gray" | "green" | "orange" | "pink" | "purple" | "red" | "teal" | "yellow" | "secondary" | "tertiary" | undefined;
11
+ buttonSx?: SystemStyleObject;
10
12
  }
@@ -32,7 +32,7 @@ var FormLabel_1 = require("../Common/FormLabel");
32
32
  var ErrorMessage_1 = __importDefault(require("../Common/ErrorMessage"));
33
33
  var HelperText_1 = __importDefault(require("../Common/HelperText"));
34
34
  function Select(_a) {
35
- var _b = _a.placeholder, placeholder = _b === void 0 ? "Select Option" : _b, _c = _a.size, size = _c === void 0 ? "md" : _c, _d = _a.variant, variant = _d === void 0 ? "outline" : _d, icon = _a.icon, onChange = _a.onChange, onBlur = _a.onBlur, onFocus = _a.onFocus, errorBorderColor = _a.errorBorderColor, isDisabled = _a.isDisabled, isReadOnly = _a.isReadOnly, _e = _a.isRequired, isRequired = _e === void 0 ? false : _e, _f = _a.value, value = _f === void 0 ? "" : _f, colorScheme = _a.colorScheme, label = _a.label, error = _a.error, errorMessage = _a.errorMessage, helperText = _a.helperText, _g = _a.options, options = _g === void 0 ? [] : _g, _h = _a.width, width = _h === void 0 ? 500 : _h, _j = _a.height, height = _j === void 0 ? "2.75rem" : _j, formControlStyle = _a.formControlStyle, _k = _a.isInformation, isInformation = _k === void 0 ? false : _k, informationMessage = _a.informationMessage, selectStyle = _a.selectStyle;
35
+ var _b = _a.placeholder, placeholder = _b === void 0 ? "Select Option" : _b, _c = _a.size, size = _c === void 0 ? "md" : _c, _d = _a.variant, variant = _d === void 0 ? "outline" : _d, icon = _a.icon, onChange = _a.onChange, onBlur = _a.onBlur, onFocus = _a.onFocus, errorBorderColor = _a.errorBorderColor, isDisabled = _a.isDisabled, isReadOnly = _a.isReadOnly, _e = _a.isRequired, isRequired = _e === void 0 ? false : _e, _f = _a.value, value = _f === void 0 ? "" : _f, colorScheme = _a.colorScheme, label = _a.label, error = _a.error, errorMessage = _a.errorMessage, helperText = _a.helperText, _g = _a.options, options = _g === void 0 ? [] : _g, _h = _a.width, width = _h === void 0 ? "31.25rem" : _h, _j = _a.height, height = _j === void 0 ? "2.75rem" : _j, formControlStyle = _a.formControlStyle, _k = _a.isInformation, isInformation = _k === void 0 ? false : _k, informationMessage = _a.informationMessage, selectStyle = _a.selectStyle;
36
36
  var getOptionsList = (0, react_1.useCallback)(function () {
37
37
  if (!options.length)
38
38
  return react_1.default.createElement("option", { value: "" }, "No Options");
@@ -38,6 +38,6 @@ var SelectPage = function () {
38
38
  react_1.default.createElement(Select_1.default, { options: [
39
39
  { id: 1, label: "magesssssss" },
40
40
  { id: 2, label: "sjdfg" },
41
- ], onChange: handleOnChange, value: selected })));
41
+ ], onChange: handleOnChange, value: selected, width: 200 })));
42
42
  };
43
43
  exports.default = SelectPage;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pixelize-design-library",
3
- "version": "2.1.27",
3
+ "version": "2.1.29",
4
4
  "private": false,
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",