@popmenu/admin-ui 0.120.0 → 0.121.1

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,3 +1,11 @@
1
1
  import React from 'react';
2
2
  import { ButtonProps } from './ButtonProps';
3
- export declare const Button: React.ForwardRefExoticComponent<Pick<ButtonProps, "variant" | "className" | "style" | "classes" | "innerRef" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "tabIndex" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "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" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "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" | "onClick" | "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" | "form" | "key" | "autoFocus" | "disabled" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "name" | "type" | "value" | "disableElevation" | "fullWidth" | "startIcon" | "endIcon" | "ButtonRef" | "component" | "loading" | "textTransform" | "disableFocusRipple" | "href" | "size" | "action" | "buttonRef" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "onFocusVisible" | "TouchRippleProps"> & React.RefAttributes<HTMLButtonElement>>;
3
+ interface ButtonType {
4
+ <C extends React.ElementType = 'a'>(props: ButtonProps<C> & {
5
+ component?: C;
6
+ }): React.ReactElement;
7
+ defaultProps?: Partial<ButtonProps>;
8
+ displayName?: string;
9
+ }
10
+ export declare const Button: ButtonType;
11
+ export {};
@@ -1,7 +1,8 @@
1
+ import React from 'react';
1
2
  import { ButtonProps as CommonButtonProps } from '@popmenu/common-ui';
2
- export interface ButtonProps extends Omit<CommonButtonProps, 'variant'> {
3
+ export declare type ButtonProps<C extends React.ElementType = 'button'> = Omit<CommonButtonProps<C>, 'variant'> & {
3
4
  loading?: boolean;
4
5
  /** Sets the overall visual of a button according the the design system button variants. Accepts MUI variants and
5
6
  * pre-defined design system variants */
6
7
  variant?: 'primary' | 'secondary' | 'tertiary' | 'ghost' | 'success' | 'info' | 'warning' | 'error' | 'outlined' | 'contained' | 'text';
7
- }
8
+ };
@@ -1,3 +1,11 @@
1
1
  import React from 'react';
2
2
  import { SettingsIndexCardProps } from './SettingsIndexCardProps';
3
- export declare const SettingsIndexCard: React.ForwardRefExoticComponent<SettingsIndexCardProps & React.RefAttributes<HTMLButtonElement>>;
3
+ interface SettingsIndexCardType {
4
+ <C extends React.ElementType = 'a'>(props: SettingsIndexCardProps<C> & {
5
+ component?: C;
6
+ }): React.ReactElement;
7
+ defaultProps?: Partial<SettingsIndexCardProps>;
8
+ displayName?: string;
9
+ }
10
+ export declare const SettingsIndexCard: SettingsIndexCardType;
11
+ export {};
@@ -1,6 +1,9 @@
1
1
  import { ThemeColors } from '@popmenu/common-ui/build/components/Typography/TypographyProps';
2
2
  import React from 'react';
3
- export interface SettingsIndexCardProps {
3
+ import { ButtonBaseProps } from '@material-ui/core';
4
+ export declare type SettingsIndexCardProps<C extends React.ElementType = 'button'> = ButtonBaseProps<C, {
5
+ component?: C;
6
+ }> & {
4
7
  /** The icon from @popmenu/web-icons to be rendered */
5
8
  Icon?: React.FC<React.SVGProps<SVGSVGElement>>;
6
9
  /** Sets the title of the card */
@@ -14,4 +17,4 @@ export interface SettingsIndexCardProps {
14
17
  text: string;
15
18
  color: ThemeColors;
16
19
  };
17
- }
20
+ };
package/build/index.es.js CHANGED
@@ -508,6 +508,8 @@ var getBorder = function (theme) { return function (props) {
508
508
  }
509
509
  return borderColor;
510
510
  }; };
511
+ // using `any` here is a bit of cheating but it doesn't matter since this doesn't depend on
512
+ // any component-specific props
511
513
  makeStyles$1(function (theme) { return ({
512
514
  root: {
513
515
  background: getBackground$1(theme),
@@ -694,6 +696,7 @@ var useLinkStyles = makeStyles$1(function (theme) { return ({
694
696
  },
695
697
  }); });
696
698
 
699
+ // eslint-disable-next-line react/display-name -- false positive
697
700
  var Link = forwardRef(function (props, ref) {
698
701
  var children = props.children, muiProps = __rest(props, ["children"]);
699
702
  var classes = useLinkStyles(props);
@@ -1277,6 +1280,7 @@ var deriveButtonProps = function (buttonProps) {
1277
1280
  return derived;
1278
1281
  };
1279
1282
 
1283
+ // eslint-disable-next-line react/display-name -- false positive
1280
1284
  var Button = forwardRef(function (props, ref) {
1281
1285
  var children = props.children; props.variant; var classesOverride = props.classes, commonProps = __rest$1(props, ["children", "variant", "classes"]);
1282
1286
  var classes = useButtonStyles(props);
@@ -1878,6 +1882,7 @@ var useSettingsIndexCardStyles = makeStyles$1(function (theme) { return ({
1878
1882
  },
1879
1883
  }); });
1880
1884
 
1885
+ // eslint-disable-next-line react/display-name -- false positive
1881
1886
  var SettingsIndexCard = forwardRef(function (props, ref) {
1882
1887
  var title = props.title, description = props.description, Icon$1 = props.Icon, onClick = props.onClick, statusLabel = props.statusLabel, restProps = __rest$1(props, ["title", "description", "Icon", "onClick", "statusLabel"]);
1883
1888
  var classes = useSettingsIndexCardStyles(props);