@publicplan/kern-react-kit 1.3.3 → 1.3.4

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.
package/dist/index.d.cts CHANGED
@@ -622,13 +622,15 @@ type CommonProps = {
622
622
  children?: React$1.ReactNode;
623
623
  className?: string;
624
624
  };
625
- type ButtonAsButton = CommonProps & Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, 'type' | 'className'> & {
625
+ type ButtonAsButton = CommonProps & Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, 'className'> & {
626
+ type: 'button' | 'submit' | 'reset';
626
627
  as?: 'button';
627
628
  href?: never;
628
629
  target?: never;
629
630
  };
630
631
  type ButtonAsAnchor = CommonProps & Omit<React$1.AnchorHTMLAttributes<HTMLAnchorElement>, 'type' | 'className'> & {
631
632
  as: 'a';
633
+ type?: never;
632
634
  href: string;
633
635
  target?: '_self' | '_blank';
634
636
  disabled?: boolean;
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as react_jsx_runtime0 from "react/jsx-runtime";
2
- import * as react11 from "react";
2
+ import * as react13 from "react";
3
3
  import React$1 from "react";
4
4
 
5
5
  //#region src/components/Accordion/Content.d.ts
@@ -271,13 +271,13 @@ declare const GridRow: React$1.FC<GridRowProps>;
271
271
  interface CheckboxInputProps$1 extends Omit<React.ComponentPropsWithoutRef<'input'>, 'type' | 'aria-describedby'> {
272
272
  erroneous?: boolean;
273
273
  }
274
- declare const CheckboxInput$1: react11.ForwardRefExoticComponent<CheckboxInputProps$1 & react11.RefAttributes<HTMLInputElement>>;
274
+ declare const CheckboxInput$1: react13.ForwardRefExoticComponent<CheckboxInputProps$1 & react13.RefAttributes<HTMLInputElement>>;
275
275
  //#endregion
276
276
  //#region src/components/Input/Primitives/Email/EmailInput.d.ts
277
277
  interface EmailInputProps$1 extends Omit<React.ComponentPropsWithoutRef<'input'>, 'type'> {
278
278
  erroneous?: boolean;
279
279
  }
280
- declare const EmailInput$1: react11.ForwardRefExoticComponent<EmailInputProps$1 & react11.RefAttributes<HTMLInputElement>>;
280
+ declare const EmailInput$1: react13.ForwardRefExoticComponent<EmailInputProps$1 & react13.RefAttributes<HTMLInputElement>>;
281
281
  //#endregion
282
282
  //#region src/components/Input/Primitives/Error.d.ts
283
283
  interface InputErrorProps extends Omit<React.ComponentPropsWithoutRef<'p'>, 'role'> {
@@ -297,7 +297,7 @@ interface FileInputProps$1 extends Omit<React.ComponentPropsWithoutRef<'input'>,
297
297
  supportedFormats?: (FileExtension | MimeType)[];
298
298
  erroneous?: boolean;
299
299
  }
300
- declare const FileInput$1: react11.ForwardRefExoticComponent<FileInputProps$1 & react11.RefAttributes<HTMLInputElement>>;
300
+ declare const FileInput$1: react13.ForwardRefExoticComponent<FileInputProps$1 & react13.RefAttributes<HTMLInputElement>>;
301
301
  //#endregion
302
302
  //#region src/components/Input/Primitives/Hint.d.ts
303
303
  interface HintProps extends React.ComponentPropsWithoutRef<'p'> {
@@ -333,13 +333,13 @@ declare const Label$1: ({
333
333
  interface PasswordInputProps$1 extends Omit<React.ComponentPropsWithoutRef<'input'>, 'type'> {
334
334
  erroneous?: boolean;
335
335
  }
336
- declare const PasswordInput$1: react11.ForwardRefExoticComponent<PasswordInputProps$1 & react11.RefAttributes<HTMLInputElement>>;
336
+ declare const PasswordInput$1: react13.ForwardRefExoticComponent<PasswordInputProps$1 & react13.RefAttributes<HTMLInputElement>>;
337
337
  //#endregion
338
338
  //#region src/components/Input/Primitives/Radio/RadioInput.d.ts
339
339
  interface RadioInputProps$1 extends Omit<React.ComponentPropsWithoutRef<'input'>, 'type' | 'aria-describedby'> {
340
340
  erroneous?: boolean;
341
341
  }
342
- declare const RadioInput$1: react11.ForwardRefExoticComponent<RadioInputProps$1 & react11.RefAttributes<HTMLInputElement>>;
342
+ declare const RadioInput$1: react13.ForwardRefExoticComponent<RadioInputProps$1 & react13.RefAttributes<HTMLInputElement>>;
343
343
  //#endregion
344
344
  //#region src/components/Input/Primitives/Root.d.ts
345
345
  interface RootProps extends React.HTMLAttributes<HTMLDivElement> {
@@ -360,31 +360,31 @@ interface SelectInputProps$1 extends React.ComponentPropsWithoutRef<'select'> {
360
360
  label: string;
361
361
  }>;
362
362
  }
363
- declare const SelectInput$1: react11.ForwardRefExoticComponent<SelectInputProps$1 & react11.RefAttributes<HTMLSelectElement>>;
363
+ declare const SelectInput$1: react13.ForwardRefExoticComponent<SelectInputProps$1 & react13.RefAttributes<HTMLSelectElement>>;
364
364
  //#endregion
365
365
  //#region src/components/Input/Primitives/Tel/TelInput.d.ts
366
366
  interface TelInputProps$1 extends Omit<React.ComponentPropsWithoutRef<'input'>, 'type' | 'autoComplete'> {
367
367
  erroneous?: boolean;
368
368
  }
369
- declare const TelInput$1: react11.ForwardRefExoticComponent<TelInputProps$1 & react11.RefAttributes<HTMLInputElement>>;
369
+ declare const TelInput$1: react13.ForwardRefExoticComponent<TelInputProps$1 & react13.RefAttributes<HTMLInputElement>>;
370
370
  //#endregion
371
371
  //#region src/components/Input/Primitives/Text/TextInput.d.ts
372
372
  interface TextInputProps$1 extends Omit<React.ComponentPropsWithoutRef<'input'>, 'type'> {
373
373
  erroneous?: boolean;
374
374
  }
375
- declare const TextInput$1: react11.ForwardRefExoticComponent<TextInputProps$1 & react11.RefAttributes<HTMLInputElement>>;
375
+ declare const TextInput$1: react13.ForwardRefExoticComponent<TextInputProps$1 & react13.RefAttributes<HTMLInputElement>>;
376
376
  //#endregion
377
377
  //#region src/components/Input/Primitives/Textarea/TextareaInput.d.ts
378
378
  interface TextareaInputProps$1 extends React.ComponentPropsWithoutRef<'textarea'> {
379
379
  erroneous?: boolean;
380
380
  }
381
- declare const TextareaInput$1: react11.ForwardRefExoticComponent<TextareaInputProps$1 & react11.RefAttributes<HTMLTextAreaElement>>;
381
+ declare const TextareaInput$1: react13.ForwardRefExoticComponent<TextareaInputProps$1 & react13.RefAttributes<HTMLTextAreaElement>>;
382
382
  //#endregion
383
383
  //#region src/components/Input/Primitives/Url/UrlInput.d.ts
384
384
  interface UrlInputProps$1 extends Omit<React.ComponentPropsWithoutRef<'input'>, 'type'> {
385
385
  erroneous?: boolean;
386
386
  }
387
- declare const UrlInput$1: react11.ForwardRefExoticComponent<UrlInputProps$1 & react11.RefAttributes<HTMLInputElement>>;
387
+ declare const UrlInput$1: react13.ForwardRefExoticComponent<UrlInputProps$1 & react13.RefAttributes<HTMLInputElement>>;
388
388
  //#endregion
389
389
  //#region src/components/Lists/Root.d.ts
390
390
  interface ListsRootProps extends Omit<React.ComponentPropsWithoutRef<'ol' | 'ul'>, 'type'> {
@@ -620,13 +620,15 @@ type CommonProps = {
620
620
  children?: React$1.ReactNode;
621
621
  className?: string;
622
622
  };
623
- type ButtonAsButton = CommonProps & Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, 'type' | 'className'> & {
623
+ type ButtonAsButton = CommonProps & Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, 'className'> & {
624
+ type: 'button' | 'submit' | 'reset';
624
625
  as?: 'button';
625
626
  href?: never;
626
627
  target?: never;
627
628
  };
628
629
  type ButtonAsAnchor = CommonProps & Omit<React$1.AnchorHTMLAttributes<HTMLAnchorElement>, 'type' | 'className'> & {
629
630
  as: 'a';
631
+ type?: never;
630
632
  href: string;
631
633
  target?: '_self' | '_blank';
632
634
  disabled?: boolean;
@@ -1090,23 +1092,23 @@ declare const ThemeProvider: ({
1090
1092
  }: ThemeProviderProps) => react_jsx_runtime0.JSX.Element;
1091
1093
  //#endregion
1092
1094
  //#region src/index.d.ts
1093
- declare const Accordion: react11.FC<AccordionRootProps> & typeof index_d_exports;
1094
- declare const Alert: react11.FC<AlertRootProps> & typeof index_d_exports$1;
1095
- declare const Card: react11.FC<CardRootProps> & typeof index_d_exports$2;
1096
- declare const DescriptionList: react11.FC<DescriptionListRootProps> & typeof index_d_exports$3;
1097
- declare const Dialog: react11.FC<DialogRootProps> & typeof index_d_exports$4;
1098
- declare const Fieldset: react11.FC<FieldsetRootProps> & typeof index_d_exports$5;
1099
- declare const Grid: react11.FC<GridRootProps> & typeof index_d_exports$6;
1095
+ declare const Accordion: react13.FC<AccordionRootProps> & typeof index_d_exports;
1096
+ declare const Alert: react13.FC<AlertRootProps> & typeof index_d_exports$1;
1097
+ declare const Card: react13.FC<CardRootProps> & typeof index_d_exports$2;
1098
+ declare const DescriptionList: react13.FC<DescriptionListRootProps> & typeof index_d_exports$3;
1099
+ declare const Dialog: react13.FC<DialogRootProps> & typeof index_d_exports$4;
1100
+ declare const Fieldset: react13.FC<FieldsetRootProps> & typeof index_d_exports$5;
1101
+ declare const Grid: react13.FC<GridRootProps> & typeof index_d_exports$6;
1100
1102
  declare const InputPrimitive: (({
1101
1103
  className,
1102
1104
  erroneous,
1103
1105
  ...props
1104
1106
  }: RootProps) => react_jsx_runtime0.JSX.Element) & typeof index_d_exports$7;
1105
- declare const Lists: react11.FC<ListsRootProps> & typeof index_d_exports$8;
1106
- declare const Table: react11.FC<TableRootProps> & typeof index_d_exports$11;
1107
- declare const Progress: react11.FC<ProgressRootProps> & typeof index_d_exports$9;
1108
- declare const Summary: react11.FC<SummaryProps> & typeof index_d_exports$10;
1109
- declare const TaskList: react11.FC<TaskListRootProps> & typeof index_d_exports$12;
1107
+ declare const Lists: react13.FC<ListsRootProps> & typeof index_d_exports$8;
1108
+ declare const Table: react13.FC<TableRootProps> & typeof index_d_exports$11;
1109
+ declare const Progress: react13.FC<ProgressRootProps> & typeof index_d_exports$9;
1110
+ declare const Summary: react13.FC<SummaryProps> & typeof index_d_exports$10;
1111
+ declare const TaskList: react13.FC<TaskListRootProps> & typeof index_d_exports$12;
1110
1112
  //#endregion
1111
1113
  export { Accordion, type AccordionContentProps, type AccordionGroupProps, type AccordionRootProps, type AccordionSummaryProps, Alert, type AlertBodyProps, type AlertHeaderProps, type AlertRootProps, Badge, type BadgeProps, Body, Button, type ButtonProps, Card, type CardBodyProps, type CardContainerProps, type CardFooterProps, type CardHeaderProps, type CardMediaProps, type CardPrelineProps, type CardRootProps, type CardSublineProps, type CardTitleProps, CheckboxInput, type CheckboxInputProps, DateInput, type DateInputProps, DescriptionList, type DescriptionListItemProps, type DescriptionListKeyProps, type DescriptionListRootProps, type DescriptionListValueProps, Dialog, type DialogButtonProps, type DialogContentProps, type DialogFooterProps, type DialogHeaderProps, type DialogModalProps, type DialogRootProps, type DialogTriggerProps, Divider, EmailInput, type EmailInputProps, Fieldset, type FieldsetContentProps, type FieldsetErrorProps, type FieldsetHintProps, type FieldsetLegendProps, type FieldsetRootProps, FileInput, type FileInputProps, Grid, type GridColumnProps, type GridRootProps, type GridRowProps, Heading, Icon, type IconProps, type InputErrorProps, type HintProps as InputHintProps, type LabelProps as InputLabelProps, InputPrimitive, type RootProps as InputRootProps, Kopfzeile, type KopfzeileProps, Label, type LabelProps$1 as LabelProps, Link, LinkButton, type LinkProps, Lists, type ListsBulletProps, type ListsItemProps, type ListsNumberProps, type ListsRootProps, Loader, type LoaderProps, NumberInput, type NumberInputProps, PasswordInput, type PasswordInputProps, Preline, type PrelineProps, Progress, type ProgressBarProps, type ProgressHeaderProps, type ProgressLabelProps, type ProgressRootProps, RadioInput, type RadioInputProps, SelectInput, type SelectInputProps, Subline, type SublineProps, Summary, type SummaryActionsProps, type SummaryBodyProps, type SummaryGroupHeadingProps, type SummaryGroupProps, type SummaryHeadingProps, type SummaryProps, Table, type TableBodyProps, type TableCellProps, type TableColumnProps, type TableFooterProps, type TableHeaderProps, type TableRootProps, type TableRowProps, TaskList, type TaskListHeadingProps, type TaskListItemProps, type TaskListProps, type TaskListRootProps, TelInput, type TelInputProps, TextInput, type TextInputProps, TextareaInput, type TextareaInputProps, type Theme, ThemeProvider, type ThemeProviderProps, Title, type TitleProps, UrlInput, type UrlInputProps };
1112
1114
  //# sourceMappingURL=index.d.ts.map
package/dist/index.js CHANGED
@@ -562,7 +562,7 @@ const _excluded$70 = [
562
562
  "href",
563
563
  "target",
564
564
  "disabled"
565
- ];
565
+ ], _excluded3 = ["type"];
566
566
  const isIconProps = (icon) => typeof icon === "object" && icon !== null && "name" in icon && !React.isValidElement(icon);
567
567
  const IconOnlyLabel = ({ labelText }) => {
568
568
  if (!labelText) return null;
@@ -623,19 +623,19 @@ const Button = React.forwardRef((props, ref) => {
623
623
  !iconLeft && iconElement
624
624
  ] }));
625
625
  }
626
- const buttonRest = rest;
626
+ const _ref2 = rest, { type } = _ref2, buttonRest = _objectWithoutProperties(_ref2, _excluded3);
627
627
  if (iconOnly) {
628
628
  const labelText = text || (isIconProps(icon) ? icon.name : void 0);
629
629
  return /* @__PURE__ */ jsxs("button", _objectSpread2(_objectSpread2({
630
630
  ref,
631
- type: "button",
632
- className: classes
631
+ className: classes,
632
+ type
633
633
  }, buttonRest), {}, { children: [iconElement, /* @__PURE__ */ jsx(IconOnlyLabel, { labelText })] }));
634
634
  }
635
635
  return /* @__PURE__ */ jsxs("button", _objectSpread2(_objectSpread2({
636
636
  ref,
637
- type: "button",
638
- className: classes
637
+ className: classes,
638
+ type
639
639
  }, buttonRest), {}, { children: [
640
640
  iconLeft && iconElement,
641
641
  text && /* @__PURE__ */ jsx("span", {