@overmap-ai/core 1.0.36-misc-improvements.0 → 1.0.36-misc-improvements.2

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.
@@ -9,7 +9,6 @@ export declare const useFormikInput: <TField extends AnyField>(props: ComponentP
9
9
  readonly labelId: string;
10
10
  readonly label: string;
11
11
  readonly showInputOnly: boolean | undefined;
12
- readonly placeholder: string | undefined;
13
12
  readonly fieldProps: import("formik").FieldInputProps<ValueOfField<TField>>;
14
13
  readonly helpers: import("formik").FieldHelperProps<ValueOfField<TField>>;
15
14
  readonly field: TField;
@@ -38,6 +37,7 @@ export declare const useFormikInput: <TField extends AnyField>(props: ComponentP
38
37
  readonly hidden?: boolean | undefined;
39
38
  readonly lang?: string | undefined;
40
39
  readonly nonce?: string | undefined;
40
+ readonly placeholder?: string | undefined;
41
41
  readonly spellCheck?: (boolean | "true" | "false") | undefined;
42
42
  readonly tabIndex?: number | undefined;
43
43
  readonly translate?: "yes" | "no" | undefined;
@@ -6958,7 +6958,7 @@ const InputWithLabelAndHelpText = (props) => {
6958
6958
  return /* @__PURE__ */ jsx(InputWithHelpText, { ...restProps, children });
6959
6959
  };
6960
6960
  const useFormikInput = (props) => {
6961
- const { id, field, formId: formId2, size, showInputOnly, placeholder, ...rest } = props;
6961
+ const { id, field, formId: formId2, size, showInputOnly, ...rest } = props;
6962
6962
  const [fieldProps, meta, helpers] = useField(field.getId());
6963
6963
  const { touched } = meta;
6964
6964
  const helpText = meta.error ?? field.description;
@@ -6993,7 +6993,6 @@ const useFormikInput = (props) => {
6993
6993
  labelId,
6994
6994
  label,
6995
6995
  showInputOnly,
6996
- placeholder,
6997
6996
  fieldProps: fieldPropsWithValidation,
6998
6997
  helpers,
6999
6998
  field
@@ -8465,7 +8464,7 @@ const Tabs = Object.assign({}, {
8465
8464
  Content: TabsContent
8466
8465
  });
8467
8466
  const NumberInput = memo((props) => {
8468
- const [{ inputId, labelId, size, severity, showInputOnly, placeholder, field, fieldProps }, rest] = useFormikInput(props);
8467
+ const [{ inputId, labelId, size, severity, showInputOnly, field, fieldProps }, rest] = useFormikInput(props);
8469
8468
  let [{ helpText, label }] = useFormikInput(props);
8470
8469
  helpText = showInputOnly ? null : helpText;
8471
8470
  label = showInputOnly ? "" : label;
@@ -8486,7 +8485,7 @@ const NumberInput = memo((props) => {
8486
8485
  ...fieldProps,
8487
8486
  type: "number",
8488
8487
  id: inputId,
8489
- placeholder,
8488
+ placeholder: field.placeholder,
8490
8489
  min: field.minimum,
8491
8490
  max: field.maximum,
8492
8491
  step: field.integers ? 1 : 0.1,
@@ -8797,7 +8796,7 @@ const styles$5 = {
8797
8796
  TextFieldInputCopy
8798
8797
  };
8799
8798
  const StringInput = memo((props) => {
8800
- const [{ inputId, labelId, size, severity, showInputOnly, placeholder, field, fieldProps }, rest] = useFormikInput(props);
8799
+ const [{ inputId, labelId, size, severity, showInputOnly, field, fieldProps }, rest] = useFormikInput(props);
8801
8800
  let [{ helpText, label }] = useFormikInput(props);
8802
8801
  helpText = showInputOnly ? null : helpText;
8803
8802
  label = showInputOnly ? "" : label;
@@ -8818,7 +8817,7 @@ const StringInput = memo((props) => {
8818
8817
  ...fieldProps,
8819
8818
  type: field.inputType,
8820
8819
  id: inputId,
8821
- placeholder,
8820
+ placeholder: field.placeholder,
8822
8821
  color
8823
8822
  }
8824
8823
  ) : /* @__PURE__ */ jsxs(TextField$1.Root, { className: styles$5.clickableLinkContainer, children: [
@@ -8856,10 +8855,10 @@ const emptyStringField = {
8856
8855
  };
8857
8856
  const _StringField = class _StringField extends StringOrTextField {
8858
8857
  constructor(options) {
8859
- const { inputType = "text", ...rest } = options;
8858
+ const { inputType = "text", placeholder = "Enter a short description", ...rest } = options;
8860
8859
  const maxLength = options.maxLength ? Math.min(500, options.maxLength) : 500;
8861
8860
  const minLength = options.minLength ? Math.min(options.minLength, maxLength) : void 0;
8862
- super({ ...rest, maxLength, minLength, type: "string" });
8861
+ super({ ...rest, maxLength, minLength, placeholder, type: "string" });
8863
8862
  __publicField(this, "inputType");
8864
8863
  this.inputType = inputType;
8865
8864
  }
@@ -8881,7 +8880,7 @@ __publicField(_StringField, "fieldTypeDescription", "Short text fields can hold
8881
8880
  __publicField(_StringField, "Icon", InputIcon);
8882
8881
  let StringField = _StringField;
8883
8882
  const TextInput = memo((props) => {
8884
- const [{ inputId, labelId, size, severity, showInputOnly, placeholder, field, fieldProps }, rest] = useFormikInput(props);
8883
+ const [{ inputId, labelId, size, severity, showInputOnly, field, fieldProps }, rest] = useFormikInput(props);
8885
8884
  let [{ helpText, label }] = useFormikInput(props);
8886
8885
  helpText = showInputOnly ? null : helpText;
8887
8886
  label = showInputOnly ? "" : label;
@@ -8901,7 +8900,7 @@ const TextInput = memo((props) => {
8901
8900
  ...fieldProps,
8902
8901
  resize: "vertical",
8903
8902
  id: inputId,
8904
- placeholder,
8903
+ placeholder: field.placeholder,
8905
8904
  severity
8906
8905
  }
8907
8906
  )
@@ -8917,9 +8916,10 @@ const emptyTextField = {
8917
8916
  };
8918
8917
  const _TextField = class _TextField extends StringOrTextField {
8919
8918
  constructor(options) {
8919
+ const { placeholder = "Enter a description", ...rest } = options;
8920
8920
  const maxLength = options.maxLength ? Math.min(5e3, options.maxLength) : 5e3;
8921
8921
  const minLength = options.minLength ? Math.min(options.minLength, maxLength) : void 0;
8922
- super({ ...options, maxLength, minLength, type: "text" });
8922
+ super({ ...rest, maxLength, minLength, placeholder, type: "text" });
8923
8923
  }
8924
8924
  serialize() {
8925
8925
  return super._serialize();
@@ -8939,7 +8939,7 @@ __publicField(_TextField, "fieldTypeDescription", "Paragraph fields can hold up
8939
8939
  __publicField(_TextField, "Icon", RowsIcon);
8940
8940
  let TextField = _TextField;
8941
8941
  const SelectInput = memo((props) => {
8942
- const [{ inputId, labelId, size, severity, showInputOnly, placeholder, field, fieldProps }, rest] = useFormikInput(props);
8942
+ const [{ inputId, labelId, size, severity, showInputOnly, field, fieldProps }, rest] = useFormikInput(props);
8943
8943
  const { onChange, onBlur } = fieldProps;
8944
8944
  let [{ helpText, label }] = useFormikInput(props);
8945
8945
  helpText = showInputOnly ? null : helpText;
@@ -8970,7 +8970,7 @@ const SelectInput = memo((props) => {
8970
8970
  items: options,
8971
8971
  ...fieldProps,
8972
8972
  onValueChange: handleChange,
8973
- placeholder,
8973
+ placeholder: field.placeholder,
8974
8974
  id: inputId,
8975
8975
  severity,
8976
8976
  ...rest
@@ -9145,7 +9145,7 @@ const useFieldReordering = () => {
9145
9145
  return { reorderSection, reorderField };
9146
9146
  };
9147
9147
  const MultiStringInput = memo((props) => {
9148
- const [{ inputId, labelId, size, severity, showInputOnly, placeholder, field, fieldProps }, rest] = useFormikInput(props);
9148
+ const [{ inputId, labelId, size, severity, showInputOnly, field, fieldProps }, rest] = useFormikInput(props);
9149
9149
  let [{ helpText, label }] = useFormikInput(props);
9150
9150
  helpText = showInputOnly ? null : helpText;
9151
9151
  label = showInputOnly ? "" : label;
@@ -9237,7 +9237,7 @@ const MultiStringInput = memo((props) => {
9237
9237
  onChange: handleChange,
9238
9238
  onKeyDown: handleKeyDown,
9239
9239
  id: inputId,
9240
- placeholder,
9240
+ placeholder: field.placeholder,
9241
9241
  color: updatedColor,
9242
9242
  onBlur: void 0
9243
9243
  }
@@ -9450,7 +9450,7 @@ const parseValueToArray = (value) => {
9450
9450
  return [value];
9451
9451
  };
9452
9452
  const MultiSelectInput = memo((props) => {
9453
- const [{ inputId, labelId, size, severity, showInputOnly, placeholder, field, fieldProps }, rest] = useFormikInput(props);
9453
+ const [{ inputId, labelId, size, severity, showInputOnly, field, fieldProps }, rest] = useFormikInput(props);
9454
9454
  const { onChange, onBlur } = fieldProps;
9455
9455
  let [{ helpText, label }] = useFormikInput(props);
9456
9456
  helpText = showInputOnly ? null : helpText;
@@ -9479,7 +9479,7 @@ const MultiSelectInput = memo((props) => {
9479
9479
  onValueChange: handleChange,
9480
9480
  options: field.options,
9481
9481
  name: fieldProps.name,
9482
- placeholder,
9482
+ placeholder: field.placeholder,
9483
9483
  id: inputId,
9484
9484
  severity,
9485
9485
  ...rest